- name
SKILL.md
技能檔案保留在發布者的儲存庫中。
在終端機中貼上複製的指令。它會將這個 SKILL.md 安裝到對應的代理中。
npx skills add rohitg00/pro-workflow --skill compact-guard -a cursor -y在終端機中貼上複製的指令。它會將這個 SKILL.md 安裝到對應的代理中。
npx skills add rohitg00/pro-workflow --skill compact-guard -a claude-code -y在終端機中貼上複製的指令。它會將這個 SKILL.md 安裝到對應的代理中。
npx skills add rohitg00/pro-workflow --skill compact-guard -a codex -y在終端機中貼上複製的指令。它會將這個 SKILL.md 安裝到對應的代理中。
npx skills add rohitg00/pro-workflow --skill compact-guard -a grok -y在 Grok Bot 聊天中傳送複製的訊息。Bot 會從 GitHub 取得這個 SKILL.md,並加入你所有 Bot 共用的技能中。
Install this skill: https://github.com/rohitg00/pro-workflow/tree/HEAD/skills/compact-guard來自發布者
Protect important context through compaction cycles. Based on Claude Code internals: compaction restores max 5 files with 5K tokens each, within a 50K total budget.
Use before /compact or when auto-compact warning appears.
POST_COMPACT_MAX_FILES_TO_RESTORE = 5 — only 5 files survivePOST_COMPACT_TOKEN_BUDGET = 50K — total restore budgetPOST_COMPACT_MAX_TOKENS_PER_FILE = 5K — per-file limitcontext_window - 13K bufferBefore compacting, save these to memory or a scratch file:
Before full compaction, try microcompact:
After compaction, immediately:
After running compact-guard:
COMPACT GUARD
Files to preserve: [list top 5]
Task state: [one sentence]
Decisions: [key choices]
Next step: [immediate action after compact]
Ready to compact. Run /compact now.
Smart context compaction with state preservation. Saves critical files, task progress, and working state before compaction, restores after. Use before manual compact or when auto-compact triggers.
---name: compact-guarddescription: Smart context compaction with state preservation. Saves critical files, task progress, and working state…---# skills/compact-guard/SKILL.md常見問題
從發布者下載 skills/compact-guard/SKILL.md,或複製路徑後開啟儲存庫。PlugMCP 只收錄這項技能,不代管檔案。
發布者將它存放在 https://github.com/rohitg00/pro-workflow。
Claude、Cursor、Codex 和 Grok Build 可以讀取你從發布者儲存庫加入的 SKILL.md。在聊天中傳送技能的 GitHub 資料夾連結,Grok Bot 就會安裝它。