Retrieval · citations · evaluation
Document chat that cites its sources and refuses to guess
A FastAPI service over Postgres and pgvector. It answers only from the passages it retrieved, names the file and the chunk, and says the documents don't cover the question instead of inventing an answer. A Flutter client streams the reply over SSE. Retrieval is scoped per owner, so one person's documents never turn up in another person's answer.
Hard partMulti-part questions. A question asking about two things was being answered from a single passage. Splitting the retrieval and merging the citations took the score from failing to 53 of 53. The eval is a 53-question golden set with a regression gate that fails the build when the score drops.