Skip to content

feat: 配置同步增强 + AI 推理参数重构#50

Merged
69gg merged 7 commits intomainfrom
bugfix/bugs-4
Mar 14, 2026
Merged

feat: 配置同步增强 + AI 推理参数重构#50
69gg merged 7 commits intomainfrom
bugfix/bugs-4

Conversation

@69gg
Copy link
Owner

@69gg 69gg commented Mar 14, 2026

主要变更

配置系统

  • 模板同步支持清理多余配置项sync_config_template.py 新增 --prune 参数,可自动移除用户配置中已废弃的配置项
  • WebUI 配置同步增强:前端配置表单和后端同步逻辑支持 prune 模式

AI 推理参数

  • 重构 thinking effort 参数:合并 thinking_effortreasoning_effort,统一推理控制
  • 重命名参数reasoning_effort_stylereasoning_effort(向后兼容)
  • 支持双模式:extended thinking(Claude)+ adaptive thinking(通用)
  • 完善测试覆盖:新增 test_llm_request_params.py 测试推理参数传递

文档

  • 优化 /naga 命令说明文档

测试

  • ✅ 所有单元测试通过
  • ✅ mypy strict 类型检查通过
  • ✅ ruff format + check 通过

影响范围

  • 配置模板同步脚本
  • AI 模型请求参数处理
  • WebUI 配置管理界面

Open with Devin

69gg and others added 4 commits March 14, 2026 16:15
为 Chat Completions 和 Responses API 统一 thinking 参数构建逻辑:
- 新增 thinking_effort / thinking_effort_style 配置字段,支持 OpenAI(reasoning.effort)和 Anthropic(output_config.effort)两种传参风格
- thinking_effort 非空时使用 adaptive 模式,否则回退 legacy budget_tokens 模式
- WebUI reasoning_effort 改为手动输入,新增 thinking_effort_style 下拉选项

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ort_style

移除独立的 thinking_effort 字段,复用 reasoning_effort 控制 adaptive thinking:
reasoning_enabled=True 时自动启用 adaptive 模式并根据 reasoning_effort_style
决定 effort 传参路径(openai → reasoning / anthropic → output_config)。
同时移除 reasoning_effort 的固定值校验,允许用户填写任意值。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
sync_config_template.py 新增 --prune 选项,列出并删除存在于 config.toml
但不存在于 config.toml.example 中的配置项,需二次确认。
WebUI 同步模板后若检测到多余项也会弹窗询问是否清理。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@chatgpt-codex-connector
Copy link

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

devin-ai-integration[bot]

This comment was marked as resolved.

@69gg 69gg merged commit 8752ad1 into main Mar 14, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant