Tool schemas and the validation of arguments
A tool schema steers the model and checks the call — two jobs, one contract.

Tool use — also called function calling — is how a model asks your code to act. Anthropic’s overview states that “Tool use (also called function calling) lets Claude call functions that you define or that Anthropic provides”, and that the model “returns a structured call that your application executes (client tools) or that Anthropic executes (server tools).” OpenAI’s guide supplies the other half of the contract: “A function is a specific kind of tool, defined by a JSON schema.”
Those two statements describe two jobs that one artefact — the tool schema — must do at once. It steers the model’s generation, and it validates the arguments that come back. The first is probabilistic; the second is a check your code runs, and the only one you control. Reading the schema as one thing rather than two is where tool integration usually goes wrong.
The call is a value, not a proof
A tool call is a structured message the model emits. Anthropic describes the round trip: “Claude responds with stop_reason: "tool_use" and one or more tool_use blocks. Your code executes the operation and sends back a tool_result.” The arguments are generated tokens, not typed values — OpenAI’s streaming note speaks of “the model fills its arguments”. A call is therefore a proposal: the schema says what a well-formed proposal looks like.
Shape and truth are separate properties. Anthropic documents that when “the user’s prompt doesn’t include
enough information to fill all the required parameters for a tool”, a model “might also infer a reasonable
value”: its example is a weather tool requiring a location returning
{"location": "New York, NY", "unit": "fahrenheit"} to a question that named no city. And “This behavior is
not guaranteed, especially for more ambiguous prompts and for less capable models.” A call can satisfy its
schema exactly and still answer a question nobody asked.
What a schema declares
For a client tool the schema is yours: “For tools you define, you write the schema and your application executes each call.” The vocabulary is JSON Schema: the specification “specifies a vocabulary … to make assertions about what a valid document must look like”, and its keywords “are all assertions without any annotation behavior.”
Three keywords carry most of the weight. type restricts an argument’s kind. required lists what must be
present — “An object instance is valid against this keyword if every item in the array is the name of a
property in the instance”. additionalProperties governs everything not named: it “applies only to the child
values of instance names that do not appear in the annotation results of either "properties" or
"patternProperties"”, and “Omitting this keyword has the same assertion behavior as an empty schema.” Omit
it and unnamed extra properties are accepted by default; the MCP tools page therefore recommends
{ "type": "object", "additionalProperties": false } for a tool with no arguments.
Two mechanisms, one boundary
Conformance can be enforced in two places, and they are not substitutes. The first is generation time: a
provider can constrain decoding so that arguments are produced inside the schema. OpenAI: “Setting strict to
true will ensure function calls reliably adhere to the function schema, instead of being best effort”,
subject to two requirements — that “additionalProperties must be set to false for each object in the
parameters” and that “All fields in properties must be marked as required”. Anthropic’s lever is
strict: true, to “ensure Claude’s tool calls always match your schema exactly.” But the guarantee is about
shape: constrained generation removes “the model omitting a required key, or hallucinating an invalid enum
value”. It does not make a value true, least-privileged or intended.
The second place is the boundary where the call actually runs, and that check belongs to the receiving side whatever the model did. The companion sheet on input and result validation owns those gates. MCP states the division as requirements: servers “MUST: Validate all tool inputs”, while clients “SHOULD: … Validate tool results before passing to LLM”. The same page makes the output side symmetric: when a tool declares an output schema, “Servers MUST provide structured results that conform to this schema” and “Clients SHOULD validate structured results against this schema.”
What a valid call still does not mean
A schema is an interface description, not an authorisation. Passing input validation proves only that the arguments have the declared shape. The MCP tools page is explicit that a tool’s metadata carries no authority — “clients MUST consider tool annotations to be untrusted unless they come from trusted servers” — and an argument that passes validation can still carry a value the server should have rejected, a value taken from an untrusted document, or a request the user never approved. Validation answers “is this call well-formed?”, never “should this call happen?”.
Level and prerequisites. L4 — the schema level of this layer: the reader must read a JSON Schema as a contract, know where conformance is enforced and where it is only encouraged, and treat a model-generated argument as unverified until it has been checked. Prerequisites: the L1 sheets of this area (how a model generates text and its context window) and the L2 sheets on structured output and serving.
Where to go next
- Automation & AI — the macro-area this sheet belongs to.
- Applications — the node this sheet sits in.
References
- Anthropic — Tool use with Claude — the definition of tool use, the client/server split, the
tool_useround trip, argument guessing, andstrict: true. - OpenAI — Function calling — functions as JSON-schema-defined tools, the call flow, and the two requirements of strict mode.
- OpenAI — Structured model outputs — the shape guarantee that strict mode is built on.
- JSON Schema — Validation and Core —
required,additionalPropertiesand what validation asserts. - Model Context Protocol — Tools (2025-06-18 and 2026-07-28) —
inputSchema, validation duties, output schemas and the untrusted-annotations rule.