context-checkpoint

context-checkpoint is a skill for Claude Code, Codex from clarity-digital-development/tworkflow. It costs 70 tokens per session (968 once invoked), scanned A, original, MIT.

A session guide for checking how much conversation context is being used and deciding when to start a fresh session. Context is the information the coding agent can still reliably use from the conversation.

In plain words
What is it for?
Use it after context warnings, when the agent starts repeating itself or forgetting constraints, or at workflow boundaries such as a completed commit or review.
Why use it?
It helps prevent mistakes caused by a crowded or degraded session and recommends a reset at a suitable stopping point.

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/clarity-digital-development/tworkflow/context-checkpoint
Any agent
npx skills add clarity-digital-development/tworkflow --skill context-checkpoint
Clone the repo
git clone --depth 1 https://github.com/clarity-digital-development/tworkflow

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for context-checkpoint

README.md
[![agentmods](https://agentmods.dev/badge/skills/clarity-digital-development/tworkflow/context-checkpoint.svg)](https://agentmods.dev/skills/clarity-digital-development/tworkflow/context-checkpoint)
Your own site
<a href="https://agentmods.dev/skills/clarity-digital-development/tworkflow/context-checkpoint"><img src="https://agentmods.dev/badge/skills/clarity-digital-development/tworkflow/context-checkpoint.svg" alt="Measured on agentmods" height="20"></a>
Per session 70 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 968 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.00070 $0.00968
Opus 5 $0.00035 $0.00484
Sonnet 5 $0.00014 $0.00194
Haiku 4.5 $0.00007 $0.00097

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

Security

Grade A, and why

context-checkpoint 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 4d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/context_hook.py, scripts/context_usage.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/context-checkpoint/SKILL.md · 83 lines

How it starts

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

Context Checkpoint

Measured usage for this session (may be unavailable):

!python "${CLAUDE_SKILL_DIR}/scripts/context_usage.py" "${CLAUDE_SESSION_ID}"

You are deciding whether the session should reset, and recommending — you cannot run /compact or /clear yourself; only the user can.

1. Get a real number

  • If the measurement above shows a percentage, use it.
  • Otherwise ask the user to run /context (or read their status line) and tell you the figure. Never guess a percentage, and never act on a guessed one.

2. Under 40%: report and continue

One line — "Context at ~N%, no reset needed" — then back to the task.

3. At or past 40%: recommend a reset at the next clean boundary

A clean boundary is a just-committed step, a just-delivered review or QA report — any moment the working state is written down. First finish reaching the boundary (complete the commit, deliver the artifact); never stop mid-edit. Then recommend exactly one of:

Clear and reseed — preferred when state is written down. If the plan document is committed and current: have the user fill the session-handoff template (bundled docs/templates/SESSION-HANDOFF.md if the repo has it; otherwise: current step, decisions not yet in the plan, next action, known landmines — you can draft it for them), then /clear, then seed the new session with the plan and the handoff. In Claude Code, /clear keeps the old conversation available under /resume, so nothing is lost.

Compact — when state is NOT yet written down. Mid-task with decisions that exist only in conversation: offer to write the handoff note now, and give the user a ready-to-paste command with explicit preservation instructions, e.g.:

/compact preserve: the plan at docs/plans/<file>, current step <N> and its
status, decisions made this session, unresolved findings, the exact next action

Past 60%, or if auto-compact has already fired this session: recommend clear-and-reseed, not compact — the deliberate reset is overdue.

Read the full file on GitHub · 83 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 4d ago First seen · 83 lines · 70 tokens per session scan A a9b94e3f75d5

Subscribe to this mod's changes

context-checkpoint is a skill published in the GitHub repository clarity-digital-development/tworkflow (46 stars, last pushed 2mo ago), licensed MIT. It adds 70 tokens to every session and 968 once invoked, about $0.0003 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-30.

Related

Other skills, from other repositories

moai-foundation-core

Provides MoAI-ADK foundational principles including TRUST 5 quality framework, SPEC-First DDD methodology, delegation patterns, progressive disclosure, agent catalog reference, and token budget management (absorbed from moai-foundation-context). Use when referencing TRUST 5 gates, SPEC workflow, or context window…

modu-ai/moai-adk · 68 tokens

moai-foundation-cc

Canonical Claude Code authoring kit covering Skills, sub-agents, plugins, slash commands, hooks, memory, settings, sandboxing, headless mode, and advanced agent patterns. Use when creating Claude Code extensions or configuring Claude Code features.

modu-ai/moai-adk · 55 tokens

handoff

Creates a concise local handoff document so Codex work can resume in a later session or another local context. Use when ending a session, pausing work, transferring context, or summarizing current progress without duplicating existing PRDs, issues, tests, or plans.

SetraTheXX/Codex-Engineering-Workflow-Pack · 57 tokens

agent-continuity

Use when starting or resuming a non-trivial Codex/Cursor/Claude task, especially long-running design, coding, testing, handoff, or multi-agent work. Performs a lightweight new-session continuity check, finds or creates a task ledger, and prevents stale-file assumptions without forcing per-action checks.

MagicKidd/Rokid-agentic-workflow · 66 tokens

dynamic-agent-context

Install and refresh dynamic learned context in any repo (.agent-context, AGENTS.md, learned-conventions.mdc). Use for coding, architecture code design, tests, refactors, code review, and bug fixes.

MagicKidd/Rokid-agentic-workflow · 47 tokens

moai-design-craft

Intent-First design craft specialist covering design direction, domain vocabulary, design memory, and post-build critique. Use when establishing design intent or auditing code against design principles.

modu-ai/moai-adk · 39 tokens