AIBuilding a RAG pipeline with OpenAI and Anthropic
How to build a RAG pipeline: chunking, embeddings, vector search, grounding, and evaluation, explained by a team shipping production AI systems.
Bilal Khursheed7 min read
AI service
Assistants that answer from your documents and cite their sources.
The problem
Your knowledge sits in contracts, policies, manuals, wikis and old tickets. People cannot find what they need, so they ask a colleague or guess.
A general-purpose model does not know your documents and will fill the gap with something plausible. That is not acceptable for legal, financial or operational questions.
Retrieval-augmented generation fixes this by looking up the relevant passages first and answering only from them. The quality depends almost entirely on how well the retrieval is built.
Our approach
We review what you have, where it lives, how it is structured and who is allowed to see it.
Parsing, chunking, embeddings and search are tuned to your documents, including long files, tables and scans.
The assistant answers from retrieved passages, cites them, and declines when the sources do not cover the question.
We score retrieval and answer quality on a set of real questions, then launch with monitoring and a way to refresh the index.
Delivery process
Every engagement follows the same seven stages, from requirements to post-launch support.
Workshops with your stakeholders to define goals, users, scope and constraints, captured in clear written requirements.
User flows, wireframes and interface design, reviewed with you until the product feels right before it is built.
Data model, system design, integrations and security are settled, and the work is broken into sprints.
Short iterations with code review on every change and a demo of working software each week.
Manual and automated testing across functionality, devices, APIs and performance, followed by user acceptance testing.
Release through a CI/CD pipeline onto monitored cloud infrastructure, with a go-live checklist and rollback plan.
Close monitoring and priority fixes straight after launch, then ongoing support, maintenance and improvement.
Deliverables
Technology
Related work

AI / LegalTech
Client name withheld
Turns 500 to 1,000 page legal contracts into a queryable knowledge base that answers with cited sources.

AI business tooling
Client name withheld
A conversational AI advisor that asks targeted questions and returns recommendations across marketing, HR, finance, operations, strategy and IT.
From the blog
What we have written about rag & knowledge assistants: cost, timelines and the trade-offs behind each decision.
AIHow to build a RAG pipeline: chunking, embeddings, vector search, grounding, and evaluation, explained by a team shipping production AI systems.
Bilal Khursheed7 min read
FAQ
Retrieval-augmented generation. Relevant passages are fetched from your own content and passed to the model, so the answer is based on your documents and can cite them.
No. The content is indexed and looked up at question time. There is no training run, and updating the assistant means re-indexing content, not retraining.
Yes. Long contracts and reports are split into structured sections and retrieved in pieces. We have built a multi-agent pipeline for long legal contracts on this pattern.
Yes. No system removes errors completely. Grounding, citations and refusal behaviour reduce them, and the evaluation set tells you how often they happen. Citations let users check any answer.
Yes. Retrieval respects your existing permissions, so an answer is only built from content that user is allowed to read.

Share a short brief and we will reply with next steps, usually within one working day.