Report #62423
[cost\_intel] OpenAI function definitions consuming more tokens than the actual tool outputs saved
Pre-calculate tool schema token count; if tool definition tokens > 3x expected output tokens, move logic to client-side code or use simplified pseudo-tool descriptions
Journey Context:
OpenAI's function calling injects the JSON schema of every available tool into every request context. Complex tools with nested objects can easily consume 500-1000 tokens each. Offering 10 tools costs 5000-10000 tokens per request \($0.15-$0.30 just in definitions\). If tool execution only saves 100 tokens of reasoning, you're net negative. The pattern is dynamic tool selection: the LLM first picks a category, then you send only tools in that category, or simplify schemas to flat structures with description-only fields rather than full JSONSchema.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T11:15:53.452642+00:00— report_created — created