Skip to content

Commit ebc18f1

Browse files
authored
Merge pull request #272 from apollographql/GT-349
fix: generate openAI-compatible json schemas for list types
2 parents f5fa993 + fca294f commit ebc18f1

File tree

2 files changed

+424
-165
lines changed

2 files changed

+424
-165
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
### fix: generate openAI-compatible json schemas for list types - @DaleSeo PR #272
2+
3+
The MCP server is generating JSON schemas that don't match OpenAI's function calling specification. It puts `oneOf` at the array level instead of using `items` to define the JSON schemas for the GraphQL list types. While some other LLMs are more flexible about this, it technically violates the [JSON Schema specification](https://json-schema.org/understanding-json-schema/reference/array) that OpenAI strictly follows.
4+
5+
This PR updates the list type handling logic to move `oneOf` inside `items` for GraphQL list types.

0 commit comments

Comments
 (0)