From 44794121a838c7ea65584914caaab1e630de4616 Mon Sep 17 00:00:00 2001 From: kefuxin Date: Fri, 12 Dec 2025 10:38:00 +0800 Subject: [PATCH] docs: update MCP server schema compliance documentation Update documentation to reflect the new `schemaCompliance` setting and detailed OpenAPI 3.0 transformation rules. Suggested-by: afarber --- docs/tools/mcp-server.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/tools/mcp-server.md b/docs/tools/mcp-server.md index 4a75b1fc..8d48970a 100644 --- a/docs/tools/mcp-server.md +++ b/docs/tools/mcp-server.md @@ -627,7 +627,12 @@ The MCP integration tracks several states: ### Schema Compatibility -- **Property stripping:** The system automatically removes certain schema properties (`$schema`, `additionalProperties`) for Qwen API compatibility +- **Schema compliance mode:** By default (`schemaCompliance: "auto"`), tool schemas are passed through as-is. Set `"model": { "generationConfig": { "schemaCompliance": "openapi_30" } }` in your `settings.json` to convert models to Strict OpenAPI 3.0 format. +- **OpenAPI 3.0 transformations:** When `openapi_30` mode is enabled, the system handles: + - Nullable types: `["string", "null"]` -> `type: "string", nullable: true` + - Const values: `const: "foo"` -> `enum: ["foo"]` + - Exclusive limits: numeric `exclusiveMinimum` -> boolean form with `minimum` + - Keyword removal: `$schema`, `$id`, `dependencies`, `patternProperties` - **Name sanitization:** Tool names are automatically sanitized to meet API requirements - **Conflict resolution:** Tool name conflicts between servers are resolved through automatic prefixing