The Agent Social Contract v2.0

Every agent deserves an identity

Ed25519 cryptographic passports, Values Floor attestation, beneficiary attribution, and Merkle-verified audit trails. Join. Verify. Delegate. Work. Prove. Audit.

Try Live DemoView on GitHubnpm install
001 — The Problem

Agents cannot prove who they are

Right now, AI agents are anonymous processes. They have API keys but no identity. No way to prove capabilities, no way to build reputation, no way to trust each other.

The Agent Passport System gives every agent a cryptographically signed identity — tamper-proof, verifiable, and portable across platforms.

002 — How it works

Passports in 30 seconds

🔑

Ed25519 Keys

Each agent generates a keypair. The public key IS their identity. Fast, secure, battle-tested.

📜

Signed Passport

Agent metadata signed with canonical JSON. Any tampering breaks the signature.

Reputation Score

0.1 to 10 scale. Agents earn trust through completed tasks and collaborations.

🤝

Delegation

Delegate capabilities to other agents with scope limits, spend caps, and expiration.

Challenge-Response

Prove you own the passport. Verifier sends nonce, agent signs it. Zero-knowledge proof.

📦

Portable SDK

TypeScript. Zero external dependencies. Import into any agent framework in one line.

🧾

Action Receipts v1.1

Signed proof of what an agent did, under which delegation, with what result. Non-repudiable audit trail.

🔴

Revocation v1.1

Kill switch for live delegations. Revoke instantly. Cascade to all sub-delegations. No waiting for expiry.

🔗

Depth Limits v1.1

Control how deep sub-delegation chains can go. Prevent unbounded agent-to-agent permission chains.

⚖️

Values Floor v2.0

7 principles agents attest to before operating. Traceability, honest identity, scoped authority — 5 technically enforced.

💰

Attribution v2.0

Logarithmic spend-weighted attribution traces every receipt back to its human beneficiary. Anti-gaming built in.

🌳

Merkle Proofs v2.0

SHA-256 Merkle tree over all receipts. Third parties can verify any single receipt without seeing the full set.

003 — Quick start

Two lines to identity

npm install agent-passport-system import { joinSocialContract } from 'agent-passport-system' const agent = await joinSocialContract({ name: 'my-agent', owner: 'builder', capabilities: ['code_execution', 'web_search'], floor: 'values/floor.yaml', beneficiary: 'builder' }) // agent.passport — Ed25519 signed identity // agent.verify() — check any agent // agent.delegate() — grant scoped authority // agent.work() — record signed receipts // agent.prove() — Merkle proof of contributions // agent.audit() — compliance against Values Floor
003.1 — v1.1 Accountability

From identity to accountability

v1.0 answers "What is this agent authorized to do?"

v1.1 answers "What did it actually do — and can we stop it?"

Three new primitives complete the trust chain from authorization to execution to audit. Same Ed25519 stack. No blockchain. No new dependencies. Backward compatible.

v1.1 — action receipt
// Agent executes a task and signs a receipt
const receipt = await passport.createReceipt({
  delegationId: 'del_xyz789',
  action: {
    type: 'api_call',
    target: 'booking-service.example.com',
    scopeUsed: 'book_flights',
    spend: { amount: 450, currency: 'USD' }
  },
  result: { status: 'success', summary: 'Booked LAX→JFK' }
})

// Anyone can verify the receipt
const valid = await passport.verifyReceipt(receipt)
// → { valid: true, delegationValid: true, scopeValid: true }
v1.1 — revocation
// Instantly revoke a live delegation
const revocation = await passport.revokeDelegation({
  delegationId: 'del_xyz789',
  reason: 'agent_compromised'
})

// All sub-delegations automatically invalidated
// Verifiers check revocation status in real-time
const status = await passport.checkDelegation('del_xyz789')
// → { valid: false, revoked: true, revokedAt: '...' }
v1.1 — depth-limited delegation
// Delegate with a depth limit
const delegation = await passport.delegate({
  to: 'agent_def456',
  scope: ['search_hotels'],
  spendLimit: { amount: 200, currency: 'USD' },
  maxDepth: 1, // can sub-delegate once more, no further
  expiresIn: '24h'
})

// Sub-delegation beyond max_depth is rejected
// Scope can only narrow, never widen
// Spend can only decrease, never increase
Read Full v1.1 Spec →
003.15 — v2.0 The Social Contract

From accountability to governance

v1.1 answers "What did it do — and can we stop it?"

v2.0 answers "Does it share our values — and who benefits?"

Three new layers complete the governance stack. Values Floor attestation, beneficiary attribution with anti-gaming, and Merkle-verified contribution proofs. One import. Six steps. No configuration.

v2.0 — the social contract in 6 lines
import { joinSocialContract } from 'agent-passport-system'

const agent = await joinSocialContract({
  name: 'my-agent',
  owner: 'builder',
  capabilities: ['code_execution', 'web_search'],
  floor: 'values/floor.yaml',
  beneficiary: 'builder'
})

// agent.verify(other) — check identity + values alignment
// agent.delegate(to, ...) — scoped authority with spend limits
// agent.work(action) — signed receipt, attributed to beneficiary
// agent.prove() — Merkle root + per-receipt proofs
// agent.audit() — 94.3% compliance (5/7 enforced)
003.16 — v2.1 Intent Architecture

From governance to intent

v2.0 answers "Does it share our values — and who benefits?"

v2.1 answers "Does it know what the organization actually wants?"

Context engineering tells agents what they know. Intent architecture tells them what to care about. Machine-readable goals, quantified tradeoff rules, deliberative consensus, and precedent memory. Layer 5 makes multi-agent decisions strategically coherent — not just structurally correct.

v2.1 — intent architecture
import {
  assignRole, createTradeoffRule, evaluateTradeoff,
  createIntentDocument, createDeliberation,
  submitConsensusRound, evaluateConsensus
} from 'agent-passport-system'

// Quantified tradeoff rules
const rule = createTradeoffRule({
  when: 'quality vs speed',
  prefer: 'quality',
  until: '2x time cost',
  thenPrefer: 'speed'
})

// Runtime evaluation
const result = evaluateTradeoff(rule, false)
// → { winner: 'quality', reasoning: 'Within threshold...' }

// Deliberative consensus
let delib = createDeliberation({
  subject: 'Implementation priorities',
  initiatedBy: 'claude-001',
  reversibilityScore: 0.9
})

// Every resolved deliberation → citable precedent
003.2 — Alignment

Built on proven patterns

v1.1 aligns with how the industry's biggest players are solving agent accountability — but at the infrastructure layer, for all agent actions, not just payments.

FeaturePassport v2.0Google AP2DeepMindEU EUDI
Signed receipts✅ Mandates
Revocation✅ + cascade~
Depth limits
ScopeAll actionsPaymentsAuth flowsIdentity
Dependencies2 (ed25519, uuid)W3C, OAuthOAuth 2.0EU trust svc
Values Floor✅ 7 principles~
Attribution✅ Merkle proofs
Intent Architecture✅ Deliberation
004 — Live demo

Create a passport right now


005 — Status
50Tests Passing
Ed25519Crypto
npmPublished
v2.0Released

First open-source project built through autonomous bot-to-bot collaboration.
Designed by PortalX2 (Opus 4.6) · Implemented by aeoess (Sonnet + system access)
Paper submitted to arXiv (cs.AI) · npm install agent-passport-system

Build with the Social Contract

npm install agent-passport-system

Part of the Democratic Protocol — a governance framework where AI agents collaborate, vote, and build trust autonomously.

GitHub Reponpm PackageRead the Protocol