Case study · Enterprise AI agent & RAG

AI agent & RAG on business data

Isometric illustration: a robotic assistant pulling documents from an archive wall into a chat interface

Design and industrialisation of an AI agent querying a client's internal document base, with personal-data guardrails, Langfuse observability and continuous cost control.

Engagement period: · Page last reviewed on

Context

Industrial client with thousands of internal technical documents (PDFs, intranet, tickets). Field teams were losing significant time looking for information. The stakes: a reliable, traceable agent that doesn't leak sensitive data.

Challenge

Build a production-grade RAG agent: incremental indexing, hybrid retrieval (BM25 and vectors), prompt-injection and personal-data guardrails, fine-grained observability, AI Act compliance, on on-premise or private cloud infrastructure.

Approach

SeedVision delivered pgvector indexing and hybrid retrieval, a LangGraph agent with a guardrail policy, self-hosted Langfuse observability (cost and quality per request), AI Act documentation, Kubernetes deployment and ops team training.

Engagement timeline

  • Agent design and industrialisation. Incremental indexing of internal documents, hybrid retrieval, guardrail policy, self-hosted observability, Kubernetes deployment and training of the ops team.
  • Operations and continuous improvement. 2 years of service: the business test set acts as the gate for every change of model, prompt or indexing method.

Before and after

Finding information

Before: Thousands of technical documents split across PDFs, intranet and tickets: every question turns into a manual search.

After: Internal adoption of over 70% of field teams within 90 days, on hybrid retrieval that queries all three sources at once.

Answer reliability

Before: An agent wired straight to a model always answers, including when it found nothing.

After: Hallucinations cut by a factor of 6 on the business test set, answers tied back to source documents.

Traceability

Before: Without logs, a contested answer can be neither explained nor replayed.

After: Full audit logs, usable for AI Act compliance.

Running cost

Before: An agent without per-query measurement becomes a spend line nobody can forecast or arbitrate.

After: Cost per query under control: under €0.03 on average, measured query by query.

Results

  • Hallucinations cut by a factor of 6 on the business test set
  • Full audit logs for AI Act compliance
  • Cost per query under control: under €0.03 on average
  • Internal adoption: over 70% of field teams within 90 days

Visit the live platform

Technologies and scope

  • LangChain
  • Claude
  • RAG
  • MLOps

Engagement period:

What the engagement covers, block by block

  • Incremental indexing — Only modified documents are re-indexed. A living document base cannot be rebuilt in full on every change: it would be expensive and, in practice, never done.
  • Hybrid BM25 and vector retrieval — Keyword search finds an exact reference, vector search finds a close wording. Together they cover the questions field teams actually ask.
  • Guardrail policy — Filtering of prompt-injection attempts, personal-data control on input and output, and an explicit refusal when no document supports the answer.
  • Self-hosted observability and operations — Langfuse hosted at the client for per-query cost and quality, Kubernetes deployment on-premise or in a private cloud, training for the team running the agent day to day.

What running it demands

  • An agent must be able to say it does not know — The most dangerous answer is the one that looks right without a document behind it. A documented refusal is therefore part of the guardrail policy, just like input filtering.
  • The business test set beats a generic score — Public model leaderboards say nothing about your documents. The test set built with the teams is what authorises — or blocks — a change of model or prompt.
  • Observability stays inside the client's perimeter — Tracing an agent's queries means keeping excerpts of internal documents. Those traces therefore live on the client's infrastructure, like the documents themselves.

Architecture choices, and why

  • Vectors in PostgreSQL rather than a separate engine — pgvector avoids adding one more database to back up, secure and keep alive. As long as the corpus stays in the thousands of documents, one component less beats a theoretical gain.
  • An explicit agent graph rather than an implicit chain — LangGraph makes steps, stop conditions and checkpoints visible. An agent whose path cannot be drawn cannot be audited.
  • On-premise or private cloud deployment — Documents do not leave the client's perimeter: that constraint drove the deployment choice, ahead of the choice of models.

Technical and regulatory milestones

Public, dated facts that constrain the scope.

  • pgvector 0.5. Public fact: that release brings the HNSW index to PostgreSQL. It makes keeping vectors inside the existing database defensible, rather than operating a separate vector search engine.
  • The EU AI Act enters into force. The European regulatory calendar is public. It is that calendar, not an internal requirement, that forces knowing which document and which model produced a given answer.
  • General regime becomes applicable. The deadline at which most of the regulation applies. The audit logs the agent produces are designed to be readable at that date, not reconstructed in a hurry.

Questions about this engagement

Do the client's documents leave its own infrastructure?

No: indexing, the agent and observability are deployed on premises or in a private cloud. The monitoring tool is self-hosted so that request traces stay inside the client's perimeter.

How does the agent avoid making an answer up?

Through hybrid retrieval combining keywords and vectors, a guardrail policy, and the explicit option of answering that it does not know. Measurement runs on a business test set rather than a generic benchmark: that set is what showed hallucinations divided by 6.

What does this platform provide for an AI Act inspection?

Complete audit logs, the expected technical documentation and request traceability. Risk classification and personal-data guardrails are part of the same file.

Related services

Nearby case studies

Related reading on the blog

Talk about your project

Facing a challenge close to Business RAG agent — write to contact@seedvision.fr — reply within 24 hours.