PRODUCTION SCENARIO
Your logistics assistant aggregates 240 tools from five MCP-backed services, and different requests genuinely reach different corners of that catalog. To save context the team added the regex tool search tool and then set defer_loading to true on every entry in the tools array, the tool search tool included. No tool in the request carries cache_control. Every request now fails with a 400 invalid_request_error.
What change makes the requests valid again?
Answering here is anonymous. Nothing is saved unless you sign in.
Show answer and explanation
Answer: Leave the tool search tool itself non-deferred so one definition loads into context up front
A request where every tool is deferred is rejected, because the search tool has to be in context for the model to have anything to search the catalog with; keeping the three to five most-used tools loaded as well saves a search step. Moving the cache breakpoint is the fix for a different 400, the one a deferred tool carrying cache_control produces, and no tool in this request carries it. The BM25 variant is the right switch when regex patterns are missing tools a natural-language query would find; it changes the query format, not the loading rule. A small fixed toolset is the documented better fit below about ten tools, and requests here reach across 240.