CMP-0.1 — Source inventory and integration verification¶
Status: CMP-0.1 inventory assessment complete; ComputeMarket implementation and end-to-end integration NOT complete. Inspected repository abvhiael/420-integrated-v0.1, immutable main baseline 277395931f5419af0728f3ea801800401a8bb336 (same main SHA checked at audit). This is a source-and-test evidence audit, not deployment certification or proof that external repositories contain no implementation. The frozen ComputeMarket V1 architecture, not former recovery branches or aspirational contract catalogs, controls CMP.
Method and evidence semantics¶
Checked the frozen architecture, Genesis dApp catalog, frozen system-address assignments, post-PR-365 reconciliation, target source directories and named source contracts, AI/Vault/Resource/Trust/Arbitration code, AI and Vault Foundry tests, node420 source/CLI, service/SDK package directory, and the CMP PR qualification runs. SOURCE = executable checked-in source inspected; TEST = specific test source exists, not a new CMP integration test; CATALOG = filename in a manifest without proven deployable source; NOT LOCATED = queried named path absent on this baseline, not a universal negative about all branches/other repositories; LIVE UNVERIFIED = no execution-chain receipt, runtime codehash, deployed registry publication or live job/settlement evidence established here. Source URLs are pinned to the audited SHA.
1. Normative authority, addresses and discovery¶
- Frozen V1 architecture: 30 CMP-INV invariants, general-purpose compute identity/lifecycle, bounded economic terms, off-chain work, immutable match, receipts/verification and Vault settlement. AI is a client, not market owner.
- Genesis application contract map lists proposed
ComputeIds420,ComputeAuthorization420, policy/provider/node/resource/offer/request/match/job/receipt/verification/settlement/dispute/router files and AIAIComputeAdapter420,AIRequestRegistry420,AIResultRegistry420. CATALOG only: the inspectedcontracts/src/compute/directory,contracts/src/compute/ComputeIds420.sol,contracts/src/compute/ComputeJobRegistry420.sol,contracts/src/ai/AIComputeAdapter420.sol,contracts/src/ai/AIRequestRegistry420.soleach returned 404 at the pinned baseline. Other compute-related code DOES exist in AI and Resource directories; these cannot be treated as implementations of the proposed general-purpose CMP modules. - Frozen system-address map reserves
0x0420–0x04ff, explicitly fixes AI provider/model/job/escrow/reputation0x042f–0x0433,ProtocolRegistry0x0434, andConsensusSystemCall4200x043c. The main address reconciliation retires conflicting historical assignments. No CMP contract gains a new fixed predeploy or a collision-prone candidate address by appearing in a catalog. - ProtocolRegistry.sol is SOURCE: authorized service publication tracks version, implementation, runtime codehash, manifest/interface/dependency metadata and history. Its registration supplies discovery, not custody, execution or economic rights. LIVE UNVERIFIED for CMP: no deployed CMP implementation/codehash and authorized registry-publication evidence supplied by this audit.
2. Existing AI contracts — reusable boundaries, not an alternative ComputeMarket¶
| Source | Verified behavior in source | CMP integration disposition |
|---|---|---|
| AIProviderRegistry.sol | SOURCE: operator-self registration, operator/settlement accounts, stakeRef, computeProviderRef, REGISTERED/ACTIVE/SUSPENDED/RETIRED states. isOperational requires ACTIVE and nonzero stake reference. |
Preserve fixed AI provider identity; validate mapping and real stake/security policy against independently registered CMP provider; a nonzero hash by itself is not confirmed collateral. No direct AI authority over CMP matching. |
| AIJobManager.sol | SOURCE: AI request/max spend/deadline, bounded status transitions, hardcoded escrow 0x0432, one-time governance binding of computeAdapter, compute request/job/provider references; only bound adapter may match/accept/start/commit/verify/fail, only escrow can confirm funding/settlement/refund. Legacy create uses max uint spend: must never be reused as the safe CMP path. |
A real AI adapter must narrow requester constraints and verify canonical CMP state before advancing AI facade. Binding a test EOA is not a working general-purpose adapter. CMP maintains independent canonical match/job/receipt/verification/settlement. |
| AIJobEscrow.sol | SOURCE: direct custody disabled; one-time Vault and settlement adapter bindings; confirmVaultFunding, mark claimable/refundable, release to prebound beneficiary or refund recorded payer; calls fixed AI manager 0x0431. These are accounting confirmations, not transfers from a Vault. |
Do not mistake the facade for a deployed, funded Vault adapter. CMP must establish an actual atomically-reconciled funding/reservation/claim/refund path; reject arbitrary beneficiary changes and double settlement. |
| AIReputationRegistry.sol | SOURCE: one-time Trust adapter binding; evidence IDs cannot replay; arbitrary admin reputation overwrite disabled. | Send evidence through authorized Trust integration; reputation never creates settlement or slash authority. |
| AIMature420.t.sol, AIHardening420.t.sol | TEST: provider lifecycle; AI state-machine/access, max spend, escrow beneficiary and evidence replay. Compute/Vault/Trust integrations use test addresses, pranks, mock callbacks and vm.etch. |
Evidence for isolated AI contract behavior, not proof of real CMP adapter, deployed AI predeploy, funded Vault payout or signed worker receipts. |
3. Vault funding, accounting and authorization — source-level call-path verification¶
- VaultFactory420.sol deploys an
AssetVault420, but factory deployment is not registry registration; VaultRegistry420.sol requires caller = registered creator, correct vault ID/registry, valid active policies, and manages ACTIVE/FROZEN/WINDING_DOWN/CLOSED. Closure rejects nonzero assets or obligations. - AssetVault420.sol is the write/custody interface, not VaultRouter420.sol, which exposes read/authorization views.
depositNative/nativereceivedepositaddress(0);createObligation(operationId,obligationId,asset,beneficiary,amount,type,sourceRef)checks the caller's vault-scoped capability and reserves free balance;releaseObligationturns it claimable;claimtransfers only to recorded beneficiary, including in FROZEN state;cancelObligationfrees a still-reserved obligation. Mutating calls consume one-time operation IDs and use a shared reentrancy guard. Delegated withdrawal to a third party requires recipient/asset/action route-scoped authority. - VaultAccounting420.sol authorizes bookkeeping only for the registered vault address, records
recordedBalance,reserved,claimable,released, and prevents withdrawal of encumbered funds. Obligation states are 1=reserved, 2=claimable, 3=claimed, 4=cancelled, and obligation ID is globally unique in the accounting contract. - VaultAuthorization420.sol consults the shared CapabilityRegistry420.sol for principal/action/vault scope/amount and optional recipient-bound routes. There is no ambient privilege for a CMP adapter; registration, grants, actor identity, maximum per-call/period scope and revocation must be proven before operational wiring.
- Vault420.t.sol is TEST for reserved-balance protection, cancellations, beneficiary-only claims, frozen claims, closure/replay and permissions, but creates a mock capability registry and self-contained fixture, not a funded CMP job.
- Integration decision: use a registered Vault and narrowly authorized per-job obligation(s). A
cancelObligationonly frees balance inside the Vault; it does not itself send an unused/refundable balance back to a particular payer. In a shared Vault it must never make refunds withdrawable by unrelated principals. CMP needs an explicit payer-bound refundable obligation, authorized withdrawal route, or equivalent policy-proven mechanism; encode unique operation/obligation IDs, atomic order of funding confirmation versus actual custody, split/partial earning rules, failure/retry recovery, and reconciliationfunded = earned + refundable + still-reservedbefore exposing a paid job. A one-obligation release for the entire deposit is not proof that a partial provider payout plus payer refund is supported.
4. Adjacent services and non-overlap¶
| Surface | Inspected evidence | Reuse decision / limitation |
|---|---|---|
| ResourceProviderRegistry420.sol, ResourceSessionRegistry420.sol, ResourceReceiptRegistry420.sol | SOURCE: Resource Protocol has provider/offer/session/receipt constructs for its own service IDs, capped units/spend and monotonic usage. Session settles through Resource authorization; receipt binds node/session/usage, not CMP manifest/match/verification. | Reuse patterns and explicit interoperability only. Do not relabel Resource sessions as canonical CMP jobs, use its receipts as proof of computation, or grant it CMP settlement authority. |
| TrustSignalRegistry420.sol, AIReputationRegistry.sol | SOURCE: issuer/policy-scoped evidence signals and replay-resistant AI compatibility counters. | Derive CMP performance evidence after independently verified events; never interpret reputation as payment authorization or subjective slashing. |
| ArbitrationCaseRegistry420.sol | SOURCE: domain-policy case, parties, evidence-window commitments, ruling registry and appeals. | Reuse an explicit CMP arbitration domain/policy, but a case reference or human ruling is not by itself proof of an objective slash or authorization to redirect funds. |
| CapabilityRegistry420.sol, ProtocolRegistry.sol | SOURCE: scoped grants/component authority vs versioned discovery; separate purposes. | Use capability authority for actions, protocol registration for discovery. Neither may become a privileged matcher or unrestricted custodian. |
| node420 CLI | SOURCE: pinned Geth execution wrapper and optional --storage provider, cache and gateway paths. Inspected CLI enumerates no --compute provider/scheduler flag. |
No inference inside consensus/EVM execution; a new optional compute worker service needs independent configuration, isolation, tests and failure containment. |
| packages directory | Directory inventory contains shared 420-sdk, CLI, documentation and gaming packages but no independently named 420-compute-sdk package. |
A dedicated @420/compute-sdk API and package publication are NOT VERIFIED. Inspect any compute helpers inside shared SDK when designing the boundary; do not claim package is shipped. |
5. Integration disposition / deliverable matrix¶
| Capability | Inventory result at audited SHA | Prerequisite for CMP implementation |
|---|---|---|
| Frozen CMP semantics and address policy | SPEC VERIFIED; 30 invariants and no CMP fixed Genesis predeploy | Preserve without adding fixed addresses; write invariant-to-test mapping. |
| General CMP IDs/policies/provider/node/resource/offer/request/match/job | CATALOG / NOT LOCATED in named compute source paths | Build separately with deterministic IDs, bounded authority and canonical acceptance. |
| CMP signed manifest, work-unit identity, receipt, verifier and settlement | DESIGN ONLY / LIVE UNVERIFIED; adjacent Resource receipt is not equivalent | Specify typed signature/hash vectors, verification-policy decisions, proof and replay/settlement tests. |
| AI provider/job/escrow/reputation facades | SOURCE + isolated TEST; no real CMP adapter confirmed | Implement and test a strict AI-to-CMP adapter; verify AI identity, caps, recipient and status reconciliation. |
| Vault obligations/native funding | SOURCE + isolated TEST; actual reserve/release/claim primitives confirmed | Specify payer custody/refund and split settlement, narrowly scoped capabilities, real end-to-end test. |
| Trust, arbitration and shared capability/discovery | SOURCE for adjacent contracts; no CMP-specific adapter deployed | Define domain/policy, evidence proof, limits, exact auth and registered interfaces. |
fourtwentyd / node420 integration |
Execution and repository Go CI exist; inspected node420 CLI offers storage, not compute | Optional off-chain worker routing only; never require worker for chain liveness. |
Compute worker daemon, scheduler/matcher, @420/compute-sdk, Compute UI, CMP deployment and contract publication |
NOT VERIFIED in this repository inspection. Named CMP directory/adapter missing; documentation or catalog does not confer runtime status. External repositories and live chain not certified by this audit. | Supply concrete source/build/test/config/deployment IDs and a signed/verified worker-to-Vault settlement smoke before claiming operational. |
6. Test evidence and release gating¶
Prior to this audit, CMP PR #367 at head 8d140dfb7b08be0b23f1debefae68c12693f1e7f passed 420Docs #2597 and 420 Integrated Qualification #5209 including Go tests, both Go builds, fault matrix, 120-slot soak, pinned Geth and live-engine smoke. Those jobs do not establish a Foundry run for CMP or real AI/CMP/Vault integration. AI Foundry unit/fuzz fixtures and Vault unit fixtures validate their own components with mocks; cross-contract funded/verified/settled CMP tests are MISSING. No live chain release evidence has been supplied or verified. Re-run triggered checks on the final CMP PR head and run the separate required Foundry/integration tests when implementation is added.
7. CMP-0.1 closeout and next sequence¶
Inventory and integration-interface assessment is complete for this pinned repository snapshot. Real integration is explicitly classified as unimplemented/unverified, not silently declared done. No production contract, frozen-address map, funds or deployed registry was changed by this audit. Subsequent CMP-0.2/0.3/0.4 must define typed canonical schema, deterministic work-unit hashes and signed manifests with executable negative tests. Before paid execution, deliver CMP contracts, strict AI adapter, Vault payer-bound refund/partial entitlement adapter, worker receipts/verifier, deployment/codehash/registry evidence and end-to-end tests. PR #367 remains draft until CMP-0 specification gates and final exact-head qualification are satisfied; document-only audit green is not CMP protocol release qualification.