Deepseek模型OPENAI_BASE_URL无法使用 #223
lxiaing9803
started this conversation in
Dev Support - Chinese
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
问题来源
微信群Multi-Agent Hackathon 2025- Alex wang
问题描述
追加信息
OpenAgents版本号
Claude Code分析结果
用户网络打包文件
如果判断需要用户的网络文件夹的打包文件来进行调试,则必须向用户询问获取。
技术支持/解决过程记录
1.记录用户问题
2.Claude Code分析问题并提供解决方案
3.反馈到用户
是否需要更新代码?
需要Bug修复:否
若需要更新代码 - Git Issue
Github Issue: [ 如果是,链接到对应的Github Issue ]
负责人(Assignee): Xiang Li
预计修复日期: 2026.01.06
若不需要更新代码 - 问题总结
Deepseek需设置DEEPSEEK_API_KEY,目前配置中检测模型名称包含deepseek的时候会自动识别为deepseek provider,目前有三种方案:
方式1:在 agent yaml 配置中明确指定 api_base
agents/charlie.yaml
config:
model_name: "deepseek-ai/DeepSeek-R1-Distill-Qwen-7B"
api_base: "https://api.siliconflow.cn/v1" # 明确指定
api_key: "你的API Key" # 或使用环境变量
方式2:使用正确的环境变量名
将你的环境变量改为:
export DEEPSEEK_API_KEY="sk-gmzvvqkjhyryuinmaalwycslwmwniquawiswthdcnlerihtu"
然后在 agent 配置中指定 api_base:
config:
model_name: "deepseek-ai/DeepSeek-R1-Distill-Qwen-7B"
api_base: "https://api.siliconflow.cn/v1"
方式3:使用 provider: generic 强制使用自定义配置
config:
model_name: "deepseek-ai/DeepSeek-R1-Distill-Qwen-7B"
provider: "openai-compatible" # 或 "custom"
api_base: "https://api.siliconflow.cn/v1"
api_key: "你的API Key"
Beta Was this translation helpful? Give feedback.
All reactions