Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Repetition - Limitation of the current EBNF Grammar Implementation #111

Open
TheMrCodes opened this issue Dec 3, 2024 · 1 comment
Open

Comments

@TheMrCodes
Copy link

The Following functionality of the EBNF Definition from llama.cpp is mission at the moment in the grammar_parser.cc

Definition: https://github.com/ggerganov/llama.cpp/blob/master/grammars/README.md

Section

## Repetition and Optional Symbols
- {m} repeats the precedent symbol or sequence exactly m times
- {m,} repeats the precedent symbol or sequence at least m times
- {m,n} repeats the precedent symbol or sequence at between m and n times (included)
- {0,n} repeats the precedent symbol or sequence at most n times (included)

This issue can be seen as a feature as well as a documentation update request.

Thanks very much to the whole team!
I was looking for a good lightweight grammar implementation for a long time 🙏

@Ubospica
Copy link
Collaborator

Ubospica commented Dec 4, 2024

Yes, we plan to support that in the next version. Thanks for pointing that out!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants