Jurai Assurance — AI Flight Claim Assessment

A Danish and English flight-claim assessment app that turns journey details and supporting documents into a provisional assessment, then an optional legal review with archived source quotes.

Next.jsFastAPIPostgreSQLOCRLegal AIDocker
Jurai Assurance — AI Flight Claim Assessment cover

Inside the Platform

Screenshots from the running application. Open any image to inspect it at full size.

Jurai Assurance case room with a Copenhagen to London itinerary and guided claim form
Start with the journey: airport lookup, departure date, operating carrier, and passenger attendance details in an English or Danish case room.
Flight disruption form with arrival delay, reported cause, expenses, and supporting document upload
Capture the disruption and supporting evidence. PDFs and images are processed locally using text extraction and OCR when the claim is submitted.
Initial flight-claim assessment with a provisional outcome and an option to request legal reasoning
An initial assessment of an illustrative claim identifies the outlook and missing facts before the user chooses a deeper legal review.
Legal assessment with expanded EU261 Article 3 quote, source attribution, and claim summary
The optional legal review connects each reason to an archived passage. Expand a citation to inspect the exact quote, source link, and collection date. Shown with an illustrative claim.

Timeline

Evolved from the 2025 insurance-case predictor into Jurai Assurance Lite, with the current flight-claim workflow and portable deployment updated in October 2026.

Role & Scope

Built the claim intake and assessment workflow across Next.js, FastAPI, SQLAlchemy persistence, document processing, local law retrieval, citation validation, and Docker packaging.

Team Setup

Developed in the Jurai legal-tech context, with a guided interface for passengers and structured assessment outputs for claim review.

Context

Problem: Passengers need a clear way to assess disrupted flights, bring together tickets and airline messages, and understand which facts and legal sources support a claim.

Solution: Built a Next.js case room and FastAPI backend with a guided claim form, local PDF extraction and Tesseract OCR, bundled airport lookup, and two-stage LLM assessment. The deeper review retrieves passages from 36 bundled legal records and returns reasons with validated citation IDs and exact archived quotes.

Impact: Connected claim intake, document evidence, initial triage, and source-linked legal reasoning in one workflow. Saved facts and documents support review, while cached legal results avoid repeating successful model requests.

Implementation Details

Architecture

Next.js proxies same-origin requests to FastAPI. PostgreSQL stores normalized claim facts, original documents, extracted text, and results. One model request produces a first impression; a second, user-triggered request analyzes locally retrieved law passages. The backend validates citation identifiers and inserts exact archive quotes. OpenAI or Anthropic supplies model inference; airports, OCR, and the legal archive run locally.

Data & Evaluation

Backend tests cover normalization, document validation and extraction, citation grounding, persistence, and deployment boundaries with mocked model calls. Frontend tests cover translations, API and stream handling, and proxy errors. Assessments expose uncertainty and missing facts; quotes establish source traceability without guaranteeing legal correctness or current validity.

Production & Ops

Docker Compose packages the frontend, backend, and PostgreSQL with health checks and persistent storage. Uploads have file, byte, and page limits; inference has stage deadlines; successful legal analyses are cached. A source release bundles airports and the law snapshot while excluding credentials and uploaded documents.

Lessons Learned

Separating provisional triage from an optional legal review makes the workflow easier to follow. Exact source quotes, explicit evidence gaps, and local document processing keep the reasoning inspectable while reducing deployment dependencies.

Links

Last verified: September 1, 2026

Demo on Request

Public Evidence

Last verified: September 1, 2026

This case study summarizes production work delivered under private repositories and confidentiality constraints. Public artifacts are intentionally omitted while keeping the implementation narrative transparent.

AI Legal AssistantQueryLens — Conversational Data Analytics