Skip to main content
Anuraag Mishra

Retrieval & Ranking

ChatQ: a small local RAG app

Question answering over your own documents, with vector and keyword search side by side and optional web results.

Role
Personal project
Context
2025 · built over a few days
PythonFastAPIElasticsearchVector searchOllama / MistralOpenAI

Why I built it

I wanted to see the moving parts of a RAG system end to end, outside of any company setup: ingestion, retrieval, prompt assembly and the model, each one replaceable.

What it does

  • Upload PDF or text files through a small UI or the API. Each document is embedded into a vector store and indexed in Elasticsearch.
  • A question searches both indexes. Vector search catches rephrased questions; keyword search catches exact names, codes and jargon that embeddings tend to blur.
  • Live web search can be switched on per question.
  • The retrieved context goes to a local model through Ollama, or to GPT-4o when answer quality matters more than cost.

Code: github.com/mishraanuraagx/ChatQ