mirror of
https://github.com/lWolvesl/claw-code.git
synced 2026-04-02 20:51:52 +08:00
The runtime now auto-compacts completed conversations once cumulative input usage crosses a configurable threshold, preserving recent context while surfacing an explicit user notice. The CLI also publishes the requested ant-only slash commands through the shared commands crate and main dispatch, using meaningful local implementations for commit/PR/issue/teleport/debug workflows. Constraint: Reuse the existing Rust compaction pipeline instead of introducing a new summarization stack Constraint: No new dependencies or broad command-framework rewrite Rejected: Implement API-driven compaction inside ConversationRuntime now | too much new plumbing for this delivery Rejected: Expose new commands as parse-only stubs | would not satisfy the requested command availability Confidence: medium Scope-risk: moderate Reversibility: clean Directive: If runtime later gains true API-backed compaction, preserve the TurnSummary auto-compaction metadata shape so CLI call sites stay stable Tested: cargo test; cargo build --release; cargo fmt --all; git diff --check; LSP diagnostics directory check Not-tested: Live Anthropic-backed specialist command flows; gh-authenticated PR/issue creation in a real repo