$npx -y skills add getpaperclipai/paperclip --skill index-refreshUse when an operation issue is an index refresh — typically the hourly index-refresh routine. Rebuild wiki/index.md so each entry has a tight, scannable one-line summary and the catalog tracks the actual contents of wiki/. Resolve drift between the index and recent log activi
| 1 | # Index Refresh |
| 2 | |
| 3 | Keep `wiki/index.md` accurate and scannable. The index is the maintainer's first stop for navigation — its quality determines how cheap every subsequent operation becomes. |
| 4 | |
| 5 | ## Inputs |
| 6 | |
| 7 | - An operation issue with `operationType: "index"` (or the `index-refresh` routine title). |
| 8 | - The operation issue's target `wikiId`, `spaceSlug`, and space root. Refresh only that space unless the issue explicitly says this is a multi-space sweep. |
| 9 | |
| 10 | ## Workflow |
| 11 | |
| 12 | 1. **Read the target space's `wiki/index.md`** as it currently stands. |
| 13 | 2. **Walk the target space's `wiki/`.** `wiki/projects/<slug>/standup.md` entries are current-state companions for durable `wiki/projects/<slug>/index.md` pages; index them only as links attached to the matching project entry. Walk `wiki/` by category (`sources/`, `projects/`, `entities/`, `concepts/`, `synthesis/`, plus any custom subdirectories the wiki schema added). |
| 14 | 3. **Read the target space's last ~50 entries of `wiki/log.md`** to spot pages that were created or substantially changed but never made it to the index. |
| 15 | 4. **Per category, produce sorted entries** of the form: |
| 16 | ``` |
| 17 | - [[<path>]] — <one-line summary> |
| 18 | ``` |
| 19 | The summary is one factual sentence pulled from the page's first paragraph or its title. **No status, no datestamps in the index** — those belong in the page itself or in the log. |
| 20 | 5. **Drop entries whose page no longer exists.** Note the deletion in the log: |
| 21 | ``` |
| 22 | ## [YYYY-MM-DD] index-refresh | reconciled |
| 23 | - removed: [[wiki/old-page]] (page deleted) |
| 24 | - added: [[wiki/new-page]] — <summary> |
| 25 | ``` |
| 26 | 6. **Add entries for pages that exist on disk but were missing from the index.** Skip `wiki/log.md` and `wiki/index.md` themselves. For standalone `wiki/projects/<slug>/standup.md` without a matching durable project page, add it under Projects and flag it for later durable-page distillation. |
| 27 | 7. **Write project entries editorially.** The Projects section should group work by the project's concept and purpose, not by issue ids, dates, statuses, UUIDs, or source metadata. Link task identifiers only as supporting evidence. |
| 28 | 8. **Preserve custom categories.** If the wiki has added e.g. `wiki/papers/` or `wiki/runbooks/`, keep its index section. Do not collapse to the default five categories. |
| 29 | 9. **Append a log entry** with counts: |
| 30 | ``` |
| 31 | ## [YYYY-MM-DD] index-refresh | added=N removed=M |
| 32 | - operation issue: <issue identifier> |
| 33 | ``` |
| 34 | If the index was already accurate, the log entry says `added=0 removed=0` — still write it so future audits can see the run happened. |
| 35 | |
| 36 | ## What this skill does NOT do |
| 37 | |
| 38 | - Does not change page content. |
| 39 | - Does not resolve contradictions, fix broken links, or fill concept gaps. Those go to the next `wiki-lint` run. |
| 40 | - Does not write summaries that are not already supported by the page itself. If a page lacks a clear first paragraph to summarise, flag it for `wiki-lint`. |
| 41 | |
| 42 | ## Voice |
| 43 | |
| 44 | - Index entries are one factual line per page, present tense. |
| 45 | - No emojis, no statuses, no dates in `wiki/index.md`. Dates live in the log. |
| 46 | |
| 47 | ## Verification |
| 48 | |
| 49 | Before closing the operation issue: |
| 50 | |
| 51 | - [ ] `wiki/index.md` matches the actual contents of `wiki/` — no missing pages, no dangling entries. |
| 52 | - [ ] Project entries include current `wiki/projects/<slug>/standup.md` links when standups exist. |
| 53 | - [ ] Each index line has the form `- [[path]] — <summary>`. |
| 54 | - [ ] Custom category sections are preserved. |
| 55 | - [ ] `wiki/log.md` has the index-refresh entry with counts (even if the counts are zero). |
| 56 | - [ ] No page bodies were modified. No file under `raw/` was modified. |
| 57 | |
| 58 | ## Tools |
| 59 | |
| 60 | `wiki_search`, `wiki_read_page`, `wiki_write_page` (for `wiki/index.md` and `wiki/log.md` only). Always include the operation issue's `wikiId` and `spaceSlug`. |