第一次提交
This commit is contained in:
96
DeepSeek配置完成.md
Normal file
96
DeepSeek配置完成.md
Normal file
@@ -0,0 +1,96 @@
|
||||
# DeepSeek配置完成 ✅
|
||||
|
||||
## 配置信息
|
||||
|
||||
- **API Key**: `sk-fdf7cc1c73504e628ec0119b7e11b8cc` (已配置)
|
||||
- **Base URL**: `https://api.deepseek.com` (已配置)
|
||||
|
||||
## 配置位置
|
||||
|
||||
### 1. Docker Compose环境变量
|
||||
|
||||
已在 `docker-compose.dev.yml` 中配置:
|
||||
|
||||
```yaml
|
||||
backend:
|
||||
environment:
|
||||
- DEEPSEEK_API_KEY=sk-fdf7cc1c73504e628ec0119b7e11b8cc
|
||||
- DEEPSEEK_BASE_URL=https://api.deepseek.com
|
||||
```
|
||||
|
||||
### 2. 后端服务状态
|
||||
|
||||
- ✅ 后端服务已重启
|
||||
- ✅ DeepSeek API Key已加载
|
||||
- ✅ DeepSeek客户端已初始化
|
||||
|
||||
## 测试步骤
|
||||
|
||||
### 1. 创建工作流
|
||||
|
||||
1. 打开工作流设计器
|
||||
2. 添加LLM节点
|
||||
3. 配置节点:
|
||||
- **提供商**: 选择 "DeepSeek"
|
||||
- **模型**: 选择 "DeepSeek Chat" 或 "DeepSeek Coder"
|
||||
- **提示词**: 输入测试提示词,如 `请用一句话总结:{input}`
|
||||
- **温度**: 0.7
|
||||
|
||||
### 2. 执行测试
|
||||
|
||||
输入测试数据:
|
||||
```json
|
||||
{
|
||||
"input": "人工智能是计算机科学的一个分支"
|
||||
}
|
||||
```
|
||||
|
||||
### 3. 验证结果
|
||||
|
||||
- ✅ 执行成功
|
||||
- ✅ 返回DeepSeek的响应
|
||||
- ✅ 无错误信息
|
||||
|
||||
## 支持的模型
|
||||
|
||||
- **DeepSeek Chat** (`deepseek-chat`): 通用对话模型
|
||||
- **DeepSeek Coder** (`deepseek-coder`): 代码生成模型
|
||||
|
||||
## 注意事项
|
||||
|
||||
1. **API Key安全**:
|
||||
- API Key已保存在配置文件中
|
||||
- 请勿将API Key提交到Git仓库
|
||||
- 建议将`.env`文件添加到`.gitignore`
|
||||
|
||||
2. **费用**:
|
||||
- DeepSeek按使用量计费
|
||||
- 请注意控制调用频率
|
||||
|
||||
3. **网络**:
|
||||
- 确保服务器可以访问 `https://api.deepseek.com`
|
||||
- 如有防火墙,请开放相应端口
|
||||
|
||||
## 故障排查
|
||||
|
||||
如果遇到问题,可以:
|
||||
|
||||
1. **检查配置**:
|
||||
```bash
|
||||
docker-compose -f docker-compose.dev.yml exec backend python -c "from app.core.config import settings; print('DeepSeek API Key:', settings.DEEPSEEK_API_KEY[:15] + '...' if settings.DEEPSEEK_API_KEY else '未配置')"
|
||||
```
|
||||
|
||||
2. **查看日志**:
|
||||
```bash
|
||||
docker-compose -f docker-compose.dev.yml logs --tail=50 backend
|
||||
```
|
||||
|
||||
3. **重启服务**:
|
||||
```bash
|
||||
docker-compose -f docker-compose.dev.yml restart backend
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
**配置时间**: 2024年
|
||||
**状态**: ✅ 已配置并验证
|
||||
Reference in New Issue
Block a user