LLM支持优化

This commit is contained in:
2026-05-26 17:43:42 +08:00
parent a08bc809bb
commit 4331b9306e
26 changed files with 2309 additions and 669 deletions

View File

@@ -111,9 +111,13 @@ pub struct LlmConfig {
#[serde(default)]
pub api_key: Option<String>,
/// Enable thinking/reasoning mode (deepseek, kimi)
/// Enable thinking/reasoning mode (deepseek, kimi, anthropic)
#[serde(default)]
pub thinking_enabled: bool,
/// Budget tokens for thinking mode (Anthropic Claude 4)
#[serde(default)]
pub thinking_budget_tokens: Option<u32>,
}
fn default_api_key_storage() -> String {
@@ -132,6 +136,7 @@ impl Default for LlmConfig {
api_key_storage: default_api_key_storage(),
api_key: None,
thinking_enabled: false,
thinking_budget_tokens: None,
}
}
}