08:32
2026-09-23
til.simonwillison.net
large-language-models
Using Llama-cpp-Python grammars to generate JSON
Llama.cpp added grammar-constrained output generation on August 17, letting developers restrict a large language model's next-token selection so responses exactly match a specified grammar, and the ll…