Claude Code 接入第三方模型:配置与官方支持边界
第三方 Anthropic 兼容网关工作流在 Claude Code 里能做什么,以及绝不能夸大的 Anthropic 官方支持边界。
Claude Code 接入第三方模型:配置与官方支持边界
本文关于Claude Code with Third-Party Models: Configuration and Official Support Boundary的所有数字,都直接对照 HuggingFace API 与对应仓库的原始 config.json 核实,采样时间为 2026 年 11 月。不编造跑分、价格或仓库名;config 无法证明的部分一律标注「需实测」。
30 秒版本
Anthropic officially supports Claude models; a third-party gateway is not the same thing. Only Chinese open models are served through that compatible endpoint
已核实的规格
| Item | Value | Notes |
|---|---|---|
| Official Anthropic support | Claude models | Not non-Claude models |
| Third-party gateway workflow | User-side configuration | Not an official feature |
| Anthropic-compatible endpoint | EXAIV /api/ai/v1/anthropic/messages | OpenAI-compatible chat endpoint also exists |
| Callable IDs | glm-5.3-flash, kimi-k3, deepseek-v4.1-flash | Follow the live catalog |
| Environment variables | Check the official Claude Code docs | Do not invent names |
| Streaming | Standard OpenAI-compatible format | Works on the gateway endpoint |
| Licence and terms | Vendor-specific | Anthropic terms for Claude Code |
| Support boundary | Read the official documentation | Never overstate |
数字能证明什么
多模态措辞最容易夸大,所以事实与断言必须分开:官方 config 里的 vision_config 与 image_placeholder 能证明这是带视觉输入能力的条件生成架构,但本身不能证明视频生成、某种具体请求格式或某项跑分。HuggingFace 的 image-text-to-text 标签描述的是输入方向。最终以官方模型卡为准。
Deployment and configuration reality
显存规划对所有万亿级 MoE 一样:算力按激活参数算,显存按总参数算。1T 模型即使 4-bit,权重本身也约需 500GB,2.78T 更大,属于多卡服务器场景,不是单张消费卡能跑的。单卡请看轻量家族。本地路径是 vLLM 或 SGLang 配官方权重;社区转换文件先核对来源与量化标签。
可用边界
在 EXAIV 上,一切以 /models 实时目录为准:目前只有 kimi-k3 可调用,端点是 https://exaiv.com/api/ai/v1 的 OpenAI 兼容接口。接入只改 base_url、api_key、model 三项,流式与工具调用保持标准格式。价格一律以实时 /pricing 为准,本文不写死。建议记录模型 ID、token 数与延迟,日后换模型才有同一套基线。
场景选择
| 场景 | 建议 |
|---|---|
| Use Claude Code as documented | Official Anthropic setup |
| Experiment with a third-party gateway | User-side configuration only |
| Need guaranteed compatibility | Official documentation |
| Call a Chinese open model | EXAIV OpenAI-compatible endpoint |
| Need verified third-party support | Ask the gateway provider |
| Check a specific model ID | The live /models catalog |
| Publish a setup guide | State the support boundary explicitly |
| Confirm pricing | The live /pricing page |
FAQ
EXAIV 上该用哪个模型 ID?
本文数字核实过吗?
config 能证明视频生成吗?
需要换 SDK 吗?
价格在哪里看?
能用本地权重吗?
相关阅读
- Kimi K3 API guide — first API call
- hy4 model selection guide — sizing and selection
- GLM model pages — catalog and specs
- Claude Code third-party API — Anthropic compatible endpoint
- pricing — live credit packs
数据来源
参数与文件数据为 2026 年 11 月采样,随时间变化。