Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Generate JSON Schema definitions for MCP tool input parameters. Creates well-documented, AI-consumable schemas with proper types, descriptions, and validation rules.
.claude/skills/a5c-ai-mcp-tool-schema-generator/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 80% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 93% | 0% |
| case-03 | ✗→✓ | ▲ Improved | 90% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 206% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 85% | 0% |
Generate comprehensive JSON Schema definitions for MCP tools that are optimized for AI consumption, with clear descriptions, type constraints, and validation rules.
Invoke this skill when you need to:
| Parameter | Type | Required | Description | |-----------|------|----------|-------------| | toolName | string | Yes | Name of the MCP tool | | description | string | Yes | Tool description | | parameters | array | Yes | List of parameter definitions | | outputFormat | string | No | json-schema, zod, or typescript (default: all) | | examples | array | No | Example inputs for documentation |
json{ "parameters": [ { "name": "path", "type": "string", "description": "File path to read", "required": true, "constraints": { "pattern": "^[a-zA-Z0-9_/.-]+$", "maxLength": 255 } }, { "name": "encoding", "type": "string", "description": "File encoding", "required": false, "default": "utf-8", "enum": ["utf-8", "ascii", "base64"] }, { "name": "options", "type": "object", "description": "Read options", "required": false, "properties": [ { "name": "maxSize", "type": "number", "description": "Max bytes to read" }, { "name": "follow", "type": "boolean", "description": "Follow symlinks" } ] } ] }
schemas/
├── <toolName>/
│ ├── schema.json # JSON Schema definition
│ ├── schema.ts # TypeScript types
│ ├── validation.ts # Zod validation schema
│ ├── examples.json # Example inputs
│ └── README.md # Schema documentationjson{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "mcp://tools/read_file/input", "title": "read_file Input Schema", "description": "Read contents of a file from the filesystem", "type": "object", "properties": { "path": { "type": "string", "description": "File path to read. Must be a valid filesystem path.", "pattern": "^[a-zA-Z0-9_/.-]+$", "maxLength": 255, "examples": ["/home/user/document.txt", "./config.json"] }, "encoding": { "type": "string", "description": "File encoding. Defaults to UTF-8 for text files.", "enum": ["utf-8", "ascii", "base64"], "default": "utf-8" }, "options": { "type": "object", "description": "Additional read options", "properties": { "maxSize": { "type": "integer", "description": "Maximum bytes to read. Use for large files.", "minimum": 1, "maximum": 10485760 }, "follow": { "type": "boolean", "description": "Whether to follow symbolic links", "default": true } } } }, "required": ["path"], "additionalProperties": false }
typescript/** * Input parameters for the read_file tool * @description Read contents of a file from the filesystem */ export interface ReadFileInput { /** * File path to read. Must be a valid filesystem path. * @pattern ^[a-zA-Z0-9_/.-]+$ * @maxLength 255 * @example "/home/user/document.txt" */ path: string; /** * File encoding. Defaults to UTF-8 for text files. * @default "utf-8" */ encoding?: 'utf-8' | 'ascii' | 'base64'; /** * Additional read options */ options?: { /** * Maximum bytes to read. Use for large files. * @minimum 1 * @maximum 10485760 */ maxSize?: number; /** * Whether to follow symbolic links * @default true */ follow?: boolean; }; }
typescriptimport { z } from 'zod'; /** * Zod schema for read_file tool input validation */ export const ReadFileInputSchema = z.object({ path: z .string() .regex(/^[a-zA-Z0-9_/.-]+$/, 'Invalid path characters') .max(255, 'Path too long') .describe('File path to read. Must be a valid filesystem path.'), encoding: z .enum(['utf-8', 'ascii', 'base64']) .optional() .default('utf-8') .describe('File encoding. Defaults to UTF-8 for text files.'), options: z .object({ maxSize: z .number() .int() .min(1) .max(10485760) .optional() .describe('Maximum bytes to read. Use for large files.'), follow: z .boolean() .optional() .default(true) .describe('Whether to follow symbolic links'), }) .optional() .describe('Additional read options'), }).strict(); export type ReadFileInput = z.infer<typeof ReadFileInputSchema>;
| Type | JSON Schema | TypeScript | Zod | |------|-------------|------------|-----| | string | string | string | z.string() | | number | number | number | z.number() | | integer | integer | number | z.number().int() | | boolean | boolean | boolean | z.boolean() | | array | array | T] | z.array() | | object | object | interface | z.object() | | enum | enum | union | z.enum() | | null | null | null | z.null() | | union | oneOf | union | z.union() |
| Constraint | Types | JSON Schema | Zod | |------------|-------|-------------|-----| | minLength | string | minLength | .min() | | maxLength | string | maxLength | .max() | | pattern | string | pattern | .regex() | | format | string | format | .email()/.url() | | minimum | number | minimum | .min() | | maximum | number | maximum | .max() | | multipleOf | number | multipleOf | .multipleOf() | | minItems | array | minItems | .min() | | maxItems | array | maxItems | .max() | | uniqueItems | array | uniqueItems | custom |
The skill generates descriptions optimized for AI consumption:
Example:
"File path to read. Must be an absolute or relative path to an existing file.
Supports Unix and Windows path formats. Maximum length: 255 characters.
Example: '/home/user/config.json'"| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | fail→pass | 14,913 | 15,942 | +7% | 1 | 1 | 0% | 3,272 | 5,885 | +80% | 0 | 0 | — |
case-02 | fail→pass | 10,455 | 10,193 | -3% | 1 | 1 | 0% | 2,383 | 4,597 | +93% | 0 | 0 | — |
case-03 | fail→pass | 11,303 | 11,656 | +3% | 1 | 1 | 0% | 2,578 | 4,903 | +90% | 0 | 0 | — |
case-04 | fail→fail | 10,929 | 14,503 | +33% | 1 | 1 | 0% | 2,184 | 5,277 | +142% | 0 | 0 | — |
case-05 | fail→fail | 9,412 | 8,922 | -5% | 1 | 1 | 0% | 1,950 | 4,101 | +110% | 0 | 0 | — |
case-06 | fail→fail | 9,626 | 7,830 | -19% | 1 | 1 | 0% | 1,972 | 3,843 | +95% | 0 | 0 | — |
case-07 | fail→pass | 5,952 | 6,139 | +3% | 1 | 1 | 0% | 1,140 | 3,492 | +206% | 0 | 0 | — |
case-08 | fail→pass | 7,823 | 2,364 | -70% | 1 | 1 | 0% | 1,371 | 2,541 | +85% | 0 | 0 | — |
case-09 | fail→fail | 7,176 | 1,915 | -73% | 1 | 1 | 0% | 1,310 | 2,509 | +92% | 0 | 0 | — |
case-10 | fail→fail | 6,699 | 6,922 | +3% | 1 | 1 | 0% | 1,182 | 3,454 | +192% | 0 | 0 | — |
case-11 | fail→fail | 6,669 | 4,359 | -35% | 1 | 1 | 0% | 1,561 | 3,183 | +104% | 0 | 0 | — |
case-12 | fail→fail | 8,291 | 5,550 | -33% | 1 | 1 | 0% | 1,680 | 3,334 | +98% | 0 | 0 | — |
case-13 | fail→fail | 6,107 | 4,885 | -20% | 1 | 1 | 0% | 1,387 | 3,153 | +127% | 0 | 0 | — |
case-14 | fail→pass | 9,922 | 3,719 | -63% | 1 | 1 | 0% | 1,899 | 2,860 | +51% | 0 | 0 | — |
case-15 | fail→fail | 10,725 | 8,769 | -18% | 1 | 1 | 0% | 1,873 | 4,069 | +117% | 0 | 0 | — |
case-16 | fail→fail | 8,044 | 8,804 | +9% | 1 | 1 | 0% | 1,415 | 3,864 | +173% | 0 | 0 | — |
case-17 | fail→fail | 10,665 | 6,096 | -43% | 1 | 1 | 0% | 1,972 | 3,361 | +70% | 0 | 0 | — |
case-18 | fail→fail | 7,391 | 7,339 | -1% | 1 | 1 | 0% | 1,525 | 3,407 | +123% | 0 | 0 | — |
case-19 | fail→fail | 7,415 | 3,750 | -49% | 1 | 1 | 0% | 1,462 | 2,844 | +95% | 0 | 0 | — |
case-20 | fail→pass | 8,401 | 3,418 | -59% | 1 | 1 | 0% | 1,544 | 2,855 | +85% | 0 | 0 | — |
case-21 | fail→fail | 5,865 | 5,933 | +1% | 1 | 1 | 0% | 1,157 | 3,323 | +187% | 0 | 0 | — |
case-22 | fail→fail | 10,805 | 8,027 | -26% | 1 | 1 | 0% | 1,883 | 3,458 | +84% | 0 | 0 | — |
case-23 | fail→fail | 10,120 | 2,114 | -79% | 1 | 1 | 0% | 1,750 | 2,543 | +45% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 23 cases were attempted. The headline lift of +30 percentage points is the difference between those two pass rates over the 23 comparable cases. 1 case got worse with the skill loaded, and it is included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.