arXiv:2610.32851cs.AIOct 2026

Manuscript Offprint

arXiv:2610.32851

Reimagining Enterprise RAG for Multi-Agent Systems: A Knowledge Layer That Organizes Before It Retrieves

Garima Agrawal, Prasun Das, Akshay Sarvade, Priyanka L, Minisha N, Sravani Joshna, Hemath Manivannan, Lavanya Korada, Sambhrit Pattanayak, Srashti Gupta, Siddu R, Prasad Kalyanasundaram

Abstract

Enterprise organizations are deploying agentic AI across the software development lifecycle, and these agents need the behavioral logic of the systems they act on rather than documentation written for stakeholders. Recent work has shown that this logic can be recovered at scale: a seven-agent reverse-engineering pipeline of our own design processed 241 repositories across 18 services into thousands of artifacts describing scope, journeys, business rules and acceptance criteria. Recovery, however, does not confer usability. Business entities recur throughout such an estate under a shared vocabulary: offer, eligibility, and activation each govern rules in several services, related in name but operationally distinct, so an end-to-end journey implicates well over a thousand rules whose text is near-identical across contexts that must not be conflated. Flat vector retrieval fails here in its most consequential form, returning a structurally identical rule from the wrong service at high similarity and with no signal of error. Content-level ontology is the traditional remedy, but none existed, and relating every occurrence of every recurring entity to every other would have yielded a graph whose construction cost exceeded the engagement and whose currency would not survive a release cycle. We place the ontology at the artifact level instead. Because the corpus is machine-generated, each artifact retains its producer, component, service, domain and type, provenance sufficient to disambiguate before any content is read. We present a knowledge layer that organizes before it retrieves: a self-describing catalog, a sparse metadata registry, and a navigation hypergraph defined over artifacts rather than extracted entities. Queries resolve to a set of artifact identifiers to which vector search is then constrained, so the competing rule from another service is absent from the candidate set rather than outranked within it, and disambiguation becomes structural rather than statistical. Constructed in under a week and admitting new services by convention, the layer serves production SDLC agents alongside developers, quality engineers and analysts querying it directly. We report more than 100 production defects for which it supported root-cause analysis and resolution under developer verification, and 35 release regression failures attributed to specific rules and services.

Introduction

Enterprise software organizations are moving from using AI as a tool to deploying it as an organizational capability. Across the software development lifecycle, specialized agents now recover undocumented business logic, generate tests from behavioral specifications, triage production defects against requirements, assess merge-request risk, and attribute release failures to rule violations. Each reasons from a distinct professional standpoint, and each requires knowledge of the application at a level of detail that stakeholder documentation does not supply: the behavioral logic embedded in source code, configuration, and tests. Prior work has established that this logic can be recovered at scale (Agrawal et al. 2026, 2024). Applying a seven-agent reverse-engineering pipeline of our own design to the estate reported here, we processed 241 repositories across 18 services into several thousand structured artifacts spanning scope definitions, user journeys, business rules, acceptance criteria, and gap registers, each finding carrying a reference to its source. The behavioral specification of the estate, which had never been written, thereby came into existence as structured data.

Recovery, however, does not confer usability. This paper addresses the problem that follows it: how a corpus of machine-generated requirements artifacts must be organized if downstream agents are to retrieve from it with the precision their tasks demand.

The Organization Problem. The estate is orchestrated through 14 business process workflows. A single workflow may invoke as many as 112 endpoint-level requirements documents in one execution, and an end-to-end journey such as order placement, order submission, or customer update implicates well over a thousand business rules. Volume alone would be manageable. The compounding difficulty is that the estate's business vocabulary is shared across the services that compose it. Terms such as offer, eligibility, activation, order, and provisioning recur throughout, denoting related but non-interchangeable concepts: offer governs eligibility rules in the ordering service, definition and validity rules in catalog, and discount rules in billing. The artifacts describing them consequently exhibit substantial textual overlap while remaining operationally distinct.

Consider what resolving a production defect requires under these conditions. The traversal runs from workflow to endpoint document to business rule to owning repository to change site. Depth is not the principal obstacle; precision under vocabulary collision is. What must be retrieved is the rule governing the service in which the failure occurred, and

Copyright © 2027, Association for the Advancement of Artificial Intelligence (www.aaai.org). All rights reserved.

not its structural twin in an adjacent service that participates in the same workflow.

Why Retrieval Alone Is Not Enough. Embedding a corpus into a vector store and retrieving by cosine similarity presumes that proximity in embedding space corresponds to operational relevance. Vocabulary collision inverts that presumption: the highest-ranked result is frequently drawn from the wrong operational context. What distinguishes this failure from ordinary retrieval error is that it leaves no trace. The returned text is well-formed and topically correct, the similarity score is high, and the consuming agent proceeds to reason over it without any indication that its evidence is misattributed.

Content-level ontology is the established corrective: extract entities, declare relations, and align vocabularies across the estate (Gruber 1993; Noy and Musen 2000). Two considerations made it impracticable here. The first is combinatorial. Each recurring entity appears in several services and relates to every other entity it transacts with, so the graph an ontology would have to construct and keep consistent grows with the product of those occurrences rather than with the number of terms; across a rule population of this size, the alignment effort would constitute the greater part of the engagement rather than a preparatory step. The second is currency. Rules are revised on a release cadence, so an ontology delivered after months of specialist effort would describe a system that had already moved, while the agents depending on it required knowledge of the system as deployed.

Graph-based retrieval (Edge et al. 2024; Guo et al. 2025) induces an entity graph from corpus text and traverses it at query time, with demonstrated benefits for multi-hop reasoning. A graph induced from colliding text, however, inherits the collision: the extractor must determine whether two occurrences of offer constitute one node or two, which relocates the disambiguation problem to the construction phase rather than eliminating it. Each of these approaches treats the corpus as opaque text whose organizing structure must be reconstructed from content. That premise does not hold for a machine-generated corpus.

Organize Before You Retrieve. The corpus under consideration possesses a property that distinguishes it from the document collections retrieval systems are typically designed for. Each artifact was emitted by a known producing agent, for a known component, within a known service and domain, under a declared type, with per-finding references to source. The structure required for disambiguation was therefore never latent in content. It was available at the artifact layer, in the circumstances of production, naming, and relation, prior to any content being read.

Our response was not to forgo ontology but to relocate it to a level the organization can sustain, imposing structure over the artifacts rather than over the entities they contain. We term this approach KB Cataloging, after the apparatus by which a library renders most of its holdings irrelevant to a given inquiry before any volume is opened: a classification scheme, a catalog, and an index, none of which requires reading the collection to construct.

The mechanism this yields at query time is the framework’s principal contribution. Intent classification and the catalog resolve an incoming question to a set of artifact identifiers, and the vector query is constrained to that set (Section ). The competing rule from an adjacent service does not participate in the similarity computation at all, and disambiguation is accordingly effected by the organization of the corpus rather than by the distribution of its scores.