- Long-running agent
- Many tool calls
- Large tool outputs
- Long conversations
- Context engineWhat I built
- Compress tool results
- Keep last N tool calls
- Count tokens
- Context providers
- Model sees
- Compact context
- Only the tools it needs
The full history stays in the database - only what the model sees gets smaller.
Efficient tool calling
- Tool-result compression: once outputs pile up, agents summarize them instead of re-sending raw tool output every turn.
- Selective tool history: keep only the last few tool exchanges across runs.
- Token counting that works across OpenAI, Anthropic, Bedrock, Gemini and LiteLLM, wired into compression.
- Prototyped “code mode”, where an agent batches many tool calls into one generated Python step - a large cut in tokens per task.
Context providers
- Gmail and Calendar providers with separate read and write sub-agents and minimal scopes.
- Live streaming of sub-agent tool calls to the parent, so frontends can show what’s being looked up.
- Hardened context providers: injectable write tools, query timeouts, and Git access that keeps tokens off disk.