ComposioHQ/composio
120 source files scanned · 17 LLM call site(s) · ~2% of LLM spend looks recoverable (static heuristics · repo looks like an app)
$70per 10k runs today (claude-sonnet-5, ~2000 prompt tokens)
$68.6per 10k runs with fixes applied

[](https://tokenzero.sh/audit/ComposioHQ/composio)
Models referenced
claude-sonnet-5 ×4 (cheaper sibling: claude-haiku-5-5)gpt-4o ×3 (cheaper sibling: gpt-4o-mini)gpt-5 ×3 (cheaper sibling: gpt-5-mini)gpt-5-mini ×2gpt-4o-mini ×2gpt-4.1 ×2 (cheaper sibling: gpt-4.1-mini)claude-3-opus-20240229 ×1
Findings
| Severity | Where | Finding | Est. |
|---|---|---|---|
| medium | python/providers/openai/openai_responses_demo.py:37 | LLM call inside a loop Per-item calls repeat the full prompt prefix for every element. If items are independent and latency-tolerant, the provider Batch API is 50% cheaper, and OpenAI Flex processing (`service_tier: "flex"`) gives the same 50% on ordinary calls without restructuring; if the prefix is shared, caching pays off immediately. Fix: Batch where possible, or set `service_tier: "flex"` on OpenAI calls that can wait; otherwise keep the shared prefix cache-formatted (TokenZero does this automatically). | 25% |
| medium | python/providers/openai/openai_responses_demo.py:23 | "gpt-5" retires on 2026-12-11 The provider announced on 2026-06-11 that this model retires on 2026-12-11 (46 days). Recommended replacement: gpt-5.6-sol. Fix: Move to gpt-5.6-sol (eval first); TokenZero's cascade can route to it, and the gateway warns in X-TokenZero-Warning until you do. | 0% |
| low | ts/examples/openai/src/hackernews-agent/tool-router.ts:63 | LLM call inside a loop Per-item calls repeat the full prompt prefix for every element. If items are independent and latency-tolerant, the provider Batch API is 50% cheaper, and OpenAI Flex processing (`service_tier: "flex"`) gives the same 50% on ordinary calls without restructuring; if the prefix is shared, caching pays off immediately. Fix: Batch where possible, or set `service_tier: "flex"` on OpenAI calls that can wait; otherwise keep the shared prefix cache-formatted (TokenZero does this automatically). | 25% |
| low | ts/examples/openai/src/hackernews-agent/direct.ts:56 | LLM call inside a loop Per-item calls repeat the full prompt prefix for every element. If items are independent and latency-tolerant, the provider Batch API is 50% cheaper, and OpenAI Flex processing (`service_tier: "flex"`) gives the same 50% on ordinary calls without restructuring; if the prefix is shared, caching pays off immediately. Fix: Batch where possible, or set `service_tier: "flex"` on OpenAI calls that can wait; otherwise keep the shared prefix cache-formatted (TokenZero does this automatically). | 25% |
| low | python/providers/anthropic/anthropic_demo.py:18 | Tool definitions sent without a cache breakpoint Tool schemas render before the system prompt in the cached prefix. Without a breakpoint on the last tool they are billed in full on every call. Fix: TokenZero marks the last tool automatically; manually, add `cache_control` to the last tool definition. | 8% |
| low | ts/examples/openai/src/hackernews-agent/tool-router.ts:63 | "gpt-5-mini" retires on 2026-12-11 The provider announced on 2026-06-11 that this model retires on 2026-12-11 (46 days). Recommended replacement: gpt-5.6-terra. Fix: Move to gpt-5.6-terra (eval first); TokenZero's cascade can route to it, and the gateway warns in X-TokenZero-Warning until you do. | 0% |
| low | ts/examples/openai/src/chat-completions.ts:34 | "gpt-4o" retires on 2027-01-14 The provider announced on 2026-10-14 that this model retires on 2027-01-14 (80 days). Recommended replacement: gpt-6-luna. Fix: Move to gpt-6-luna (eval first); TokenZero's cascade can route to it, and the gateway warns in X-TokenZero-Warning until you do. | 0% |
| low | ts/examples/openai/src/responses-api/experiment.mcp.ts:47 | "gpt-4o-mini" retires on 2027-01-14 The provider announced on 2026-10-14 that this model retires on 2027-01-14 (80 days). Recommended replacement: gpt-6-luna. Fix: Move to gpt-6-luna (eval first); TokenZero's cascade can route to it, and the gateway warns in X-TokenZero-Warning until you do. | 0% |
| low | ts/examples/openai/src/responses-api/index.ts:15 | "gpt-4.1" retires on 2027-01-14 The provider announced on 2026-10-14 that this model retires on 2027-01-14 (80 days). Recommended replacement: gpt-6-luna. Fix: Move to gpt-6-luna (eval first); TokenZero's cascade can route to it, and the gateway warns in X-TokenZero-Warning until you do. | 0% |
| info | ts/examples/anthropic/src/index.ts:45 | Tool definitions sent without a cache breakpoint Tool schemas render before the system prompt in the cached prefix. Without a breakpoint on the last tool they are billed in full on every call. Fix: TokenZero marks the last tool automatically; manually, add `cache_control` to the last tool definition. | 8% |
| info | python/providers/anthropic/anthropic_demo.py:18 | Unrecognised model id "claude-3-opus-20240229" Not in the current pricing table: it may be retired or renamed. Retired models return errors or are silently remapped by some providers. Fix: Check the provider model list; TokenZero flags unpriced models in `X-TokenZero-Warning`. | 0% |
Fix all of it with one line
OPENAI_BASE_URL=https://tokenzero.sh/v1 ANTHROPIC_BASE_URL=https://tokenzero.sh
Keys pass through untouched. Cache formatting and exact caching are on by default; cascade routing stays opt-in. How it works