Ran 1 command, searched once, read 1 file1 failed
Searchreasoning_effort 12 matches0.4s
Runcargo test -p topxai claude_code exit code 1018.1s
Readcrates/topxai/src/agents/subagent_model.rs0.1s
Found it: the session’s saved reasoning_effort was carried over unchanged on the switch to Claude Code, and the CLI exits on a level it doesn’t know.
The fix has two parts:
- Drop inherited reasoning parameters for external agents; keep only interaction_mode.
- Pass --effort only for levels the model declares, and never pass default.
rustclaude_code.rs
pub fn without_reasoning_params(&self) -> Self { let mut model = self.clone(); if let Some(params) = model.request_params.as_mut() { params.retain(|key, _| key == "interaction_mode"); } model }
Changed 2 files+18−4View changes
providers/claude_code.rs+14−3
tests/claude_code_effort.rs+4−1
Tests are in, and cargo test -p topxai claude_code passes.
OK, run clippy again, check there are no warnings, then commit.
Ran 1 commandNo warnings
clippy is clean. Committing the fix next.
Needs yougit commitWaited 0:12
Committing needs your OK
Permissions are set to “Ask when risky”, so commits go through you first.
$git commit -am "fix(claude-code): drop inherited reasoning params"
The agent asks: change the 2 spots clippy suggested too?
2 queuedOnce it’s fixed, update the CHANGELOG too.
Keep typing; it queues and sends after this turn
Context38%