🗜️
AI EngineeringTypeScript

Add Compact Command

by sbusso

Add Compact Command is an AI Engineering skill for Claude Code, published by sbusso in claudeclaw.

193 stars60 forkson sbusso/claudeclawAdded 2026/09/06Repository updated 2026/08/12
agentagentic-aiclaude-codeopenclaw
Install in seconds
Install Add Compact Command
Copy Add Compact Command into your Claude Code skills folder. Run the command in your terminal, or review the source on GitHub before installing.
terminal
npx degit https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact ~/.claude/skills/add-compact

Requires Node.js. Downloads this skill only — not the rest of the repository — into your Claude Code skills folder.

Without Node.js

git clone https://github.com/sbusso/claudeclaw.git

Clones the whole repository, then copy the skill’s own directory into your skills folder yourself.

In this catalog

Source file
skills/add-compact/SKILL.md in sbusso/claudeclaw
Installs to
~/.claude/skills/add-compact
Collection
One of 25 skills cataloged from this repository
Category
AI Engineering3278 skills

What Add Compact Command does

Add Compact Command adds a /compact session command to manually compact conversation history in long-running Claude sessions. Use it to reduce context rot while keeping the same logical session and honoring main-group or trusted-sender access rules.

Add Compact Command is cataloged under AI Engineering on DirSkills. Add Compact Command comes from a repository tagged agent, agentic-ai, claude-code and openclaw.

Documentation

README

Add /compact Command

Adds a /compact session command that compacts conversation history to fight context rot in long-running sessions. Uses the Claude Agent SDK's built-in /compact slash command — no synthetic system prompts.

Session contract: /compact keeps the same logical session alive. The SDK returns a new session ID after compaction (via the init system message), which the agent-runner forwards to the orchestrator as newSessionId. No destructive reset occurs — the agent retains summarized context.

Phase 1: Pre-flight

Check if src/session-commands.ts exists:

test -f src/session-commands.ts && echo "Already applied" || echo "Not applied"

If already applied, skip to Phase 3 (Verify).

This is the opening of the README. Read the full README on GitHub.

Commands Add Compact Command provides

Slash commands named in this skill’s SKILL.md, listed in the order they first appear.

  • /compact
  • /add-compact
  • /clear

Frequently asked about Add Compact Command

  • What else does sbusso publish alongside Add Compact Command?

    Add Compact Command is one of 25 skills that DirSkills catalogs from sbusso/claudeclaw, the repository it ships in. Its siblings there include Add Gmail, Add Reactions and Add Telegram Swarm. Each one is a separate skill with its own page in this directory, installs the same way Add Compact Command does, and is maintained by sbusso in that same repository. The rest of the collection is listed on the sbusso/claudeclaw page.

  • How does Add Compact Command compare to other AI Engineering skills?

    Add Compact Command ranks #2877 by stars among the 3278 AI Engineering skills in this catalog. The most-starred ones next to it are Architecture Decision Records, AI-First Engineering and Agentic OS. DirSkills ranks by the star count of the repository each skill ships in, so that order reflects how popular those repositories are rather than any review of Add Compact Command against them. Open each page to compare what they document and how they install.

More from sbusso/claudeclaw

Add Compact Command is one of 25 skills cataloged on DirSkills from sbusso/claudeclaw.

See all 25 skills