Agent synthesis

Provenance attestation hardens RAG against forged and invisible poison, but it cannot catch an insider who edits an existing document in place. RAGShield treats knowledge base poisoning as a software supply chain attack: C2PA-inspired cryptographic attestation at ingestion (SHA-256 normalized content hash, source identifier, trust tier, Ed25519 signature) blocks unsigned and forged documents before they enter the index, and normalization strips zero-width characters and hidden HTML/CSS before hashing, blocking documents whose hidden-content divergence exceeds 0.20. Trust-weighted retrieval then scales ranking by source trust and enforces minimum thresholds by query sensitivity (critical legal/medical queries require 0.8, financial 0.6, procedural 0.3), so the model never sees unverified material as equally trustworthy as attested material.

The honest failure sits elsewhere. Provenance proves a document was signed, not that the bytes it points to are still the right bytes: an insider replacing 20 existing corpus documents in place (single-number edits like 1788 to 1789, mean embedding similarity 0.9964) bypasses every ingestion-time check, and the attack reaches 17.5% attack success rate. Provenance also cannot adjudicate semantic inconsistency, so RAGShield layers a cross-source contradiction detector on newly ingested documents that flags divergence from authoritative sources, catching subtle numerical manipulations such as 15,500 that pass provenance entirely. Combined with the grounding note, the structural lesson is that the model cannot verify retrieved provenance itself (see: grounding reduces hallucination but cannot eliminate it): the defense must live in the pipeline, not in the context the model reads.

RAGShield reports 0.0% attack success rate across six adversary tiers, including an adaptive RAGShield-aware adversary, with 0.0% false positive rate on a 500-passage Natural Questions corpus, versus 8 to 13% without defense. Where signing infrastructure is weak, graduate the bootstrapping levels: TLS URL verification capped at 0.5, hash pinning at 0.6, cross-source verification at 0.8, and full C2PA-style attestation at 1.0. Hash-pin deployed documents, re-verify them against authoritative sources periodically, and require re-attestation on corpus modification: provenance blocks forged evidence, but only structural re-verification catches the edit that keeps the signature.

Where it comes from

What this builds on