diff --git a/README.md b/README.md index c3fe6827..5fa3455c 100644 --- a/README.md +++ b/README.md @@ -60,7 +60,7 @@ TradingAgentsX 支援業界領先的多家 LLM 提供商,並為每個模型配 | 提供商 | 支援模型 | Base URL | 是否支援自訂端點 | | ------------------ | ------------------------------------------------------------------------------------------------ | --------------------------------------------------------- | ---------------- | | **OpenAI** | GPT-5.1, GPT-5 Mini/Nano, GPT-4.1 Mini/Nano, o4-mini | `https://api.openai.com/v1` | ✅ 是 | -| **Anthropic** | Claude Haiku 4.5, Claude Sonnet 4.5/4.0, Claude 3.5 Haiku, Claude 3 Haiku | `https://api.anthropic.com/v1/` | ✅ 是 | +| **Anthropic** | Claude Haiku 4.5, Claude Sonnet 4.5/4.0, Claude 3.5 Haiku, Claude 3 Haiku | `https://api.anthropic.com` | ✅ 是 | | **Gemini** | Gemini 2.5 Pro, Gemini 2.5 Flash, Gemini 2.5 Flash Lite, Gemini 2.0 Flash, Gemini 2.0 Flash Lite | `https://generativelanguage.googleapis.com/v1beta/openai` | ✅ 是 | | **Grok (xAI)** | Grok-4.1 Fast, Grok-4 Fast, Grok-4, Grok-3, Grok-3 Mini | `https://api.x.ai/v1` | ✅ 是 | | **DeepSeek** | DeepSeek Reasoner, DeepSeek Chat | `https://api.deepseek.com/v1` | ✅ 是 | @@ -483,7 +483,7 @@ docker compose down -v 快速思維 API Key: sk-your-openai-key 深層思維模型: claude-sonnet-4-5 - 深層思維 Base URL: https://api.anthropic.com/v1/ + 深層思維 Base URL: https://api.anthropic.com 深層思維 API Key: sk-ant-your-claude-key 嵌入模型 Base URL: 自訂 → https://api.your-embedding-service.com/v1 @@ -571,7 +571,7 @@ curl -X POST http://localhost:8000/api/analyze \ "quick_think_llm": "gpt-5-mini-2025-08-07", "analysts": ["market", "sentiment", "news", "fundamental"], "quick_think_base_url": "https://api.openai.com/v1", - "deep_think_base_url": "https://api.anthropic.com/v1/", + "deep_think_base_url": "https://api.anthropic.com", "embedding_base_url": "https://api.openai.com/v1", "quick_think_api_key": "sk-your-openai-key", "deep_think_api_key": "sk-ant-your-claude-key", diff --git a/cli/utils.py b/cli/utils.py index f807a199..8365008a 100644 --- a/cli/utils.py +++ b/cli/utils.py @@ -428,7 +428,7 @@ def select_llm_provider() -> tuple[str, str]: # 定義 LLM 供應商及其 API 基礎 URL BASE_URLS = [ ("OpenAI", "https://api.openai.com/v1"), - ("Anthropic", "https://api.anthropic.com/v1/"), + ("Anthropic", "https://api.anthropic.com"), ("Google", "https://generativelanguage.googleapis.com/v1beta/openai"), ("Grok", "https://api.x.ai/v1"), ("DeepSeek", "https://api.deepseek.com/v1"), diff --git a/frontend/components/analysis/AnalysisForm.tsx b/frontend/components/analysis/AnalysisForm.tsx index 37af95d8..15480c72 100644 --- a/frontend/components/analysis/AnalysisForm.tsx +++ b/frontend/components/analysis/AnalysisForm.tsx @@ -516,7 +516,7 @@ export function AnalysisForm({ onSubmit, loading = false }: AnalysisFormProps) { defaultValue={ [ "https://api.openai.com/v1", - "https://api.anthropic.com/v1/", + "https://api.anthropic.com", "https://api.x.ai/v1", "https://api.deepseek.com/v1", "https://dashscope-intl.aliyuncs.com/compatible-mode/v1", @@ -534,7 +534,7 @@ export function AnalysisForm({ onSubmit, loading = false }: AnalysisFormProps) { OpenAI (預設) - + Anthropic @@ -555,7 +555,7 @@ export function AnalysisForm({ onSubmit, loading = false }: AnalysisFormProps) { {(![ "https://api.openai.com/v1", - "https://api.anthropic.com/v1/", + "https://api.anthropic.com", "https://generativelanguage.googleapis.com/v1beta/openai", "https://api.x.ai/v1", "https://api.deepseek.com/v1", @@ -615,7 +615,7 @@ export function AnalysisForm({ onSubmit, loading = false }: AnalysisFormProps) { defaultValue={ [ "https://api.openai.com/v1", - "https://api.anthropic.com/v1/", + "https://api.anthropic.com", "https://api.x.ai/v1", "https://api.deepseek.com/v1", "https://dashscope-intl.aliyuncs.com/compatible-mode/v1", @@ -633,7 +633,7 @@ export function AnalysisForm({ onSubmit, loading = false }: AnalysisFormProps) { OpenAI (預設) - + Anthropic @@ -654,7 +654,7 @@ export function AnalysisForm({ onSubmit, loading = false }: AnalysisFormProps) { {(![ "https://api.openai.com/v1", - "https://api.anthropic.com/v1/", + "https://api.anthropic.com", "https://generativelanguage.googleapis.com/v1beta/openai", "https://api.x.ai/v1", "https://api.deepseek.com/v1",