Large tool output
Shortens long command output while keeping errors, failed tests, paths, and commands.
How it works
Install it in opencode and work as usual. TokenWarden shortens large file reads, command output, and old session history before they are sent back to the AI model.
Focused file reads
These tools help opencode avoid sending entire files when a smaller answer is enough.
| Tool | Plain explanation |
|---|---|
smart_read | Reads only the useful parts of one source file. |
smart_pack | Collects the useful parts of several files in one focused result. |
token_report | Shows how many tokens TokenWarden removed and the estimated savings. |
Automatic behavior
Shortens long command output while keeping errors, failed tests, paths, and commands.
Shortens old session history but keeps the goal, changed files, decisions, test status, and next step.
Guides opencode to give short answers with the result, changed files, checks, risks, and blockers.
Important details stay
TokenWarden keeps details that affect the next coding step: