Client for anonymous chat.
You need:
- Python >= 3.11.1
- Poetry
Install dependencies and activate environment:
poetry install
poetry shell
python src/client.py
- Register and get a token:
python src/registraion.py --host [host] --port [port]
After successful registration, the token will be written to the root of the project in the .token
file.
- To send messages you need to run the script:
python src/sender --host [host] --port [port] --message [your message]
If you want to send only one message, specify the --message
argument with your message. Otherwise the chat starts in interactive mode.
- To record a chat history, use the command:
python src/record_chat_history.py --host [host] --port [port] --history [filepath]
Where --history
is the path to the file where the history will be written. (minechat.history
in the root of the project by default)
Instead of specifying cli arguments you can create a config.yml
file in the root of project and write there the necessary data to run the scripts.
For example:
host: minechat.dvmn.org
sending_port: 5050
reading_port: 5000
history: /path/to/history_file.txt
and run script:
python src/record_chat_history.py