RAG Básico
Technologies used
Python
ChromaDB
Groq API
OpenAI GPT-OSS 20B
About the project
A terminal-based question-and-answer assistant that searches a local collection of documents. The sample collection covers common questions about refunds and cancellations. Users can index new files and then chat with the assistant.
Objective and outcome
Objective
Learn how retrieval-augmented generation (RAG) works in practice. I used a knowledge base about refunds to test how semantic search can give the model relevant information before it generates an answer.
Outcome
The assistant lets users index their own documents and query the collection from the terminal. Its answers use excerpts retrieved from the knowledge base.
How I built it
How it works
The script extracts text from PDF, DOCX, TXT and CSV files and indexes it in ChromaDB. For each question, the database compares the meaning of the query with the documents and retrieves up to two of the most relevant ones. The program adds that context to the prompt and calls OpenAI's GPT-OSS 20B model through the Groq API.
What I learned
I practiced document ingestion, embeddings and vector search. I also learned to write a prompt that guides the model to use the retrieved context in its answer.

