Feature Description
Similar to the docs for main (https://github.com/ggerganov/llama.cpp/blob/master/grammars/README.md), it'd be great to have the --grammar-file=... flag available in server as well.
Motivation
Currently, server can't process long grammars. I don't know if it's a bug but I've noticed that even with the json.gbnf files in the repo. Basically, the content of the file gets too complicated for the grammar parser to read. I think it has to do with how multi-line strings are treated in terminal.
In any case, using grammar-file simplifies API calls a lot.
Feature Description
Similar to the docs for
main(https://github.com/ggerganov/llama.cpp/blob/master/grammars/README.md), it'd be great to have the--grammar-file=...flag available inserveras well.Motivation
Currently,
servercan't process long grammars. I don't know if it's a bug but I've noticed that even with thejson.gbnffiles in the repo. Basically, the content of the file gets too complicated for the grammar parser to read. I think it has to do with how multi-line strings are treated in terminal.In any case, using
grammar-filesimplifies API calls a lot.