Bharat Singh

Principal Engineer and AI Systems Architect directing high-throughput Information Retrieval (IR) architectures, autonomous agent platforms, distributed systems, and knowledge graphs across enterprise scale (3,500+ commercial websites). Principal Engineer at Milestone Internet.

Who is the oracle when you rewrite a system?

Every rewrite reaches the same moment. The new system produces an answer, the old system produces a different one, and somebody has to decide which is right. Testing research has a name for the thing that decides: the test oracle. Barr and colleagues surveyed the difficulty of building one, “the oracle problem”, in a 2015 paper, and for most software it is a hard problem. A rewrite looks like the easy case. The old system is the answer, isn’t it? I don’t think it is that simple, and I don’t think teams talk about it enough before they start. “Who is the oracle?” is a decision, not a fact, and the choice shapes everything that follows: what you test, what you are allowed to fix, and how long the project takes. ...

November 12, 2026 · 8 min · Bharat Singh

Claude Code's grep is not grep, and it fails silently

Ask Claude Code to grep -rn your repository and it will answer. The answer is not always grep’s answer. Since version 2.1.117, Claude Code’s native builds for macOS and Linux run nearly every shell grep (a few flags such as -Z fall through to the system grep) through a bundled copy of ugrep with extra flags. Those flags make it skip some files that GNU grep would search, and it says nothing when it does. For a person that is a quirk. For an agent that treats “no match” as a fact, it is a blind spot. Everything below was measured on 2026-11-11 with Claude Code 2.1.322 on an Apple Silicon Mac. I did not test a Linux build; what I say about Linux comes from the changelog. The scripts are in the reproduction repo. ...

November 11, 2026 · 8 min · Bharat Singh

Correlation Is Not Conversion: The Problem of Attributing Business Results to AI

Three months after deploying an AI booking assistant across a hospitality client’s website, the stakeholder asks a reasonable question: Did the chatbot increase our bookings? Your analytics pipeline has a number ready. Users who interacted with the chatbot booked at 11.2%. Users who never opened it booked at 3.1%. That looks like an 8.1 percentage point lift. Ship the slide deck. Schedule the quarterly review. That number is structurally meaningless. Not approximately wrong. Not slightly optimistic. It conflates who uses chatbots with what chatbots cause, and those are entirely different questions. ...

October 21, 2026 · 11 min · Bharat Singh

Evaluating RAG Without Ground Truth: Production Pitfalls of LLM-as-a-Judge

When deploying enterprise Retrieval-Augmented Generation (RAG) systems, the hardest operational problem is often not retrieval tuning or prompt engineering; it is evaluation. In academic settings, benchmarks like MS MARCO or HotpotQA provide human-annotated ground-truth labels for every query. In production enterprise applications, users submit tens of thousands of unique, domain-specific queries daily across messy internal documentation, leaving engineering teams without curated ground-truth labels. ...

June 15, 2026 · 6 min · Bharat Singh

From Semantic Nanopublications to Knowledge Graphs: What 15 Years of Machine-Readable Data Taught Us About RAG Grounding

Long before transformer models transformed language generation, distributed systems engineers wrestled with a fundamental challenge: how do you convert sprawling human literature into machine-verifiable, provenance-tracked facts? Around 2009–2010, the concept of semantic nanopublications took shape as a solution for scientific data publishing (Mons & Velterop, 2009; Groth, Gibson & Velterop, The anatomy of a nanopublication, 2010). In 2011 we argued the case for it in a Nature Genetics commentary, The value of data (Mons et al., doi:10.1038/ng0411-281). The core thesis was simple: a machine-actionable fact cannot be a naked string. It must encapsulate three connected components: an Assertion, its Provenance, and its Publication Metadata. ...

May 20, 2026 · 7 min · Bharat Singh

The Retrieval Fallacy: Why Massive Context Windows Don't Eliminate the Need for IR

Over the past year, the widespread availability of million-token context windows has prompted a recurring refrain among engineering leaders: “Why invest in complex Retrieval-Augmented Generation (RAG) pipelines when we can simply feed the entire document store into the prompt?” In production enterprise systems, this assumption (what I call the Retrieval Fallacy) leads directly to unacceptable latency, unsustainable inference costs, and silent degradation of reasoning fidelity. Large context windows do not render Information Retrieval (IR) obsolete. Rather, they fundamentally shift what retrieval is responsible for: from naive sentence-level segmentation to high-precision contextual topology. ...

March 12, 2026 · 5 min · Bharat Singh

The Cognitive Tax of Trivial Helpers: Lessons in Interface Design from the Linux Kernel

In August 2025, during the Linux 6.17 merge window, Linus Torvalds rejected a RISC-V pull request containing what appeared to be an innocuous helper utility: make_u32_from_two_u16(a, b) The review was characteristically blunt, but setting aside the rhetoric, the technical critique addresses a fundamental anti-pattern prevalent across software engineering: the creation of trivial abstractions that increase cognitive load rather than reducing it. In modern software development, across kernel subsystems and enterprise microservices alike, teams frequently mistake abstraction for clarity. Examining why this specific helper failed offers enduring principles for API design, code review standards, and engineering leadership. ...

August 12, 2025 · 4 min · Bharat Singh