TSCG: Deterministic Tool-Schema Compilation for Agentic LLM Deployments
arXiv cs.AI / 5/7/2026
💬 OpinionDeveloper Stack & InfrastructureTools & Practical UsageModels & Research
Key Points
- The paper argues that common production agent tool protocols (e.g., OpenAI Function Calling, Anthropic Tool Use, MCP) send tool schemas in JSON, which is not ideal for LLM interpretation, and this mismatch drives most tool-use failures at realistic catalog sizes for smaller models.
- It introduces TSCG, a deterministic tool-schema compiler that converts JSON schemas into token-efficient structured text at the API boundary, improving tool-use without requiring model access, fine-tuning, or runtime retrieval.
- Experiments on TSCG-Agentic-Bench (~19,000 calls across 12 models and 5 scenarios) show large accuracy recoveries for Phi-4 14B (from 0% to 84.4% at 20 tools, and 90.3% at 50 tools) and substantial token savings (52–57%).
- The study finds representation change is the dominant mechanism behind the gains, and operator-by-operator analysis reveals different operator-response profiles across frontier models to guide deployment choices.
- The approach generalizes from synthetic benchmarks to real MCP schemas within 0.1 accuracy points and is provided as a small, dependency-free TypeScript package (about 1,200 lines).




