一键导入
ac-reset
Clear all auto-context data and remove auto-generated sections from CLAUDE.md. Use to start fresh or uninstall auto-context from a project.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Clear all auto-context data and remove auto-generated sections from CLAUDE.md. Use to start fresh or uninstall auto-context from a project.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | ac-reset |
| description | Clear all auto-context data and remove auto-generated sections from CLAUDE.md. Use to start fresh or uninstall auto-context from a project. |
| disable-model-invocation | true |
Remove all auto-context state from this project. This is a destructive operation.
Before proceeding, inform the user what will be deleted:
.auto-context/ directory (all conventions, candidates, anti-patterns, config, session logs)<!-- auto-context:start --> and <!-- auto-context:end -->, inclusive of the markers)Ask: "This will permanently delete all auto-context data. Proceed?"
If the user says no, stop immediately.
Delete the .auto-context/ directory:
rm -rf .auto-context/
Verify removal:
test ! -d .auto-context/ && echo "Data store removed" || echo "WARNING: .auto-context/ still exists"
If .auto-context/ does not exist, report "No data store found" and continue to Step 3.
If CLAUDE.md does not exist, report "No CLAUDE.md found" and skip to Step 4.
If CLAUDE.md exists, check for auto-context markers:
grep -c -F "auto-context:" CLAUDE.md 2>/dev/null || echo "0"
If no markers found (count is 0), report "No auto-context markers found in CLAUDE.md" and skip to Step 4.
If markers exist, remove everything between <!-- auto-context:start --> and <!-- auto-context:end --> (inclusive):
awk '/<!-- auto-context:start -->/{skip=1; next} /<!-- auto-context:end -->/{skip=0; next} !skip{print}' CLAUDE.md > CLAUDE.md.ac-tmp && mv CLAUDE.md.ac-tmp CLAUDE.md
After removal, check if CLAUDE.md is empty or whitespace-only:
if [ ! -s CLAUDE.md ] || ! grep -q '[^[:space:]]' CLAUDE.md 2>/dev/null; then
rm CLAUDE.md
echo "CLAUDE.md was empty after cleanup -- removed"
fi
If CLAUDE.md still has user content, keep it.
Verify no orphaned markers remain:
grep -c -F "auto-context:" CLAUDE.md 2>/dev/null || echo "0"
If orphaned markers remain (corrupted state), remove any lines containing the marker patterns:
grep -v -F "auto-context:start" CLAUDE.md | grep -v -F "auto-context:end" > CLAUDE.md.ac-tmp && mv CLAUDE.md.ac-tmp CLAUDE.md
Tell the user what was cleaned:
.auto-context/ was found and removed (or was already absent)/auto-context:ac-init to re-bootstrap if desired"Show auto-context pipeline status including observation counts, candidates, conventions, anti-patterns, reward signals, and lifecycle statistics.
Review pending convention candidates. Approve, reject, or edit each candidate before it reaches CLAUDE.md.
Bootstrap project context by scanning structure, tech stack, config files, and git history. Generates initial conventions that surpass Claude Code's built-in /init. Use when setting up auto-context for a new project.