Matryoshka is a document analysis tool that reduces LLM token usage by 80% through recursive analysis and caching. Instead of repeatedly sending entire codebases to the LLM, it treats documents as external environments that can be queried incrementally. The tool uses a declarative S-expression query language (Nucleus) and

12m read time From yogthos.net
Post cover image
Table of contents
The Problem: Context Rot and Token CostsPrior Work: Two Key InsightsMatryoshka: Combining the InsightsThe LifecycleHow Agents Discover and Use MatryoshkaReal-World Example: Analyzing anki-connectArchitectureGetting StartedConclusion

Sort: