Repository navigation
fix(config): O93 agent.reasoningBudget 支持 config set/show/env - #98
Merged
Merged
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Help (en/zh) explains meaning and cost/latency; text config show lists value+source; untrusted projects drop reasoningBudget with the usual skipped-settings tip; empty set lists off|adaptive|high; invalid MOSS_REASONING_BUDGET warns once (stderr + configWarnings) then falls back.
Untrusted folders keep a project agent.reasoningBudget when it is <= the user effective value (unset user => adaptive); a raise is dropped into ignoredProjectRouting so config show, -p, and TUI startup share the same untrusted-folder notice. Help clarifies off = do not escalate (not disable provider thinking). QA cases + revert-red covered in test/config-reasoning-budget-o93.spec.mjs.
This was referenced Oct 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
O93:
moss config set agent.reasoningBudget把原先只能靠
MOSS_REASONING_BUDGET设置的推理档位,接到配置面(set/unset/show/env/help),并补齐不受信项目「只许调低」规则。合门
config --help:说明含义、可选值off|adaptive|high、耗时/费用;并写明 off = 不把预算升到 high,不是关掉模型自带推理。config show:显示推理强度当前值与来源(不只--json)。off < adaptive < high):用户有效值 = 用户配置,未设视为默认adaptive。项目值 ≤ 用户有效值 → 生效(来源 project);项目值 > 用户有效值 → 丢弃并记入ignoredProjectRouting。受信不受限。MOSS_REASONING_BUDGET仍最高优先。提示走现有 untrusted-folder notice(config show /-p/ TUI 启动同一套;每文件夹对同一提示行只打一次)。config set agent.reasoningBudget:报错列出off|adaptive|high。MOSS_REASONING_BUDGET=max):stderr 一次警告 +configWarnings,再回落配置/默认。出站字段(QA 抓包佐证,非阻塞)
reasoningBudget字段名。MOSS_REASONING_BUDGET同一条路径:在agent-loop-llm-call里把档位落实为每次调用的reasoning(ThinkingLevel),再经pi-ai-adapter放进出站 stream options 的reasoning。high:强制reasoning: "high"。adaptive:在验证失败/回合出错等压力下,若本轮已有配置的推理档,可升到high。off:不升档,保留模型/会话已有推理档;不是关闭 provider 原生 thinking。MOSS_REASONING_BUDGET=high与moss config set agent.reasoningBudget high出站reasoning应一致;off在压力场景下不应再被升到high。测试
test/config-reasoning-budget-o93.spec.mjs:QA1 不受信 project off + 用户 high → off;QA2/2b/2c 不受信 project high + 用户未设 → adaptive +-p/TUI 提示含reasoningBudget;QA3 受信 high;QA4 env 压过项目。撤掉「只许调低」比较后相关用例变红。全量npm test353 绿。