context-end

context-end is a skill for Claude Code, Codex from conorbronsdon/agent-context-os. It costs 46 tokens per session (1,100 once invoked), scanned A, original, MIT.

A session-closing procedure for a workspace system that reviews a proposed handoff summary, records approved results, updates state and decisions, and checks repository safety.

In plain words
What is it for?
Use it to close or hand off a session, validate the required repository markers, run the workspace lifecycle command, and leave reviewable state and decision records.
Why use it?
It helps preserve what happened and what should happen next when a coding session ends.

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/conorbronsdon/agent-context-os/context-end
Any agent
npx skills add conorbronsdon/agent-context-os --skill context-end
Clone the repo
git clone --depth 1 https://github.com/conorbronsdon/agent-context-os

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-end

README.md
[![agentmods](https://agentmods.dev/badge/skills/conorbronsdon/agent-context-os/context-end.svg)](https://agentmods.dev/skills/conorbronsdon/agent-context-os/context-end)
Your own site
<a href="https://agentmods.dev/skills/conorbronsdon/agent-context-os/context-end"><img src="https://agentmods.dev/badge/skills/conorbronsdon/agent-context-os/context-end.svg" alt="Measured on agentmods" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,100 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.00046 $0.01100
Opus 5 $0.00023 $0.00550
Sonnet 5 $0.00009 $0.00220
Haiku 4.5 $0.00005 $0.00110

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

Security

Grade A, and why

context-end 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.

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.

.agents/skills/context-end/SKILL.md · 108 lines

How it starts

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

End a workspace session

Execution roots (required)

Use the exact roots supplied by the host attachment: KernelRoot is the trusted Context OS product containing scripts/contextos.sh; ContextRoot owns tracked identity and lifecycle state; and WorkingRoot is the ordinary application. For an external attachment, require all three exact absolute paths and run:

bash <KernelRoot>/scripts/contextos.sh --context-root <ContextRoot> --working-root <WorkingRoot> <command>

Do not search upward or infer a root from cwd or the skill installation. The kernel must validate the ignored local binding before strict lifecycle work. A missing, moved, stale, linked, nested, or mismatched binding stops the workflow; use the explicit project rebind proposal after a legitimate move. ContextRoot owns all lifecycle writes. WorkingRoot is read-only evidence. The colocated bash scripts/contextos.sh <command> compatibility form remains valid.

Throughout this procedure, resolve routing, state, session, proposal, receipt, and local-artifact paths beneath ContextRoot. In split mode, spell local paths as absolute <ContextRoot>/... paths and invoke every lifecycle command through the absolute KernelRoot wrapper with both exact role options. In colocated mode, run the relative compatibility commands from the colocated root.

Leave durable, reviewable state for the next session.

Procedure

1. Draft before writing

Determine today's local date and time. Extract completed work, durable decisions and rationale, meaningful rejected alternatives, priority or thread changes, blockers, open work, and next actions. Present the draft and obtain confirmation before creating a proposal.

2. Build the deterministic proposal

Create a reviewed JSON payload under <ContextRoot>/.context-os/inputs/ with:

  • what_happened: approved factual strings;
  • decisions: durable objects containing decision, rationale, and optional rejected_alternatives;
  • next_time: approved open-work strings; and
  • optional complete desired Markdown for current_markdown, blockers_markdown, or weekly_priorities_markdown, only when that state materially changed.

Read the full file on GitHub · 108 lines

Files

What ships with it

1 file 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. 2d ago Changed · +29 lines e36eec5b29cc
  2. 4d ago First seen · 79 lines · 46 tokens per session scan A 3adeccfb8afa

Subscribe to this mod's changes

context-end is a skill published in the GitHub repository conorbronsdon/agent-context-os (21 stars, last pushed yesterday), licensed MIT. It adds 46 tokens to every session and 1,100 once invoked, about $0.0002 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

trpc

Skill "trpc" from neverinfamous/memory-journal-mcp, covering trpc guidelines, 1. routers and procedures, 2. context and middleware and 3. client integration.

neverinfamous/memory-journal-mcp · 50 tokens

journal-optimizer

Guided database pruning and optimization workflows for memory-journal-mcp. Uses importance scores, relationship density, and entry metadata to identify low-value entries for safe soft-deletion. Includes dry-run previews, backup gates, and revert guidance. Use when the user says "clean up the database", "optimize…

neverinfamous/memory-journal-mcp · 101 tokens

kn-init

Use at the start of a new session to read project docs, understand context, and see current state.

knowns-dev/knowns · 23 tokens

kn-extract

Use when extracting reusable patterns, decisions, failures, or knowledge into documentation.

knowns-dev/knowns · 18 tokens

alive:save

The human wants to checkpoint. Or: the stash has grown heavy — 5+ items, 30+ minutes, a natural pause in the work. The squirrel doesn't decide when to save. It surfaces the need and lets the human pull the trigger. Runs the full save protocol: confirms stash, writes log, updates state, generates projections…

alivecontext/alive · 78 tokens

alive:session-history

Revive sessions (quick or heavy), browse, and search — 'what happened recently?', 'find the session where we discussed X', 'revive yesterday's session'. For single-session recall and multi-session browsing. If the human needs to merge multiple sessions into one working context or detect conflicts between parallel…

alivecontext/alive · 76 tokens