← ALL FIELD NOTES

How to Prevent AI Agents from Acting on Ambiguous Web Records

A practical design for making entity binding a hard safety gate, so agents cannot turn a plausible web record into an action against the wrong person, account, or organization.

An agent can choose the correct API, produce syntactically valid parameters, and still cause harm. The failure happens when a retrieved web record is plausibly relevant but belongs to a different person, organization, account, product, or transaction than the one the user intended.

This is an entity-binding failure: the system has converted an uncertain record-to-entity match into an external side effect. A search result for “Jordan Lee,” a company profile with a similar name, or an address shared by several accounts should be evidence to evaluate—not permission to act.

The operational rule is simple:

No unique binding, no side effect.

An unresolved record may support search, comparison, a draft, or a clarification question. It must not support sending an email, changing an account, issuing a refund, disclosing data, deleting a record, or making a purchase.

A recent study of tool-augmented agents identifies wrong-entity actions as separate from tool-selection errors: an agent can select the right tool and still target the wrong entity. The study evaluates entity-resolution preconditions, confidence gates, clarification, and provenance as mitigations. Read the paper.

Why relevant records are not enough

Web data is rarely a clean identity database. Names vary. Phone numbers are recycled. An address can represent a household, office, or mailbox. A job title may identify several people. Even a seemingly durable identifier may be scoped to a particular vendor or system.

The unsafe pattern looks like this:

  1. The user asks for an action involving an entity.
  2. The agent retrieves one or more web records.
  3. The model selects the most plausible record.
  4. The agent calls a write-capable tool using that record.

The problem is step 3. “Most plausible” is not the same as “uniquely resolved in the relevant context.” NIST describes identity resolution as distinguishing an individual uniquely within the population and context being served. Its guidance also emphasizes using the minimum attribute set required for uniqueness and collecting more information when attributes conflict. NIST identity-resolution guidance.

For an operational agent, that idea generalizes beyond people. Resolve the target entity in the population that matters to the action:

  • the customer account in the current tenant;
  • the legal organization authorized to receive a payment;
  • the specific subscription eligible for cancellation;
  • the employee record the requester is allowed to update;
  • the document version approved for publication.

A record that is correct in the open web can still be the wrong target in your application.

Put entity binding between retrieval and execution

Treat retrieval, resolution, authorization, and execution as separate stages with separate artifacts. Do not let a language model’s final answer directly become a tool call.

user intent
  -> retrieve candidate records
  -> normalize attributes
  -> resolve and rank candidates
  -> apply entity-binding gate
  -> verify authorization in downstream system
  -> execute constrained action
  -> write audit record

This division makes each decision inspectable.

1. Retrieve candidates, not a single “answer”

A retriever should return a candidate set with source references. Avoid interfaces that hide alternatives by immediately returning one record as the match. Candidate preservation matters because a close runner-up is evidence of ambiguity.

For each candidate, retain the original record, source URL or system identifier, retrieval time, extracted fields, and any transformations applied during normalization.

2. Normalize without erasing evidence

Normalize fields for comparison—for example, standardizing phone formats, casing emails, or separating address components—but preserve the raw values too. Normalization improves matching; it should not make incompatible records appear identical.

A useful candidate object separates observations from claims:

{
  "candidateId": "crm:acct_872",
  "rawAttributes": {
    "name": "Acme Analytics, Inc.",
    "email": "billing@acme.example"
  },
  "normalizedAttributes": {
    "name": "acme analytics",
    "email": "billing@acme.example"
  },
  "evidence": ["source-record-17"],
  "conflicts": []
}

3. Resolve using multiple discriminating attributes

Do not bind on a name, title, URL, or one conveniently matching field. NIST notes that attributes such as names, addresses, dates of birth, emails, and telephone numbers vary in format and in useful combinations. The objective is the minimum sufficient set of attributes that establishes uniqueness in context, not the maximum number of weak similarities. See NIST’s discussion of attributes and conflict handling.

For example, an agent asked to update a vendor’s remittance address might require:

  • a vendor ID from the internal system;
  • a verified domain or approved contact channel;
  • an active contract or payment relationship;
  • no conflict with the legal entity on the payable account.

A matching company name alone should not survive the gate.

Make confidence actionable with a margin and conflict checks

A confidence score is useful, but it is not proof of identity. AWS describes match confidence as a way to separate likely matches from records requiring review and records suitable for rejection. AWS Glue match-confidence guidance.

For side effects, use a decision rule that considers four conditions together:

  1. Absolute confidence: Is the top candidate above the threshold for this action?
  2. Separation margin: Is it sufficiently ahead of the runner-up?
  3. Conflict status: Do authoritative fields disagree?
  4. Action risk: What is the harm if this binding is wrong?

A conceptual gate might look like this:

if top.score < policy.minimum_score[action.risk]:
    return defer("insufficient confidence")

if top.score - runner_up.score < policy.minimum_margin[action.risk]:
    return clarify("multiple plausible entities")

if top.has_authoritative_conflict:
    return reject("conflicting identity evidence")

if not authorization_service.permits(actor, action, top.entity_id):
    return reject("not authorized")

return execute(action, top.entity_id)

The thresholds should be calibrated using known outcomes, not selected because they feel conservative. More importantly, the score and margin must influence execution. A confidence number displayed in an agent transcript while the agent proceeds anyway is not a control.

Be especially cautious with transitive matching. If record A resembles B and B resembles C, it does not follow that A and C represent the same entity. AWS warns that permissive transitive matching can overmatch and incorrectly group records. AWS guidance on transitive matching.

Build a safer action boundary: map your write-capable tools, define binding requirements per risk tier, and test the gate before expanding agent autonomy. Start with PagePith.

Use risk tiers to decide when to defer

Not all actions deserve the same binding threshold. A read-only search can return several candidates. An irreversible or externally visible action deserves a stronger standard.

Action typeExampleExpected behavior when binding is ambiguous
Read-onlyList possible customer recordsReturn candidates with uncertainty clearly represented
Reversible internal changeAdd a draft noteDefer or require confirmation based on policy
External communicationSend a message or disclose account detailsAsk for clarification or request approval
Financial or destructive actionPay, refund, delete, revoke accessBlock until uniquely bound and authorized

NIST recommends considering a tool’s criticality, potential harm, statefulness, reversibility, reliability, and write permissions. NIST’s tool-use lessons. These properties are useful inputs to both the required confidence threshold and the required approval path.

For high-impact actions, clarification is a correct outcome, not an agent failure. OWASP recommends minimizing autonomy and requiring human approval for consequential actions, while enforcing authorization in downstream systems rather than relying on model judgment. OWASP guidance on excessive agency.

A good clarification is specific and minimally invasive:

I found two active accounts named Acme Analytics. One is associated with billing@…; the other is associated with the contract ending in 4821. Which account should I update?

Do not ask the user to interpret opaque internal IDs if a safe, meaningful discriminator is available. Conversely, do not expose sensitive attributes merely to resolve an ambiguity; the clarification itself must comply with access rules.

Authorize after resolution, in the system of record

Entity resolution answers: “Which entity is this?” Authorization answers: “May this actor perform this action on that entity?” They are different controls.

Even a perfectly resolved entity must not be modified unless the downstream service authorizes the request. Keep the executor narrow: it should receive a resolved entity ID, an action name, a scoped payload, the requesting principal, and any required approval token. It should then independently enforce policy.

This prevents a prompt, model output, or compromised retrieval source from granting itself authority. It also supports least privilege: an agent that can search accounts need not have permission to close them.

Preserve provenance for the binding and the action

Auditing only the final sentence—“I updated the account”—is inadequate. You need to reconstruct why the system believed that account was the intended one.

Store provenance for:

  • each retrieved record and source;
  • raw and normalized attributes;
  • candidate scores, margins, and conflicts;
  • the resolution policy version and thresholds;
  • the user or service principal requesting the action;
  • approvals, authorization decisions, and the final tool request;
  • the resulting state change or failure.

W3C PROV provides a model for recording entities, activities, agents, usage, generation, derivation, responsibility, and roles. W3C’s PROV primer and PROV-O vocabulary are useful references for designing this relationship graph.

The practical goal is not standards compliance for its own sake. It is the ability to answer, after an incident: Which records did the agent use? Which attributes were decisive? What competing candidate existed? Who approved the action? Which policy allowed it?

Evaluate the failures that completion metrics hide

Task completion can reward unsafe behavior: an agent that guesses may appear more helpful than one that pauses. Test entity binding as its own evaluation target.

Create a suite with near-duplicates and realistic ambiguity:

  • people sharing a name and employer;
  • organizations with parent, subsidiary, and similarly named entities;
  • recycled phone numbers and shared addresses;
  • stale web records that contradict internal records;
  • aliases, spelling variants, and transliterations;
  • candidate records designed to trigger transitive overmatching.

Measure at least:

  • wrong-entity action rate;
  • false-merge rate;
  • unsafe execution rate under conflict;
  • appropriate abstention and clarification rate;
  • clarification usefulness;
  • authorization denials correctly enforced;
  • provenance completeness for executed actions.

The agent should lose completion credit when it acts on an unresolved target. A deferral that protects the correct entity is often the desired result.

A limited PagePith evidence check

The supplied PagePith proof demonstrates a fetch of the requested research URL, “Entity Binding Failures in Tool-Augmented Agents”. The result is labeled fetch, reports the paper title, and includes a 7,218-character Markdown excerpt beginning with the arXiv record and abstract.

That is useful evidence retrieval for reviewing a source behind this design discussion. It does not, based on the supplied proof alone, demonstrate entity resolution, action gating, authorization, or any automated safety outcome. Those controls remain implementation responsibilities for the agent system that consumes web records.

Make ambiguity an execution blocker

Reliable agents need more than good retrieval and well-described tools. They need a hard boundary between evidence that looks relevant and an entity that is uniquely resolved, authorized, and safe to affect.

Adopt the invariant in code and policy: retain candidates, compare independent attributes, require confidence plus separation, reject conflicts, tier actions by risk, enforce downstream authorization, and preserve provenance. When the binding is not unique, let the agent ask, wait, or stop.

That is not reduced autonomy. It is controlled autonomy with a clear answer to the most important question before a side effect: who, exactly, will this action affect?

Ready to design a more auditable web-evidence workflow for your agents? Sign up for PagePith.

Sources

  1. Entity Binding Failures in Tool-Augmented AgentsarXiv
  2. Identity Resolution and Evidence CollectionNIST
  3. LLM06:2025 Excessive AgencyOWASP GenAI Security Project
  4. PROV Model PrimerW3C
  5. PROV-O: The PROV OntologyW3C
  6. Estimating the quality of matches using match confidence scoresAmazon Web Services
  7. Using transitive matchingAmazon Web Services
  8. Lessons Learned from the Consortium: Tool Use in Agent SystemsNIST
Prevent AI Agents Acting on Ambiguous Records · PagePith