Evelyn Harbor OS
Master Dashboard 01. Prompt Repository 02. Prompt Inspector 03. 5-Layer Meta Matrix 04. KV-Cache Calculator 05. Evaluation Rubrics 06. Agent Memory Bridge
Relational Database 03: KV-Cache Calculator

Token Multiplier Law in Agentic Tool Loops

Total Tokens = N × Prompt + ∑(Output_i × (N - i)). Unbounded 15 KB tool outputs compound to 5.4 Million tokens over 60 steps. Bounded head piping saves 77% ($12.54 per session).

Real-World Tool Output Token Compounding Benchmark 77.1% Overall Savings
Agent Task / Tool Type Raw Output Size Compounded Input Cost (60 Steps) With Bounded Pipe (cap-tool) Total Savings
Git Log / Commit History Dumps 150 KB (38k tokens) 1,824,000 tokens ($5.47) 9,600 tokens ($0.03) 99.4% Saved
Database SQL Select Queries 40 KB (10.5k tokens) 504,000 tokens ($1.51) 12,000 tokens ($0.04) 97.6% Saved
Raw HTML DOM Extraction 80 KB (21k tokens) 1,008,000 tokens ($3.02) 14,400 tokens ($0.04) 98.5% Saved
Test Suite Pytest Verbose Output 25 KB (6.5k tokens) 312,000 tokens ($0.94) 7,200 tokens ($0.02) 97.7% Saved
File Tree Searches (find / grep) 30 KB (7.8k tokens) 374,400 tokens ($1.12) 6,000 tokens ($0.02) 98.4% Saved
60-Step Full Autonomous Engineering Run 341.8 KB (88k tokens) 5,420,000 tokens ($16.26) 1,240,000 tokens ($3.72) 77.1% Total Run Savings