diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..2b539f3 --- /dev/null +++ b/.env.example @@ -0,0 +1,26 @@ +# ============================================ +# TELEGRAM BOT CONFIGURATION +# ============================================ + +# Telegram Bot Token (Required) +# Get it from BotFather: https://t.me/botfather +BOT_TOKEN=your_bot_token_here + +# Creator ID (Required) +# Your Telegram user ID - the bot will recognize you as creator +CREATOR_ID=your_user_id_here + +# ============================================ +# OPTIONAL: AI MODELS +# ============================================ + +# Google Gemini +GEMINI_API_KEY= + +# Mistral AI +MISTRAL_API_KEY= + +# Ollama (Local) +OLLAMA_ADDRESS= +OLLAMA_MODEL= +SYSTEM_PROMPT= diff --git a/README.md b/README.md index 1dc7ffb..230d7f3 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,51 @@ -# tg-chat-bot - +# Telegram Chat Bot + + +## Quick Start + +```bash +cp .env.example .env +# Edit .env: add BOT_TOKEN and CREATOR_ID or +``` + +**With Bun (Recommended):** +```bash +bun install +bunx drizzle-kit generate && bunx drizzle-kit migrate +bun run build && bun start +``` + +**With Node.js:** +```bash +npm install +npx drizzle-kit generate && npx drizzle-kit migrate +npm run build && npm start +``` + +**With Docker:** +```bash +docker build -f Dockerfile -t tg-bot . +docker run -d --env-file .env -v $(pwd)/data:/config/data tg-bot +``` + +**With Docker (Bun):** +```bash +docker build -f Dockerfile-bun -t tg-bot-bun . +docker run -d --env-file .env -v $(pwd)/data:/config/data tg-bot-bun +``` + +## Requirements + +- Node.js >= 18 OR Bun >= 1.0 +- Docker (optional) + + +## Features + +- AI chat (Gemini, Mistral, Ollama) +- Custom answers and commands +- Admin management +- User blocking (mute/unmute) +- QR code generation +- System info +- And more...