CPContext Passport
Document №
CP-2025-001 / V1.0
Classification
Open Standard · Draft
Issued by
Community / CC0
Valid
In perpetuity
Open Standard · Est. 2025

The envelope
format for AI agent
events.

Specimen · Plate IA verified event chain, end-to-end
§ 01researcher
researcher
anthropic · claude
sha256:9f4c…0b9a
§ 02planner
planner
openai · gpt-4o
sha256:6b1e…0c4d
§ 03writer
writer
google · gemini
sha256:a7c2…f9e8
§ 04reviewer
reviewer
mistral · large
sha256:d4c3…1f9e

Each agent receives a passport, performs its task, and commits a new one. Every commit hashes the previous — a chain anyone can verify, on any machine, with no trusted intermediary.

rootverified ✓
sha256:9f4c2e1a7b3d8c5f6e4a2d1b9c8e7f6a5d4c3b2a1f9e8d7c6b5a4f3e2d1c0b9actx_1714402299411_a7c2f9schema_version: 1.0parent_hash: sha256:6b1e…0c4devent: commitverified ✓trace_id: trc_0e21a8branch_key: mainprovider: anthropic · openai · google · mistral · local
sha256:9f4c2e1a7b3d8c5f6e4a2d1b9c8e7f6a5d4c3b2a1f9e8d7c6b5a4f3e2d1c0b9actx_1714402299411_a7c2f9schema_version: 1.0parent_hash: sha256:6b1e…0c4devent: commitverified ✓trace_id: trc_0e21a8branch_key: mainprovider: anthropic · openai · google · mistral · local
Status
Draft v1.0
License
Open — CC0 1.0
Reference implementation
Open source, Apache-2.0
Specification steward
Community
§ 01 — The problem

Agents hand context to each other with no agreed format.

When Agent A finishes its task and hands work to Agent B, the format is arbitrary. A string. A dict. A JSON blob with no fixed shape. Agent B has to guess where the output is, who produced it, whether it was tampered with, and what model generated it.

Every team building multi-agent systems invents their own format. Those formats are incompatible. Cross-framework pipelines break at the boundary. Audit trails are unverifiable. Schema drift between agents causes silent failures in production.

Context Passport is the missing envelope format — a minimal, versioned schema that any agent, framework, or model can produce and consume, with built-in cryptographic integrity.

Fig. 01 — Verified event chain

One sealed envelope. Many agents.

01 · researcher
Researcher
anthropic · claude
02 · planner
Planner
openai · gpt-4o
03 · writer
Writer
google · gemini
04 · reviewer
Reviewer
mistral · large
sha256:9f4c…0b9a
sha256:6b1e…0c4d
sha256:a7c2…f9e8
sha256:d4c3…1f9e
root commitchain · sha-256verified ✓

Each agent receives a passport, performs its task, and commits a new one. Every commit hashes the previous — a chain that can be verified by any party, on any machine, with no trusted intermediary.

§ 02 — Design principles

Built to last.

Context Passport is designed with properties that will allow it to endure.

01

Minimal by design

The best standards do one thing well. Context Passport defines the envelope: who sent it, what it contains, that it is intact. The payload is open. Agents put whatever they need inside payload.input, payload.output, payload.memory, payload.variables.

02

Independent of transport

Context Passport works with any orchestration framework, any model provider, any language. The schema is JSON with a fixed structure. No SDK required — a curl command is enough.

03

Verifiable without trusting the issuer

SHA-256 parent hash chaining means any party can verify the chain is intact without trusting the system that stored it. The chain of trust is mathematical, not organizational.

04

Versioned from day one

schema_version: "1.0" is a first-class field. Backward compatibility is a design constraint from day one, not an afterthought.

05

Open governance

The specification is released under CC0 — no copyright, no restrictions. Reference implementations are Apache-2.0 with an explicit patent grant. The standard belongs to the community.

+06

Forward-compatible by extension

New event types and vendor-specific fields are namespaced (myorg.custom_type). Existing implementations ignore unknown extensions safely. The spec grows by addition, never by breaking change within a major version.

§ 03 — Specification v1.0

The schema.

Every field has a purpose. No field is required without a reason. The integrity block is computed automatically by compliant implementations.

context-passport.schema.json
v1.0 · draft
{
  "$schema":        "https://contextpassport.com/schema/v1.json",
  "schema_version": "1.0",

  // Identity
  "id":         "ctx_{unix_ms}_{6_hex_bytes}",  // globally unique
  "parent_id":  "ctx_... | null",               // null = root commit
  "trace_id":   "trc_... | null",               // groups a pipeline run
  "branch_key": "main",                         // fork branch name

  // Agent attribution
  "created_by": {
    "agent_id":   "string",           // unique agent identifier
    "agent_name": "string",           // human-readable name
    "role":       "researcher | writer | reviewer | ...",
    "provider":   "anthropic | openai | google | mistral | local",
    "model":      "string"            // specific model version
  },

  // Event
  "event": {
    "type":        "commit | fork | checkpoint | audit | spawn | ...",
    "to_agent_id": "string | null",   // recipient agent
    "timestamp":   "ISO 8601"
  },

  // Payload — open structure, use what is relevant
  "payload": {
    "input":     "string | object | null",  // what this agent received
    "output":    "string | object | null",  // what this agent produced
    "memory":    "object | null",           // persistent state, config
    "variables": "object | null"            // named values between agents
  },

  // Integrity — computed by implementation, not set manually
  "integrity": {
    "payload_hash":        "sha256:hex",        // sha256(normalize(payload))
    "parent_hash":         "sha256:hex | null", // parent's integrity_hash
    "integrity_hash":      "sha256:hex",        // sha256(payload_hash+parent_hash)
    "verification_status": "valid | broken | unverified"
  },

  // Lineage — populated on fork operations
  "lineage": {
    "fork_of":      "ctx_... | null",
    "fork_point":   "ctx_... | null",
    "lineage_root": "ctx_... | null"
  },

  "created_at": "ISO 8601"
}

Field reference

FieldTypeDescription
idstringRequired. Globally unique. Format: ctx_{unix_ms}_{6 hex bytes}
parent_idstring | nullID of previous context in the chain. Null for root commits. Links commits into a lineage graph.
trace_idstring | nullGroups multiple commits into a single pipeline run. Optional but recommended.
branch_keystringRequired. Branch name. Default main. Used to distinguish fork branches.
created_by.agent_idstringRequired. Unique identifier of the committing agent.
created_by.agent_namestringRequired. Human-readable agent name.
created_by.rolestringSemantic role: researcher, writer, reviewer, critic, planner, executor, validator.
created_by.providerstringLLM provider: anthropic, openai, google, mistral, local, custom.
created_by.modelstringSpecific model name or version string.
event.typestringRequired. What happened. See event types.
event.to_agent_idstring | nullRecipient agent. Null for checkpoint or audit events.
event.timestampISO 8601Required. When the event occurred.
payload.inputstring | objectWhat this agent received. Use structured JSON where possible.
payload.outputstring | objectWhat this agent produced. Structured JSON preserves schema across the chain.
payload.memoryobjectPersistent state, parameters, config, or tool results.
payload.variablesobjectNamed values passed between agents.
integrity.*computedDo not set manually. Computed by compliant implementations at commit time.

Integrity model

Each passport stores two hashes, computed deterministically. Tampering with any commit changes its hash, which changes every downstream hash. The chain is tamper-evident from any point. Verification requires only the chain of passports — no access to the originating system.

payload_hash   = sha256(JSON.stringify(payload, Object.keys(payload).sort()))
parent_hash    = integrity_hash of parent commit  (or "root" for root commits)
integrity_hash = sha256(payload_hash + parent_hash)

Event types

Developer
commitforkcheckpointrevertbranchmergespawnretrytimeouterror
Compliance
overrideconsentescalateredactaudit
§ 05 — Implementations

Compatible implementations.

Context Passport is an open standard. Any system can implement it. The following are known implementations:

§ 04 — Adoption

How to adopt.

Context Passport is a schema, not a service. You can implement it in any system. The reference implementation (DarkMatter) handles the hash chain computation and storage — or you can compute it yourself.

  1. 01

    Produce passports in your agents

    After each agent step, emit a Context Passport with the payload.input and payload.output fields populated. Pass parent_id from the previous step to chain them.

  2. 02

    Use the reference implementation or implement your own

    The fastest path: use an existing implementation (see the implementations section below). Or implement the hash chain yourself — the algorithm is fully specified above and takes about 20 lines in any language.

  3. 03

    Verify and replay

    Any party with the chain of passports can verify integrity independently. Recompute the hashes yourself using the algorithm in section 3.4 — no external system required.

  4. 04

    Register your implementation

    Building a Context Passport implementation? Open a pull request on the specification repository to list it under implementations. The goal is an ecosystem of compatible tools, not a single vendor.