AI engineering services AI that survives
contact with production
Faizan Amir builds production RAG pipelines, agent workflows and LLM features with evaluation, observability and human approval where risk demands it. Five or more RAG and agentic systems have reached production, including legal-document extraction measured at 95% accuracy on its evaluated set.
What this includes
Chunks follow the document hierarchy and retain their ancestry, so retrieved passages arrive with enough context to interpret and cite correctly.
A classifier routes each input to a focused agent with its own tools and validation schema instead of forcing every document through one prompt.
A scored regression set makes pipeline changes measurable. On Agentic RAG, the same 110 cases scored the first version and the rebuild side by side, one same-day run each: answer correctness rose from 91.1% to 95.3% while cost per turn fell 39% at reference prices. On mailagent, the harness came before the extractor and set a 92.9% exact-match baseline against naive floors of 35.7% and 0%.
Actions that change calendars, documents or customer records pause for approval as an explicit step in the agent graph.
Model calls track tokens, latency and price. Unknown cost remains NULL rather than becoming a misleading zero.
How the work runs
- *[01]
Scope the failure mode
Identify what the model gets wrong on real data and whether the failure belongs to retrieval, routing, validation or prompting.
- *[02]
Build the scoring harness
Create a labelled fixture set before tuning so every change can be compared against a stable baseline.
- *[03]
Ship the pipeline
Build ingestion, chunking, retrieval, routing and actions with the simplest inspectable stack that fits the product.
- *[04]
Put a human in the path
Require approval for irreversible actions and show the relevant trace to the reviewer.
- *[05]
Instrument, then iterate
Track token cost, node latency, retrieval hit rate and task accuracy from the first deployment.
Where this has been built
Golegal
AI Legal Workspace
Agentic RAG for legal documents: 95% extraction accuracy on the evaluated set, 100+ files processed monthly and 30% less manual work reported by users.
READ THE GOLEGAL CASE STUDY →Muterpe
AI Image Generation SaaS
Per-user model training and queued generation on Fal.ai, billed by usage and running at 99% uptime over a rolling twelve months.
READ THE MUTERPE CASE STUDY →mailagent
Human-in-the-Loop Scheduling Agent
* IN DEVELOPMENT
A Gmail-to-calendar scheduling agent that books nothing without approval: 92.9% exact match on its 14-email golden set, and every calendar write the agent makes bound to the approved action by an HMAC. In a dry-run pilot.
READ THE MAILAGENT CASE STUDY →Agentic RAG
Document Research Agent
* IN DEVELOPMENT
A multi-tenant document research agent with cited, verified answers. Against its first version on a 110-case benchmark, one run each: 95.3% answer correctness against 91.1%, half the time to first token and 39% lower cost per turn at reference prices. In development.
READ THE AGENTIC RAG CASE STUDY →
[STACK]
- Python
- LangChain
- LangGraph
- OpenAI
- Gemini
- PostgreSQL + pgvector
- FastAPI
- Next.js
Questions about AI engineering
Retrieval-augmented generation gives a model relevant source material at query time. Use it when answers must be grounded in private or changing data, such as contracts, policies or internal knowledge. Generic writing and classification often need only a well-designed prompt.
Preserve document structure during retrieval, route document types to validated extraction paths and test against labelled fixtures. This approach produced 95% extraction accuracy on Golegal’s evaluated set.
Yes. Most engagements add a focused pipeline and API surface to an existing backend rather than rewriting the product. Golegal and medical platforms at Ward Web Solutions followed this approach.
A scoped first version usually takes weeks and includes evaluation data, ingestion, retrieval, one validated task path and instrumentation. Preparing reliable labelled fixtures often takes longer than connecting the model.