Tool selection in the OpenAI Agents SDK is model-driven. Each function tool exposes structured metadata that gives the model enough information to determine whether the tool is appropriate and how it should be invoked. The SDK represents a function tool using a name , description , and JSON parameter schema . OpenAI's SDK reference explicitly defines these properties as information shown to the LLM, while function-tool helpers automatically generate the parameter schema from the Python function signature and derive descriptions from documentation when available.
During an agent run, the model evaluates the user's request together with the available tool definitions. It can then select an appropriate tool and generate arguments conforming to that tool's schema. This mechanism is fundamentally semantic and contextual: meaningful names and descriptions tell the model what a tool does, while schemas describe the arguments required to execute it.
There is no rule requiring the first registered tool to be selected, every tool to be invoked, or random selection. Such behavior would undermine agentic reasoning and dynamic orchestration. Consequently, B is the technically correct answer and is explicitly identified as correct in the uploaded question set.
Study Guide reference/topic: OpenAI Responses API and Agents SDK — Function Tools, tool metadata, JSON schemas, tool selection, and model-driven invocation.
===============
Submit