This project is a backend system built using FastAPI that demonstrates a complete Retrieval-Augmented Generation (RAG) pipeline. It allows users to upload documents, ask questions based on those documents, and book interview slots using natural language.
- Upload PDF or TXT documents
- Text extraction and chunking
- Embedding generation
- Vector storage and retrieval
- Conversational question answering (RAG)
- Multi-turn chat using Redis
- Natural language interview booking
-
User uploads a CV (PDF/TXT)
-
The system:
- Extracts text
- Splits it into chunks
- Generates embeddings
- Stores them in Qdrant
-
User asks a question
-
Relevant chunks are retrieved
-
LLM generates an answer using context
The system also supports booking interviews like:
"My name is Sashwat, email sashwataryala@outlook.com, book interview tomorrow at 4pm"
- Python
- FastAPI
- Sentence Transformers (embeddings)
- Qdrant (vector database)
- Groq API (LLM)
- SQLite (booking storage)
- Redis (Docker container for chat memory)
All required libraries are listed in requirements.txt. These include:
- fastapi
- uvicorn
- sentence-transformers
- qdrant-client
- redis
- groq
- sqlalchemy
- pypdf
- Create virtual environment
python -m venv .venv.venv\Scripts\activate
- Install dependencies
pip install -r requirements.txt
- Run Redis using Docker
docker run -d -p 6379:6379 redis
- Start backend server
uvicorn app.main:app --reload
Open in browser:
Document Ingestion POST /ingest Upload a PDF or TXT file.
Chat (RAG) POST /chat Ask questions based on the uploaded document.
Interview Booking POST /book Book interview using natural language.
Example input: My name is Sashwat, email sashwataryala@outlook.com, book interview tomorrow at 4pm
User uploads CV, then asks:
What skills are mentioned in my CV?
System retrieves relevant chunks and generates an answer using LLM.
This project demonstrates:
- Custom RAG implementation
- Vector search using Qdrant
- Redis-based chat memory
- Real-world backend API design
- LLM-powered natural language booking system
- Redis is containerized using Docker
- Backend runs locally using FastAPI
- Vector database is handled using Qdrant local storage