[providers.deepseek]
display_name = "DeepSeek"
adapter = "openai_compatible"
api_key_url = "https://platform.deepseek.com/api_keys"
base_url = "https://api.deepseek.com"
priority = 75

[providers.deepseek.auth]
credentials = ["env:DEEPSEEK_API_KEY", "vault:DEEPSEEK_API_KEY"]

# DeepSeek V4 uses thinking mode by default. The API accepts sampling
# parameters in that mode but ignores them, so Fabro omits those parameters.
# Prompt caching is automatic and usage reports prompt_cache_hit_tokens.
# Prices are from api-docs.deepseek.com/quick_start/pricing, verified
# 2026-07-31.

[providers.deepseek.models."deepseek-v4-flash"]
display_name = "DeepSeek V4 Flash"
family = "deepseek-v4"
aliases = ["deepseek-v4", "deepseek", "deepseek-flash"]
# DeepSeek uses a general coding prompt and standard JSON function tools.
agent_profile = "openai"
default = true
small_default = true
probe = true

[providers.deepseek.models."deepseek-v4-flash".limits]
context_window = 1048576
max_output = 384000

[providers.deepseek.models."deepseek-v4-flash".features]
tools = true
vision = false
reasoning = true
reasoning_effort = "levels"
reasoning_by_default = true
prompt_cache = true
sampling_params = false

[providers.deepseek.models."deepseek-v4-flash".controls]
reasoning_effort = ["low", "high", "max"]

[providers.deepseek.models."deepseek-v4-flash".costs]
input_cost_per_mtok = 0.14
output_cost_per_mtok = 0.28
cache_input_cost_per_mtok = 0.0028

[providers.deepseek.models."deepseek-v4-pro"]
display_name = "DeepSeek V4 Pro"
family = "deepseek-v4"
agent_profile = "openai"

[providers.deepseek.models."deepseek-v4-pro".limits]
context_window = 1048576
max_output = 384000

[providers.deepseek.models."deepseek-v4-pro".features]
tools = true
vision = false
reasoning = true
reasoning_effort = "levels"
reasoning_by_default = true
prompt_cache = true
sampling_params = false

[providers.deepseek.models."deepseek-v4-pro".controls]
# V4 Pro currently maps low to high. Keep only its distinct effort levels;
# DeepSeek says it plans to change Pro's mapping in early August 2026.
reasoning_effort = ["high", "max"]

[providers.deepseek.models."deepseek-v4-pro".costs]
input_cost_per_mtok = 0.435
output_cost_per_mtok = 0.87
cache_input_cost_per_mtok = 0.003625
