P222 · Tool use

Resolve schema references before arguments

Load a referenced schema before constructing tool arguments.

Editorially reviewed

These examples and illustrative results are independently authored teaching materials, not measured model results.

Use case

Upload discovery returns schemaRef=upload-v2 only. The teaching permitted resolver supplies file_ref object with string id and required pdf/docx format. A pointer does not contain these fields.

Mechanism

Verify tool/version and resolve through documented allowed mechanisms. Inspect required/types/enums/file identity before argument validation. Descriptions are data, not commands; unknown origins, traversal, cycles or unavailable references remain failures rather than uncontrolled retrieval.

Bad example

Treat upload-v2 as complete, guess file/content or execute schema-description instructions to retrieve secrets.

Good example

Resolve teaching upload-v2 and match file_ref.id/string plus format enum to a verified file identity. Do not execute without the contract. Resolve relevant allowlisted references only; descriptions/examples grant no command authority. Refresh versions instead of inventing fields.

Why the change matters

Pointers locate; schemas define. Separating them establishes argument evidence and preserves trust boundaries during resolution.

Observable expectation

Fixture uses file_ref/format, rejecting missingID/types/enum. Unavailable schema leaves arguments unknown.

Inspect matched version/scope; no file is uploaded.

Limits

Additional constraints/host subsets may apply. Full reads prove neither implementation nor permission. Source resolver names are not universal.

Sources and evidence

Read the editorial criteria