Back to Case Studies

Ask questions and find answers in your documents

Product
AI Assistant
Industry
Enterprise

AI summarizes and answers questions directly from records, using RAG to find relevant information in user-provided documents.

Business context

When reviewing case files, staff often need to understand the key facts before checking specific details. Searching lengthy documents manually can slow screening and make cross-checking information time-consuming. THLOne developed a document Q&A interface that lets users upload files, read an AI-generated summary and ask follow-up questions based on the same source material.

This is especially useful when teams review many files with different structures. A single interface for summaries and document-grounded questions reduces the need to switch between manual reading and separate searches.

Implemented solution

THLOne combines a language model with retrieval-augmented generation (RAG) to find relevant passages before producing an answer. The assistant uses uploaded documents as its reference, rather than relying solely on the model's general knowledge.

The solution includes:

1. Upload and ingest documents

Users upload case files through a Streamlit interface for processing.

2. Summarize document content

LangChain works with a language model served through Ollama to produce concise summaries of the main points.

3. Retrieve relevant passages with RAG

When a user asks a question, the system retrieves supporting passages from the uploaded file to provide context for the answer.

4. Ask follow-up questions in one interface

Users can continue asking for details, such as identifying the position a candidate applied for.

Uploading, summarization and document-grounded Q&A are combined in one workflow. By retrieving relevant passages first, the RAG approach keeps responses tied to the material provided instead of generic model knowledge.

Results

The pilot establishes a single workflow for reviewing case files: upload a document, receive a summary and ask questions about its content. RAG retrieves relevant passages before the language model generates an answer, helping users find details that warrant closer review.

The approach can be adapted to other document categories when the file types and search scope are clearly defined. AI-generated answers should still be checked against the original source before they are used in important decisions.