Mehrium
All Case Studies
Concept / Illustrative Work
AI Engineering

Lumen Copilot

Developing an enterprise-grade document chat assistant extracting legal metadata with fallback verification logic.

99.9%
Semantic Accuracy
The Problem

A legal technology firm needed an AI assistant capable of accurately answering questions about complex contract documents — clauses, obligations, and deadlines — without hallucinating non-existent terms or misattributing provisions between parties.

Our Approach

We built a RAG (Retrieval-Augmented Generation) pipeline using Pinecone for document embedding storage and OpenAI for answer generation. Each document was chunked semantically at clause boundaries to preserve context windows. A confidence-scored citation layer required the model to reference specific document passages before generating answers, with a fallback path that responded with a structured 'not found' signal rather than hallucinating. Helicone provided real-time LLM observability and cost monitoring.

The Outcome

Semantic accuracy — measured as retrieval correctness against a ground-truth QA dataset — reached 99.9% on in-distribution legal document types. Hallucination rate dropped to near-zero after implementing the mandatory citation requirement. Legal teams reported a 60% reduction in manual clause-search time.

Tech Stack
PythonOpenAI APIPineconeHelicone

ⓘ  This is a concept and illustrative case study. It represents Mehrium's engineering design approach and capability depth — not a verified or named client engagement. No client relationship or endorsement is implied.

Solve a problem like this.

Bring us your spec and we'll tell you exactly how we'd build it.

Call us: +1 (510) 851-8447Call us