This document belongs to the previous reader. Open that edition’s reader
Contract map
Four contracts describe a system from different angles. A workflow orders the work, a policy decides whether it may proceed, an operation carries out a step, and a type gives meaning to the data they share.
- OBC · Workflows
- Describes the steps in a process and the transitions between them. It can reference the policies and operations the flow needs.
- OPC · Policies
- Declares the conditions the host evaluates when allowing or denying an action.
- OFR · Operations
- Describes callable functions, their inputs and outputs, and their declared effects. For sharing the code of an implementation, see OSR.
- OTC · Types
- Defines the structure and meaning of data that systems can share.
How the contracts fit together when saving a decision
In OKHAM Memory, the write request has an OTC type. The OBC workflow classifies the request, prepares the record and asks for authorization before saving it. The OPC policy checks context.memoryWriteAllowed to find out whether the host permits writes. The functions that classify, prepare, authorize and persist the record are declared in the OFR.
An application can adopt these contracts with its existing code. A state machine can also coordinate the workflow when the host can supply the operations and enforce the policies.
Specifications for the four primary contracts
Release candidate 0.2.0-rc.2. The specifications and schemas are edition 0.2.0. These four examples come from the OKHAM Memory save workflow.
- OBCSpecification · JSON schema · Example
- OPCSpecification · JSON schema · Example
- OFRSpecification · JSON schema · Example
- OTCSpecification · JSON schema · Example
Additional contracts
- OLR · Checking rules
- Shares the rules a project applies to its contracts or code.
- Specification · JSON schema · Example
- OVR · Verification results
- Records what was checked and the results of applying the rules.
- Specification · JSON schema · Example
- OUCC · Interface components
- Describes a reusable component and the interface an application can use.
- Specification · JSON schema · Example
- OSR · Reusable implementations
- Identifies snippets by language and execution requirements. A function described in OFR can have different implementations for different environments.
- Specification · JSON schema · Example
Applications, the capabilities they offer and the events they produce can all be described with OTC types. See the definitions of application, capability and event.
Edition archive
The February 2026 map assigned responsibilities differently. It is preserved for readers interpreting documents and projects from that period. The historical inventory includes OAP for applications, OCC for capabilities and OEC for events.
February 2026 map (original edition) · Previous specification releases