@@ -8,7 +8,7 @@ import type { Client } from "@modelcontextprotocol/client";
88import { call , connect , makeTempGraph , textOf } from "./helpers.js" ;
99import type { Connection } from "./helpers.js" ;
1010
11- const DRAFT_07 = "https://json-schema.org/draft/2020-12/schema" ;
11+ const JSON_SCHEMA_2020_12 = "https://json-schema.org/draft/2020-12/schema" ;
1212
1313// JSON Schema fragments as the SDK emits them. Output schemas close every
1414// object with additionalProperties: false; input schemas leave them open.
@@ -56,15 +56,15 @@ const graphOutputSchema = {
5656 relations : { type : "array" , items : relationItem ( true ) } ,
5757 } ,
5858 required : [ "entities" , "relations" ] ,
59- $schema : DRAFT_07 ,
59+ $schema : JSON_SCHEMA_2020_12 ,
6060 additionalProperties : false ,
6161} ;
6262
6363const statusOutputSchema = {
6464 type : "object" ,
6565 properties : { success : { type : "boolean" } , message : { type : "string" } } ,
6666 required : [ "success" , "message" ] ,
67- $schema : DRAFT_07 ,
67+ $schema : JSON_SCHEMA_2020_12 ,
6868 additionalProperties : false ,
6969} ;
7070
@@ -101,7 +101,7 @@ const expectedTools = [
101101 type : "object" ,
102102 properties : { entities : { type : "array" , items : entityItem ( false ) } } ,
103103 required : [ "entities" ] ,
104- $schema : DRAFT_07 ,
104+ $schema : JSON_SCHEMA_2020_12 ,
105105 } ,
106106 outputSchema : {
107107 type : "object" ,
@@ -110,7 +110,7 @@ const expectedTools = [
110110 skipped : { type : "array" , items : { type : "string" } } ,
111111 } ,
112112 required : [ "entities" ] ,
113- $schema : DRAFT_07 ,
113+ $schema : JSON_SCHEMA_2020_12 ,
114114 additionalProperties : false ,
115115 } ,
116116 annotations : writeAnnotations ,
@@ -125,13 +125,13 @@ const expectedTools = [
125125 type : "object" ,
126126 properties : { relations : { type : "array" , items : relationItem ( false ) } } ,
127127 required : [ "relations" ] ,
128- $schema : DRAFT_07 ,
128+ $schema : JSON_SCHEMA_2020_12 ,
129129 } ,
130130 outputSchema : {
131131 type : "object" ,
132132 properties : { relations : { type : "array" , items : relationItem ( true ) } } ,
133133 required : [ "relations" ] ,
134- $schema : DRAFT_07 ,
134+ $schema : JSON_SCHEMA_2020_12 ,
135135 additionalProperties : false ,
136136 } ,
137137 annotations : writeAnnotations ,
@@ -166,7 +166,7 @@ const expectedTools = [
166166 } ,
167167 } ,
168168 required : [ "observations" ] ,
169- $schema : DRAFT_07 ,
169+ $schema : JSON_SCHEMA_2020_12 ,
170170 } ,
171171 outputSchema : {
172172 type : "object" ,
@@ -185,7 +185,7 @@ const expectedTools = [
185185 } ,
186186 } ,
187187 required : [ "results" ] ,
188- $schema : DRAFT_07 ,
188+ $schema : JSON_SCHEMA_2020_12 ,
189189 additionalProperties : false ,
190190 } ,
191191 annotations : writeAnnotations ,
@@ -206,7 +206,7 @@ const expectedTools = [
206206 } ,
207207 } ,
208208 required : [ "entityNames" ] ,
209- $schema : DRAFT_07 ,
209+ $schema : JSON_SCHEMA_2020_12 ,
210210 } ,
211211 outputSchema : statusOutputSchema ,
212212 annotations : deleteAnnotations ,
@@ -241,7 +241,7 @@ const expectedTools = [
241241 } ,
242242 } ,
243243 required : [ "deletions" ] ,
244- $schema : DRAFT_07 ,
244+ $schema : JSON_SCHEMA_2020_12 ,
245245 } ,
246246 outputSchema : statusOutputSchema ,
247247 annotations : deleteAnnotations ,
@@ -261,7 +261,7 @@ const expectedTools = [
261261 } ,
262262 } ,
263263 required : [ "relations" ] ,
264- $schema : DRAFT_07 ,
264+ $schema : JSON_SCHEMA_2020_12 ,
265265 } ,
266266 outputSchema : statusOutputSchema ,
267267 annotations : deleteAnnotations ,
@@ -271,7 +271,11 @@ const expectedTools = [
271271 name : "read_graph" ,
272272 title : "Read Graph" ,
273273 description : "Read the entire knowledge graph" ,
274- inputSchema : { type : "object" , properties : { } , $schema : DRAFT_07 } ,
274+ inputSchema : {
275+ type : "object" ,
276+ properties : { } ,
277+ $schema : JSON_SCHEMA_2020_12 ,
278+ } ,
275279 outputSchema : graphOutputSchema ,
276280 annotations : readAnnotations ,
277281 execution,
@@ -291,7 +295,7 @@ const expectedTools = [
291295 } ,
292296 } ,
293297 required : [ "query" ] ,
294- $schema : DRAFT_07 ,
298+ $schema : JSON_SCHEMA_2020_12 ,
295299 } ,
296300 outputSchema : graphOutputSchema ,
297301 annotations : readAnnotations ,
@@ -311,7 +315,7 @@ const expectedTools = [
311315 } ,
312316 } ,
313317 required : [ "names" ] ,
314- $schema : DRAFT_07 ,
318+ $schema : JSON_SCHEMA_2020_12 ,
315319 } ,
316320 outputSchema : graphOutputSchema ,
317321 annotations : readAnnotations ,
0 commit comments