Key Features:
- Prompt Compression: Rewrites bloated prompts into lean equivalents, maintaining the original instruction while significantly reducing token count.
- Context Pruning: Strips unnecessary elements like dead files and repeated boilerplate from the context window, focusing on relevant information.
- Tool-Output Trimming: Shrinks oversized tool results to include only the essential lines needed for the task.
- Drop-in Proxy: Acts as a middleware between your agent and the model, requiring minimal rewiring and no SDK swaps.
- Agent Compatibility: Works seamlessly with Claude Code and any agent that communicates via the model API.
- Token Analytics: Provides insights into what was cut and the savings achieved per run.
- Meaning Preservation: Paraphrases input to retain meaning while reducing token count, ensuring the same model and parameters yield comparable results.
- Semantic Deduplication: Collapses repeated file contents and similar conversational turns within a session.
- Streaming-Safe: Trims input without disrupting token streaming, tool calls, or the agent loop.
tokenolo is an optimizing CLI designed to sit between your coding agent and the AI model. It intelligently shrinks prompts, context, and tool outputs before they reach the model, leading to significant cost savings and improved efficiency. By reducing the input token count, tokenolo ensures you use the same models and achieve comparable results at a fraction of the cost. It's built for engineers who want to streamline their AI interactions without complex setup, offering a drop-in solution that integrates smoothly into existing workflows.
The tool offers features like prompt compression, context pruning, and tool-output trimming to make inputs lean. It also provides token analytics to track savings and semantic deduplication to remove redundancy. tokenolo is designed to be streaming-safe and compatible with various agents, including Claude Code.