Skip to content
New issue

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

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

Already on GitHub? # to your account

Usage should be added to docs #2

Open
accraze opened this issue Feb 13, 2017 · 0 comments
Open

Usage should be added to docs #2

accraze opened this issue Feb 13, 2017 · 0 comments

Comments

@accraze
Copy link
Owner

accraze commented Feb 13, 2017

The file docs/usage.rst should be filled out with some basic information. Maybe something like:

This module (ia_markov) allows you to train a Markov model with text files from the Internet Archive. To download text files, simply find the slug located in the Internet Archive URL and pass it to MarkovModel.train_model. This will automatically download the text to your current working directory and then train a model on the downloaded text file.

For example:

If we wanted to download the text from https://archive.org/details/FuturistManifesto/page/n0

We pass the slug (FuturistManifesto) to the our model and if there is a text file, it will be downloaded and trained on.

from ia_markov import MarkovModel

m = MarkovModel()
ia_slug = ''FuturistManifesto'
m.train_model(slug)
m.model.make_sentence()
'Courage, audacity, and revolt will be drunk with love and admiration for us.'
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

1 participant