Welcome to this official repository, This is designed to help users navigate and understand the resources, rules, and offerings of a college website. Whether you're a prospective student or a current one, this chatbot ensures that you get the right answers — fast and accurately.
-
Data Collection & Preprocessing
Web crawling and PDF processing are used to gather data from the college's digital resources (e.g., rules, syllabus PDFs, notices, FAQs). -
Text Chunking & Embedding
Extracted content is chunked usingRecursiveCharacterTextSplitter
, and each chunk is embedded using Google Gemini’sembeddings-001
model. -
Vector Store
These embeddings are stored in a local FAISS (Facebook AI Similarity Search) index for lightning-fast similarity searches. -
Question Answering
When a user asks a question, the chatbot:- Performs a similarity search on the vector store.
- Sends the most relevant chunks to Google Gemini (
gemini-1.5-pro
). - Returns an accurate, context-aware response.
- Real-time question answering from college documents 🧾
- Persistent local vector store for faster retrieval ⚡
- Simple API interface for frontend integration 💬
- Cross-platform and extensible architecture 🔧
Tech | Purpose |
---|---|
FastAPI | API backend framework for handling user requests |
Google Gemini | Embeddings (embedding-001 ) + QA (gemini-1.5-pro ) |
FAISS | Efficient local vector store and similarity search |
PyPDF2 | Parses and extracts text from PDF documents |
dotenv | Manages environment variables securely |
CORS Middleware | Enables frontend-backend interaction |
Ensure you have Python 3.8+ installed. Then, install the required libraries:
pip install -r requirements.txt
There is a .env file inside the folder "Backend Chatbot Python" Open that file and add your Google Gemini API Key.
Type the following command in your terminal once all the setup is done.
uvicorn main:app --reload
The backend python code is setup and is up and running.
Next open "Website" folder and run the index.html file, The website will be loaded and you can ask any relevant questions related to the college to the Chatbot and it will answer the question
✅ Add user session tracking and chat history 🔄 Live website scraping and index refresh scheduler 📤 Upload UI to allow admins to add new documents 🌐 Deploy to cloud services (Render, Railway, or AWS)
Feel free to fork the repository, improve the project, and create a pull request!
This project is licensed under the MIT License.
⚡ Happy Coding! 🚗🚦