Plugin Skill Development Guide
anthropics/claude-plugins-official
Explains how to design and write skills for Claude Code plugins: SKILL.md frontmatter, bundled scripts, references and assets, and descriptions that trigger at the right time.
Add /compact command for manual context compaction. An agent skill from sbusso/claudeclaw.
$ npx skills add sbusso/claudeclaw --skill add-compact -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install sbusso/claudeclaw add-compact --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/sbusso/claudeclaw.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/add-compact .claude/skills/add-compact && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "add-compact" agent skill from https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact into .claude/skills/add-compact/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-compact", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/sbusso/claudeclaw/tree/main/skills/add-compactType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add sbusso/claudeclaw --skill add-compact -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install sbusso/claudeclaw add-compact --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sbusso/claudeclaw.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/add-compact .agents/skills/add-compact && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "add-compact" agent skill from https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact into .agents/skills/add-compact/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-compact", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add sbusso/claudeclaw --skill add-compact -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install sbusso/claudeclaw add-compact --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sbusso/claudeclaw.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/add-compact .cursor/skills/add-compact && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "add-compact" agent skill from https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact into .cursor/skills/add-compact/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-compact", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/sbusso/claudeclaw.git --path skills/add-compact--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add sbusso/claudeclaw --skill add-compact -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install sbusso/claudeclaw add-compact --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sbusso/claudeclaw.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/add-compact .gemini/skills/add-compact && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "add-compact" agent skill from https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact into .gemini/skills/add-compact/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-compact", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install sbusso/claudeclaw add-compactInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add sbusso/claudeclaw --skill add-compact -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/sbusso/claudeclaw.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/add-compact .github/skills/add-compact && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "add-compact" agent skill from https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact into .github/skills/add-compact/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-compact", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add sbusso/claudeclaw --skill add-compact -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install sbusso/claudeclaw add-compact --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sbusso/claudeclaw.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/add-compact .opencode/skills/add-compact && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "add-compact" agent skill from https://github.com/sbusso/claudeclaw/tree/main/skills/add-compact into .opencode/skills/add-compact/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-compact", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
add-compactAdd /compact command for manual context compaction. An agent skill from sbusso/claudeclaw.
Add Compact is an agent skill from sbusso/claudeclaw. Add /compact command for manual context compaction. Solves context rot in long sessions by forwarding the SDK's built-in /compact slash command. Main-group or trusted sender only.
Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Agent Workflows, covering Context engineering and Hooks and plugins. The repository describes itself as: Use Claude to orchestrate agents like OpenClaw. The licence is MIT.
3 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 1395af4. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
npmgitclaudeFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use npm and git, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Add Compact loads about 1.8k tokens when it runs. Until then it costs about 48 tokens; SKILL.md has 819 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from sbusso/claudeclaw at commit 1395af4, republished under its MIT licence (© sbusso). 819 words, ~1,794 tokens.
.claude/skills/add-compact/SKILL.md (or your agent's skills folder).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.
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).
Merge the skill branch:
git fetch upstream skill/compact
git merge upstream/skill/compactNote:
upstreamis the remote pointing tosbusso/claudeclaw. If using a different remote name, substitute accordingly.
This adds:
src/session-commands.ts (extract and authorize session commands)src/session-commands.test.ts (unit tests for command parsing and auth)src/index.ts (both processGroupMessages and startMessageLoop)agent/runner/src/index.tsnpm test
npm run build./src/runtimes/docker/build.shService name: Derived from the directory name:
com.claudeclaw.<dirname>(macOS) /claudeclaw-<dirname>(Linux). For example, if cwd ismy-assistant, the service iscom.claudeclaw.my-assistant. Determine the correct service name before running service commands below.
launchctl kickstart -k gui/$(id -u)/com.claudeclaw # macOS
# Linux: systemctl --user restart claudeclawnpm run dev/compactgroups/{folder}/conversations/ (by the PreCompact hook)Compact boundary observed (confirms SDK actually compacted)compact_boundary was NOT observed, the response says "compact_boundary was not observed"@<assistant> /compactis_from_me), send: @<assistant> /compact/compact/compact, then another normal message in quick succession (same polling batch):runAgent calls)/compact in the batch are preserved (cursor advances to /compact's timestamp only) and processed on the next poll cycle@<assistant> /compact:/compact is consumed (cursor advanced) — it does NOT replay on future polls/compact + other messages in the same polling interval)requiresTrigger enabled) as a non-admin user, send bare /compact (no trigger prefix):/compact is consumed silentlyrequiresTrigger is false, a denial message IS sent because the sender is considered reachable/compact triggers itgit clone <your-fork> /tmp/claudeclaw-test
cd /tmp/claudeclaw-test
claude # then run /add-compact
npm run build
npm test
./src/runtimes/docker/build.sh
# Manual: send /compact from main group, verify compaction + continuation
# Manual: send @<assistant> /compact from non-main as non-admin, verify denial
# Manual: send @<assistant> /compact from non-main as admin, verify allowed
# Manual: verify no auto-compaction behaviordocs/SECURITY.md). Non-main groups are untrusted — a careless or malicious user could wipe the agent's short-term memory. However, the device owner (is_from_me) is always trusted and can compact from any group.PreCompact hook in the agent-runner archives the full transcript to conversations/ before the SDK compacts it./clear command (separate skill, separate semantics — /clear is a destructive reset)is_from_me) or main-group senders can use /compact. Other users are denied./compact fail to process, the error message says "Failed to process messages before /compact." The cursor advances past sent output to prevent duplicates; /compact remains pending for the next attempt.© sbusso, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/add-compact of sbusso/claudeclaw.
Open the folder on GitHubat commit 1395af4
Add Compact next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Add Compact this skillsbusso/claudeclaw | 194 | — | ~1.8k | Automated safety check: Pass | MIT | |
| Plugin Skill Development Guideanthropics/claude-plugins-official | 38k | 9 repos | ~5.6k | Automated safety check: Pass | Apache-2.0 | |
| Token-Saver Configurationppgranger/token-saver | 153 | — | ~1k | Automated safety check: Pass | Apache-2.0 | |
| Claude Code Mastery Squadohmyjahh/xquads-squads | 276 | — | ~1.1k | Automated safety check: Pass | MIT | |
| Hook Development for Claude Code Pluginsanthropics/claude-plugins-official | 38k | 11 repos | ~4.1k | Automated safety check: Notes | Apache-2.0 | |
| Claude Code Agent Developmentanthropics/claude-plugins-official | 38k | 8 repos | ~2.8k | Automated safety check: Pass | Apache-2.0 |
anthropics/claude-plugins-official
Explains how to design and write skills for Claude Code plugins: SKILL.md frontmatter, bundled scripts, references and assets, and descriptions that trigger at the right time.
ppgranger/token-saver
Checks and tunes token-saver output compression: reads stats, explains why a command was or was not compressed, and edits config files or environment variables.
ohmyjahh/xquads-squads
Routes a request to one of eight specialist agents covering hooks, skills, subagents, MCP integration and context engineering for Claude Code.
anthropics/claude-plugins-official
Explains how to write Claude Code plugin hooks, both prompt-based checks and bash commands, for events such as PreToolUse, Stop and SessionStart.
anthropics/claude-plugins-official
Explains how to write agents for Claude Code plugins: the markdown file with YAML frontmatter, trigger descriptions, model and color settings, and system prompt design.
diet103/claude-code-infrastructure-showcase
A guide to creating and managing Claude Code skills with auto-activation: skill-rules.json triggers, hooks, enforcement levels, YAML frontmatter and progressive disclosure.
sbusso/claudeclaw
Debug container agent issues. An agent skill from sbusso/claudeclaw.
sbusso/claudeclaw
X (Twitter) integration for ClaudeClaw. An agent skill from sbusso/claudeclaw.
sbusso/claudeclaw
Add Gmail integration to ClaudeClaw. An agent skill from sbusso/claudeclaw.
sbusso/claudeclaw
Add QMD (Query Markup Documents) as an advanced memory search backend.
sbusso/claudeclaw
Add Telegram as a channel. An agent skill from sbusso/claudeclaw.
sbusso/claudeclaw
Add Agent Swarm (Teams) support to Telegram. An agent skill from sbusso/claudeclaw.
Categories
Add /compact command for manual context compaction. An agent skill from sbusso/claudeclaw. Add Compact is an agent skill from sbusso/claudeclaw. Add /compact command for manual context compaction.
Add Compact fits situations like: tasks that involve Context engineering; tasks that involve Hooks and plugins.
Run `npx skills add sbusso/claudeclaw --skill add-compact -a claude-code`. Or copy the skill folder (skills/add-compact in sbusso/claudeclaw) into .claude/skills/add-compact in your project. Claude Code loads it when a task matches its description.
Run `npx skills add sbusso/claudeclaw --skill add-compact -a codex`. Or copy the skill folder (skills/add-compact in sbusso/claudeclaw) into .agents/skills/add-compact in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add sbusso/claudeclaw --skill add-compact -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/add-compact, .gemini/skills/add-compact, .github/skills/add-compact and .opencode/skills/add-compact in your project.
Going by SKILL.md and its folder, Add Compact needs the command-line tools its instructions call (npm, git and claude). Our summary lists: Docker.
SKILL.md contains no URLs. Its commands use npm and git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Add Compact is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.8k tokens (SKILL.md is roughly 7.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Add Compact: Plugin Skill Development Guide (anthropics/claude-plugins-official, 38k stars), Token-Saver Configuration (ppgranger/token-saver, 153 stars), Claude Code Mastery Squad (ohmyjahh/xquads-squads, 276 stars) and Hook Development for Claude Code Plugins (anthropics/claude-plugins-official, 38k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
sbusso (a GitHub user) maintains it in sbusso/claudeclaw, which has 194 GitHub stars. The repository holds 23 skills in this directory. The repository was last updated on August 12, 2026.
Source: sbusso/claudeclaw on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.