This is a bot, which uses GRU module to predict next word. Data are displayed in a such way to make net think, that it should write poems not just text.
The main goal of this project is to get acquainted with NLP. The simplest task here is to predict next word, so I've chosen already written model and tried to play around with it.
- Python 3.8.x
-
Clone repository:
git clone https://github.com/jollianreap/talk_to_me_like_poet.git
-
Create venv:
python3.8 -m venv .venv
-
Base requirements:
make base-requirements
I've created a special file .env to get the links, which will be parsed (only https://slova.org.ru/).
-
Paste links into config file:
LINKS = your, links, with, commas
-
Run parsing loop:
make parse_links
-
Run training loop:
make train
Before getting started, you should paste your bot token in .env file.
-
Installing screen, if not installed:
sudo apt install screen
-
Running model API:
screen -d -m python3 lyrics-generator_copy/ml_api.py
-
Running bot
screen -d -m python3 bot.py
-
Verifying
screen -ls