ml · web · engineering
Citewell
In progressUpload a PDF, DOCX or TXT and ask questions about it. Answers carry numbered, page-aware citations, decline when the document does not say, and can be checked claim by claim. Early prototype, still in progress.

Key figures
- 12/12
- 3
- 12 docs
Write-up
Citewell is a retrieval-augmented generation (RAG) app for asking questions about one document at a time. It can also summarise the document and translate answers into Nepali.
- Cited answers. Each answer carries numbered sources with the page and a relevance score, so a claim can be traced back to the text.
- Abstention. If the best retrieved chunk is below a relevance threshold, the model is not called. The model can also decline on its own. The threshold is provisional and not yet calibrated.
- Claim checking. An optional pass labels each claim in the answer as supported, unsupported or uncited. It uses an LLM judge from the same model family, so it can share the answer model's blind spots.
- Long documents. Summaries use a map-reduce pass with an on-disk cache.
- Prompt-injection hardening. Uploaded text is treated as untrusted data and delimited in the prompt. A live 12-attack corpus on one model gave no failures, which is "no failures observed", not "secure".
Stack. FastAPI backend with a persistent ChromaDB store, a React 19 and TypeScript front end, and offline tests that use a fake model and embedder, so CI needs no API key.
What is not done. Citation fidelity, the abstention gate and the verifier have not been evaluated against labelled data yet. A 12-document evaluation set is in the repository, and no result has been produced from it. Scanned PDFs are rejected because there is no OCR, and Nepali translation is a plain prompt that has not been evaluated.
Built with
- Python
- FastAPI
- ChromaDB
- Google Gemini
- React 19
- TypeScript
- Vite
- Tailwind CSS 4