1 unstable release
Uses old Rust 2015
0.1.0 | Sep 22, 2020 |
---|
#19 in #markov-chain
Used in warkov-wordgen
12KB
241 lines
Markov chain generator
Documenation
Look a head size
When generating a new term, it looks at the previous X items that it has already output to decide the next item. This number controls this.
Example
use warkov::MarkovChain;
// Create a new generator
let mut mc = MarkovChain::new(5);
// Train it on some words
mc.train("foo".chars());
mc.train("bar".chars());
mc.train("baz".chars());
// Generate a new word
let new_word: Vec<char> = mc.generate();
warkov
A weighted link:markov chain in rust. This project contains the base library and command line programmes to generate things from other things.
warkov
This is the library for generating things with Markov Chains, and can be used by other programmes. See link:target/doc/warkov/index.html[the API documentation].
warkov-wordgen
Generate words from a text file of existing entries. See link:warkov-wordgen/README.adoc[it's README].
All copyrighted, and licenced under the GNU Affero GPL v3 (or later), see link:LICENCE[]
Dependencies
~410KB