All notable changes to Schema Forge will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
-
Date Type Support: Properties with
Datetype are now automatically mapped to JSON Schema{ type: "string", format: "date-time" }. -
Class-Validator Integration: Automatic inference of JSON Schema constraints from class-validator decorators when used in your project. Supported decorators:
@ArrayMaxSize(n)→maxItems: n@ArrayMinSize(n)→minItems: n@ArrayUnique()→uniqueItems: true@ArrayNotEmpty()→minItems: 1@Max(n)→maximum: n@Min(n)→minimum: n@IsInt()→type: 'integer'@MinLength(n)→minLength: n@MaxLength(n)→maxLength: n@IsUrl()→format: 'uri'@IsEmail()→format: 'email'@IsPositive()→minimum: 1
-
Validation Constraint Options in ToolProp: New options for
@ToolPropdecorator to manually specify validation constraints:minimum,maximumfor number constraintsminLength,maxLengthfor string constraintsminItems,maxItems,uniqueItemsfor array constraintsformatfor string format specification
- When both class-validator decorators and explicit
@ToolPropoptions are present, the explicit options take precedence.
- update README.md
- Add reflect-metadata v0.1.14 backward-compatibility.
- Publish
jsonSchemaToGeminiOldTool,jsonSchemaToGeminiOldResponseSchemathat whould be published in 1.0.0. - Support the tool format and responseSchema format of google vertex API,
@google-cloud/vertexai. Supply the following functionsjsonSchemaToGeminiVertexTooljsonSchemaToGeminiVertexResponseSchemaclassToGeminiVertexResponseSchemaclassToGeminiVertexTool
- Improve README
Schema Forge is now ready for production use! This release provides a complete TypeScript library for transforming classes into JSON Schema definitions with first-class support for various LLM function calling formats.
-
Core Functionality
- Class-to-JSON Schema conversion with powerful decorator API
- Support for nested object structures and complex property paths
- Extensible metadata and property attributes
- Comprehensive handling of TypeScript types and enums
-
LLM Provider Support
- OpenAI Chat Completions API tool format
- OpenAI Response API tool format
- OpenAI structured output formats (response_format and text.format)
- Anthropic Claude tool format
- Google Gemini tool and response schema formats (for both @google/genai and @google/generative-ai)
-
Optional Property Handling
- Automatic conversion of optional properties to OpenAI's preferred ["type", "null"] format
- Standard JSON Schema handling for Gemini and other providers
-
Direct Converters
- JSON Schema to various LLM formats without requiring TypeScript classes
- Conversion between different LLM formats (e.g., OpenAI to Anthropic)
-
Developer Experience
- Well-documented API with extensive examples
- Type-safe interfaces with full TypeScript support
- Modern package exports for both ESM and CommonJS compatibility
- First stable release with a complete feature set
- Documentation with comprehensive examples
- Full test coverage for all supported features and LLM providers
- CI/CD pipeline for quality assurance