OpenApiValidator validates runtime data against OpenApi.IJsonSchema
definitions. Returns IValidation with detailed error paths and
expected types.
Primary use case: Validating LLM-generated function call arguments. LLMs
frequently make type errors (e.g., "123" instead of 123). Use the
validation errors to provide feedback and retry.
Functions:
create: Create reusable validator function from schema
OpenAPI JSON Schema validator.
OpenApiValidatorvalidates runtime data against OpenApi.IJsonSchema definitions. Returns IValidation with detailed error paths and expected types.Primary use case: Validating LLM-generated function call arguments. LLMs frequently make type errors (e.g.,
"123"instead of123). Use the validation errors to provide feedback and retry.Functions:
Set
equals: trueto reject objects with extra properties (strict mode).Author
Jeongho Nam - https://github.com/samchon