consolidate

consolidate is a skill for Claude Code from choiyounggi/groundwork. It costs 85 tokens per session (2,504 once invoked), scanned A, original, MIT.

A memory cleanup procedure for an agent's saved notes. It merges duplicates, resolves conflicts using newer information, and updates unclear relative dates, then asks for confirmation before writing.

In plain words
What is it for?
Use it when memory files have grown large or contain repeated and conflicting notes. It prepares a proposed cleaned-up version for review.
Why use it?
It prevents long-term memory from becoming bloated, contradictory, or outdated.

Skill for Claude Code

Written for Claude Code: SessionStart hook event. Also seen: reads .claude/ paths; mentions CLAUDE.md.

Part of the memory-loop plugin — 5 skills shipped together

Good fit Use it when memory files have grown large or contain repeated and conflicting notes. It prepares a proposed cleaned-up version for review.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/choiyounggi/groundwork/consolidate
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.

Any agent
npx skills add choiyounggi/groundwork --skill consolidate
Clone the repo
git clone --depth 1 https://github.com/choiyounggi/groundwork

Made for: Claude Code.

Or install memory-loop, the plugin that ships this one along with the rest of its 5 skills.

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 consolidate

README.md
[![agentmods](https://agentmods.dev/badge/skills/choiyounggi/groundwork/consolidate/github.svg)](https://agentmods.dev/skills/choiyounggi/groundwork/consolidate)
Your own site
<a href="https://agentmods.dev/skills/choiyounggi/groundwork/consolidate"><img src="https://agentmods.dev/badge/skills/choiyounggi/groundwork/consolidate/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for consolidate

Your own site · 80×15
<a href="https://agentmods.dev/skills/choiyounggi/groundwork/consolidate"><img src="https://agentmods.dev/badge/skills/choiyounggi/groundwork/consolidate.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 85 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,504 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00085 $0.02504
Opus 5.5 $0.00034 $0.01002
Sonnet 5.5 $0.00017 $0.00501
Haiku 4.5 $0.00009 $0.00250

Measured 1mo ago against content hash 2b5182ec5846, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

consolidate 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 1mo 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.

plugins/memory-loop/skills/consolidate/SKILL.md · 194 lines

How it starts

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

memory-loop: consolidate

Capture and expiry keep memory flowing; nothing keeps it coherent. Over many sessions the index bloats, two files describe the same thing, an old fact survives next to the newer one that disproved it, and "yesterday" is frozen in a note whose yesterday is long gone. This skill is the operate-stage cleanup: a reflective pass that merges long-tier memory into durable, well-organized form — and, like remember, never writes without your confirmation.

Adapted from xai-org/grok-build's "dream" consolidation pass (Apache-2.0), reframed around memory-loop's save gate and tier model.

When to run

It is a manual skill — there is no forced trigger. Run it when:

  • MEMORY.md has grown large (~120+ lines).
  • signals.jsonl has accumulated correction signals worth reviewing (see the signals pass below).
  • A big piece of work finished and left several related memories behind.
  • The SessionStart upkeep check (memory-staleness-check.sh) reported habits over budget, habits over rule cap, or habits over split threshold — or a write to HABITS.md was denied by habits-budget-guard.sh.
  • The SessionStart upkeep check (memory-staleness-check.sh) listed re-verification candidates, index drift, orphans or broken index links — it is the closest thing this skill has to a trigger, and it only ever reports.

Scope — what it may touch

Read MEMORY.md, the tier: long memory files beside it, and the habit file (habitsPath, default ~/.claude/groundwork/HABITS.md). Exclude:

Excluded Why
Files without a tier key Outside the lifecycle (the compatibility contract) — never touch them
tier: short memories The expiry sweep owns these; consolidation leaves them alone
Identity files (the user/assistant names from setup) Continuity anchors — changed only through the identity skill, never here
Anything already under archived/ Already retired

The five verbs

Review each memory or group through five lenses (the consolidation prompt):

Read the full file on GitHub · 194 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. 1mo ago Changed · +28 lines 2b5182ec5846
  2. 1mo ago Changed · +77 lines · +20 tokens per session f44b47910732
  3. 1mo ago First seen · 89 lines · 65 tokens per session scan A e16ae501412b

Subscribe to this mod's changes

consolidate is a skill published in the GitHub repository choiyounggi/groundwork (3 stars, last pushed 2d ago), licensed MIT. It adds 85 tokens to every session and 2,504 once invoked, about $0.0003 per session on Opus 5.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

reflect

Per-project self-improvement - reads the .harness ledger and feedback memories, then proposes gated rule/threshold/ADR changes so the project stops repeating mistakes. Run periodically.

sneg55/agent-starter · 37 tokens

remember

Review auto-memory entries and propose promotions to CLAUDE.md, CLAUDE.local.md, or shared memory. Also detects outdated, conflicting, and duplicate entries across memory layers.

sneg55/agent-starter · 38 tokens

dream

Memory consolidation - review, merge, prune, and index memory files. Run periodically to keep memories organized and up-to-date.

sneg55/agent-starter · 27 tokens

ucai-patterns

Use when the user asks about Claude Code best practices, how to write agents, how to use hooks, how to manage context, or how to work effectively with Claude Code's native systems.

Joncik91/ucai · 42 tokens

audit-context

Measures where a project's Claude context is going before applying any of clean-context's levers. Reports what Glob discovers with and without ignore files applied, the twenty largest files in the repo and which are generated, the cumulative size of every CLAUDE.md loaded for this working directory, and how many MCP…

Malo-T/claude-toolbelt · 218 tokens

self-improvement

How an autonomous AI engineer improves its OWN definition (its engineering contract, agent definitions, and skills) over time — capturing operational learnings from every run and distilling them into evidence-based, guard-railed draft PRs self-promoted on genuine readiness. Use at the end of every run (to log…

devantler-tech/agent-plugins · 100 tokens