โ
FREEBeginner
RESPONSE VALIDATOR
Validate LLM JSON output against a schema and auto-retry on failure.
Drop-in for any function that returns JSON from an LLM. Pass your value + schema, get back errors. Or pass an llm_call function + schema and it'll auto-retry: each retry appends the validation errors to the prompt so the model can self-correct. Supports type, required, properties, additionalProperties, enum, pattern, format (email/uri/date), minLength/maxLength, minItems/maxItems/uniqueItems, minimum/maximum/exclusive, multipleOf, items, oneOf/anyOf/allOf, const. CLI mode for offline schema-checking JSON files. Pure stdlib, no jsonschema dependency.