Status: โ Completed & Tested
MultiGenAI is a personalized, general-purpose Generative AI assistant that understands what the user wants automatically and generates context-aware responses.
Instead of forcing users to manually select a domain, MultiGenAI uses an LLM-powered Smart Intent Detection system to understand the user's request and dynamically adapt the response.
- ๐ง Smart Intent Detection
- ๐ฏ Automatic domain detection
- ๐ Subject detection
- ๐ก Intent detection
- ๐ Task detection
- โก Urgency detection
- ๐ค Qwen LLM powered by Groq
- ๐ฌ Context-aware conversations
- ๐ User Registration and Login
- ๐ Secure password hashing
- ๐ค User-specific private chat history
- ๐พ Persistent SQLite database
- ๐ Chat history search
- ๐ New Chat management
- โก Streaming AI responses
- ๐ฅ Medical safety-aware responses
- ๐ General-purpose AI capability
- ๐จ Clean dark-themed interface
The main feature of MultiGenAI is its Smart Mode.
Users do not need to manually select a domain.
The system automatically analyzes the user's message and identifies:
Domain
Subject
Intent
Task
Urgency
User:
Tomorrow my chemistry exam. Give me 10 MCQs with answers.
MultiGenAI understands:
Domain โ Education
Subject โ Chemistry
Intent โ Exam Preparation
Task โ Generate MCQs with answers
Urgency โ High
The detected context is then passed to the Prompt Builder to create a more relevant instruction for the main LLM.
โโโโโโโโโโโโโโโโโโโโโ
โ User Message โ
โโโโโโโโโโโฌโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ Intent Detector โ
โ โ
โ โข Domain โ
โ โข Subject โ
โ โข Intent โ
โ โข Task โ
โ โข Urgency โ
โโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ Prompt Builder โ
โโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ Conversation Context โ
โโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ Qwen + Groq โ
โโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ AI Response โ
โโโโโโโโโโโโโโโโโโโโโโโโโ
MultiGenAI supports real user authentication.
User
โ
โโโ Register
โ โ
โ โผ
โ User Account
โ
โโโ Login
โ
โผ
Authenticated User
โ
โผ
Chat
โ
โผ
user_id
โ
โผ
User-specific Chat History
Each chat is associated with the authenticated user's user_id.
This ensures that one user cannot access another user's conversations through the application's database queries.
MultiGenAI uses SQLite for persistent storage.
users
โโโ id
โโโ name
โโโ email
โโโ password_hash
chats
โโโ id
โโโ user_id
โโโ title
โโโ domain
โโโ messages
The user_id connects every conversation to its owner.
MultiGenAI/
โ
โโโ tests/
โ โโโ test_intent.py
โ โโโ test_prompt.py
โ
โโโ screenshots/
โโโ streamlit/
โ
โโโ app.py
โโโ auth.py
โโโ database.py
โโโ intent_detector.py
โโโ prompt_builder.py
โ
โโโ requirements.txt
โโโ README.md
โโโ .gitignore
โ
โโโ .env
โโโ multigenai.db
The following files should not be committed to GitHub:
.env
multigenai.db
venv/
__pycache__/
| File | Purpose |
|---|---|
app.py |
Main Streamlit application, UI and chat flow |
auth.py |
User registration, login and password verification |
database.py |
SQLite database initialization |
intent_detector.py |
Detects domain, subject, intent, task and urgency |
prompt_builder.py |
Creates dynamic context-aware prompts |
tests/test_intent.py |
Tests Smart Intent Detection |
tests/test_prompt.py |
Tests Prompt Builder |
- Python
- Qwen
- Groq API
- Large Language Models
- Prompt Engineering
- Intent Detection
- Streamlit
- SQLite
- Werkzeug Password Hashing
- Streamlit
- Groq
- python-dotenv
- Werkzeug
MultiGenAI is designed as a general-purpose AI workspace.
Example:
Why does my Python code give a ValueError?
MultiGenAI identifies the request as a programming and debugging task.
Example:
Explain overfitting with a real-world example.
The system identifies the topic and provides a practical explanation.
Example:
Tomorrow is my chemistry exam.
Give me 20 MCQs with answers.
The system understands the educational context and exam preparation requirement.
Example:
Analyze this Data Science internship job description
and tell me what skills I need.
The system identifies the career-related task and provides relevant guidance.
Example:
Write a professional LinkedIn post about my new AI project.
The system adapts the response according to the requested writing task.
Example:
Why is the sky blue?
MultiGenAI can also handle questions outside predefined domains.
For health-related questions, MultiGenAI follows safety-aware response behavior.
The system is designed to:
- Provide general educational information
- Avoid claiming to diagnose users
- Avoid prescribing personalized medication or dosage
- Recommend appropriate urgent medical care when symptoms may indicate an emergency
MultiGenAI is an AI assistant and does not replace a qualified medical professional.
User
โ
Authentication
โ
Enter Message
โ
Smart Intent Detection
โ
Domain + Subject + Intent + Task + Urgency
โ
Prompt Builder
โ
Conversation Context
โ
Qwen Model via Groq
โ
Streaming Response
โ
Save Conversation
โ
SQLite Database
MultiGenAI includes separate testing scripts for the Smart Mode components.
python tests/test_intent.pypython tests/test_prompt.pyThese tests help verify the individual components before using them inside the main application.
git clone <YOUR_GITHUB_REPOSITORY_URL>Then enter the project directory:
cd MultiGenAIpython -m venv venvvenv\Scripts\activatepip install -r requirements.txtCreate a .env file in the project root:
GROQ_API_KEY=your_groq_api_keyNever upload the .env file to GitHub.
streamlit run app.pyThe application will open in your browser.
Note: Keep your
GROQ_API_KEYprivate and never commit.envor database files.
| Variable | Description |
|---|---|
GROQ_API_KEY |
API key used to access the Groq API |
Traditional chatbot applications often require users to manually choose a category before asking a question.
MultiGenAI removes that unnecessary step.
User
โ
Select Domain
โ
Ask Question
โ
AI Response
User
โ
Ask Anything
โ
AI Understands Intent
โ
Builds Context
โ
Generates Response
This creates a more natural and user-friendly AI experience.
MultiGenAI follows a modular architecture.
Different responsibilities are separated into different modules:
Authentication
โ
Database
โ
Intent Detection
โ
Prompt Building
โ
LLM Generation
โ
User Interface
This makes the application easier to:
- Maintain
- Debug
- Test
- Extend
- Improve
- Deploy
- SQLite is currently used for persistent storage.
- Intent detection depends on an LLM.
- Groq API usage is subject to model and service limits.
- Conversation memory is limited by the available context.
- No external document RAG system is currently integrated.
- No autonomous AI agent system is currently integrated.
Possible future improvements include:
- PostgreSQL or MongoDB integration
- Google OAuth authentication
- Advanced long-term memory
- File upload and document understanding
- RAG-based knowledge retrieval
- Multi-model selection
- Voice interaction
- Image understanding
- Tool calling
- AI agents
- Personalized user preferences
- Advanced analytics dashboard
MultiGenAI is designed as a foundation for a more advanced AI ecosystem.
MultiGenAI
โ
โโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโ
โ โ โ
GenAI RAG Agents
โ โ โ
Generation Knowledge Autonomous
Retrieval Tasks
โ โ โ
โโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโ
โ
Intelligent AI
Workspace
B.Tech Computer Science & Engineering
- Artificial Intelligence
- Machine Learning
- Deep Learning
- Natural Language Processing
- Generative AI
- Retrieval-Augmented Generation
- AI Agents
- Data Science
The goal of MultiGenAI is to build a practical, intelligent and extensible Generative AI workspace that understands what users actually want instead of forcing them to manually configure how the AI should respond.
This project is created for educational, portfolio and development purposes.


