https://github.com/techycsr/advaitelegrambot
Telegram Advanced AI ChatBot: GPT-4o and Gpt-4o-mini, Dall-E Model, OCR and Google Voice2Text.
https://github.com/techycsr/advaitelegrambot
gpt-4o gpt-4o-mini machine-learning ocr-python openai pyrogram python3 telegram-bot tgbot
Last synced: 5 months ago
JSON representation
Telegram Advanced AI ChatBot: GPT-4o and Gpt-4o-mini, Dall-E Model, OCR and Google Voice2Text.
- Host: GitHub
- URL: https://github.com/techycsr/advaitelegrambot
- Owner: TechyCSR
- License: mit
- Created: 2024-08-01T13:30:37.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-05-11T07:51:12.000Z (5 months ago)
- Last Synced: 2025-05-11T08:29:57.789Z (5 months ago)
- Topics: gpt-4o, gpt-4o-mini, machine-learning, ocr-python, openai, pyrogram, python3, telegram-bot, tgbot
- Language: Python
- Homepage: https://t.me/AdvChatGptBot
- Size: 7.02 MB
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://github.com/TechyCSR/AdvAITelegramBot/stargazers)
[](https://github.com/TechyCSR/AdvAITelegramBot/network/members)
[](https://github.com/TechyCSR/AdvAITelegramBot/issues)
[](https://github.com/TechyCSR/AdvAITelegramBot/blob/main/LICENSE)
[](https://github.com/TechyCSR/AdvAITelegramBot/graphs/contributors)
[](https://github.com/TechyCSR/AdvAITelegramBot/pulls)
[](https://github.com/TechyCSR/AdvAITelegramBot/commits)Welcome to the **Telegram Advanced AI ChatBot** project! This bot leverages cutting-edge AI technologies to provide a seamless and intelligent chat experience on Telegram. With features like AI chat, voice interaction, image generation, and visual analysis, this bot is designed to enhance your conversational experience and make interactions more engaging and dynamic.
## ✨ Features
### 🚀 Getting Started:
- **Direct AI Chat:** Start typing in the chat to interact with the AI instantly.
- **Voice and Image Commands:**
- Record a voice message or send an image to chat with the AI.
- In groups, send an image with a caption `"ai"` or `"ask"` to extract text from the image and interact with the AI.### 🔧 Commands:
- **Text Commands:**
- `/start` - 🚀 Start the Bot
- `/ai` - 🤖 Start a Chat with AI in Groups
_(Eg: `/ai what is the capital of India?`)_
- `/img` or `/image` - 🖼️ Generate an image from the given prompt
_(Eg: `/img Sunset on a beach` or `/image Sunset on a beach`)_
- `/settings` - ⚙️ Configure Bot Settings
- `/new` or `/newchat` - 🔄 Start a New Chat and Clear Previous Chat History
- `/rate` - ⭐️ Rate the Bot
- `/help` - ❓ Show this Help Menu- **Voice Commands:**
- Record a voice message for seamless interaction.- **Image Commands:**
- Send an image with a caption like `"ai"` or `"ask"` for text extraction and interaction.### 🧠 AI-Powered Features:
- **💬 Intelligent ChatBot (GPT-4):**
Engage in dynamic, context-aware conversations with the bot.
- **🎙️ Voice Interaction:**
Convert speech to text and generate speech from text for a smooth voice experience.
- **🖼️ Image Generation (DALL-E 3):**
Transform your ideas into stunning visuals by generating images from textual prompts.
- **🔍 Visual Analysis (Google Lens):**
Extract insights and text from any image using cutting-edge AI tools.---
### 💡 Group & Personal Chat Features:
- Interact with the bot in **group chats** or private conversations seamlessly.
- Leverage powerful commands and AI tools to enhance your experience in any context.## 🛠️ Technology Stack
- **Natural Language Processing (NLP):**
- **Models:** GPT-4o, GPT-4o-mini (OpenAI)
[OpenAI GPT-4o](https://chat.openai.com/)
- **Libraries:** NLTK, SpaCy
- **Speech Recognition and Synthesis:**
- **Voice Generation Model:** [Google Speech-to-Text](https://cloud.google.com/speech-to-text)
- **Voice Recognition Model:** [Google Text-to-Speech](https://cloud.google.com/text-to-speech)- **Generative AI for Images:**
- **Image Generation Model:** [DALL-E-3 Model](https://openai.com/dall-e/)- **Image Recognition:**
- **Image to Text Model:** [OCR](https://ocr.space/ocrapi), [Google Cloud Vision API](https://cloud.google.com/vision)- **Backend Development:**
- **Framework:** [Flask](https://flask.palletsprojects.com/)
- **APIs:** [Telegram Bot API](https://core.telegram.org/bots/api), [OpenAI API](https://beta.openai.com/docs/)- **Database Management:**
- **Database:** [MongoDB](https://www.mongodb.com/)- **Cloud Services:**
- Hosting on [Railway](https://railway.app/)
- Additional support: AWS, Google Cloud, Azure- **Security and Privacy:** SSL/TLS
- **Source Code Management:** [GitHub](https://github.com/TechyCSR/AdvAITelegramBot)
---
## 📂 Project Structure```plaintext
AdvAITelegramBot/
├── assets/ # Static assets (images, icons, etc.)
│ ├── logos/ # Logos for branding
├── database/ # Database-related scripts or schema
│ ├── migrations/ # Database migration scripts
│ └── models.py # Database models
├── modules/ # Core logic and functionality modules
│ ├── __init__.py # Marks 'modules' as a package
│ ├── group/ # Group-related functionalities
│ │ ├── __init__.py # Marks 'group' as a package
│ │ ├── group_info.py # Handles group information
│ │ ├── group_settings.py # Manages group settings
│ │ ├── new_group.py # Handles new group creation
│ ├── image/ # Image processing functionalities
│ │ ├── __init__.py # Marks 'image' as a package
│ │ ├── image_generation.py # AI-based image generation
│ │ ├── img_to_text.py # Extract text from images
│ ├── speech/ # Speech processing functionalities
│ │ ├── __init__.py # Marks 'speech' as a package
│ │ ├── text_to_voice.py # Converts text to speech
│ │ ├── user_voice.py # Manages user voice data
│ │ ├── voice_to_text.py # Converts voice input to text
│ ├── user/ # User-related functionalities
│ │ ├── __init__.py # Marks 'user' as a package
│ │ ├── assistant.py # AI assistant functionalities
│ │ ├── commands.py # Manages user commands
│ │ ├── dev_support.py # Developer-specific support logic
│ │ ├── global_setting.py # Global user settings
│ │ ├── help.py # Help command handling
│ │ ├── lang_settings.py # Language-related user settings
│ │ ├── settings.py # General user settings management
│ │ ├── start.py # User onboarding/start commands
│ │ ├── user_support.py # Feedback and support handling
| ├── chatlogs.py # Chat logging script
| ├── feedback_and_ratings.py # Feedback and ratings handling
| ├── maintenance.py # Maintenance scripts
| ├── lang.py # General language processing utilities
├── tests/ # Test cases for modules
│ ├── test_speech.py # Test cases for speech module
├── har_and_cookies/ # Stores HAR files and cookies for debugging
│ └── ... # HAR and cookie files
├── .env # Environment variables (API keys, etc.)
├── .gitignore # Git ignore rules
├── Dockerfile # Docker configuration for the project
├── LICENSE # License for the project
├── README.md # Project documentation
├── config.py # Bot configuration file
├── requirements.txt # Python dependencies
├── run.py # Entry point for running the bot```
---
## 🚀 Quick Start
### 📦 Installation1. **Clone the Repository:**
```bash
git clone "https:github.com/TechyCSR/AdvAITelegramBot.git"
cd AdvAITelegramBot
```
2. **Install Dependencies:**```bash
pip install -r requirements.txt
```
3. **Set Environment Variables:**Create a `.env` file in the root directory and add the following environment variables:
```plaintext
TELEGRAM
OPENAI
OCR_SPACE
MONGO_URI
Log_Channel (Mandatory)
```
4. **Run the Bot:**```bash
python run.py
```
5. **Start Chatting:**Open the Telegram app and start chatting with the bot!
---
### Contributors
Maintained by:
- **[TechyCSR](https://techycsr.me)**
- **[Ankit](@Ankit-Sharma-Dev)**
- **[Aarushi](@111Aaru11)**### License
Licensed under the [MIT License](LICENSE). This open-source project provides no warranties or guaranteed support.
[//]: # (End of file)