Skip to content

Commit

Permalink
Create readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Alison of Sheesania committed Mar 14, 2017
1 parent 7ed6894 commit fe84ece
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# MarkovTextGenerator
Generates text similar to input text using Markov probability chains.

Given a text file, this program analyzes the pattern of text in the file, creating Markov chains of letters/words that are statistically likely to appear after each letter/word. Then it can generate text similar to the input using the Markov chains.

## Usage

`mtg.exe -i *input_path* -o *num_words_to_generate* [-g *group_size*] [-w]`

Input path: Path to a plain text file with at least one space.

Num words to generate: Number of words to generate from the input text.

Group size: Number of characters or words to group together in Markov chains. Defaults to 1. The larger the group size, the closer the generated text will be to the input text.

-w: Calculate probabilities based on words (delimited by spaces) instead of by chunks of characters.

## Examples

`mtg.exe -i NalhallanText.txt -o 16`

`mtg.exe -i NalhallanText.txt -o 16 -g 2`

`mtg.exe -i NalhallanText.txt -o 16 -w`

`mtg.exe -i NalhallanText.txt -o 16 -g 2 -w`

0 comments on commit fe84ece

Please sign in to comment.