Agent Aftercare — AI skill for Claude Code
Reclaim disk space left by AI coding agents without deleting your work.
How to install Agent Aftercare
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open leavemagic-cyber/agent-aftercare and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Agent Aftercare does
Reclaim disk space left by AI coding agents without deleting your work.
Alternatives in AI
- BrowserSkill — Let AI agents use your real, logged-in browser without interrupting your work 9.1k ★
- OpenSpace — "OpenSpace: The Skill Management Layer for AI Agents" -- https://open-space.cloud/ 7.5k ★
- J Space Cognition Suite V3.7 — J-Space Cognition Suite V3.7 - AI cognitive-enhancement Skills based on Anthropic's J-space global workspace r 3k ★
README
Agent Aftercare
**Your AI made the mess. Make it clean it up — without deleting your work.**
[](https://github.com/leavemagic-cyber/agent-aftercare/actions/workflows/ci.yml) [](LICENSE) [繁體中文](README.zh-TW.md)
AI coding agents are excellent at creating things and terrible at taking out the trash. Old sessions, duplicated subagent histories, and abandoned worktrees quietly grow until you need disk space *right now*.
You could hunt through hidden folders yourself. You could also delete the wrong thing. Agent Aftercare gives you the lazy, cowardly, sensible option:
- see only known agent residue;
- refuse anything recent or tied to a detected provider process;
- compress and deduplicate what you choose;
- restore the exact bytes if you regret it.
[!IMPORTANT] Agent Aftercare is alpha software. Version 0.1 quarantines old **session logs**. It detects known worktree roots but deliberately blocks worktree removal until Git metadata can be restored safely.
The 15-second demo
$ python -m scripts.demo
scan: 4 found | 3 review | 1 blocked
claude review 2340000 bytes
codex review 2340000 bytes
gemini review 875000 bytes
codex blocked 12 bytes
quarantine: 5555000 original bytes -> 9494 new stored bytes
dedupe: 1 reused object
restore: exact_bytes=True
This is the real output of [`scripts/demo.py`](scripts/demo.py), using disposable fake sessions. It does not invent a 200 GB success story.
Why this exists
This is not a theoretical cleanup problem:
- a Codex user reported a
.codex/sessionsdirectory above 400 GB after image data was duplicated about 150,000 times (openai/codex#35470); - another reported 118 untracked run copies consuming 202 GB ([openai/codex#35383](https://github.com/openai/codex/issue
Related Skills
Lagless
A native macOS task manager for the age of AI agents: see every Claude Code session, Codex thread and MCP serv
Mac Dev Cleanup
Safely free disk space and RAM on a macOS dev machine: package caches, Xcode/iOS simulator cleanup, AI-agent w
Agent Hoard
Local disk space manager for AI coding agents (DSH, Codex, Claude Code, Cursor, Gemini, Aider...) - risk-tiere
Amnesia Sweep
See what AI coding agents left on disk, then delete it or archive it for later.
Cleanup Cache
Clean system caches (npm, Homebrew, Yarn, browsers, Python/ML) to free disk space
Pc Cleanup Performance
Cross-platform skill that lets your AI coding agent (Claude Code, Codex, Cursor...) safely clean up and speed
Related Agents
Frappe Doctor
Diagnose a Frappe/ERPNext site's health, read-only — background workers, error logs, slow queries, failed jobs
Feedback Update
Feedback subagent 3. Finds existing memory entries that one piece of human feedback contradicts, narrows or co
UI Tree Reader
Answer a specific question about an iOS simulator accessibility tree (an axe describe-ui JSON dump on disk) —