DocuMind.
Intelligent Document Q&A System
From a PDF to a grounded answer: a document intelligence platform with semantic retrieval, citation-backed responses, and reusable MCP tools.
01 / Overview
From a PDF to a grounded answer: a document intelligence platform with semantic retrieval, citation-backed responses, and reusable MCP tools.
02 / Problem
Documents contain useful information, but finding a precise answer requires more than keyword search. The system needs to retrieve relevant passages and keep generated answers connected to their sources.
03 / Solution
I built a RAG pipeline that parses PDFs with PyMuPDF, creates overlapping chunks, embeds them with HuggingFace all-MiniLM-L6-v2, and retrieves relevant context from ChromaDB. LangChain and AWS Bedrock generate citation-backed answers through a FastAPI backend and React chat interface.
04 / Architecture
Parse uploaded PDFs into text for downstream retrieval.
MCP exposes document search and summarization through the existing ingestion and retrieval logic.
05 / How it works
- Upload a PDF and extract its text with PyMuPDF.
- Create overlapping chunks and compute sentence-transformer embeddings.
- Index the chunks in ChromaDB.
- Embed the question and retrieve relevant context.
- Orchestrate response generation with LangChain and AWS Bedrock.
- Display the answer with source citations. MCP clients can also call document search and summarization tools directly.
06 / Technology stack
Parses PDF content into the text needed by the retrieval pipeline.
Provides the all-MiniLM-L6-v2 embedding model used for semantic similarity.
Stores embeddings and supplies relevant chunks at query time.
Connect retrieval context to model-powered answer generation.
Separate the backend pipeline from the chat experience.
Makes document search and summarization reusable outside the REST interface.
Supports parameter-efficient adaptation of an open-source model for domain-specific responses.
07 / Engineering challenges
- Context across chunk boundaries: overlapping chunks retain surrounding information for retrieval.
- Grounding: retrieval and citations connect generated responses back to source passages.
- Tool reuse: the MCP server exposes existing ingestion and retrieval logic to compatible clients.
- Domain relevance: LoRA / QLoRA fine-tuning improved relevance over base-model prompting.
08 / Key features
- Natural-language PDF questions
- Semantic search and source citations
- React chat interface and FastAPI backend
- MCP document search and summarization
- Domain-specific LoRA / QLoRA fine-tuning
09 / Load-test observations
Average response time during load testing
Concurrent users in load testing
The FastAPI backend and React interface supported natural-language document queries with citation-backed answers during load testing.
10 / Engineering takeaways
The implementation connects ingestion, retrieval, generation, and source attribution as one system. Exposing the same logic through REST and MCP demonstrates how a retrieval pipeline can support multiple client interfaces.