SinGPTUltimate / grammars /arithmetic.gbnf
shapermindai's picture
Synced repo using 'sync_with_huggingface' Github Action
a3ffd31 verified
raw
history blame contribute delete
177 Bytes
root ::= (expr "=" ws term "\n")+
expr ::= term ([-+*/] term)*
term ::= ident | num | "(" ws expr ")" ws
ident ::= [a-z] [a-z0-9_]* ws
num ::= [0-9]+ ws
ws ::= [ \t\n]*