bnfgenversion

Random text generator that takes context-free grammars from BNF files

BNFGen generates random texts based on user-defined context-free grammars specified in a BNF-like syntax. There are descriptive syntax error messages and tracing options.

You can specify "weight" for rules with alternation to influence their probabilities. For example, in <foo> ::= 10 <foo> "foo" | "foo"; the first (recursive) option will be taken ten times more often.

You can also specify deterministic repetition ranges, like <foo>{4} (exactly four of <foo>) or <foo>{1,5} (from one to five of <foo>).

This package includes both a library and a CLI tool based on it.

AuthorDaniil Baturin <daniil@baturin.org>
LicenseMIT
Published
Homepagehttps://baturin.org/tools/bnfgen
Issue Trackerhttps://github.com/dmbaturin/bnfgen/issues
MaintainerDaniil Baturin <daniil@baturin.org>
Dependencies
Source [http] https://github.com/dmbaturin/bnfgen/archive/3.1.0.tar.gz
md5=e9e9fdd121dd2d4a188dc1ac03089c82
sha512=069ad2497ac2f6f180d853ef7cb85084a6be3d94df5e7f72496eae9e41e81120c95dc392c20d8b4428698519d921a7ddbc2a18df8093dc698ef11b772e0c66cb
Edithttps://github.com/ocaml/opam-repository/tree/master/packages/bnfgen/bnfgen.3.1.0/opam
Required by