]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
examples : add pydantic models to GBNF grammar generator (#4883)
authorMaximilian Winter <redacted>
Fri, 12 Jan 2024 19:46:45 +0000 (20:46 +0100)
committerGitHub <redacted>
Fri, 12 Jan 2024 19:46:45 +0000 (21:46 +0200)
commit52ee4540c0f2e11d52c839db6eb51d014ce060e1
treeae5ed429efc613cd6e875fa5f13d41eef41808e4
parent3fe81781e3bf98b8e44946240a19f3a6ad08a11a
examples : add pydantic models to GBNF grammar generator (#4883)

* Create pydantic-models-to-grammar.py

* Added some comments for usage

* Refactored Grammar Generator

Added example and usage instruction.

* Update pydantic_models_to_grammar.py

* Update pydantic-models-to-grammar-examples.py

* Renamed module and imported it.

* Update pydantic-models-to-grammar.py

* Renamed file and fixed grammar generator issue.
examples/pydantic-models-to-grammar-examples.py [new file with mode: 0644]
examples/pydantic_models_to_grammar.py [new file with mode: 0644]