compact-prep

compact-prep is a skill for Codex from roarista/awesome-harness. It costs 73 tokens per session (870 once invoked), scanned A, original, MIT.

A closing checklist for each substantial coding session that saves the work to the repository and records where to resume.

In plain words
What is it for?
Committing and pushing changes, recording durable lessons, updating resume notes, and producing a handoff block before the session ends or its context is shortened.
Why use it?
It prevents important decisions, progress, or next steps from existing only in the chat and being lost.

Skill for Codex

Written for Codex: reads ~/.codex or $CODEX_HOME. Also seen: mentions CLAUDE.md; mentions AGENTS.md; mentions Codex.

Good fit Committing and pushing changes, recording durable lessons, updating resume notes, and producing a handoff block before the session ends or its context is shortened.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/roarista/awesome-harness/compact-prep
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/roarista/awesome-harness/compact-prep
Any agent
npx skills add roarista/awesome-harness --skill compact-prep
Clone the repo
git clone --depth 1 https://github.com/roarista/awesome-harness

Made for: 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 compact-prep

README.md
[![agentmods](https://agentmods.dev/badge/skills/roarista/awesome-harness/compact-prep.svg)](https://agentmods.dev/skills/roarista/awesome-harness/compact-prep)
Your own site
<a href="https://agentmods.dev/skills/roarista/awesome-harness/compact-prep"><img src="https://agentmods.dev/badge/skills/roarista/awesome-harness/compact-prep.svg" alt="Measured on agentmods" height="20"></a>
Per session 73 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 870 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.1 $0.00073 $0.00870
Opus 5 $0.00036 $0.00435
Sonnet 5 $0.00015 $0.00174
Haiku 4.5 $0.00007 $0.00087

Measured 6d ago against content hash 89b203addc9b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

compact-prep 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 6d 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.

codex/skills/compact-prep/SKILL.md · 80 lines

How it starts

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

compact-prep (Codex edition) — the every-turn close

Step 7 of THE PROCEDURE (~/.codex/AGENTS.md). Anything that exists only in the conversation is at risk; this pushes it into files, git, and mulch.

MINIMUM PATH (every turn — this is the whole skill)

1. commit the work
2. `ml record` the durable lesson   (syntax below; <=2 sentences)
3. REPLACE `## Active Resume Point` in .planning/STATE.md  (replace, never prepend)
4. `.now.md` — NOW / LAST_VERIFIED / NEXT, <=5 lines
5. push to origin
6. emit the CONTINUE block

1. Commit

git status --short
git log --oneline -5

Triage what is uncommitted:

  • Real work (code, tests, migrations) — commit it. If on the default branch, branch first.
  • Session metadata (.planning/STATE.md, .now.md, .mulch/) — commit with the work or alongside it.
  • Ambiguous / untracked WIP you did not create — ask Ro, never sweep it in silently.

2. Record the durable lesson

Skip if which ml returns nothing (ml lives at ~/.npm-global/bin/ml).

ml record <domain> --type <pattern|convention|failure|decision|reference> [required fields] --description "..."
ml sync

Type-specific required fields the CLI rejects without:

  • pattern--name
  • failure--resolution
  • decision--title and --rationale
  • convention, reference--description only

Record format: each record ≤2 sentences. Overflow (dates, exact flags, counts, evidence) goes to .mulch/details/<slug>.md, and you read that detail file before acting on the record. Full rules: ~/.codex/MEMORY_STANDARD.md.

Record (HIGH signal): a bug that took >30min to find, with root cause and how to spot it next time; an architectural decision plus its rationale; a failure mode and its resolution; a convention this repo now follows. Do NOT record: anything already in AGENTS.md/CLAUDE.md, transient per-run data, raw payloads, PII, or "today I learned X" with no evidence.

3. STATE resume point

Replace the ## Active Resume Point section in .planning/STATE.md — never prepend a new one, or the file grows into an unreadable log. It answers exactly one question: what does the next session do first?

Read the full file on GitHub · 80 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. 6d ago First seen · 80 lines · 73 tokens per session scan A 89b203addc9b

Subscribe to this mod's changes

compact-prep is a skill published in the GitHub repository roarista/awesome-harness (1 stars, last pushed 11d ago), licensed MIT. It adds 73 tokens to every session and 870 once invoked, about $0.0004 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.