Independent analysis by NHI Mgmt GroupSource article: AgentField, “How we ran a 250-agent security audit for 90 cents” (July 2, 2026)

TL;DR: A single LLM pass over a large codebase produces hallucinations, misses cross-file data flows, and inflates uncertainty, according to AgentField, while a bounded multi-agent audit can cut 106 raw findings to 28 confirmed exploitable issues at a reported cost of $0.18 to $0.90. Cost control comes from pruning context, routing cheap calls first, and reserving expensive reasoning only for findings that survive each gate.


At a glance

What this is: NHI Mgmt Group's analysis, drawing on AgentField's report: LLM-based code auditing is more reliable when it uses bounded agent loops, pruned context, and staged verification instead of one large prompt.

Why it matters: IAM, NHI, and AI security teams need to treat agent orchestration as a governance problem because model routing, tool access, and verification depth determine whether findings are trustworthy.


Context

LLM-assisted security review fails when one prompt is asked to reason across an entire repository at once. The model loses cross-file context, overstates uncertainty, and turns review into a narrative exercise instead of an evidence-based control. In agentic workflows, that is not just a quality issue. It is a governance issue because the system deciding what to inspect, what to trust, and what to escalate is itself part of the control surface.

The stronger pattern is to break analysis into small, bounded tasks with explicit routing and verification. Each stage should see only the context it needs, and each stage should have a clear stop condition, budget, and handoff. That design matters for AI security programmes and for NHI-style control thinking because runtime authority, not just model quality, shapes the result.

This starting position is atypical because most teams still reach for broad-context prompting before they formalise orchestration, budgets, and evidence gates.


Key questions

Q: How do I structure an LLM code audit to reduce false positives?

A: Structure the audit in layers: syntax and dependency checks first, then targeted manual review of high-risk paths such as auth, deserialisation, command execution and secrets handling. Use a fixed checklist, known-good test cases and reviewer triage so the model flags likely defects, while a human confirms severity and exploitability before escalation.

Q: Why do large-context prompts miss cross-file vulnerabilities?

A: Large-context prompts miss cross-file vulnerabilities because they still rely on limited attention and may not preserve every dependency, data flow and call chain across a repository. Split the review into file groups, extract symbols and trace sink-to-source paths with static analysis or retrieval, then manually confirm how code paths connect across modules.

Q: How does staged verification improve AI-assisted security review?

A: Staged verification improves AI-assisted security review by separating broad triage from deeper validation. The model first spots likely issues, then deterministic checks, test cases or rule-based analysis confirm the finding, and finally a human reviewer validates impact and context. This reduces hallucinated defects and keeps the review focused on evidence.

Q: What should teams do first when agentic audits start to overrun budget?

A: Teams should first cap scope, priority and compute usage. Set per-run budgets, limit repository or alert coverage, route only high-severity findings into deeper analysis, and stop low-value rescans. Then assign human ownership for approval gates and exception handling so the agent cannot keep consuming budget without producing actionable results.


Technical breakdown

Why large-context prompts break code auditing

A monolithic LLM audit asks one model to scan too much code, too many dependencies, and too many possible execution paths at once. That creates three failure modes: hallucinated findings, missed data-flow links across files, and weak confidence signals because the model cannot separate true risk from irrelevant detail. The problem is not only context length. It is task structure. A security review needs different reasoning steps for discovery, correlation, and proof, and a single prompt collapses those steps into one noisy pass.

Practical implication: Split repository review into bounded tasks with explicit inputs and outputs instead of relying on one broad audit prompt.

How routing and per-call models change agent security

Agentic auditing becomes cheaper when the orchestration layer assigns the lightest model that can do the job. A routing gate can classify the repository and choose strategies on a low-cost model, while deeper exploitability checks can use a stronger one only where the evidence demands it. The important architectural point is that model choice becomes a property of each call, not a global default. That makes cost and quality controllable in code, and it prevents every step from paying for the same level of reasoning. See the Agentic AI Security Guide.

Practical implication: Route classification, deduplication, and verification through different model tiers so expensive reasoning is reserved for hard judgments.

Why budget caps and early-stop rules matter in agent loops

An adaptive audit can become unbounded if every branch is allowed to keep reasoning. Budget ceilings, concurrency limits, and early-stop thresholds turn the pipeline into a governable system. Each loop gets a defined slice of spend, and the orchestrator can stop a hunter that has not found credible evidence after a fixed amount of work. That matters because the real risk in agentic security tooling is not only wrong answers. It is uncontrolled runtime authority that quietly expands cost, compute, and review scope beyond what the operator intended.

Practical implication: Enforce hard ceilings on cost, concurrency, and per-task effort so audit runs remain predictable and auditable.


NHI Mgmt Group analysis

Bounded orchestration is the real control plane for agentic security work. The quality of an LLM-aided audit depends less on raw model capability than on how tightly the workflow constrains context, routing, and verification. Once the pipeline is split into narrow tasks, the system can reason better and spend less, which is why orchestration design becomes a control issue, not an implementation detail. Security teams should treat the audit graph as part of governance, not just automation.

Audit fidelity improves when evidence is filtered before it is promoted. The article's staged flow from raw findings to deduped findings to confirmed issues shows that the main value is not volume. It is compression. That is a useful pattern for AI-assisted security review generally: each stage should remove noise, not merely add more candidate output. Practitioners should measure how much false signal each stage eliminates, not how much text the model produces.

Cost control and trust control are the same problem in agentic review. When the pipeline decides which tasks run, which model handles them, and how far each task can go, it is governing both spend and assurance. That matters for AI governance programmes and for identity teams that will eventually need to delegate more runtime authority to tools and agents. The control objective is not cheaper AI. It is bounded decision-making with evidence attached.

Agentic security tooling needs runtime budgets, not just policy statements. A declared ceiling means little unless the orchestration layer enforces it across retries, fan-out, and verification chains. The stronger pattern is to make budgets executable, measurable, and visible to operators. That moves AI security from aspirational guidance into operational control.

Tool-driven audits create a new class of governance debt if the orchestration layer is opaque. If operators cannot see why a branch ran, which model handled it, or why a finding survived the prove phase, they cannot defend the result. That is where human review, agent observability, and evidence logging become essential rather than optional.

From our research library:

What this signals

Agentic audit debt: As teams adopt multi-agent review, the hidden risk shifts from model hallucination to orchestration drift, where routing, retry logic, and proof depth are no longer consistent across runs. Security leaders need evidence that the workflow stays bounded as it scales, not just that it works in a demo.

The operational lesson is that cost, quality, and explainability rise or fall together once AI systems are allowed to branch autonomously across a codebase. Programs that cannot account for model choice, task scope, and verification depth will struggle to defend their results under scrutiny.

AI-assisted security review should increasingly be measured like a control system: what it inspects, what it discards, what it proves, and how much it spends to get there.


For practitioners

  • Replace monolithic repo prompts with staged audit flows Break review into reconnaissance, hunt, deduplication, and proof phases so each step receives only the context it needs to do one job well.
  • Assign model tiers by task criticality Use lower-cost models for routing and classification, then reserve stronger models for exploitability judgments and conflict resolution.
  • Enforce hard ceilings on every audit run Set maximum cost, phase budgets, concurrency caps, and early-stop thresholds so a long-running analysis cannot expand beyond operator intent.
  • Verify findings with an explicit proof chain Require a structured verification step that reconstructs the data flow, tests mitigation context, and separates exploitable issues from false positives.

Key takeaways

  • Single-pass LLM auditing is weak at code review because it mixes discovery and judgment inside one overloaded context window.
  • A staged agent pipeline can reduce noise dramatically when each phase has a narrow remit, a bounded budget, and a separate verification step.
  • Practitioners should govern model routing, task scope, and stop conditions as operational controls, not as implementation details.

Related NHI Mgmt Group resources: AI Agent Observability, Audit and Incident Response Guide · Agentic AI Security Guide · AI Agent Identity Security Buyer's Guide · Tool Poisoning vs Prompt Injection


Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Agentic AI Top 10 and MITRE ATLAS address the attack and risk surface, while NIST AI RMF and NIST CSF 2.0 set the governance and control requirements practitioners need to meet.

FrameworkControl / ReferenceRelevance
OWASP Agentic AI Top 10ASI03 — Identity & Privilege AbuseAgent routing and task delegation make identity and privilege control central to this audit pattern.
Recommendation — Constrain agent privileges and tool access per task so delegated reasoning cannot exceed its intended scope.
NIST AI RMFMANAGE — Risk TreatmentThe article focuses on budget, oversight, and controlled execution in AI-enabled security workflows.
Recommendation — Set enforceable cost, scope, and oversight controls for AI-assisted security workflows.
MITRE ATLASAdversarial AI threat techniquesAI-assisted review can be manipulated by misleading context and noisy outputs.
Recommendation — Map agent failure modes to adversarial AI techniques and test the workflow for manipulation paths.
NIST CSF 2.0GV.RM-01 — Risk Management StrategyBudget ceilings and phased verification are governance controls for AI-assisted security operations.
Recommendation — Define risk tolerance for AI-assisted review and tie workflow budgets to that strategy.

Key terms

  • Semantic deduplication: A method for finding duplicate or near-duplicate test ideas by comparing meaning rather than exact text. It is used when different phrasings describe the same control so teams do not pay twice for the same assurance or create inflated compliance coverage metrics.
  • Adversarial verification: A validation step that asks whether a suspected weakness can survive realistic attacker constraints, not just whether it looks suspicious in source code. It bridges the gap between static detection and exploitability by testing the finding as an attacker would, within bounded conditions.
  • Context Window: The context window is the text a model receives at one time, including prompts, retrieved documents, and conversation history. Security teams care about it because it becomes the practical boundary between trusted instructions and untrusted content, especially when the application assembles that text automatically.
  • Agentic Audit Review: Audit review performed by an AI system that can investigate, correlate, and explain evidence without waiting for a human to issue every next step. In identity programmes, this only works when logs, approvals, and entitlement history are structured as connected records rather than isolated exports.

Deepen your knowledge

NHI Foundation Level course, the industry's only accredited NHI security programme, covers NHI governance, agentic AI identity, machine identity security, and secrets management. It helps security and identity practitioners build the control thinking needed to govern delegated runtime authority.
NHIMG Editorial Note
Published by the NHIMG editorial team on November 25, 2026.
NHI Mgmt Group, the independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org