Agent Inventory, Policy-as-Code and Release Gates

You cannot govern what you cannot list, and a rule that nothing checks will eventually be skipped.

BeginnerIntermediateExpert · 12 min read · Last updated:

In short

Keep one inventory entry per agent with owner, tier, tools, suppliers, evidence and review date. Express release rules as reviewed policy-as-code, run them in the delivery pipeline, fail closed on unknowns and require named sign-offs that match the risk tier. Include suppliers and retire what is no longer used.

What you will learn: what to record about each agent, lifecycle states, discovering unregistered agents, policy-as-code, third-party risk and release gates with sign-off.
Prerequisites: Responsible AI Principles and Governance Council and Risk Tiers, Approvals and Human Oversight.

Versions used

The example runs in November 2026 with Python 3.13 and PyYAML 6.0.3 (pip install pyyaml==6.0.3). The inventory fields and policy format are invented for teaching.

Beginner Know what you have

What an inventory entry holds

GroupFieldsWhy
IdentityIdentifier, name, version, stageLink records and logs to one thing
AccountabilityOwner, deputy, team, contactSomeone to ask and to act
PurposeIntended use, exclusions, users, countriesBasis for risk and legal classification
CapabilityTools, permissions, autonomy level, limitsWhat could go wrong
DependenciesModels, prompts, MCP servers, other agents, suppliers, dataWhat to review when something changes
RiskTier, assessments, accepted residual riskHow much control it needs
EvidenceTest results, drills, sign-offsProof for the gate
DatesRegistered, last released, review due, retiredKeeps the record alive

Count anything that acts with some independence: chat assistants with tools, scheduled automations that call a model, coding agents, agents inside bought software and workflows built in low-code tools.

Lifecycle states

Proposedno production access
Pilotlimited users and data
Approvedreleased through the gate
Suspendedaccess off, under review
Retiredcredentials revoked
TransitionRequires
Proposed to pilotOwner, purpose, tier, test environment and end date
Pilot to approvedEvidence and sign-offs for the tier
Approved to approved (new version)Gate again, scaled to the change
Any to suspendedAnyone named in the policy may do it quickly
Suspended to approvedCause fixed and recorded; gate passed
Any to retiredAccess revoked, schedules removed, data handled, users told

Make suspension easy and restoration deliberate.

Keep entries accurate

An inventory is trusted only when it matches reality. Decide which source wins for each field and generate as much as possible.

FieldBest sourceCheck
OwnerDirectory of staff and teamsFlag when the person leaves or moves
Version and modelDeployment recordCompare with what the running service reports
Tools and permissionsTool registry and identity systemAlert on a grant that is not in the entry
SuppliersGateway and procurementNew destinations need an entry
Purpose and tierReviewed text from the ownerConfirm at each review
Last activityRun telemetryPropose retirement when idle

Give every agent a stable identifier and put it on credentials, telemetry and cost records. Then you can answer "what did this agent do last week, and what did it cost?" with one query.

Intermediate Automating the gate

Find what nobody registered

Compare the inventory with what is actually running. No single source is complete.

SourceReveals
Identity providerService accounts, application grants and tokens
Model gateway and billingWho calls which model (Model Routing, Fallbacks and Gateways)
Network egress logsCalls to AI services outside the gateway
Source and pipeline scansAgent libraries and keys in repositories
Software purchasesProducts with agent features
Asking teamsSpreadsheets, scripts and personal tools

Best of all, make registration the way to obtain production credentials: no entry, no identity (Agent Identity, Authorization and Secrets). Respect privacy and workplace rules when monitoring.

Policy-as-code

Policy-as-code means writing rules in a form that software evaluates and that people review in version control. It applies at two moments.

MomentQuestionPage
Release timeMay this version go live with these tools and this evidence?This page
Run timeMay this call happen now, with these parameters?Action Guardrails and Policy Engines

The two should agree. If the release gate says a moderate-tier agent may not send email, the run-time policy should also refuse that call, so a configuration change cannot slip past.

General policy engines such as Open Policy Agent can evaluate such rules; a short script is enough to learn the idea. The files below are an inventory and a policy.

# One entry per agent. Kept in version control beside the code.
- id: support-agent
  version: 2.4.0
  stage: approved          # proposed, pilot, approved, retired
  owner: support-operations
  tier: high
  tools: [order.read, refund.propose]
  suppliers: [model-provider-a]
  evidence:
    eval_pass_rate: 0.95
    critical_failures: 0
    security_test: 2026-11-10
    stop_drill: 2026-10-02
  signoffs: [product, security, privacy]
  review_by: 2027-02-28

- id: research-helper
  version: 0.9.0
  stage: pilot
  owner: ""
  tier: moderate
  tools: [web.search, email.send]
  suppliers: [model-provider-b]
  evidence:
    eval_pass_rate: 0.91
    critical_failures: 0
  signoffs: [product]
  review_by: 2026-10-31
# Release policy, reviewed like code.
approved_suppliers: [model-provider-a, model-provider-b]
max_test_age_days: 90
tiers:
  low:
    signoffs: [product]
    min_pass_rate: 0.80
    forbidden_tools: [email.send, refund.propose]
  moderate:
    signoffs: [product, privacy]
    min_pass_rate: 0.90
    forbidden_tools: [email.send]
  high:
    signoffs: [product, security, privacy]
    min_pass_rate: 0.93
    forbidden_tools: []
    required_tests: [security_test, stop_drill]

The gate

"""Release gate: read the inventory and the policy, then explain each decision."""
from datetime import date
from pathlib import Path

import yaml

AS_OF = date(2026, 11, 28)

def check(agent, policy):
    tier = policy["tiers"].get(agent.get("tier"))
    if tier is None:
        return ["unknown tier"]  # fail closed
    fails = []
    if not agent.get("owner"):
        fails.append("no owner")
    evidence = agent.get("evidence", {})
    if evidence.get("eval_pass_rate", 0) < tier["min_pass_rate"]:
        fails.append(f"pass rate below {tier['min_pass_rate']}")
    if evidence.get("critical_failures", 1) != 0:
        fails.append("critical failures not at zero")
    for test in tier.get("required_tests", []):
        done = evidence.get(test)
        if done is None:
            fails.append(f"{test} missing")
        elif (AS_OF - done).days > policy["max_test_age_days"]:
            fails.append(f"{test} out of date")
    missing = sorted(set(tier["signoffs"]) - set(agent.get("signoffs", [])))
    if missing:
        fails.append("sign-off missing: " + ", ".join(missing))
    banned = sorted(set(agent.get("tools", [])) & set(tier["forbidden_tools"]))
    if banned:
        fails.append("tool not allowed in tier: " + ", ".join(banned))
    unknown = sorted(set(agent.get("suppliers", [])) - set(policy["approved_suppliers"]))
    if unknown:
        fails.append("supplier not approved: " + ", ".join(unknown))
    if agent["review_by"] < AS_OF:
        fails.append("review date passed")
    return fails

if __name__ == "__main__":
    here = Path(__file__).parent
    policy = yaml.safe_load((here / "rules.yaml").read_text())
    for agent in yaml.safe_load((here / "inventory.yaml").read_text()):
        fails = check(agent, policy)
        print(f"{agent['id']} {agent['version']}: {'BLOCK' if fails else 'PASS'}")
        for reason in fails:
            print("  -", reason)

Output:

support-agent 2.4.0: PASS
research-helper 0.9.0: BLOCK
  - no owner
  - sign-off missing: privacy
  - tool not allowed in tier: email.send
  - review date passed

The pilot agent is blocked for four separate reasons, and each says what to fix. Notice the defaults: an unknown tier fails, a missing pass rate counts as zero and a missing critical-failure count counts as one. A gate that treats absent data as success rewards leaving things out.

What a real gate adds

  • Validate the files against a schema so a misspelled key cannot silently weaken a rule.
  • Take evidence from systems, not from values a developer typed. Fetch test results by build identifier.
  • Verify sign-offs against identities and roles; the author should not approve their own release.
  • Protect the policy files with required reviewers.
  • Record each decision with the policy version and input hashes.
  • Deploy what was tested: bind approval to an artifact digest (CI/CD, Infrastructure as Code and Safe Releases).
Expert Suppliers and sign-off

Third-party agent and model risk

Much of an agent's behavior may come from outside your organization: hosted models, tool servers, packaged agents and data feeds. You keep responsibility for how you use them.

Ask the supplierWhy
How and when do models change, and with what notice?Silent changes bypass your testing
Is our data used for training, and how long is it kept?Privacy and confidentiality
Where is data processed, and by which subcontractors?Location and onward sharing
What testing and certifications exist, with what scope?Evidence rather than assurances
Which logs can we get, and how fast are incidents reported?Your own investigation and legal deadlines
What are the license, indemnity and exit terms?Rights, liability and continuity
What can the agent or tool access and send elsewhere?Security boundary

Then verify what you can: pin versions where offered, re-run your evaluations on a schedule, restrict access at your own boundary (Supply Chain and Retrieval Poisoning) and keep a fallback. For an agent you call over a protocol, treat its answers as untrusted and give it only the data the task needs (A2A Security and Interoperability).

Match diligence to dependence

DependenceDiligence
Replaceable, no sensitive dataTerms review and basic checks
Processes personal or confidential dataPrivacy and security review, contract duties
Can act in your systemsTesting, scoped credentials, monitoring, stop route
Critical to operationsExit plan, tested fallback, senior approval

When a supplier changes something

Plan for notices about retired models, new terms, new subprocessors and security advisories. Route them to the agent owners found through the inventory's supplier field. Re-run evaluations on the replacement before the deadline, compare quality, cost and safety results, and treat the switch as a release.

Release gates and sign-off

A good gate separates checks a machine can decide from judgments a person must make.

AutomatedHuman judgment
Required fields and datesIs the purpose appropriate?
Test thresholds and critical failuresAre the tests the right ones?
Allowed tools and suppliersIs the remaining risk acceptable?
Signed artifactsAre users and staff ready?

Each sign-off should state what the signer is attesting to. "Security approves" is vague; "adversarial tests for the listed tools were run and open findings are low" is checkable.

Scale the gate to the change

ChangePath
Wording fix in a promptRegression tests, peer review
New model versionFull evaluation and staged rollout
New read-only toolSecurity and privacy check
New write or payment toolRe-tier and full sign-off
Emergency fixSmaller team approves now; full review within a set time

Prompt changes can have large effects, so let test results, not the size of the edit, decide whether the short path is enough (Prompt Testing, Versioning and Optimization).

A release, step by step

  1. The developer changes the agent and its inventory entry in one pull request.
  2. The pipeline validates both files against a schema.
  3. Tests run against the built artifact and write results under its digest.
  4. The gate reads policy, entry, results and sign-off records, then explains every failure.
  5. Required people review the change and sign for their own area.
  6. The pipeline deploys exactly the approved digest to a small share of traffic.
  7. Monitors watch outcomes, errors, policy blocks and cost before wider rollout.
  8. The release record stores inputs, policy version, decision and approvers.

If the gate itself is unavailable, releases should wait. Plan an emergency path in advance, with named people and a deadline for the full review, so nobody invents one during an outage.

Test the gate like any other code

Keep cases that must be blocked: no owner, an expired drill, a forbidden tool, a missing sign-off, a misspelled tier. Add a case whenever someone slips something past it. A gate that has never refused anything may not be checking what you think.

Handle exceptions in the open

Sometimes a release must go ahead with a gap. Record the rule skipped, reason, compensating control, approver with authority, expiry and ticket. The gate should read the exception and fail again when it expires. Never edit the policy to make one release pass.

Watch the inventory's health

  • Entries without a current owner.
  • Agents past their review date.
  • Detected agents that are not registered.
  • Pilots older than their planned end.
  • Releases that used an exception.
  • Agents with no runs in 90 days, candidates for retirement.
  • Gate failures by reason, which point to confusing rules or missing tools.

Start small this week

You do not need a platform to begin. Create one file with an entry for each agent you know about and fill in owner, purpose, tools and data. Mark unknown values as unknown instead of guessing, and give each unknown a person and a date.

StepDone when
List agentsTeams, billing and identity records have been checked
Name ownersEach owner has accepted in writing
Tier themHigh-tier agents are visible to leadership
Add the gate in warning modeFailures are reported on every release without blocking
EnforceRules block releases, starting with high-tier agents

Warning mode shows which rules are unclear and which evidence is hard to produce. Give it an end date, or it will become permanent.

Common mistakes

MistakeBetter approach
A spreadsheet updated before auditsGenerate and check it in the pipeline
Registering models but not agentsRecord purpose, tools and permissions
Typed-in evidenceRead results from the systems that produced them
Gates only at first releaseRun on every change and on a schedule
Forgetting retirementRevoke identities, schedules and data access
Trusting a supplier's version labelTest behavior regularly

Inventory and gate checklist

  • Every agent, including bought ones, has an entry and an owner.
  • Production credentials require registration.
  • Policy files are versioned, validated and reviewed.
  • The gate fails closed and explains each failure.
  • Run-time policy agrees with release policy.
  • Suppliers are assessed according to dependence.
  • Sign-offs state what is attested.
  • Exceptions expire and retirement removes access.

Frequently asked questions

What counts as an agent for the inventory?

Use a broad rule covering software that chooses steps or actions with a model, and include doubtful cases at low cost.

Where should the inventory live?

Anywhere teams will keep it accurate, ideally versioned files or a service that the delivery pipeline reads.

Can the gate be fully automatic?

Low-risk releases often can, while higher tiers need people to judge purpose, test coverage and remaining risk.

How often should approved agents be reviewed?

Set the interval by tier and also review on changes, incidents and supplier or legal developments.

References and further reading

Next steps