The EnGram Telegram bot was created for practicing English grammar. It was built using the aiogram framework. The bot extracts tests from APIs presented here (Async API) and here (Sync API), depending on the specified setup. It also uses Aioredis for saving the user's ID, allowing the user to continue interacting with the bot without having to reselect their English level.
- aiogram: Framework for building Telegram bots.
- Aioredis: Asynchronous Redis client for managing the cache layer.
- Pydantic: For data validation in the bot's logic.
- pytest-asyncio: For writing and running asynchronous unit tests.
git clone https://github.com/yourusername/EnGram_bot.git
cd EnGram_bot
pip install -r requirements.txt
Create .env and file based on the provided example.
Download Redis and place the folder on disk C (for example). Open a command prompt and navigate to the Redis folder:
cd C:\Redis
Set up configuration file. You can either modify the redis.windows.conf or create a copy: redis-bot.conf. Start Redis server:
redis-server.exe redis-bot.conf
python api/app.py
And check the telegram bot.