Title: AI Asbestos Assessment Report Builder: from Lab PDFs to an Editable Word & PDF Report
Context: An environmental consulting company inspects buildings for asbestos before renovation. On site, a field employee records every suspect material (location, condition, measured area, planned work) and takes samples. An accredited lab tests the samples and returns PDF reports. From these two sources the employee prepares an assessment report for the client in Word and PDF. It covers what was found, where it was found, what a professional should review, and an illustrative removal and replacement cost estimate in CAD.
Problem: The report is assembled by hand from several PDFs, and every step can produce an expensive mistake:
- Lab rows are retyped manually, and sample IDs are matched to locations by eye.
- One floor sample can have two layers with opposite results (tile not detected, adhesive detected). If only the first line is kept, the asbestos is missed.
- Two samples from the same ceiling become two charged areas.
- An unmeasured quantity quietly becomes zero in Excel.
- A “not detected” result for one plaster sample turns into “the building is asbestos-free” in the summary. No inspection company can afford to make that claim.
- After the first correction, the Word file sent for edits and the PDF sent to the client no longer match.
Solution: A web application that takes the employee through the whole report:
project and material register → lab PDF upload → AI extraction with evidence → employee review → automatic matching, review categories and costs → AI-drafted narrative → one report revision exported to Word and PDF, with an in-app preview.
Responsibilities are strictly split: AI reads and drafts, code decides, the employee approves.

Overall logic:
- Project: project header with client, building, address, inspection and report dates, scope, planned work and limitations.
- Materials: the material register. Each zone (M01–M07) has a location, sample IDs, quantity and unit (m², linear m or “Unknown”), condition, planned disturbance, accessibility and a rate reference.
- Lab reports: drag-and-drop upload of lab PDFs. Each file is stored read-only under its SHA-256 hash. Claude extracts every sample layer together with its page and the quoted source line.
- Review → Lab results: the employee checks each row against the line highlighted on the PDF page, then accepts it, corrects it (a reason is required) or rejects it.
- Review → Matching: code matches results to zones by exact sample ID, assigns categories A–D, calculates the cost scenario and lists everything that needs attention.
- Report → Draft: Claude drafts the narrative from verified facts and code guardrails check it. The employee edits the text and completes the final review checklist.