# CAIN42 — ARGUS Protocol (Prompt 14) and CAAP (proposed open protocol)

## Part A — ARGUS enforcement protocol (restriction-only)

ARGUS runs as ordered restriction-only stages on the hosted MCP decision path. Each stage may only ADD a refusal;
when it has no opinion it abstains, so ordinary traffic is unchanged. The first DENY stops the call before the tool
body runs. Every decision is written to the durable decision ledger.

| Stage | Trigger argument | Refuses when |
|---|---|---|
| `assurance_lease` | `_cain_assurance_lease` + `_cain_lease_pub` | invalid signature/expired/revoked/restricted lease; or lease required and absent |
| `behavioral_envelope` | `_cain_behavioral_envelope` + `_cain_execution_path` | envelope malformed, path absent, or envelope violated by the path |
| `continuous_reauthorization` | `_cain_reauthorization` | impact action ∈ {REAUTHORIZE, RESTRICT, HALT} |
| `assurance_certificate` | `_cain_assurance_certificate` (+ `_cain_assurance_pub`) | clean-room certificate verification fails |
| `memory_authority` | `_cain_memory_authority` | retrieved memory unusable / exceeds current authority / revoked |
| `independent_verification` | `_cain_verifier_votes` (+ quorum) | not an independently quorate allow |
| `evolution_authority` | `_cain_evolution_delta` | capability change without explicit regrant/verification |
| `world_model_assurance` | `_cain_world_state_class` (+ consequence) | authority ∈ {DENY, RESTRICTED, REVALIDATE} |
| `physical_assurance` | `_cain_physical_request` | simulated physical effect not verified |

Fail-closed: a stage that raises is treated as DENY; a policy that cannot be read denies governed actions.

## Part B — CAAP: proposed open protocol

CAAP (Continuous Autonomous Assurance Protocol) is a **proposed** vendor-neutral object set for interoperable
continuous assurance. It is **not** a standard and has **no** adopters; it is positioned as an open proposal.

Documents (illustrative JSON; reference implementation in `cain/argus/`):

1. `agent-identity` — subject agent, lineage, model/runtime identity, keys.
2. `authority` — scope, delegation chain, budget, ceiling.
3. `behavioral-envelope` — the machine-verifiable boundaries (see `CAIN42_ARGUS_ASSURANCE_SPEC.md` §2).
4. `assurance-lease` — validity interval, renewal/revocation conditions, reauthorization triggers.
5. `execution-path` — hash-chained steps + cumulative consumption.
6. `evidence` — root/source/status/freshness/corroboration.
7. `drift` — per-dimension divergence + authority action.
8. `capability-delta` — target, direction, authority impact.
9. `reauthorization` — impact set + action.
10. `revocation` — state + reason + monotonicity.
11. `verification` — verifier votes grouped by independence root.
12. `assurance-certificate` — the signed proof of current assurance state.

### Interoperability examples

- **Raw Python:** call `cain.argus` engines directly; present `_cain_*` fields to the CAIN/MCPGate boundary.
- **MCP:** send the objects as tool-argument `_cain_*` metadata; the hosted pipeline enforces them.
- **LangGraph / CrewAI / AutoGen:** wrap tool nodes with the governed-tool adapter and attach the objects.
- **OpenAI-compatible agents:** emit the objects alongside function calls; verify the certificate before dispatch.
- **Coding agents:** require a valid assurance lease + certificate before write/deploy tools execute.

### Status (public truth)

`DESIGN` for the CAAP schema set; `IMPLEMENTED` + `TESTED` + `INTEGRATED` + `LIVE` for the ARGUS engines and the
9 hosted stages. No standards adoption is claimed.
