"Big output go file. Small word stay. Context happy."
Start a new session after installation. That's it.
AI coding agents hit a wall when tool outputs bloat your context. One big test run or log dump eats thousands of tokens that sit there forever. After context summarization, Claude forgets the details you need.
FewWord implements dynamic context discovery — using the filesystem as infinite, searchable memory.
| Output Size | What Happens |
|---|---|
< 512B |
Shown inline (normal behavior) |
512B - 4KB |
Compact pointer only (~35 tokens) |
> 4KB |
Compact pointer + tail preview (failures only) |
Instead of 26,000 tokens of command output, you get ~35 tokens:
For failures, you also get a preview of the last 5 lines:
You: Run the test suite Claude: [26,000 tokens of output] You: Fix the auth bug Claude: [still carrying 26k tokens] You: What tests failed? Claude: [context compacted, details lost]
You: Run the test suite
Claude: [fw A1B2] pytest e=1 45K 234L
FAILED test_auth... (~35 tokens)
You: Fix the auth bug
Claude: [clean context, full output on disk]
You: What tests failed?
Claude: /context-open A1B2
Small outputs inline, medium get compact pointer, large failures get preview. Smart thresholds minimize context while preserving actionable info.
Success outputs retained 24h, failures 48h (you might need those error logs). LRU eviction at 250MB keeps disk tidy.
Track your savings with /fewword-stats. See outputs intercepted, bytes offloaded, and estimated tokens saved per session.
Only logs tool names and parameter keys. Never logs your actual data, secrets, or command arguments.
Quick retrieval with LATEST.txt and LATEST_{cmd}.txt symlinks. No need to remember IDs.
Works automatically after installation. No setup, no configuration files. Just install and go.
Use /context-save to manually offload content with custom labels. Great for API responses, debug data, or any large text.
Export your session history as markdown with /context-export. Perfect for documentation or sharing context.
/context-open <id>
Retrieve an offloaded output by its ID
/context-recent
Show recent offloaded outputs — primary recovery path after context compaction
/fewword-stats
Show session statistics and estimated token savings
/context-pin <id>
Pin an output to prevent auto-cleanup
/context-search <term>
Search through all offloaded context files (use --all-sessions for cross-session search)
/context-save <content>
Manually save arbitrary content to FewWord storage with custom labels
/context-export
Export session history as a markdown report
/fewword-help
Show detailed help and documentation
/fewword-version
Show installed version and check for updates
FewWord checks for updates automatically on session start and notifies you if a new version is available.
Then start a new session for hooks to reload. Disable auto-check with FEWWORD_DISABLE_UPDATE_CHECK=1
FewWord works out of the box, but power users can customize via environment variables:
| Variable | Default | Description |
|---|---|---|
FEWWORD_INLINE_MAX |
512 | Below this: show inline |
FEWWORD_PREVIEW_MIN |
4096 | Above this: add preview (failures) |
FEWWORD_SHOW_PATH |
0 | Set to 1 to show file path in pointer |
FEWWORD_DISABLE |
0 | Set to 1 to disable offloading |