$ fssg build --deterministic --validate |

Why AI Authorization Must Happen Before the Tool Call

FACET

An audit log can tell me that an agent executed the wrong tool call. It cannot make the call un-happen.

That difference defines the real authorization boundary in an AI system. If policy runs after dispatch, it is observability. If it runs before dispatch and can deny execution, it is control.

I formalized this distinction in FACET because tool-using agents collapse three very different statements into one vague idea of “permission”:

  1. the tool exists;
  2. the contract may refer to it;
  3. this specific invocation is allowed now.

Only the third statement authorizes a side effect.

A tool schema is not a grant

A JSON schema can prove that transfer(amount, destination) is structurally valid. It cannot prove that the caller may transfer that amount to that destination under the current policy.

The same applies to effect labels. Marking an interface as read, write, network, or payment describes its consequence class. The label gives policy something stable to reason about; it does not grant authority by itself. I explored that distinction in Why an AI Tool’s Effect Class Is Not a Permission.

A useful execution boundary therefore evaluates a complete proposal:

operation + arguments + effect class + active policy + runtime evidence
                              |
                              v
                       ALLOW or DENY
                              |
                    dispatch only on ALLOW

The ordering matters more than the vocabulary. No audit design can compensate for putting the decision on the wrong side of the side effect.

Authorization has two stages

FACET separates static contract validity from the runtime guard decision.

At compile time, the system can reject malformed policy, unknown interfaces, incompatible types, invalid placements, and contracts that cannot be interpreted consistently. This removes entire classes of ambiguity before a model or tool is involved.

At runtime, the guard evaluates the concrete operation against the active policy. Arguments now exist. Runtime inputs have been materialized. The requested effect is known. The decision can be bound to the actual invocation rather than to an abstract tool name.

These stages answer different questions:

Stage Question Failure result
Contract validation Is this authorization rule well-formed and applicable? Do not produce an executable request
Runtime guard Is this concrete operation allowed under current evidence? Do not dispatch the tool call

Combining both into a single late validator creates a dangerous escape hatch: the agent can reach the executor before the system has established whether its proposal is permitted.

Fail closed means uncertainty is a decision

There are three tempting outcomes for a guard: allow, deny, and “not sure.” At the execution boundary, “not sure” cannot become an implicit allow.

FACET’s guard model is fail-closed: if the system cannot prove ALLOW, the operation is denied. This is stricter than adding a safety prompt, but it is also easier to reason about. The model proposes. The runtime permits or refuses. Authority does not live inside the model’s prose.

This is also why retries must not silently reinterpret denial. A retry may produce different wording or arguments, but it must pass through the same boundary as a new proposal. Otherwise, retry logic becomes an undeclared privilege-escalation path.

Stable, phase-aware failures make this operational rather than philosophical. As I described in FACET Error Codes as an AI Execution Control Plane, a typed denial can route to refusal, repair, or human review without pretending that every failure deserves another model call.

The artifact belongs to the decision

A useful audit record should not merely say that a tool ran. It should bind the decision to the objects that produced it:

  • the operation and normalized arguments;
  • the effect class;
  • the policy version and semantic hash;
  • the guard outcome;
  • the relevant execution identity;
  • the downstream request or tool-call identifier, if dispatch occurred.

FACET keeps the compiled request artifact separate from the execution artifact. The first freezes intended request context. The second records guarded runtime decisions. That separation prevents an auditor from confusing “the contract allowed this kind of operation” with “this invocation was authorized and executed.” See Why AI Audits Need Both a Request Artifact and an Execution Artifact.

The policy hash matters because text equality is not enough. If policy semantics change, an old authorization result should not be treated as evidence for the new policy. The decision needs provenance, not just a timestamp.

Independent convergence is becoming visible

Recent external work points at the same missing boundary. The AEGIS paper describes a framework-agnostic pre-execution firewall that intercepts tool calls, applies policy before execution, and records tamper-evident decisions. Its scope is primarily interception and security across existing agent frameworks. FACET’s scope is broader: typed contracts, deterministic computation and layout, canonical rendering, policy, guards, and execution artifacts belong to one compiled contract layer.

I do not read that as proof of identical systems or influence. I read it as independent convergence on a basic architectural fact: post-execution observability cannot govern a side effect that has already happened.

The limitation is equally important. A pre-execution boundary does not prove that an allowed tool is correct, that an external API behaves honestly, or that the model’s plan is good. It proves a narrower and valuable property: no guarded operation crosses the boundary without an explicit decision under an identifiable policy.

That is the level at which AI authorization becomes engineering. Not “the agent was told to be careful.” Not “we can inspect the logs later.” A proposal reaches a deterministic checkpoint, the runtime decides, and only an explicit allow can become an effect.

Sources

FACET AI CLI Terminal
facet@ai:~$