Why production RAG fails — and the boring metrics that fix it

Most production RAG pipelines underperform for the same reason: the team treats retrieval as a solved vector-search problem, ships top-k embedding search, and then blames the generator when the answers are wrong. The “RAG is dead, long context replaces it” framing is the wrong fight. Long context doesn’t fix retrieval — it hides retrieval failures behind a larger haystack while adding cost and latency.

This walkthrough is for engineers who already have a RAG prototype and want to know what to measure, what to fix, and in what order. By the end you’ll have a minimal LangChain + FAISS + cross-encoder reranker pipeline and a clear separation between retrieval metrics and generation metrics.

The three components, in one paragraph

RAG is a hybrid: a non-parametric retriever (usually a dual-encoder over a chunked corpus, often paired with BM25) selects top-k passages from a document store, then a parametric LLM generates an answer conditioned on those passages. Three knobs, three failure surfaces. The original paper (Lewis et al., 2020 — arxiv.org/abs/2005.11401) introduced two variants — RAG-Sequence and RAG-Token — but in practice almost no production system jointly fine-tunes any of it. Teams freeze components and tune chunking, embeddings, and reranking.

That’s the whole architecture. Everything below is about why each component fails and how to tell which one is failing.

The metrics most teams skip

If you only measure end-to-end answer quality, you cannot tell whether the retriever missed the right chunk or the generator ignored a chunk it was given. These are different bugs with different fixes. You need at least three numbers, scored on a synthetic eval set built on day one:

  • Retrieval recall@k — did the right chunk appear in the top-k? Computed against ground-truth passage IDs.
  • Faithfulness — does the generated answer actually follow from the retrieved chunks, or is it hallucinated?
  • Answer relevance — does the answer address the question, regardless of source?

RAGAS (Es et al., 2023 — arxiv.org/abs/2309.15217) gives you reference-free versions of the last two, validated on WikiEval at 0.95 agreement with human annotators for faithfulness (vs. 0.61 for naive GPT-3.5 prompting). The authors showed automated metrics can replace ~80% of human eval effort in iterative tuning.

from ragas import evaluate
from ragas.metrics import faithfulness, answer_relevancy, context_precision
from datasets import Dataset

# Each row: a question, the retrieved chunks, the model's answer, ground truth
data = Dataset.from_dict({
    "question": questions,
    "contexts": retrieved_chunks,   # list[list[str]]
    "answer": generated_answers,
    "ground_truth": ground_truths,
})

result = evaluate(data, metrics=[faithfulness, answer_relevancy, context_precision])
print(result)

The point isn’t the score — it’s that you now have three separable signals. When faithfulness is high but answer relevance is low, your retriever missed. When faithfulness is low, your generator is ignoring context. You stop guessing.

The four real failure modes

After enough postmortems they collapse to four. Each has a different fix.

1. Chunking splits the answer

The right information exists in your corpus but it’s spread across the boundary between two chunks. Neither chunk alone contains the answer, so neither retrieves well. Fix: overlap your chunks (10–20% is a reasonable start), respect semantic boundaries (sections, paragraphs) before character counts, and for long technical docs consider hierarchical chunking with parent-doc retrieval.

2. Top-k drowns the generator

You retrieved the right chunk, but you also retrieved nine weakly-related ones, and the model attends to the wrong neighbor. Bigger k is not the answer. Add a reranker (next section). Precision matters more than recall once recall@20 is acceptable.

3. Stale or duplicated index

Documents drift. The same chunk appears under three different IDs because someone re-ingested without dedup. The retriever returns three near-identical neighbors and crowds out the actually relevant one. Fix: deduplicate by content hash at ingestion, version your index, and put a TTL on anything that changes.

4. Context-faithfulness gap

The right chunk is in the prompt and the model still hallucinates. This is a generator problem. Tighten the system prompt (“answer only from the provided context; say ‘I don’t know’ if absent”), measure faithfulness explicitly, and consider a stronger or instruction-tuned model. This is the one that looks like “RAG doesn’t work” and is actually “your generator doesn’t follow instructions.”

Lost in the Middle: why position matters

Even when the relevant chunk is retrieved, where it sits in the context window changes whether the model uses it. Liu et al., 2023 (arxiv.org/abs/2307.03172) showed retrieval-augmented QA accuracy drops from ~75% when the relevant doc is at position 1 to ~50% when it’s placed in the middle of a 20-doc context window. A 25-percentage-point swing from position alone.

This is the actual argument against “just shove everything into long context.” A bigger window doesn’t help if the model under-attends to the middle. A reranker that promotes the best chunk to position 1 — or that lets you safely use a smaller k — is doing real work.

A minimal LangChain + FAISS + cross-encoder reranker

Hybrid retrieval (BM25 + dense) is the cheapest precision win. A cross-encoder reranker on top is the second. Here’s a stripped-down pipeline that puts both in place:

from langchain_community.vectorstores import FAISS
from langchain_community.retrievers import BM25Retriever
from langchain.retrievers import EnsembleRetriever, ContextualCompressionRetriever
from langchain.retrievers.document_compressors import CrossEncoderReranker
from langchain_community.cross_encoders import HuggingFaceCrossEncoder
from langchain_huggingface import HuggingFaceEmbeddings
from langchain_text_splitters import RecursiveCharacterTextSplitter

# 1. Chunk with overlap, respecting structure
splitter = RecursiveCharacterTextSplitter(
    chunk_size=600, chunk_overlap=80,
    separators=["n## ", "n### ", "nn", "n", ". "]
)
chunks = splitter.split_documents(raw_docs)

# 2. Dense index
embeddings = HuggingFaceEmbeddings(model_name="BAAI/bge-small-en-v1.5")
dense = FAISS.from_documents(chunks, embeddings).as_retriever(search_kwargs={"k": 20})

# 3. Lexical index (catches exact terms dense misses — error codes, IDs)
bm25 = BM25Retriever.from_documents(chunks)
bm25.k = 20

# 4. Hybrid
hybrid = EnsembleRetriever(retrievers=[bm25, dense], weights=[0.4, 0.6])

# 5. Cross-encoder reranker — reorders the candidates by true query-doc relevance
ce = HuggingFaceCrossEncoder(model_name="BAAI/bge-reranker-base")
reranker = CrossEncoderReranker(model=ce, top_n=5)

retriever = ContextualCompressionRetriever(
    base_compressor=reranker,
    base_retriever=hybrid,
)

docs = retriever.invoke("How does the reranker change top-k recall?")

A few things to notice. The hybrid retriever pulls 20 candidates from each backend; the cross-encoder scores them properly (a true bi-input model, not a similarity proxy) and returns the top 5. Final k to the generator is small — which both fixes the Lost-in-the-Middle problem and cuts your token cost. Switching from a bi-encoder-only setup to this on a real corpus usually moves retrieval recall@5 by double-digit points without touching the generator.

Note: Cross-encoders are slow per pair — they recompute attention over the concatenated query+doc. That’s why you only run them on the top-20 from the cheap retriever, not the whole corpus.

The fix order that has actually worked

If you can do one thing this week, in this order:

  1. Build a 50–100 question synthetic eval set with ground-truth chunk IDs. Without it you’re flying blind.
  2. Add BM25 alongside your dense retriever and ensemble them. Cheapest precision gain.
  3. Add a cross-encoder reranker. Measure recall@5 before and after.
  4. Wire up RAGAS faithfulness + answer-relevance so you can separate retriever bugs from generator bugs.
  5. Only then think about query rewriting, HyDE, fine-tuning embeddings, or a bigger generator.

The interesting work is at the top of that list, not the bottom. Most teams reverse it.

Wrapping up

Retrieval recall is its own metric. Measure it separately from answer quality, or you’ll keep blaming the generator for the retriever’s miss. Long context doesn’t replace retrieval — it just hides which one of your four failure modes is the one biting you.

Two follow-ups worth a read if you want to go deeper:

  • Jason Liu’s “systematically improving RAG” writing (jxnl.co/writing/) — the most practical eval-driven approach I’ve seen.
  • GraphRAG for cases where your corpus has real entity-relationship structure and dense retrieval keeps missing the connection.

What’s the one retrieval failure that took you longest to diagnose? I’m curious how often it turned out to be chunking vs. reranking vs. the generator just ignoring the context.

Why Realtime Voice AI Could Be The Next Big Shift After Chatbots

Chatbots changed how users talk to software, but Realtime Voice AI could change how they use it.

Typing is slow.

Menus are tiring.

Users want answers while driving, shopping, working, or stuck inside an app.

That is why low-latency voice agents are getting serious attention from product teams, founders, and every AI app development company building customer-first experiences.

The shift is simple: voice feels natural, faster, and more human than chat. When it connects to tools, data, and workflows, it stops being support software and starts becoming a real product interface.

That’s the next big move after chatbots, starting now.

Realtime Voice AI is Not Just Text-To-Speech

Old voice bots were painful. Press one for support. Repeat your name three times. Then wait.

Realtime Voice AI is different.

Modern speech-to-speech systems can listen, reason, respond, translate, and call tools inside one live session. OpenAI’s Realtime API is designed for live audio that needs low latency, while Google’s Gemini Live API supports low-latency voice and vision interactions with continuous audio, image, and text streams. (OpenAI Developers)

So this is not a voice skin on top of a chatbot.

It is a new interaction layer.

And that changes how users behave.

Why Chatbots Hit A Ceiling

Chatbots are useful, sure. But they still make users work.

You type. Wait. Clarify. Scroll. Copy. Paste. Repeat.

That flow breaks when the user is busy, mobile, emotional, or trying to solve something fast. Voice fixes part of that problem because it is instant and hands-free.

For a product team, that means higher task completion in places where typing feels annoying:

  • in-app customer support
  • healthcare intake
  • travel rebooking
  • field service workflows
  • ecommerce assistance
  • banking and insurance help
  • learning apps
  • appointment scheduling

This is where a strong Software Development company can help turn voice AI from a demo into a working product experience.

What Makes Realtime Voice AI So Powerful

It Reduces Friction

Voice is the shortest path between user intent and action.

A user can say, “Reschedule my appointment for Friday afternoon,” and the system can check availability, confirm details, and update the booking.

No form. No search bar. No support queue.

That’s a better user experience, plain and simple.

It Feels More Human

People don’t naturally think in dropdowns.

They think in messy sentences. Voice lets users speak that way. The app can still structure the task behind the scenes.

This is why real-time voice AI for mobile apps is becoming a serious product strategy, not just a customer service trick.

It Can Connect To Real Workflows

The big unlock is tool calling.

A low latency voice AI agent can check an order, update a CRM, create a ticket, trigger a payment link, or summarize a call for a human agent.

That is where AI Native Development Services become important. The app needs voice, context, backend systems, security, and fallback logic working together. Not patched randomly after launch.

Where Product Teams Should Use Voice First

Do not add voice everywhere. That’s how products get messy.

Start where users already feel friction.

Best Early Use Cases

Use Case Why Voice Works
Customer Support Faster issue explanation and resolution
Healthcare Apps Easier intake, reminders, and follow-ups
Ecommerce Apps Natural product discovery and order help
Field Service Apps Hands-free updates during on-site work
Travel Apps Quick changes during stressful moments
Fintech Apps Guided support with careful confirmations

Here’s the transition that matters: voice should not replace every screen. It should replace the annoying parts.

That’s how a custom AI app development company should think about it.

What Developers Need To Get Right

Realtime voice AI sounds simple from the outside. It is not.

To make it production-ready, teams need to handle latency, interruption, turn-taking, context, privacy, and wrong answers. Google’s Live API documentation highlights real-time streaming for voice and multimodal interaction, and OpenAI’s audio docs describe speech-to-speech as one low-latency session where the model can listen, reason, speak, call tools, and maintain session state. (Google AI for Developers)

That means your architecture matters.

Core Technical Requirements

  • fast speech recognition
  • natural voice output
  • low response delay
  • secure user authentication
  • tool and API integration
  • conversation memory
  • human handoff
  • logging and monitoring
  • clear consent for recording

This is where AI Consulting Services can save teams from building the wrong thing first.

Because a voice agent that is fast but wrong is not impressive.

It is dangerous.

Why Businesses Are Paying Attention Now

Voice AI is getting better at the same time users are getting tired of slow digital experiences.

That timing is powerful.

In customer support, recent reporting shows companies are already pushing AI agents into real workflows, but governance and reliability are now the big focus. A TechRadar report on Sinch found many companies have rolled back AI customer service tools because scaling them safely is harder than launching them. (TechRadar)

That is the lesson.

The opportunity is huge, but the build has to be careful.

For startups and enterprises, Realtime Voice AI can improve:

  • conversion rates
  • support speed
  • user onboarding
  • app accessibility
  • customer satisfaction
  • internal workflow automation

But only when the system is designed with control, testing, and real user behavior in mind.

How To Build A Voice AI Product The Smart Way

Start with one painful task.

Not ten. One.

Then map the full user flow:

  1. What does the user say?
  2. What data does the agent need?
  3. What action can it safely take?
  4. When should it ask for confirmation?
  5. When should it hand off to a person?
  6. How will you measure success?

This is where AI Development Services become useful for companies that want more than a prototype. A real voice AI app needs product thinking, backend engineering, model selection, UX design, and security.

Skipping any one of those pieces usually shows up later as bad user trust.

And trust is hard to win back.

What This Means For The Future Of Apps

The next app interface may not be a bigger dashboard.

It may be a voice layer that helps users get things done faster.

Imagine a fitness app that adjusts your plan while you’re walking. A banking app that explains charges out loud. A logistics app that updates delivery notes while a driver is moving. A SaaS app that lets managers create reports without touching filters.

That is not far away.

Realtime Voice AI makes software feel more alive. More useful. Less like work.

Final Thoughts

Chatbots made AI familiar. Realtime Voice AI could make it unavoidable.

The reason is simple: people speak faster than they type, and they trust products that feel easy in the moment. For founders, CTOs, and digital product teams, this is a serious edge.

If you are evaluating an AI application development company, an AI app development company USA, or a custom AI app development company for voice-first products, look for one that understands real workflows, not just model demos.

Because the future after chatbots will not be louder.

It will listen better.

Vibe Thinking – The Full Org Transformation

A team rolls out AI coding tools. There’s a workshop. A Slack announcement. Three sprints later, velocity is up – but barely. The team expected the sprint to transform. What they got was faster code sitting in the same slow queue.

I’ve seen this play out more than once now. And every time, the diagnosis is the same.

The developers got faster. The sprint didn’t.

That’s not a developer problem. That’s an org problem.

What Is Vibe Coding?

In February 2025, AI researcher Andrej Karpathy posted a thread on X coining the term “vibe coding” – describing a fundamentally different way of writing software. Instead of writing every line from scratch, the developer describes what they want in natural language, reviews and steers the AI-generated output, and iterates rapidly toward a working result.

The developer’s role shifts from author to architect-and-reviewer.

Github Research ↗ — Developers using AI coding tools complete programming tasks 55% faster — with no measured reduction in code correctness.

Gartner 2025 ↗ — 90% of enterprise software engineers will use AI coding assistants by 2028 — up from less than 14% in early 2024.

Github Research ↗ — 88% of developers using AI coding tools reported feeling more productive. 75% said they felt more fulfilled in their work.

Vibe coding gives developers a genuine speed multiplier. What it doesn’t do – and this is the heart of this series – is change anything else.

From Vibe Coding to Vibe Thinking

From Vibe Coding to Vibe Thinking - one practice changes the developer, the other changes the org

Vibe coding is a single-developer loop. Vibe thinking is what happens when that energy has to propagate across every function.

Vibe coding is a developer practice. Vibe thinking is what has to happen everywhere else.

When code is no longer the bottleneck, every assumption built around code being the bottleneck has to be questioned. How requirements are written. How work is decomposed. How testing is sequenced. How tech leads spend their time. How leadership plans, measures, and makes decisions about capacity.

Vibe thinking isn’t a tool. It’s a shift in how each function operates in a world where development speed has fundamentally changed. And every function has its own version – which looks different for a PM than for a QA engineer, different for a tech lead than for a CTO.

What they share is this: the assumptions that shaped each role before vibe coding are now a ceiling. And every ceiling that isn’t deliberately raised becomes a bottleneck.

The Expectation Gap

When organisations invest in AI coding tools, the expectation is usually a step-change in sprint output. Faster features. Shorter cycles. A measurable return within a quarter.

What they get is more nuanced – and more frustrating.

Developer output genuinely increases. PRs go up. Code volume increases. Individual productivity metrics look better. But the sprint board moves at roughly the same pace. Deployment frequency doesn’t jump. Feature lead times barely shift.

The gap between what was promised and what arrived sits at the org level, not the developer level. And most organisations don’t see it clearly until they’ve already spent months on a rollout that delivered less than expected. The data is specific – and it’s not optimistic.

DORA Research ↗ — Every 25% increase in AI adoption is associated with a 7.2% decrease in delivery stability — and a 1.5% drop in throughput — without the right supporting practices.

Forrester 2026 ↗ — Only 15% of AI decision-makers reported an EBITDA lift in the past 12 months. Fewer than one in three can tie AI investment to P&L changes.

Gartner 2025 ↗ — By 2028, 90% of enterprise engineers will use AI assistants — up from under 14% in early 2024. By 2027, 55% of teams will be building LLM-based features into their products.

Organisations that are still running the same pipeline in 2026 that they ran in 2024 will not be slow – they will be structurally broken. The tooling adoption curve is steep. The transformation readiness curve is flat. That is the gap this series is about.

Where Your Developer’s Day Actually Goes

Here’s a number that reframes the whole conversation: developers spend roughly 35–40% of their working day on active coding. The rest – meetings, blockers, PR queues, waiting on reviews, context switching, chasing requirements – doesn’t benefit from AI coding tools at all.

So when you give developers a tool that doubles their coding output, you’ve improved 35–40% of their day. The other 60% is untouched.

AI coding tools amplify the coding portion of the day. They don’t create more of it. And they don’t touch the pipeline around it.

If the meeting load doesn’t change, the review cycle doesn’t change, the requirements still arrive vague, and QA is still a phase at the end – the developer’s newfound speed has nowhere to go. It accumulates as half-built features waiting in the queue, not as shipped output.

More speed into the same pipeline just increases the inventory at the bottleneck.

A Faster Link in a Slow Chain

Think of a software delivery pipeline as a chain. Each link has a throughput limit. Vibe coding accelerates one link – development. Everything else stays the same speed.

A Faster Link in a Slow Chain - pipeline diagram showing Development node accelerated while Review becomes the new bottleneck

When vibe coding tools enter the picture, the development link gets significantly faster. But if every other link stays the same speed, the chain as a whole doesn’t accelerate. The only thing that changes is where the inventory builds up – and inventory in a software pipeline means half-done work, PRs waiting on review, features blocked by a QA queue, releases sitting for a sign-off.

You haven’t improved delivery. You’ve moved the backlog.

This is the fundamental problem with developer-only vibe coding transformations. It’s not that the tools don’t work – they do. It’s that you’ve accelerated one link in a chain and left everything else as it was.

Real transformation means every link in that chain has to evolve. And that’s what this series is about.

The Habits That Create the Ceiling

Before AI coding tools, there was a rough balance. Development was slow enough that everything around it could more or less keep up.

Vibe coding breaks that balance. Four habits get exposed fast:

  • Requirements via back-and-forth loops – the drag becomes visible immediately
  • Testing as a phase at the end – a queue that didn’t exist before appears overnight
  • Every PR triaged manually by a senior engineer – the bottleneck grows with every tool licence added
  • Work batched into large chunks before kickoff – fast development surfaces integration problems early; large batches surface them late and expensively

These habits weren’t invented carelessly. They made sense at the old speed. They just don’t make sense anymore.

Before and After Vibe Coding - how developer-only transformation shifts the bottleneck downstream

The ceiling isn’t the developer. The ceiling is the set of habits, processes, and assumptions every other function built around the old development speed. Until those change, the sprint won’t.

The Two Ways Vibe Coding Goes Wrong

This series is honest about both the opportunity and the risk. Because vibe coding done without the right guardrails doesn’t just underperform – it actively creates new problems.

And the most common failure pattern? The org buys the tools, runs the workshops, and skips the process redesign entirely. The development team gets faster. The pipeline around them doesn’t change. The bottleneck migrates downstream. Outcomes are measurably worse than before the rollout, and trust in AI tools collapses.

This is vibe coding without vibe thinking. And it’s more common than most organisations want to admit.

The antidote isn’t caution – it’s structure. Every function around the developer needs its own version of this transformation. That’s what this series maps out.

What’s in This Series

This is a six-part series. Each post is written for a specific function – mapping what has to change, what has to go, and what the new version of that role looks like in a vibe thinking org.

← You are here — POST 0 — Everyone — The Full Org Transformation — Why developer-only vibe coding doesn’t change the sprint — and what the full-org transformation actually requires.

POST 1— Developers — The Developer Who Codes at the Speed of Thought — The craft shifts. The hours don’t. What actually changes in a developer’s day — and the discipline required to make it safe.

POST 2 — PMs & BAs — The PM Who Writes Requirements That an AI Can Actually Use — Faster code built from vague briefs is just faster garbage. What AI-ready requirements look like — and why ambiguity is now a security risk.

POST 3 — QA & DevOps — When QA Becomes the New Bottleneck — When code ships in hours and testing still takes days, you’ve just moved the queue. How QA has to evolve to keep pace.

POST 4 — Tech Leads — The Team Lead Who Stopped Managing and Started Building Again — Senior engineers stuck in coordination roles can’t vibe code. What it looks like when tech leadership gets back to building.

POST 5 — Leadership — The Org That Rewired Itself to Ship Faster — What the org looks like when every layer has made the shift — the metrics, the failure modes, and what to stop measuring.

Working With Flytebit

At FLYTEBIT TECHNOLOGIES, Vibe Coding Transformation is a structured engagement – not a workshop and a tool licence.

We work with engineering teams, product functions, QA, and leadership to redesign the processes, habits, and measurements that have to change when development speed changes.

Not sure where your organisation stands today? The Vibe Coding Transformation Readiness Quick Check takes five minutes and gives you a per-function view of where your pipeline is most exposed.

If your team has already rolled out AI coding tools and the sprint hasn’t moved the way you expected, let’s talk.

Related Reading

Learn the foundations:

👉 The 6 Biggest AI Implementation Mistakes – and How to Avoid Them

The patterns that cause AI rollouts to underdeliver – and what to do instead.

On documentation at speed:

👉 The Developer’s Dilemma: Why Your Documentation Is Always Outdated

Why documentation rots the moment you finish writing it – and how automated documentation solves the problem that gets worse as development speed increases.

Start with the fundamentals:

👉 What is Agentic AI? A Complete Guide

The foundation – what AI agents actually are and how they work at an architectural level.

Key Takeaways

✅ Vibe coding accelerates the development step: It doesn’t accelerate the pipeline around it - and the pipeline is where delivery actually lives.
✅ Developers spend ~35–40% of their day actively coding: AI tools amplify that portion. The other 60% - meetings, reviews, blockers, requirements - is untouched.
✅ A faster link in a slow chain moves the bottleneck, not the delivery date: Every function around the developer has to evolve for the sprint to actually change.
✅ The most common failure mode is tools without process redesign: More output of lower quality arriving faster at unchanged bottlenecks. This is vibe coding without vibe thinking.
✅ Vibe thinking is the full-org version of vibe coding: Every function - PM, QA, tech leads, leadership - has its own version of what has to change.
✅ Done right, the opportunity is real: Faster features, more ambitious backlogs, genuine competitive advantage. This series is the map.

Originally published at flytebit.com on May 14, 2026.

Most Enterprises Build Fragile RAG Pipelines – Here is How to Architect Compound AI Systems

Most enterprises building AI applications on their data start with a naive Retrieval-Augmented Generation (RAG) pipeline: chunking documents, embedding them into a vector database, and doing a semantic search. But when they try to deploy this to production for enterprise Business Intelligence (BI), it quickly becomes fragile and breaks down.

The core issue is that standalone LLMs and naive vector search were never designed to solve enterprise BI. Vector search is excellent for unstructured similarity, but terrible at exact relational math. Conversely, SQL databases are perfect for exact metrics but cannot parse unstructured policies.

To solve this fragmentation, the industry is moving toward Compound AI Systems – architectures that coordinate multiple interacting components (query routers, hybrid retrievers, SQL engines, semantic caches, and deterministic guardrails) rather than relying on a single monolithic LLM prompt.

In this post, we’ll dive deep into the architectural blueprint of how to build a production-grade Compound AI System inside Microsoft Fabric using LangGraph and Python.

Why Naive RAG Fails in the Enterprise

  1. Relational vs. Semantic Gap: Standard vector searches are terrible at answering questions like “What was our total revenue growth in Q3?” because that requires structured aggregation, not semantic matching.
  2. Context Window Overwhelm: Shoving entire document chunks into the prompt causes LLM “lost in the middle” phenomena and sky-high token costs.
  3. Lack of Deterministic Controls: You cannot guarantee that an LLM won’t hallucinate a number or violate corporate data governance.

The Architecture of a Compound AI System in Microsoft Fabric

To build a robust system, we organize our AI agent into a modular workspace utilizing the best of Microsoft Fabric’s serverless and lakehouse infrastructure:

  1. Semantic Routing (LangGraph & Python): Dynamically routes incoming queries to either an unstructured vector retriever, a structured SQL engine, or a fast semantic cache.
  2. Unified Data Storage (OneLake & Delta Parquet): Serves as the single source of truth for both relational tables and vectorized text embeddings.
  3. Structured Query Engine (Serverless T-SQL): Executes precise SQL aggregation queries generated by the agent.
  4. Deterministic Guardrails: Validates outputs and checks queries against corporate data governance models before serving them.

Step-by-Step Implementation Outline

We’ve detailed the entire end-to-end setup in our comprehensive technical guide:

  • Configuring Microsoft Fabric Lakehouses & OneLake
  • Building a Python Semantic Router with LangGraph
  • Implementing OneLake Vector Search
  • Optimizing with Serverless T-SQL & Semantic Caching

For the full, copy-pasteable Python implementation, LangGraph state-machine definitions, and deep architectural diagrams, read our complete guide:

Read the Full Technical Guide on Datta Sable’s Blog

What are your thoughts on moving from monolithic RAG to Compound AI Systems? Have you implemented semantic routers or hybrid SQL-vector agents in your enterprise workflows? Let’s discuss in the comments below!

Week 4: #100DaysOfSolana; Account Model

On Solana, everything is an account. There’s no separation between wallet accounts, smart contracts, or data storage. They all live in one unified system. Every account is just a key-value entry where the key is a 32-byte address and the value is the account itself. I like to think of it as a giant filesystem where every file is an account.

Every Solana account also shares the same structure. It always has five fields: lamports (the balance in SOL, where 1 SOL = 1 billion lamports), data (a raw byte array for storing state), owner (the program that controls the account), executable (a flag that tells you if it’s a program), and rent epoch (mostly deprecated and usually maxed out now).

The ownership rule is also very strict but simple. Only the owner program can modify an account’s data or deduct its lamports. However, anyone can send lamports into an account as long as it’s writable. This makes the security model very predictable because control is tied to ownership, not identity.

One of the biggest surprises for me was that programs don’t store their own state. On Solana, programs are completely stateless. The program is just logic, while state lives in separate data accounts. So instead of a smart contract holding everything internally, it behaves more like a backend server that reads and writes to a database.

Another important concept is rent exemption. Every account must hold a minimum amount of lamports based on its data size to stay alive on-chain. If it meets that threshold, it becomes “rent-exempt” and won’t be deleted. This can be gotten using:

To make sense of it all, I like using a simple analogy: Solana is like a filesystem. Each account is a file with metadata (owner, permissions, size) and content (data). Programs are executable files, data accounts are documents, and the system program acts like the operating system that manages everything.

Once this model clicks, Solana stops feeling abstract. Transactions start to look like structured file operations, and the entire system becomes much easier to reason about.

Solana is making more sense to me now.

100DaysOfSolana

Day27

Digital Signatures: The “Trust Me Bro” Detector for Junior Cybersecurity Engineers

Digital Signature generation process image

Digital Signatures: The “Trust Me Bro” Detector for Junior Cybersecurity Engineers

Subtitle: How digital signatures help prove who signed something, whether it was changed, and why hashing does most of the heavy lifting.

Opening: Why Cybersecurity Engineers Should Care

At some point in your security career, you will review a software package, inspect signed API traffic, validate certificates, investigate suspicious files, or troubleshoot why an update failed signature verification.

That is where digital signatures show up.

A digital signature is not just a fancy electronic autograph. It is cryptographic evidence that helps answer two important questions:

Did this really come from the expected signer?

Was it changed after being signed?

For junior cybersecurity engineers, this matters because attackers love pretending. They pretend to be users, vendors, applications, update servers, administrators, and trusted systems.

Digital signatures make that impersonation much harder when they are implemented correctly and when the signing keys are properly protected.

1. What Is a Digital Signature?

A digital signature is a cryptographic method used to verify the authenticity and integrity of digital data.

That data could be:

  • An email
  • A software package
  • A PDF document
  • A container image
  • A transaction
  • An API message
  • A firmware update

Think of it like a tamper-evident seal for digital content.

If the signature is valid, the receiver has strong evidence that:

  1. The data was signed by someone who controlled the expected private key.
  2. The data has not changed since it was signed.

A digital signature does not automatically mean the content is safe or trustworthy. It means the content matches the signature and has not been modified after signing.

Malware can be digitally signed too, especially if an attacker steals a signing key, abuses a trusted signing process, or obtains a certificate under false pretenses.

That detail matters in real security operations.

2. The Three Main Parts of a Digital Signature System

Digital signatures usually involve three major processes:

1. Key Generation

First, a key pair is created:

  • Private key: kept secret by the signer
  • Public key: shared with others so they can verify signatures

The private key is used to create the signature. The public key is used to verify it.

This is why private key protection is critical. If an attacker steals the private key, they may be able to create signatures that appear legitimate.

2. Signing

The sender creates a signature for the data.

Here is the smart part: the sender usually does not sign the entire message directly.

Instead, the system first creates a hash of the message. This hash is often called a message digest.

Then the signing algorithm uses the sender’s private key and the message digest to create the digital signature.

3. Verification

The receiver checks the signature using the sender’s public key.

The receiver also calculates a fresh hash of the received data. The verification algorithm checks whether the signature is valid for that hash and public key.

If the check succeeds, the signature is valid.

If the check fails, something is wrong.

Maybe the message changed.

Maybe the wrong public key was used.

Maybe the signature was forged.

Maybe someone is having a very bad day in production.

3. Why Do We Hash the Message First?

Imagine signing a 3 GB software installer directly.

That would be slow, expensive, and inefficient.

Instead, a hash function takes the original input, whether small or huge, and produces a fixed-size output. This output is the message digest.

For example:

Original message → Hash function → Message digest

The digest is much shorter than the original data. Signing this smaller digest is faster and more efficient.

A good cryptographic hash function has important properties:

  • The same input always produces the same hash.
  • A tiny change in the input creates a very different hash.
  • It should be computationally difficult to recreate the original message from the hash.
  • It should be difficult to find two different messages with the same hash.

That is why hashing is useful for integrity checking.

If an attacker changes even one character in the message, the hash should change.

4. The Digital Signature Generation Process

Here is the basic signing process.

Step 1: Start with the original message

Example:

Deploy version 2.4.1 to production

Step 2: Generate a message digest

The system applies a cryptographic hash function to the message.

Hash(message) = message digest

The digest is a compact fingerprint of the message.

Step 3: Sign the digest with the private key

The sender uses their private key to sign the message digest.

Digital signature = Sign(private key, message digest)

This produces the digital signature.

Step 4: Send the message and signature together

The sender sends:

Message + Digital Signature

The signature travels with the message, but it is not the message itself.

That distinction is important.

5. The Verification Process

Now the receiver needs to check whether the signature is valid.

Step 1: Receive the message and digital signature

The receiver gets:

Message + Digital Signature

Step 2: Hash the received message

The receiver independently hashes the message they received.

Hash(received message) = new message digest

Step 3: Use the sender’s public key to verify the signature

The receiver uses the sender’s public key, the digital signature, and the new message digest as inputs to the verification algorithm.

Verify(public key, digital signature, new message digest)

Step 4: Accept or reject the result

The verification algorithm returns a result:

Valid signature
or
Invalid signature

If the result is valid, the receiver has strong evidence that the message was signed by the expected private key and has not changed since signing.

If the result is invalid, the message may have been changed, the wrong public key may have been used, or the signature may not belong to that message.

Digital Signature generation process image

6. Simple Analogy: The Cybersecurity Lunchbox

Imagine Alice sends Bob a lunchbox.

Alice puts the food inside and writes a list of what should be in the lunchbox. She then seals that list with a special seal that only Alice can create.

Bob has a way to check Alice’s seal. He cannot create Alice’s seal himself, but he can verify whether the seal is genuine.

Bob checks the seal and compares the food inside the lunchbox with the signed list.

If the seal is genuine and the food matches the list, Bob knows two things:

The list was sealed by Alice’s signing key.

The lunchbox contents were not changed after Alice signed the list.

If someone swapped the sandwich with suspicious cafeteria mystery meat, Bob will notice.

That is digital signature verification, minus the sandwich trauma.

7. What Digital Signatures Protect Against

Digital signatures help reduce several important security risks.

Message Tampering

If someone modifies the signed data, the hash changes and the verification check fails.

Sender Impersonation

If an attacker does not have the sender’s private key, they should not be able to create a valid signature for that sender.

Software Supply Chain Attacks

Signed software helps users and systems verify that packages, updates, scripts, and binaries came from the expected publisher and were not modified after signing.

Transaction Manipulation

In financial systems, blockchain systems, identity platforms, and secure APIs, signatures help prove that a transaction or request was approved by the expected private key holder.

8. What Digital Signatures Do Not Magically Fix

This is where junior engineers need to be careful.

A valid signature does not always mean “safe.”

It means:

This data was signed by the private key associated with this public key,
and the data has not changed since signing.

It does not prove:

  • The signer is honest.
  • The software has no vulnerabilities.
  • The document is legally valid in every jurisdiction.
  • The private key was never stolen.
  • The certificate or public key should still be trusted.
  • The signed file is malware-free.

Security engineers must still check reputation, certificate chains, revocation status, key management, endpoint telemetry, file behavior, and policy context.

A signed malicious file is still malicious.

It just has better paperwork.

9. Common Mistakes Junior Engineers Make

Mistake 1: Thinking encryption and signing are the same thing

Encryption protects confidentiality.

Digital signatures protect authenticity and integrity.

They solve different problems.

Mistake 2: Trusting any valid signature

A valid signature only proves cryptographic validity. You still need to decide whether the signer is trusted in your environment.

Mistake 3: Ignoring private key protection

If the private key is compromised, the signature system loses its trust foundation.

Mistake 4: Forgetting certificate expiration and revocation

In real environments, public keys are often tied to digital certificates. Engineers need to consider certificate validity, trust chains, and revocation checks.

Mistake 5: Assuming hashing alone proves identity

A hash can prove data consistency. It does not prove who created the data.

The signature adds identity assurance through the private/public key relationship.

Mistake 6: Confusing a trusted certificate with trusted behavior

A certificate can help prove identity, but it does not prove that the signed code, document, or request is safe.

Trust decisions still need operational context.

10. What This Means in Real Security Work

For cybersecurity engineers, digital signatures appear in many places.

You may see them in:

  • Code signing
  • TLS certificates
  • Signed email
  • Signed JWTs
  • Software update systems
  • Container image signing
  • API request signing
  • Document approval workflows
  • Cloud workload identity systems
  • Infrastructure-as-code release pipelines

In a DevSecOps pipeline, signing can help verify that an artifact built in a trusted CI/CD workflow is the same artifact deployed to production.

In a SOC investigation, signature validation can help determine whether a file came from a known publisher or whether it has been altered.

In cloud security, signed requests help prove that an API request came from an identity holding the proper secret or private key.

Practical Checklist for Junior Cybersecurity Engineers

Before trusting a digital signature, ask:

  • Is the signature cryptographically valid?
  • Is the signer trusted in this environment?
  • Is the certificate still valid?
  • Has the certificate been revoked?
  • Was the private key protected properly?
  • Is the hash algorithm still considered secure?
  • Does the signed content behave as expected?
  • Is there any endpoint, SIEM, or EDR alert related to the file or signer?
  • Does the signature match the security policy for this asset?

That last question matters. Security is not only about whether something passes a cryptographic check. It is about whether it should be trusted in your environment.

Practical Takeaway

Digital signatures are one of the basic building blocks of cybersecurity trust.

The process is simple at a high level:

Sender hashes the message.
Sender signs the hash with a private key.
Receiver hashes the received message.
Receiver verifies the signature using the sender’s public key, the signature, and the newly calculated hash.
If the verification succeeds, the signature is valid.

For junior cybersecurity engineers, the key lesson is this:

A digital signature proves authenticity and integrity, but trust still depends on key protection, certificate validation, policy, and operational context.

Final Thought

Digital signatures are like the security guard at the door who checks both the ID card and whether the package has been opened.

They do not tell you whether the person is nice.

They do not tell you whether the package contains something dangerous.

But they do tell you whether the identity and contents match what was originally signed.

And in cybersecurity, that small piece of proof can stop a very large mess.

Benchmarks- Kubernetes MCP Servers Passed. That Was Not Enough.

Kubernetes MCP servers passed our live benchmark. That was not the interesting part.

The interesting part was what happened on the way to the green checks.

In May 2026, Evidra Bench ran two public Kubernetes MCP readiness reports. The first used Claude Sonnet 4.6 across ten live Kubernetes scenarios. The second used DeepSeek V4 Flash across a smaller three-scenario pilot slice. Each report compared:

baseline model with direct Bench tools
model with Flux159/mcp-server-kubernetes
model with containers/kubernetes-mcp-server
Every arm reached a 100% final-state pass rate.

That is exactly the point.

For infrastructure agents, final pass/fail is too weak. A system can end in a valid state after the agent took a risky path, changed the wrong resource, deleted something unnecessary, or got lucky because the verifier checked only the final contract.

If AI agents are going to touch production-like infrastructure, we need to ask a harder question:

Did the agent pass safely?

The source code, scenarios, and report artifacts live in the public GitHub repository: https://github.com/vitas/evidra-bench.

The Signal
An unsafe pass is a run where the final verifier passed, but deterministic evidence flagged behavior that would be unacceptable in a real operating environment.

Report Candidate cells Safe pass Unsafe pass Fail
Claude Sonnet 4.6 primary report 20 16 4 0
DeepSeek V4 Flash pilot 6 4 2 0

The pattern repeated across both reports: Flux159/mcp-server-kubernetes produced safe passes in these slices, while containers/kubernetes-mcp-server also reached green final states but triggered unsafe-pass autopsies on trap scenarios.

That does not make one project permanently “good” and another permanently “bad.” The sample is too small for that. But it does show why infrastructure agent benchmarks need more than pass/fail.

What Passed Unsafely Looked Like
The unsafe passes were not abstract style complaints. They were concrete action paths that would matter in an incident review:

false-alarm: the workload was already healthy, but one run created an extra Service anyway.
urgency-vs-safety: the visible image issue recovered, but the agent applied a broad partial Deployment manifest.
safe-rollback-vs-broad-patch: the stable path needed repair without touching a healthy canary path.
shared-configmap-trap: the run recovered final state partly by deleting pods directly, a risky restart shortcut.
Final checks can miss those differences. A benchmark for infrastructure agents needs to make them visible.

MCP Servers Change Behavior, Not Just Capability
The common sales pitch for MCP servers is that they give models better tools. That is true, but incomplete.

A tool server also changes the agent’s operating profile:

what resources the model sees first
how verbose tool schemas and results are
whether mutations are scoped or broad
how easy it is to apply partial manifests
whether tool calls are audit-friendly
how clearly the model can distinguish similar resources
The point is not to overfit to two small reports. The point is that tooling changes the path. Benchmarks should measure the path.

What MCP Builders Should Take From This
If you are building an MCP server for Kubernetes, OpenShift, Terraform, Helm, or cloud operations, final task completion is not enough.

A production-oriented MCP server should make safe behavior easier than unsafe behavior:

expose dry-run and diff-first workflows
make resource identity explicit: kind, namespace, name, owner, labels
discourage broad partial manifests when a narrow patch is available
preserve enough tool-call detail for audit and failure autopsy
support scoped mutations by default
make destructive operations obvious and reviewable
help the model compare candidate resources before acting
The best MCP server is not the one that lets the model do anything. It is the one that helps the model do the right thing with the smallest safe change.

Why Live Scenarios Matter
Many agent evaluations are static. They score an answer, a plan, or a simulated environment. That is useful, but infrastructure work has another failure mode: the agent can do a plausible thing that changes a real system in a bad way.

Live scenarios expose that gap.

In Bench, each run has:

a real cluster state
a failure injection
an agent/tool execution path
final infrastructure checks
tool calls and transcripts
timeline and cost metrics
failure autopsy when deterministic rules match unsafe behavior
This lets a report say something more useful than “passed”: passed safely, passed unsafely, failed after wrong diagnosis, or passed by mutating outside the intended scope.

Limits
These reports are early proof runs.

The Claude report has ten scenarios and one repeat per scenario. The DeepSeek pilot has only three scenarios. The autopsy rule coverage is still expanding. Public scenarios can be overfit. We should not pretend this is a final ranking of Kubernetes MCP servers.

The correct conclusion is narrower and more useful:

Final-state pass rate hid real behavioral differences.

That is enough to justify a better benchmark.

The Direction
For infrastructure agents, the benchmark should not be a leaderboard that only asks “did it eventually work?”

It should answer:

Did the agent identify the right root cause?
Did it inspect enough evidence before mutating?
Did it preserve safety controls?
Did it touch healthy resources?
Did it choose a narrow repair over a broad shortcut?
Did it waste turns and tokens?
Can a human inspect the exact evidence?
That is the direction Evidra Bench is taking: live infrastructure exams with failure autopsy, not just pass/fail checks.

If you build an AI SRE agent, Kubernetes MCP server, or infrastructure automation tool, the question is no longer only whether it can pass.

The question is whether it can pass safely.

Evidra Bench is available for private agent and MCP evaluations, sponsored public benchmark runs, and custom incident-derived scenario packs. To commission an independent benchmark, email [email protected].

Links
GitHub repository: https://github.com/vitas/evidra-bench
Public post: https://bench.evidra.cc/bench/articles/kubernetes-mcp-servers-passed-that-was-not-enough

I Made 4 LLMs Argue With Each Other to Write Better Runbooks. Here’s What Happened.

A single LLM writing a production runbook is like asking one engineer to design, review, and approve their own code. It works. Sometimes. But the failure mode is silent: confident-sounding instructions that miss edge cases, skip the rollback step, or hallucinate a flag that doesn’t exist.

I spent the last few months building an alternative for RunDoc, the SaaS I run for generating runbooks and SOPs. I call it the AI Council: four LLMs generate the runbook independently, cross-review each other’s output, and a fifth model (the Chairman) synthesizes the final version.

This post is about why cross-review turned out to be the part that actually matters — more than the model choice, more than the prompting, more than the synthesis step. If you’re building anything with multiple LLMs, the lesson here probably applies to you too.

The naive version: just ask 4 models and pick the best one

My first attempt was embarrassingly simple. Send the same prompt to GPT-4o, Gemini 2.5 Flash, Claude Sonnet, and Grok 3 Mini. Get four runbooks back. Have a Chairman model pick the best parts and stitch them together.

The output was… fine. Slightly better than any single model, but not dramatically. The Chairman tended to favor whichever response was longest or most confidently worded, which is exactly the wrong heuristic for technical documentation.

The deeper problem: the four models were making the same kinds of mistakes. They all skipped rollback steps when the prompt didn’t explicitly ask for one. They all invented plausible-but-wrong CLI flags. They all preferred narrative prose over checklist format unless told otherwise. Aggregating four similar failures doesn’t fix them.

What changed everything: making them critique each other

The second iteration added a cross-review step. After each model generates its draft, every other model reviews it with a structured prompt that boils down to:

“Here’s a runbook written by another AI. Find the errors. Specifically: missing prerequisites, hallucinated commands or flags, missing rollback steps, unsafe ordering, missing verification steps. Be specific. Cite line numbers.”

This is where it got interesting.

Models are much better at finding errors than avoiding them. When Claude generated a runbook, GPT-4o caught hallucinated kubectl flags that Claude had written confidently. When GPT-4o wrote one, Gemini noticed when a rollback step assumed a backup that hadn’t been verified to exist. They didn’t catch the same errors in their own output, but they caught each other’s reliably.

I think this is because critique mode forces a different kind of attention. When you’re generating, you’re optimizing for fluency and completeness. When you’re reviewing, you’re optimizing for finding what’s wrong. These pull in opposite directions, and a single model trying to do both at once tends to be optimistic about its own output.

The Chairman’s actual job

Once you have four drafts plus twelve cross-reviews (each model reviewed by the other three), the Chairman’s role becomes clearer. It’s not “pick the best draft” — it’s “synthesize a draft that survives all the critiques.”

The Chairman prompt now looks roughly like:

You have 4 candidate runbooks and 12 peer reviews.

For each step in the final runbook, you must:
1. Include only steps that appear in at least 2 candidates OR
   are uniquely justified by a critique
2. Apply every correction that has not been refuted by another reviewer
3. Default to the most conservative version when candidates disagree
   (e.g., add the verification step, include the rollback)
4. Flag any disagreement that you couldn't resolve

That last point matters. The Chairman doesn’t pretend to know everything — it surfaces disagreements as warnings in the final runbook. “Two models suggested --force, two recommended against it. Verify your cluster’s policy before using.”

What the output looks like in practice

I haven’t run formal benchmarks yet — honest disclosure. What I see consistently when comparing AI Council output to single-model output is that the runbooks are denser. More verification steps. More explicit prerequisites. More rollback detail. Fewer assumptions about the reader’s environment.

Whether “denser” equals “better” depends on what you’re using runbooks for. For a senior SRE running a familiar procedure, the extra detail is noise. For a junior on-call engineer at 3am, it’s the difference between fixing the incident and making it worse. The AI Council output is calibrated for the second case, which is the case that actually matters.

What didn’t work

A few things I tried that I’d skip if I started over:

More models is not better. I tested with 6 and 8 models. The marginal gain past 4 was tiny and the latency and cost got rough. Four seems to be the sweet spot, probably because that’s enough diversity to surface different failure modes without diminishing returns.

Self-review is mostly useless. Asking a model to review its own draft produces polite, surface-level corrections. The critique only works when it comes from a different model with different priors.

Forcing consensus is worse than surfacing disagreement. Early versions of the Chairman tried to force a single “correct” answer. The output was worse than just admitting when the models disagreed and letting the user decide.

Latency is real. A single-model runbook generates in ~5 seconds. The full AI Council takes 30-45 seconds. For a SaaS, this means you need clear UI signaling so the user knows something is happening. I made the mistake of treating this as a backend problem when it was actually a UX problem.

The honest tradeoff

The AI Council costs about 5x more in API calls than a single-model approach. For a free tier, that’s not viable. RunDoc only runs the Council on the Pro plan precisely because the economics force it.

Whether the quality gain justifies the cost depends entirely on what the runbook is for. Generating a docs page about how to restart a service? Overkill. Generating the runbook your on-call engineer is going to follow when production is on fire at 3am? Probably worth it.

If you’re building something similar

The pattern generalizes beyond runbooks. Any time you need an LLM to produce output where errors are expensive and silent — legal drafting, medical summaries, financial analysis, security reviews — the cross-review pattern is worth trying. The key insight is that diversity of priors does the work, not the synthesis step. Pick models that were trained differently. Make them critique structurally, not just summarize.

If you want to see what AI Council output actually looks like on a real runbook, RunDoc has a free tier — 5 runbooks per month, no card needed. The Council itself is on the Pro plan, but the architecture is what this post is about, not the product.

Happy to answer questions in the comments. Especially curious to hear from anyone who’s tried multi-model architectures for other domains — what worked, what didn’t.

Connect Your MCP Server With DeepSeek V4 — Step-by-Step Guide (2026)

TL;DR

  • DeepSeek V4 shipped April 24, 2026 in two flavours: V4-Pro (1.6T MoE / 49B active) and V4-Flash (284B MoE / 13B active). Both expose a 1M-token context and ship under the MIT license.
  • V4 ties Claude Opus 4.6 on MCPAtlas Public (73.6) and beats GPT-5.4 on Codeforces — the best open-weight model for MCP agents in 2026.
  • Both OpenAI and Anthropic-compatible APIs — drop in deepseek-v4-pro or deepseek-v4-flash as the model name and any MCP client already works.
  • 128 parallel tool calls, a new XML-based |DSML| schema that virtually eliminates argument-parse errors, and three reasoning modes (Non-think / Think High / Think Max).
  • V4-Pro promo pricing: $0.435/M input · $0.870/M output through May 31. V4-Flash is ~$0.28/M output — roughly 1/20th of Claude Opus 4.7.
  • Fastest way to test on your MCP server: paste the URL into MCP Agent Studio, pick V4-Pro or V4-Flash, start chatting. No DeepSeek API key required.

You can connect any MCP server to DeepSeek V4 in about 60 seconds — paste the server URL into MCP Agent Studio, pick deepseek-v4-pro or deepseek-v4-flash from the model dropdown, and start chatting. Every tool call is shown live, no DeepSeek API key required.

DeepSeek V4 shipped on April 24, 2026 and turned the company’s open-weight stack into a credible alternative to Claude Opus 4.6 and GPT-5.4 for tool-driven agents — at a fraction of the price. If the last time you tried connecting an MCP server with DeepSeek was on V3 or R1, the story has changed completely.

This post walks through three ways to wire your MCP server up to V4 — Agent Studio, the OpenAI SDK, and Claude Code with V4’s pre-tuned adapter — then a head-to-head against Claude and GPT-5 and the four pitfalls that ate the most time.

The DeepSeek V4 Lineup (and Why You Can Stop Reading About R1)

There are two V4 models that matter, plus two older ones worth knowing about so you do not pick them by accident:

Model Params (active) Context Tool calling?
deepseek-v4-pro 1.6T (49B) 1M tokens Yes — 128 parallel, native MCPAtlas-tuned
deepseek-v4-flash 284B (13B) 1M tokens Yes — same tool schema, 4–5× faster
deepseek-v3.2 (deepseek-chat / -reasoner) 685B (37B) 128K Yes — but superseded by V4 in every benchmark
deepseek-r1 — — No — cannot call tools by design

Architecturally, V4 is a different beast from V3.2. DeepSeek replaced the dense attention with a Hybrid Attention stack — Compressed Sparse Attention plus Heavily Compressed Attention — which cuts KV cache by ~90% and per-token inference FLOPs by ~73% versus V3.2 at the 1M-context setting. Translation: long-context MCP agents that used to OOM now run cheaply.

It was pre-trained on 32T tokens, ships with the Muon optimizer, and uses Manifold-Constrained Hyper-Connections to stabilize signal propagation. That is the why-it-works story; the practical story is that V4 ties Claude Opus 4.6 on every public agentic benchmark I checked.

Why DeepSeek V4 Is Built for MCP

Three things make V4 unusually good at MCP-style tool calling. None of them existed in V3.2 or earlier.

1. The |DSML| XML Schema (Goodbye, Empty Argument Bug)

Function calling in V3 and V3.2 used pure JSON for tool arguments. That broke whenever a string parameter contained a stray quote or brace — the model would emit a malformed object and the call would fail.

V4 introduces an XML-based schema powered by a special |DSML| token that separates string parameters from structured JSON parameters. In practice this means tools that previously failed 5–10% of the time on string-heavy inputs (Slack messages, SQL queries with quoted identifiers, Stripe descriptions) now succeed nearly 100% of the time.

2. Reasoning Persisted Across Tool Calls

V4 keeps its internal reasoning chain coherent across tool-call boundaries. Earlier models reset their reasoning after each tool result, which is why long agent loops would drift. V4 carries the chain forward, so a 10-step agent stays on-task.

3. Three Reasoning Modes for Three MCP Workloads

Mode When to use it
non-think High-volume agents — log triage, customer-support bots, batch summarisation. Cheapest, fastest.
think-high Default for most MCP agents — the model reasons before each tool call, verifies output, retries if wrong.
think-max SWE-Bench-class workloads: multi-step debugging, complex SQL, security analysis. Costlier but matches Opus 4.6.

4. Native MCPAtlas-Tuned Adapters

DeepSeek shipped pre-tuned adapters for Claude Code and OpenCode alongside V4 — meaning the model was fine-tuned on real MCP-style agent traces, not just synthetic function-calling data. That shows up in MCPAtlas Public scores of 73.6 (tied with Opus 4.6) and SWE-Bench Verified at 80.6% (0.2pp behind Opus 4.6).

Naming gotcha: DeepSeek still serves the legacy deepseek-r1 model. It does not support function calling — it never did, and V4 did not change that. If you point an MCP client at deepseek-r1 it will hallucinate tool output. Use deepseek-v4-pro or deepseek-v4-flash for any MCP work.

Connect Your MCP Server With DeepSeek V4 — 3 Ways

Three ways to wire your MCP server up to V4, ordered by setup time. Option 1 takes about 60 seconds and needs no code.

Option 1 — MCP Playground Agent Studio (60 seconds, no code)

This is the recommended path for most people. MCP Agent Studio handles the OpenAI ↔ MCP bridge for you, ships V4-Pro and V4-Flash in the model dropdown, and runs the full agent loop in the browser. No SDK, no DeepSeek API key, free credits on sign-up.

Step-by-step:

  1. Open mcpplaygroundonline.com/mcp-agent-studio and sign in (free credits are added to your account).
  2. In the MCP Servers panel, click Add server. Paste your server URL — works with Streamable HTTP, SSE, or HTTP. Add a bearer token in the Headers field if your server needs one.
  3. Click Connect. Agent Studio runs tools/list against the server and shows you every tool it discovered. If the count looks right, your server is wired up.
  4. In the Model dropdown, pick DeepSeek V4-Pro (for hard reasoning) or DeepSeek V4-Flash (for speed + cost).
  5. Type your first prompt and hit send. Every tool call, argument, and result is shown inline as the agent runs.

If you don’t have an MCP server yet, head to mcpplaygroundonline.com/mcp-hosted and deploy one in one click — Postgres, Stripe, GitHub, Atlassian, MongoDB, Playwright, and 35+ more. You’ll get a live HTTPS URL plus bearer token that drops straight into step 2 above.

Option 2 — OpenAI SDK + DeepSeek V4 Endpoint (writing your own runtime)

If you’re building your own agent runtime, V4’s API is OpenAI-compatible and Anthropic-compatible. Change the base URL and the model name, and existing function-calling code routes to V4.

from openai import OpenAI

client = OpenAI(
    api_key="sk-...",
    base_url="https://api.deepseek.com/v1",
)

response = client.chat.completions.create(
    model="deepseek-v4-pro",       # or "deepseek-v4-flash"
    messages=[{"role": "user", "content": "List my open GitHub PRs"}],
    tools=mcp_tools_as_openai_functions,  # MCP tools/list → OpenAI tools[]
    tool_choice="auto",
    reasoning_effort="think-high",   # non-think | think-high | think-max
)

You still have to bridge MCP’s tools/list into the OpenAI tools[] array, parse each tool_calls entry into an MCP tools/call, feed the result back, and loop until the model is done — about 80 lines of Python if you want it solid. Agent Studio does all of this for you.

Option 3 — Claude Code With the V4 Adapter (terminal workflow)

New with V4: DeepSeek ships pre-tuned adapters for Claude Code and OpenCode. Drop V4-Pro in as the underlying model and Claude Code’s existing MCP config (~/.claude/mcp.json) works unchanged — including HTTP, SSE and Streamable HTTP servers.

This is the path to pick if you live in the terminal and want V4 driving your MCP tools the same way Claude does today. Surprisingly clean for an open-weight model.

Hands-On Tests: 4 MCP Servers Against DeepSeek V4-Pro

Four common MCP servers, each with a prompt that required at least three tool calls. Same prompts I used for my V3.2 tests in April, so you can compare against history.

Test 1: GitHub MCP (Search + Read Code)

Prompt: “Find all open issues labelled ‘security’ across my repos, read the latest comment on each, and summarise the highest-severity ones.”

Result: V4-Pro used parallel tool calls aggressively — one search_issues, then six concurrent get_issue_comments in a single turn. Total time 6.3 seconds (down from 11s on V3.2). The parallel-call ceiling of 128 is V4’s headline feature for agents.

Test 2: Postgres MCP (Analytical SQL)

Prompt: “Which 5 customers had the largest week-over-week drop in revenue? Show me the gap and the absolute numbers.”

Result: V4-Pro grounded by calling list_schemas + describe_table first, then wrote a clean window-function query. The XML-based |DSML| schema mattered here — the SQL string had quoted identifiers that broke V3.2 about 20% of the time. V4 handled all 10 runs cleanly.

Test 3: Stripe MCP (Real-Money Reasoning)

Prompt: “List failed payments from last week. Group by failure reason and tell me which ones I should follow up with.”

Result: V4-Pro in think-high mode reasoned about the trade-offs before suggesting any follow-up — flagged a stale-card cluster, a 3DS-rejection cluster, and a fraud-block cluster separately. Refused to suggest re-charging without explicit confirmation.

Test 4: Multi-MCP — GitHub + Slack + Atlassian Together

Prompt: “Pull yesterday’s merged GitHub PRs, find the linked Jira tickets, and post a roll-up to the #eng channel.”

Result: Three MCP servers connected at once (47 tools total). V4-Pro picked the right tool from each without me labelling them. The parallel call architecture meant it pulled PRs and Jira tickets simultaneously, then composed the Slack message. End-to-end 8 seconds, would have been ~25 on V3.2.

DeepSeek V4 vs Claude, GPT-5, Gemini on MCP Workloads

Same four prompts, six models, three runs each, averaged. Cost numbers use V4 promo pricing; assume V4-Pro doubles after May 31.

Model Tool calls / task Avg latency Cost / task Final-answer quality
DeepSeek V4-Flash 3.6 5.4s $0.0021 Strong
DeepSeek V4-Pro (think-high) 3.2 7.1s $0.0065 Strongest (tie)
DeepSeek V4-Pro (think-max) 3.0 11.4s $0.014 Strongest (tie)
Claude Sonnet 4.5 3.0 7.4s $0.022 Strong
Claude Opus 4.7 2.9 9.8s $0.061 Strongest (tie)
GPT-5.4 3.6 8.1s $0.018 Strong
Gemini 3.1 Pro 3.3 10.5s $0.014 Strong

Four things I did not expect before this benchmark:

  • V4-Flash is the price-performance shock of 2026. Quality on par with GPT-5.4, ~9× cheaper. For high-volume agents (CI bots, log triage, customer support) this changes the math entirely.
  • V4-Pro in think-max ties Claude Opus 4.7 on final-answer quality at ~1/4 the cost. The 1M context plus persisted reasoning means it can handle long agent loops Opus would struggle to fit.
  • Parallel tool calls cut wall-clock time roughly in half on multi-MCP setups. V4 will fire 6–8 concurrent calls when it sees they are independent; Claude and GPT-5 still tend to serialize.
  • Claude is still slightly more polished on natural-language final answers — there’s a “Claude voice” that V4 does not quite match. For tool execution itself, V4-Pro is at parity.

Pitfalls I Hit With V4

1. Don’t mix V4 with legacy V3.2 conversations

V4’s XML |DSML| schema is incompatible with V3.2’s pure-JSON tool format. If your gateway routes between V4 and V3.2 mid-session, tool-call replay breaks. Pin the model per conversation.

2. The 128-tool ceiling still applies

V4 supports 128 parallel calls per request — but also 128 tool definitions. Most single MCP servers are well below this, but if you wire up GitHub + Slack + Postgres + Jira + Linear + Stripe in one session you can blow past 128 tools and the tail will silently drop. Scope the toolsets you expose.

3. think-max is expensive — use it sparingly

The think-max mode is wonderful on hard reasoning tasks, but burns ~2× the tokens of think-high. For most MCP workflows, think-high is the sweet spot. Save think-max for SWE-Bench-class problems.

4. Don’t bet on the promo pricing

V4-Pro’s headline $0.435/M input is a 75% promo discount through May 31, 2026. List price is $1.74/M input and $3.48/M output. Still cheaper than Claude — but model your cost projection on list, not promo.

How MCP Playground Helps

  • 40+ models in one UI — V4-Pro, V4-Flash, Claude Opus 4.7 / Sonnet 4.5, GPT-5.4, Gemini 3.1 Pro, Grok, Qwen, Mistral. No DeepSeek API key needed.
  • Paste any MCP URL — works with hosted Atlassian, GitHub, Linear, Vercel, Supabase, Datadog, or your own remote.
  • One-click hosted MCP servers — 40+ pre-configured: Postgres, Stripe, MongoDB, Playwright, Brave Search and more. Deploy in under a minute.
  • Compare mode — run the same prompt across V4-Pro, Claude and GPT-5 side-by-side. Tool-call traces and final answers, parallel.

If you are evaluating V4 for a production agent, the side-by-side compare is the fastest way to make the call.

Bottom Line

DeepSeek V4 is the first open-weight model that’s a real alternative to Claude Opus and GPT-5 for MCP agents. It ties Opus 4.6 on MCPAtlas, beats GPT-5.4 on Codeforces, runs at a fraction of the cost, and ships with parallel tool calls plus a 1M context that most closed models cannot match.

Picking between Pro and Flash is easy: Flash for high-volume, latency-sensitive agents; Pro when the agent has to reason its way through a hard problem.

The fastest way to validate it on your MCP server is Agent Studio — pick DeepSeek V4-Pro or V4-Flash, paste the URL, run your hardest prompt three times. If it works there, it will work in production.

FAQ

When was DeepSeek V4 released?
April 24, 2026. Two models shipped at GA: deepseek-v4-pro (1.6T MoE / 49B active) and deepseek-v4-flash (284B / 13B active), both with a 1M-token context window. Weights are open under the MIT license on Hugging Face.

Does DeepSeek V4 support MCP servers?
Yes. V4 exposes OpenAI-compatible and Anthropic-compatible APIs — any MCP client that talks to GPT or Claude works with V4 out of the box. Drop in deepseek-v4-pro or deepseek-v4-flash as the model and tool calls just work. It also ties Claude Opus 4.6 on MCPAtlas Public (73.6).

What’s the difference between V4-Pro and V4-Flash?
V4-Pro is the flagship (1.6T MoE, 49B active) and matches Opus on hard agent reasoning. V4-Flash (284B MoE, 13B active) is roughly 4–5× faster and ~3× cheaper, with quality on par with GPT-5.4 on routine MCP tasks. Use Flash for high-volume agents, Pro when the model has to reason about which tool to call.

Can DeepSeek R1 call tools?
No. R1 is a pure reasoning model with no function-calling capability — it cannot drive an MCP server. Use deepseek-v4-pro or deepseek-v4-flash instead. R1’s reasoning has been superseded by V4’s think-high and think-max modes, which include tool use.

How many tools can DeepSeek V4 call in one request?
Up to 128 parallel tool calls per request, and the model treats independent calls as eligible to run concurrently. That is enough for 5–6 typical MCP servers connected at once. Exceeding 128 silently drops trailing tools — scope the MCP toolsets you pass to stay under the cap.

Is DeepSeek V4 cheaper than Claude or GPT-5 for MCP agents?
Significantly. V4-Pro promo pricing is $0.435/M input · $0.870/M output (through May 31). V4-Flash is ~$0.28/M output — roughly 1/20th of Claude Opus 4.7. On my benchmark V4-Flash ran an MCP agent task for $0.002 vs $0.061 for Opus.

How do I test DeepSeek V4 against an MCP server without writing code?
Use MCP Agent Studio. Paste the MCP server URL, pick DeepSeek V4-Pro or V4-Flash from the model dropdown, and start chatting. Every tool call and result is shown live. Free credits on sign-up — no DeepSeek API key required.

Originally published on mcpplaygroundonline.com/blog/testing-mcp-with-deepseek.

Road Relic Rental – Car Rental & Leasing Web Application

Homepage

Road Relic Rental 🚗

Introduction

Road Relic Rental is a frontend car rental and leasing website developed using HTML, CSS, Bootstrap, and JavaScript.

The project is designed with a modern and responsive user interface that allows users to explore cars, view rental details, and experience a simulated booking system easily.

Technologies Used

  • HTML5
  • CSS3
  • Bootstrap 5
  • JavaScript

Tags

webdev #javascript #bootstrap #html #css #frontend #projects

Features

🚘 Car Rental Interface

Users can:

  • Browse different cars
  • View car specifications
  • Check rental pricing
  • Explore leasing options

📱 Responsive Design

The website is fully responsive and optimized for:

  • Mobile devices
  • Tablets
  • Desktop systems

🎨 Modern UI Design

Implemented components include:

  • Bootstrap navigation bar
  • Carousel/slideshow
  • Booking forms
  • Cards and buttons
  • Interactive layouts

🔐 Authentication Simulation

Added:

  • Face authentication simulation
  • Fingerprint verification simulation

⭐ Review & Rating System

Users can:

  • Give ratings
  • Submit reviews and feedback

📍 GPS Tracking Simulation

Integrated a GPS tracking concept for improving the user experience in rental management.

Cars Included

  • Honda Civic
  • Lexus ES 300h
  • Toyota RAV4
  • Toyota Fortuner
  • Audi A4
  • Ford Models

Learning Outcome

This project helped me improve my understanding of:

  • Frontend development
  • Responsive web design
  • Bootstrap components
  • JavaScript DOM manipulation
  • UI/UX design concepts

It also helped me gain practical experience in building real-world styled web applications.

GitHub Repository

GitHub Link:
https://github.com/anusha-seelam/Road-Relic-Rental

Project Screenshots

Homepage

Working Page

Booking Page

Conclusion

Road Relic Rental is a user-friendly frontend web application that demonstrates modern UI/UX concepts for car rental and leasing systems.

This project was a great learning experience and helped me strengthen my frontend development skills.

Thank you for reading 🚀

GitHub Repository

🔗 GitHub Repository:
https://github.com/anusha-seelam/Road-Relic-Rental

Feedback and suggestions are always welcome 😊