continuity-kernel

A continuity system for OpenClaw agents that injects limited context into model input and stores ongoing identity and task state. It also defines fail-open behavior, reproducible proof receipts, and evaluation commands.

In plain words
What is it for?
Use it to persist a Soul Card and Mission Ticket, inject bounded continuity context, run the test suite, generate runtime proof, or perform shadow-mode evaluations.
Why use it?
It helps agents retain relevant context across runs while ensuring continuity failures do not stop the main workflow and can be checked with repeatable tests.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/cacheforge-ai/cacheforge-skills/continuity-kernel
Any agent
npx skills add cacheforge-ai/cacheforge-skills --skill continuity-kernel
Clone the repo
git clone --depth 1 https://github.com/cacheforge-ai/cacheforge-skills

Made for: Claude Code, Codex.

Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 917 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00028 $0.00917
Opus 5 $0.00014 $0.00458
Sonnet 5 $0.00006 $0.00183
Haiku 4.5 $0.00003 $0.00092

Measured 2d ago against content hash 2a58a08b04e0, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

continuity-kernel scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

The scan reads SKILL.md. This mod also ships 15 executable files (benchmark.py, contracts.py, diagnostics.py, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/continuity-kernel/SKILL.md · 69 lines

How it starts

The opening of the file, as written. The whole thing — 69 lines — stays where its author put it; the contents beside it link to each section on GitHub.

When to use this skill

Use this skill when the user wants to:

  • Inject bounded continuity context into llm_input without manual configuration
  • Persist Soul Card + Mission Ticket state with deterministic runtime contracts (durable default SQLite path, zero-config)
  • Keep agent behavior fail-open if continuity logic or storage has an error
  • Generate reproducible runtime proof receipts for audits and reviews
  • Run shadow-mode evals and append chunk-level quality snapshots

Commands

# Run full test suite
python3 -m unittest discover -s tests/continuity-kernel -p 'test_*.py'

# Generate deterministic runtime contract proof artifact
python3 skills/continuity-kernel/generate_runtime_contract_proof.py

# SC-02 core-shadow gate (trace optional, synthetic allowed for this suite)
python3 skills/continuity-kernel/run_shadow_eval.py --layer 'Soul Card' --chunk 'SC-02' --suite core-shadow --runs 100 --append artifacts/continuity-kernel/p0-evals.json

# SC-02 perturb robustness gate (trace-backed, deterministic selector + size_only)
python3 skills/continuity-kernel/run_shadow_eval.py --layer 'Soul Card' --chunk 'SC-02' --suite memoryarena-mini-perturb --perturb-profile deletion --selector-mode deterministic --compaction-policy size_only --runs 100 --trace-jsonl tests/continuity-kernel/fixtures/shadow_eval_trace_memoryarena_mini_perturb.jsonl --append artifacts/continuity-kernel/p0-evals.json

# SC-02 perturb robustness gate (trace-backed, dual-route + attention-preserving)
python3 skills/continuity-kernel/run_shadow_eval.py --layer 'Soul Card' --chunk 'SC-02' --suite memoryarena-mini-perturb --perturb-profile deletion --selector-mode dual_route_experimental --compaction-policy attention_preserving_experimental --runs 100 --trace-jsonl tests/continuity-kernel/fixtures/shadow_eval_trace_memoryarena_mini_perturb.jsonl --append artifacts/continuity-kernel/p0-evals.json

Options

run_shadow_eval.py options:

  • --layer TEXT — Active P0 layer name
  • --chunk TEXT — Active chunk id/name
  • --suite core-shadow|memoryarena-mini|memoryarena-mini-perturb — Task suite for eval scoring
  • --perturb-profile none|deletion|noise_injection|reorder — Deterministic perturb profile for memoryarena-mini-perturb
  • --selector-mode deterministic|dual_route_experimental — Selector mode tag for A/B eval receipts
  • --compaction-policy size_only|attention_preserving_experimental — Compaction policy label for dropped-field A/B eval comparison
  • --runs N — Number of evaluated shadow runs (default: 100)
  • --trace-jsonl PATH — JSONL file containing observed shadow outcomes (repeatable)
  • --trace-dir PATH — Directory scanned for *.jsonl observed shadow outcomes (repeatable)
  • --append PATH — JSON file path to append snapshot results
  • --allow-synthetic — Permit synthetic fallback for non-core suites when traces are unavailable (forced pass=false)
  • --artifacts-root PATH — Directory for summary receipts (default: ~/.cache/continuity-kernel/p0-evals)

Read the full file on GitHub · 69 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 69 lines · 28 tokens per session scan A 2a58a08b04e0

Subscribe to this mod's changes

continuity-kernel is a skill published in the GitHub repository cacheforge-ai/cacheforge-skills (10 stars, last pushed 6mo ago), licensed MIT. It adds 28 tokens to every session and 917 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

pm-sim

This skill has been renamed. Install the new version.

agent-next/polymarket-paper-trader · 29 tokens

polymarket-paper-trader

Everyone's trading Polymarket with AI agents. Practice first — $10k paper money, real order books, zero risk. No wallet, no API keys, no real money. Then compete on the leaderboard.

agent-next/polymarket-paper-trader · 50 tokens

cortex-mem-mcp

Persistent memory enhancement for AI agents. Store conversations, search memories with semantic retrieval, and recall context across sessions. Use this skill when you need to remember user preferences, past conversations, project context, or any information that should persist beyond the current session. Provides…

sopaco/cortex-mem · 72 tokens

alphafold-database

Access AlphaFold's 200M+ AI-predicted protein structures. Retrieve structures by UniProt ID, download PDB/mmCIF files, analyze confidence metrics (pLDDT, PAE), for drug discovery and structural biology.

FreedomIntelligence/OpenClaw-Medical-Skills · 55 tokens

adhd-daily-planner

Time-blind friendly planning, executive function support, and daily structure for ADHD brains. Specializes in realistic time estimation, dopamine-aware task design, and building systems that actually work for neurodivergent minds.

FreedomIntelligence/OpenClaw-Medical-Skills · 49 tokens

aeon

This skill should be used for time series machine learning tasks including classification, regression, clustering, forecasting, anomaly detection, segmentation, and similarity search. Use when working with temporal data, sequential patterns, or time-indexed observations requiring specialized algorithms beyond standard…

FreedomIntelligence/OpenClaw-Medical-Skills · 74 tokens