SpecDoors — Hallucination-Proof Compliance RAG
An AI compliance and estimating tool for construction that answers questions over dense specification PDFs — with citations enforced so it never hallucinates on compliance-critical content.
RAGFAISSClaude APIFastAPI
Enforced
Citations
Section-aware
Chunking
Prevented
Hallucination
The Problem
Construction compliance work depends on dense, inconsistent specification PDFs. A naive LLM over that content hallucinates — and on compliance-critical answers, a confident wrong answer is worse than none.
The Solution
- Built the full pipeline from scratch: PDF ingestion and section-boundary semantic chunking (not fixed-size) to preserve meaning.
- Generated OpenAI embeddings and stored them in a FAISS vector store for fast retrieval.
- Used the Claude API with citation-only prompting so every answer is grounded in and cites the source spec.
Results
- Compliance answers are traceable to the exact source passage.
- Section-aware chunking eliminated the context-splitting errors of fixed-size chunking.
- Citation enforcement prevents hallucination on compliance-critical content.
Want a system like this?
Let's talk about automating your operations end to end.