mirror of
https://github.com/ollama/ollama.git
synced 2026-04-19 12:54:19 +02:00
This package provides a way to convert JSON schemas to equivalent EBNF. It is intended to be a replacement to llama.cpp's schema_to_grammar. This is still an early version and does not yet support all JSON schema features. The to-do list includes: - minumum/maximum constraints on integer types - minLength/maxLength constraints on string types - defs and refs
63 lines
253 B
Plaintext
63 lines
253 B
Plaintext
-- old --
|
|
1
|
|
2
|
|
3
|
|
4
|
|
5
|
|
6
|
|
7
|
|
8
|
|
9
|
|
10
|
|
11
|
|
12
|
|
13
|
|
14
|
|
14½
|
|
15
|
|
16
|
|
17
|
|
18
|
|
19
|
|
20
|
|
-- new --
|
|
1
|
|
2
|
|
3
|
|
4
|
|
5
|
|
6
|
|
8
|
|
9
|
|
10
|
|
11
|
|
12
|
|
13
|
|
14
|
|
17
|
|
18
|
|
19
|
|
20
|
|
-- diff --
|
|
diff old new
|
|
--- old
|
|
+++ new
|
|
@@ -4,7 +4,6 @@
|
|
4
|
|
5
|
|
6
|
|
-7
|
|
8
|
|
9
|
|
10
|
|
@@ -12,9 +11,6 @@
|
|
12
|
|
13
|
|
14
|
|
-14½
|
|
-15
|
|
-16
|
|
17
|
|
18
|
|
19
|