01Schema quality drives tool quality
Names and descriptions should distinguish when tools apply; argument schemas should make invalid states difficult. Expose only relevant tools to reduce confusion and prompt footprint.
A tool call is a structured proposal, not an executed action. The application exposes a schema, receives a tool name and arguments, validates them, checks the current caller's permission, executes the allowed operation, and returns a structured observation. The model can then use that observation in its continuation. Trace these stages separately so a correct-looking proposal cannot bypass executor policy.
Use narrow names and argument contracts. “refund_order” with order_id, amount, currency, and operation_id is easier to validate than a generic “run_command” string. Explain units, required fields, and bounded values. Derive the tenant from trusted request context rather than accepting a model-selected tenant. Tool errors should identify safe retry conditions without leaking secrets or hidden resources.
- Validate types and business rules server-side
- Never let tool descriptions grant permission
- Use stable call IDs for tracing and deduplication