# Reproducible RAG-ingestion lab

Run `python ingestion_cases.py` from the repository root. The lab creates an original synthetic policy corpus in a temporary directory. It generates a three-page PDF with ReportLab, extracts it with pypdf, and verifies page references. It also executes deterministic OCR-quality, chunking, overlap, table, metadata, version, deletion, reindexing, completeness and contract cases.

No external corpus, embedding API, vector database or OCR engine runs. OCR text and embedding-candidate scores are authored fixtures used to demonstrate quality gates and selection records. Python, ReportLab and pypdf package versions are part of the programme checker’s environment evidence.

The verifier must pass twenty checks and writes the complete result to `ingestion-verification.json`. Local success does not establish production scale, document permissions or human approval.

The 20-check verifier passed on 20 September 2026. Review corrected two fixture assumptions before completion: the overlap query initially produced a tie, and the first contradiction detector looked for an overly narrow phrase. The final tests cross a real boundary and compare the changed rule directly.
