From e8b78c28eb049c11cef76278fce991f23a068f82 Mon Sep 17 00:00:00 2001 From: ochafik Date: Sun, 10 Mar 2024 16:49:15 +0000 Subject: [PATCH] json: revert space to 1 at most --- examples/json-schema-to-grammar.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/json-schema-to-grammar.py b/examples/json-schema-to-grammar.py index 161704c67..becd35b8e 100755 --- a/examples/json-schema-to-grammar.py +++ b/examples/json-schema-to-grammar.py @@ -8,7 +8,7 @@ from typing import Any, Dict, List, Set, Tuple # whitespace is constrained to a single space char to prevent model "running away" in # whitespace. Also maybe improves generation quality? -SPACE_RULE = '" "*' +SPACE_RULE = '" "?' PRIMITIVE_RULES = { 'boolean': '("true" | "false") space',