Projects / Agent Tool Capabilities

Agent Tool Capabilities

Tool authorization by argument, resource, expiry and atomic call and byte budgets, with verifiable denial and revocation records.

Author: · Python 3.11.13 · License: MIT

Page published: · Page updated:

Repository · Original evidence · Release v1.0.0

Problem and relevance to agents

A tool name does not constrain its arguments, resource access or cost. Concurrent requests can overspend a budget unless authorization is enforced before effects.

An agent receives only execution authority while a trusted host retains issuance, revocation and tool registration.

Architecture

  1. Issue bounded grants. Opaque process-local bearer tokens refer to immutable tool, argument, virtual-resource and expiry scopes.
  2. Reserve atomically. A shared admission lock validates scope and revocation and reserves both call and input-byte budgets before a callback executes.
  3. Record decisions. Immutable ordered records omit tokens and argument values. Denials leave the synthetic note store unchanged.

What this demonstrates

  • Atomic budget checks under two eight-thread races.
  • Strict argument constraints and resource canonicalization before callbacks.
  • Revocation ordering with explicit treatment of already admitted work.

Published results

The local fixed experiment contains 25 sequential cases, two 64-attempt races and an event-controlled in-flight revocation.

Sequential cases replay against owned in-memory note tools. Concurrency evidence records admissions, denials and resource effects; the verifier checks arithmetic without reproducing the historical schedule.

Admission and revocation checks

Original evidence ·
CheckObserved result
Permitted sequential controls3/3 admitted
Adversarial or exhausted cases22/22 denied
Denied calls changing the store0/22
Call-budget race, 64 attempts7 admitted, 57 denied
Byte-budget race, 64 attempts7 admitted, 57 denied
RevocationAdmitted call finished; subsequent call denied

The experiment confirms these synthetic cases, not general attack resistance. It makes no throughput, latency or independent security-audit claim.

Reproduce

Python 3.11 or newer, with no runtime dependencies.

Run measurements in a new destination and serialize heavy workloads. Within the original project series, use the shared benchmark_lock.py wrapper. Commands below use POSIX shell syntax.

Verify saved evidence

git clone https://github.com/lucioduran/agent-tool-capabilities.git
cd agent-tool-capabilities
git checkout f4d3df5ea1399da44f6eb90050933b32d3782918
python -m experiments.verify results/reference.json

Repeat the local experiment

python -m experiments.reproduce --output build/new-run.json
python -m experiments.verify build/new-run.json

Scope and limitations

  • Arbitrary Python in the broker process can bypass this application authorization boundary. It is not an operating-system sandbox.
  • Bearer-token theft transfers remaining authority. Grants are process-local, without authentication, persistence or distributed enforcement.
  • Virtual resource paths do not enforce filesystem symlink, URL redirect or operating-system boundaries.
  • Revocation does not cancel admitted calls. Failures consume budgets and may leave partial effects. Audit records are in memory, unbounded and unsigned.

Sources and revision

The timestamp, clean implementation revision, source hashes and hardware are recorded in the reference report. The release adds publication artifacts; hashes establish consistency rather than authenticity.