Skip to main content
Version: dev

DeepSeek

Configure DB-GPT to use DeepSeek's language models for chat and reasoning.

Prerequisites​

Install dependencies​

uv sync --all-packages \
--extra "base" \
--extra "proxy_openai" \
--extra "rag" \
--extra "storage_chromadb" \
--extra "dbgpts"
Embedding model

DeepSeek does not provide embedding models. The default config uses a HuggingFace embedding model (BAAI/bge-large-zh-v1.5). If using this, also add:

uv sync --all-packages \
--extra "base" \
--extra "proxy_openai" \
--extra "rag" \
--extra "storage_chromadb" \
--extra "dbgpts" \
--extra "hf" \
--extra "cpu"

Configuration​

Edit configs/dbgpt-proxy-deepseek.toml:

[models]
[[models.llms]]
name = "deepseek-v4-pro"
provider = "proxy/deepseek"
api_key = "your-deepseek-api-key"
# Disable V4-Pro thinking mode for strict ReAct output parsing.
thinking_enabled = false

[[models.embeddings]]
name = "BAAI/bge-large-zh-v1.5"
provider = "hf"
# Uncomment to use a local model path:
# path = "models/bge-large-zh-v1.5"

Available models​

ModelConfig nameNotes
DeepSeek-V4-Prodeepseek-v4-pro1M context, advanced reasoning, coding, and agent tasks
DeepSeek-R1deepseek-reasonerStrong reasoning, chain-of-thought
DeepSeek-V3deepseek-chatGeneral purpose chat

For ReAct agents, keep thinking_enabled = false with deepseek-v4-pro. DeepSeek V4-Pro enables thinking mode by default, which can add reasoning blocks before the strict Thought/Action/Action Input response format.

The official DeepSeek API does not support tool_choice="required" or a named tool choice in thinking mode. The DeepSeek provider automatically disables thinking for these requests before sending them, while preserving the requested tool choice. This also applies when thinking_enabled = true; other requests retain their existing thinking settings. No extra configuration is needed when switching models.

This adaptation applies only to the DeepSeek provider when its actual API endpoint is api.deepseek.com. Other providers and third-party API endpoints retain their existing behavior; their tool-calling capabilities depend on their own API contract.

Start the server​

uv run dbgpt start webserver --config configs/dbgpt-proxy-deepseek.toml

Troubleshooting​

IssueSolution
AuthenticationErrorVerify your DeepSeek API key at platform.deepseek.com
Embedding download slowPre-download the model or use a mirror (UV_INDEX_URL)
Out of memory for embeddingUse --extra "cpu" to run embeddings on CPU

What's next​