Quickstart
This guide walks you through installing the CKP SDK, validating a manifest against the spec, and running conformance tests against an agent.
Install the SDK
Section titled “Install the SDK”npm install @clawkernel/sdkCurrent npm release: @clawkernel/[email protected].
The SDK has zero runtime dependencies. It provides the full protocol stack: JSON-RPC 2.0 routing, lifecycle state machine, heartbeat, and the L2 tool execution pipeline (quota, policy, sandbox, approval, execute with timeout).
Build a conformant agent in under 10 lines
Section titled “Build a conformant agent in under 10 lines”import { createAgent } from "@clawkernel/sdk";
const agent = createAgent({ name: "my-agent", version: "1.0.0", // Add tools, memory, swarm, telemetry for L2/L3});
agent.listen(); // stdio JSON-RPC — ready for ckp-testYou write the handlers. The SDK handles the wire.
Validate a manifest
Section titled “Validate a manifest”Use the conformance harness to validate any claw.yaml against the protocol schema:
# Clone the conformance harnessgit clone https://github.com/angelgalvisc/ckp-test.gitcd ckp-test && npm install && npm run build
# Validate any claw.yamlnode dist/cli.js validate path/to/claw.yamlTest an agent for conformance
Section titled “Test an agent for conformance”Run the test vectors against a running agent to verify its conformance level:
# Run L1 vectors against a stdio agentnode dist/cli.js run \ --target "node path/to/your/agent.js" \ --manifest path/to/claw.yaml \ --level 1
# Expected output: 13/13 PASS → L1 CONFORMANTBump --level to 2 or 3 to test higher conformance levels (10 L2 vectors, 8 L3 vectors).
Build the SDK from source
Section titled “Build the SDK from source”If you want to build the SDK locally or run the example agents:
cd sdk && npm install
# Build library (dist/index.js)npm run build
# Build library + examples (for testing)npm run build:dev
# Run the L1 example agent: 13/13 PASSnode dist/examples/l1-agent.js
# Run the L3 example agent: 31 PASS + 0 SKIP -> L3 CONFORMANTnode dist/examples/l3-agent.jsThe sdk/examples/ directory contains complete L1, L2, and L3 example agents with their manifests, plus an optional world-model.claw.yaml example for CKP 0.3.0 planning manifests.
What’s next
Section titled “What’s next”- Why CKP? — Understand the problems CKP solves
- Architecture — How the 11 primitives fit together
- Primitives — Deep dive into each primitive
- Conformance Levels — L1, L2, L3 requirements and test vectors