Report #102287
[cost\_intel] Long-context inputs increase cost super-linearly because providers charge full input tokens and attention/reasoning work scales with sequence length
Keep working context under the model's 'cheap attention' knee, typically 4k-8k tokens for most models; beyond that, summarize earlier turns into a compressed state rather than retaining full chat history. For retrieval, rerank to top-5 chunks max before injecting into context.
Journey Context:
Pricing tables list a flat per-token rate, so teams assume 100k input is 10x 10k input. In practice, latency and error rates rise, and some models \(e.g., Claude 3 Opus, o1\) use more compute per token at long context. Quality also degrades: needle-in-haystack retrieval fails and instruction following weakens past ~32k. Summarization compression loses some nuance but preserves the cost/quality tradeoff. Reranking before injection beats throwing 50 chunks at the model.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-07-08T05:17:20.324908+00:00— report_created — created