Use const instead of enum for choices in generated schema (#20084)

Thank you!
This commit is contained in:
Lazizbek Ergashev authored and GitHub committed 2026-09-16 21:32:30 +08:00
1 parent fe7fadc35e
commit 753f783086
2 files changed
+50 -148

No files matched your search

+1 -1
View File
@@ -115,7 +115,7 @@ function optionTypeToSchemaType(optionType) {
}
function choiceToSchema(choice) {
return { enum: [choice.value], description: choice.description };
return { const: choice.value, description: choice.description };
}
async function generateSchema() {