Reset

From Chanw-research/claude-code-paper-writing · View interactive version

Reset is an AI agent skill from the GitHub repository Chanw-research/claude-code-paper-writing. Reset wiki state to a clean scaffold by scope (wiki / raw / log / checkpoints / all). Useful during development or carefree restarts after a botched setup.

How to use this skill

Skill file

/reset

Resets the wiki to a clean scaffold by scope. Designed for development iteration and recovery after a failed setup — not a routine operation.

Trigger

Manual: /reset --scope wiki / --scope raw / --scope log / --scope checkpoints / --scope all. Multiple scopes may be combined comma-separated: --scope wiki,log.

Inputs

Outputs

Wiki Interaction

Reads

Writes

Workflow

Pre-conditions: working directory contains wiki/, tools/. Set WIKI_ROOT=wiki/.

Step 1: Build the deletion plan (dry-run)

python3 tools/reset_wiki.py --scope <scope>

This prints a JSON plan listing every file that would be deleted or reset, without modifying anything. Display the plan to the user grouped by scope (wiki entity dirs, raw subdirs, log, checkpoints).

Step 2: Confirm with the user

Print the plan summary and ask for explicit confirmation:

About to delete N files and reset M files. Continue? [y/N]

If the user says no, exit. Never proceed without explicit approval — /reset is destructive and raw/ deletions are not tracked by git.

Step 3: Execute

python3 tools/reset_wiki.py --scope <scope> --yes

The tool prints a JSON status report ({deleted_files, reset_files}).

Step 4: Log (unless `log` scope was reset)

If the executed scope did not include log, append a log entry so future sessions can see the reset happened:

python3 tools/research_wiki.py log wiki/ "reset | scope: <scope>"

Step 5: Report

Print the result and suggest next steps:

## Reset complete — scope: <scope>

Deleted: N files
Reset:   M files

Next steps:
- /init       — bootstrap wiki from raw/
- /prefill    — seed foundational background
- /ingest     — add a single source manually

Constraints

Error Handling

Dependencies

Tools (via Bash)

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.