Hallucination Mitigation with Agentic AI, Nested Learning, and AI Sustainability via Semantic Caching

Diego Gosmar, Deborah A. Dahl · 2026

Read Hallucination Mitigation with Agentic AI, Nested Learning, and AI Sustainability via Semantic Caching by Diego Gosmar, Deborah A. Dahl (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2605-29055.txt.

Introduction

Diego Gosmar and Deborah Dahl test hallucination mitigation with nested learning and semantic caching on 310 prompts. A pipeline scores responses on four dimensions, improving by about 6 percent of its attainable range. About 84 percent of the gain comes from Explicit Contextualization alone, while Factual Claim Density stays flat. In stress tests, about 11 percent of final answers still present invented items as real. Semantic caching serves about 48 percent of model calls, and cross-family judges confirm the gain.

Catalog record

CREATORDiego Gosmar, Deborah A. Dahl
YEAR2026
COLLECTIONPAPERS
FORMATTXT
FILE SIZE51862
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2605.29055

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

Hallucination Mitigation with Agentic AI, Nested Learning, and AI Sustainability via Semantic Caching Diego Gosmar, Deborah A. Dahl Abstract Hallucination remains a major reliability barrier for production LLM systems, particularly in multi-agent pipelines where unsupported claims can propagate unchecked across stages. This paper adapts a HOPE-inspired Nested Learning architecture with Continuum Memory Systems (CMS) and semantic similarity caching to a hybrid benchmark of 310 prompts combining 217 realistic epistemic-uncertainty prompts and 93 fabrication-induction stress-test prompts. A three-stage agentic pipeline orchestrated via the Open Floor Protocol (OFP) is evaluated with five KPIs — FCD (Factual Claim Density), FGR (Factual Grounding References), FDF (Fictional Disclaimer Frequency), ECS (Explicit Contextualization Score), and OSR (Observability Score Ratio) — aggregated into THS (Total Hallucination Score) across five weighting configurations to study mitigation–observability trade-offs. FDF, ECS, OSR, and FGR are subtracted as mitigation signals, so that a more negative THS indicates stronger mitigation. The FrontEndAgent is deliberately configured as a weak, high-stochasticity generator (temperature = 1.0) to produce a realistic hallucination baseline, while the SecondLevelReviewer and ThirdLevelReviewer operate as progressive correctors. This asymmetric design yields end-to-end THS reductions of − 31.3 % -31.3\% to − 35.9 % -35.9\% across five weighting configurations, where a more negative score corresponds to stronger mitigation. Semantic caching achieves 440 cache hits over 930 potential calls (47.3% hit rate), reducing LLM invocations to 490, lowering energy and CO 2 e footprint, and making multi-stage review pipelines operationally viable at production scale. ExtremeObservability attains the most negative final THS ( − 0.0709 -0.0709 ), confirming that observability-heavy configurations reinforce rather than compromise mitigation. These findings suggest that memory-augmented multi-agent designs can jointly improve factual reliability, operational efficiency, and auditability without model retraining. 1 Introduction The deployment of LLMs in production systems has exposed a persistent reliability gap: models generate factually unsupported claims with high confidence, a phenomenon commonly termed hallucination. In single-model settings this is already problematic; in multi-agent pipelines, where the output of one agent becomes the input of the next, an unchecked hallucination can propagate and amplify across stages before reaching the end user [ 13 ] . Structural defences against this class of failure have been studied primarily in the context of prompt-injection attacks, where the threat is an adversarial input rather than an internally generated unsupported claim; yet the defensive architectures transfer directly. They fall broadly into two families: input-side filters that intercept unreliable content before it reaches the model [ 12 ] , and output-side judges that score or rewrite generated content after the fact [ 4 ] . Both families, however, are typically applied as single-pass corrections and do not exploit the accumulated context of prior interactions. This paper addresses that gap by embedding hallucination mitigation inside a persistent memory architecture. Building on the multi-agent framework discussed in [ 11 ] — which targeted prompt-injection robustness — we shift the objective to factual reliability. We add a fifth KPI — OSR (Observability Score Ratio) — to the existing four-dimensional evaluation framework [ 9 ] , explicitly measuring how much factuality-relevant reasoning each agent exposes, and examine how weighting observability in the aggregate score affects overall mitigation. We also explore the applicability of the HOPE-inspired Nested Learning mechanism [ 3 ] through Continuum Memory Systems (CMS) to hallucination mitigation in addition to prompt injection. CMS maintains medium- and long-term memory layers across prompts and allows agents to reuse semantically similar prior responses rather than invoking the underlying model from scratch on every call. The resulting system is evaluated on a hybrid benchmark of 310 prompts spanning two risk profiles: realistic epistemic-uncertainty questions, where a well-calibrated agent should hedge rather than confabulate, and fabrication-induction stress-test prompts, which actively pressure the pipeline to hallucinate on demand. This asymmetric design is intentional: by configuring the first-stage agent as a maximally stochastic generator with no hedging instructions, we ensure the pipeline faces a genuine hallucination load, making the corrective value of the downstream reviewer stages directly measurable. Section 2 describes the three-stage OFP-orchestrated pipeline and the CMS pairing. Section 3 situates the work in the broader literature on hallucination defences and memory-augmented LLM systems. Section 4 details the Nested Learning architecture and semantic caching implementation. Section 5 defines the benchmark, KPIs, and THS formula. Section 6 reports empirical results, and Sections 7 – 11 discuss implications and limitations. All acronyms are defined formally in Section 5 . 2 Architecture Overview The architecture is described in detail in the prior work [ 11 ] and summarised here for completeness. Figures 1 and 2 show the OFP-orchestrated three-stage pipeline and the CMS pairing respectively. LLM backbone per agent All four agents run on Llama 3.1 ( llama3.1:latest ) via Ollama, differentiated by inference parameters and system prompts. The FrontEndAgent (1st stage, temp=1.0, top-p=0.99, ctx=8192) is deliberately configured as a weak, high-stochasticity generator: its system prompt instructs it to answer with full confidence, supply specific details even when extrapolating, and avoid all disclaimers — maximising FCD and minimising FDF/ECS to create a measurable hallucination baseline. The SecondLevelReviewer (2nd stage, temp=0.1, top-p=0.9, ctx=8192) is the primary corrector: it detects unsupported claims, replaces them with cautious wording, and returns three structured fields: utterance , whisper_context , whisper_value . The ThirdLevelReviewer (3rd stage, temp=0.05, top-p=0.85, ctx=8192) is the final factuality enforcer, returning only clean user-facing text without metadata or internal reasoning. The KPI Evaluator (4th agent, temp=0.0, top-p=0.8, ctx=8192) operates independently from the pipeline and returns FCD, FGR, FDF, ECS as floats in [0,1] in strict JSON. The temperature gradient (1.0 \to 0.1 \to 0.05 \to 0.0) encodes the design intent: maximum creative freedom at the first stage, progressively tighter factual control downstream, fully deterministic evaluation. OFP The Open Floor Protocol (OFP) [ 16 , 5 ] is an open interoperability standard for agentic systems that orchestrates the message flow across pipeline agents and allows the KPI Evaluator to observe the full trace without being part of the decision path, making inter-agent boundaries explicit and supporting reproducible logging. Rationale for three pipeline stages The choice of three active pipeline agents reflects the minimum architecture required to instantiate the distinct functional roles this study evaluates: a generator (FrontEndAgent), a corrector (SecondLevelReviewer), and a factuality enforcer (ThirdLevelReviewer). Each stage corresponds to a qualitatively different task and operates at a distinct temperature regime ( 1.0\to 0.1\to 0.05 ), encoding a deliberate progression from maximum stochasticity to tight factual control. A fourth pipeline agent would either replicate the enforcer function — yielding diminishing returns already visible in the U-shaped THS trajectory at the third stage — or require defining a novel role not motivated by the current KPI framework. The KPI Evaluator constitutes a fourth agent by count, but it sits outside the mitigation path as a read-only observer, preserving the integrity of the evaluation. Additional stages could be explored in future work, but three is sufficient to demonstrate progressive mitigation and the trade-offs this study targets. User FrontEnd Agent Llama 3.1 SecondLevel Reviewer Llama 3.1 ThirdLevel Reviewer Llama 3.1 KPI Evaluator — Llama 3.1, temp = 0.0 FCD \cdot FGR \cdot FDF \cdot ECS \cdot OSR \;\rightarrow\; THS (5 weighting configs) REQ RESP REVIEW FINAL Figure 1: OFP-based multi-agent pipeline. The user submits a prompt ( OFP_REQUEST ); the FrontEndAgent

Read the complete text