fix(agents): preserve runtime tools in lean mode#88381
Conversation
|
Codex review: needs maintainer review before merge. Reviewed May 31, 2026, 9:49 AM ET / 13:49 UTC. Summary PR surface: Source +57, Tests +138. Total +195 across 5 files. Reproducibility: yes. Source inspection shows current main forces Review metrics: 1 noteworthy metric.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Land the narrow preserve-through-filtering fix after maintainer review with the focused tests or changed gate refreshed against the final merge result. Do we have a high-confidence way to reproduce the issue? Yes. Source inspection shows current main forces Is this the best way to solve the issue? Yes. Centralizing preserved tool names and threading them through both tool construction and embedded schema projection is a narrow fix for the observed gap without disabling lean filtering. AGENTS.md: found and applied where relevant. Codex review notes: model gpt-5.5, reasoning high; reviewed against 0d17623f0090. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +57, Tests +138. Total +195 across 5 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
63f0e20 to
33d998d
Compare
33d998d to
23f31e8
Compare
23f31e8 to
e4573b6
Compare
e4573b6 to
9502f74
Compare
|
Maintainer verification before merge: Behavior addressed: local-model lean filtering could remove runtime-required tools, including |
…n-rotation-current * origin/main: (52 commits) fix(agents): prevent embedded runtime shadowing fix(outbound): route source replies through configured channels refactor(cron): split tool and doctor repair helpers perf: reduce tui refresh work feat: default exec shell snapshots fix(ui): keep chat usable during session loading fix(cron): guard flat atMs canonicalization refactor(cron): keep runtime on canonical sqlite rows fix(codex): restore bounded recovery continuity refactor: clean up ACP package metadata and helpers (#88659) fix(discord): ping mention-bearing final replies fix(telegram): preserve usage footer for tool-only replies fix(agents): avoid alias setup load for matching refs chore(ui): translate thinking default label fix(agents): preserve runtime tools in lean mode (#88381) fix(messages): use best-effort for implicit tool-only source replies (#84232) docs: raise bulk PR close threshold feat: add exec shell snapshot cache fix: use typed tui empty session defaults perf: speed up tui session refresh ... # Conflicts: # src/tui/tui-command-handlers.test.ts
fix(agents): preserve runtime tools in lean mode Keep runtime-required tools, especially `message`, available when local-model lean filtering is enabled. This preserves `forceMessageTool`, `message_tool_only` source replies, explicit runtime allowlists, and schema projection without disabling lean filtering for ordinary denied tools. Proof: focused Vitest passed 190 tests; `git diff --check origin/main...HEAD` passed; PR CI had no failing or pending checks.
fix(agents): preserve runtime tools in lean mode Keep runtime-required tools, especially `message`, available when local-model lean filtering is enabled. This preserves `forceMessageTool`, `message_tool_only` source replies, explicit runtime allowlists, and schema projection without disabling lean filtering for ordinary denied tools. Proof: focused Vitest passed 190 tests; `git diff --check origin/main...HEAD` passed; PR CI had no failing or pending checks.
fix(agents): preserve runtime tools in lean mode Keep runtime-required tools, especially `message`, available when local-model lean filtering is enabled. This preserves `forceMessageTool`, `message_tool_only` source replies, explicit runtime allowlists, and schema projection without disabling lean filtering for ordinary denied tools. Proof: focused Vitest passed 190 tests; `git diff --check origin/main...HEAD` passed; PR CI had no failing or pending checks.
Summary
localModelLeanfrom stripping runtime-required tools when replies must go through themessagetoolforceMessageToolandsourceReplyDeliveryMode: "message_tool_only"through both tool construction and embedded-run schema projectionVerification
node scripts/run-vitest.mjs src/agents/local-model-lean.test.ts src/agents/agent-tools.create-openclaw-coding-tools.test.ts src/agents/embedded-agent-runner/run/attempt.test.ts --reporter=dotpassed, 190 testsgit diff --check origin/main...HEADpassedpnpm check:changedpassed: provideraws, leasecbx_05e9c25d9687, slugcrimson-hermit, runrun_e0161fcff3cd, machinec7a.8xlarge, exit 0, leaseStopped=trueWhat was not tested