Command Palette

Search for a command to run...

UnylyUnyly

Claude Code 接入第三方模型 vs claude-api

Сравнение двух Agent Skills бок о бок. Выбери подходящий для Claude Code или Claude Desktop.

Claude Code 接入第三方模型

把本地 Claude Code 接到第三方端点——分两路:① 原生 Anthropic 兼容端点(DeepSeek / Kimi / GLM)直接改 ANTHROPIC_BASE_URL;② 只有 OpenAI 兼容端点的模型(Space Bunny / 各类 stealth 模型)必须加本地网关做…

claude-api

Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…

Сравнение

ПараметрClaude Code 接入第三方模型claude-api
Скриптыестьнет
Разрешённые инструментылюбыелюбые
Тип установкиpersonalpersonal
Категорияcodingcoding
Проверен—
ЛицензияMITComplete terms in LICENSE.txt
АвторoracisAnthropic
Repo—anthropics/skills

Когда брать Claude Code 接入第三方模型

把本地 Claude Code 接到第三方端点——分两路:① 原生 Anthropic 兼容端点(DeepSeek / Kimi / GLM)直接改 ANTHROPIC_BASE_URL;② 只有 OpenAI 兼容端点的模型(Space Bunny / 各类 stealth 模型)必须加本地网关做 Anthropic→OpenAI 协议转换 —— **用自建零依赖 `ccproxy.py`**(claude-code-router 2.1.1 的流式 SSE 输出畸形、已弃用)。并诊断「模型名写对了却不生效」「配置被别处覆盖」「未知模型告警」「连第三方后变慢」「API Error: The response stream was malformed」五类问题。当用户说「给 claude code 配置 deepseek/别的模型」「claude code 换模型不生效」「ANTHROPIC_BASE_URL 怎么设」「unrecognized_model 警告」「claude code 连 deepseek 很慢」「effort 设多少」「要不要开 max」「把 OpenRouter 上的某某模型接进 claude code」「space bunny 怎么接」「响应流畸形/回答不完整/流式报错」「网关 502 / WinError 10054 刷屏」「error code 1010」「It may not exist or you may not have access to it」「卡住不动」「Bash 工具卡住」「auto mode cannot determine the safety of Bash」「大 payload 变慢」时使用。也覆盖**多 profile 一键切换**(`ccswitch.py`:「切 deepseek」「切 space bunny」「现在什么模型」)。含模型 ID 实测法、配置优先级判定法、Windows 注册表排查、用本地中继抓真实请求做性能归因、claude-code-router 的 config-router.json 文件名陷阱、自建网关的规范 SSE 生成法与客户端令牌鉴权。也覆盖**把模型配进 WorkBuddy 客户端**(`~/.workbuddy/models.json`)——含「`apiKey` 留空会被回落成平台 token 导致上游 401 / 错误码 3001」这一最易踩坑的诊断与修法。

Когда брать claude-api

Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER — read BEFORE opening the target file; don't skip because it "looks like a one-liner" — whenever: the prompt names Claude/Anthropic in any form (Claude, Anthropic, Fable, Opus, Sonnet, Haiku, `anthropic`, `@anthropic-ai`, `claude-*`, `us.anthropic.*`, `[1m]`); the user asks about an LLM (pricing/model choice/limits/caching) — never answer from memory; OR the task is LLM-shaped with provider unstated (agent/MCP/tool-definition/multi-agent/RAG/LLM-judge/computer-use; generate/summarize/extract/classify/rewrite/converse over NL; debugging refusals/cutoffs/streaming/tool-calls/tokens). SKIP only when another provider is being worked on (overrides all triggers): OpenAI/GPT/Gemini/Llama/Mistral/Cohere/Ollama named in the query; OR `grep -rE 'openai|langchain_openai|google.generativeai|genai|mistralai|cohere|ollama'` over the project hits (run this grep FIRST if no provider named — don't Read the file).

Ищешь другое? Все скиллы.