AGENTIC SYSTEMS GUIDE

Output & validation for AI agents

Typed schemas and validation tools turn generated content into application data with an explicit contract.

Start with the problem you need to solve

SEE HOW THE SYSTEM FITS TOGETHERSELECT A COMPONENT
inputprocessresultcheckoutputUntrusted payloadModel or API responseJSON parsingSyntax boundaryOutput & validationSelected layerDomain checksMeaning and permissionTyped application dataAccepted or rejectedRegression casesKnown bad inputs
  1. Treat incoming fields as untrusted until validated.

  2. Reject malformed serialization before evaluating the data contract.

  3. Typed schemas and validation tools turn generated content into application data with an explicit contract. Validate structure, then validate meaning. A well-formed response can still contain the wrong fact or an unauthorized action.

  4. Check allowed values, cross-field constraints, and resource scope.

  5. Handle validation failure explicitly rather than coercing an unsafe action.

  6. Keep malformed, extra-field, and boundary-value examples in the test suite.

    Result or stopping point
Output & validation

Typed schemas and validation tools turn generated content into application data with an explicit contract. Validate structure, then validate meaning. A well-formed response can still contain the wrong fact or an unauthorized action.

Follow the arrows, then select a component to inspect its responsibility. On mobile, downward arrows connect the next step; bent arrows identify branches and return paths. Select a destination to jump to that component.

Validate structure, then validate meaning. A well-formed response can still contain the wrong fact or an unauthorized action.

Explore all tool categories