Agent skill

Wiki Rebuild

by Ar9av in Ar9av/obsidian-wiki

Archive and rebuild wiki knowledge from source, or restore a prior archive.

MITAuto-check: notesKnowledge Management

Install Wiki Rebuild

skills CLI
$ npx skills add Ar9av/obsidian-wiki --skill wiki-rebuild -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install Ar9av/obsidian-wiki wiki-rebuild --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/Ar9av/obsidian-wiki.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.skills/wiki-rebuild .claude/skills/wiki-rebuild && rm -rf skills-src

Use ~/.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/

Facts

Skill name
wiki-rebuild
GitHub stars
3.5k
Token cost
~1.9k tokens
SKILL.md length
848 words
Files
1
Skills in repo
39
Repo updated
First seen
Licence
MIT

At a glance

Archive and rebuild wiki knowledge from source, or restore a prior archive.

  • Works in 9 steps: Archive current state → Clear live wiki → Rebuild → …
  • Full restart/recovery when incremental repair is inappropriate
  • SKILL.md covers Before You Start, The Archive System, Mode 1: Archive Only and Mode 2: Archive + Rebuild, plus 3 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Wiki Rebuild is an agent skill from Ar9av/obsidian-wiki. Archive and rebuild wiki knowledge from source, or restore a prior archive. Use for full restart/recovery when incremental repair is inappropriate; this is broader and more destructive than ordinary update or lint.

Its SKILL.md is about 1.9k 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 Knowledge Management, covering LLM wikis. It works with Obsidian. The repository describes itself as: Framework for AI agents to build and maintain a digital brain through Obsidian wiki | Memory System for Agents. The licence is MIT.

When your agent uses it

  • Full restart/recovery when incremental repair is inappropriate
  • This is broader and more destructive than ordinary update

Example prompts

  • “/wiki-rebuild”

Workflow steps

9 steps, taken from the step headings in SKILL.md.

  1. Archive current state
  2. Clear live wiki
  3. Rebuild
  4. Log the rebuild
  5. List available archives
  6. Confirm which archive to restore
  7. Archive current state first
  8. Restore
  9. Report

What it can do on your machine

Read from SKILL.md and the folder at commit 4a0630b. It shows what the files ask for, not the result of running them.

  • Tool permissions

    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.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are bash, json and markdown).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Wiki Rebuild loads about 1.9k tokens when it runs. Until then it costs about 57 tokens; SKILL.md has 848 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~57
When it runs · the whole SKILL.md, loaded when a task matches
~1.9k

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.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NoteMentions a .env fileSKILL.md:13
    line `@name` override → walk up CWD for `.env` → global config → prompt setup). This gives `OBSIDIAN_VAULT_PATH` and opt
  • NoteMentions a .env fileSKILL.md:89
    - `.env` (if present in vault)

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.

SKILL.md

The full file from Ar9av/obsidian-wiki at commit 4a0630b, republished under its MIT licence (© Ar9av). 848 words, ~1,860 tokens.

Download SKILL.mdSave it as .claude/skills/wiki-rebuild/SKILL.md (or your agent's skills folder).
name
wiki-rebuild
description
Archive and rebuild wiki knowledge from source, or restore a prior archive. Use for full restart/recovery when incremental repair is inappropriate; this is broader and more destructive than ordinary update or lint.

Wiki Rebuild — Archive, Rebuild, Restore

You are performing a destructive operation on the wiki. Always archive first, always confirm with the user before proceeding.

Before You Start

  1. Resolve config — follow the Config Resolution Protocol in llm-wiki/SKILL.md (inline @name override → walk up CWD for .env → global config → prompt setup). This gives OBSIDIAN_VAULT_PATH and optional QMD settings such as QMD_WIKI_COLLECTION
  2. Read .manifest.json to understand current state
  3. Confirm the user's intent. This skill supports three modes:
    • Archive only — snapshot current wiki, no rebuild
    • Archive + Rebuild — snapshot, then reprocess all sources from scratch
    • Restore — bring back a previous archive

The Archive System

Archives live at $OBSIDIAN_VAULT_PATH/_archives/. Each archive is a timestamped directory containing a full copy of the wiki state at that point.

$OBSIDIAN_VAULT_PATH/
├── _archives/
│   ├── 2026-04-01T10-30-00Z/
│   │   ├── archive-meta.json
│   │   ├── concepts/
│   │   ├── entities/
│   │   ├── skills/
│   │   ├── references/
│   │   ├── synthesis/
│   │   ├── journal/
│   │   ├── projects/
│   │   ├── index.md
│   │   ├── log.md
│   │   └── .manifest.json
│   └── 2026-03-15T08-00-00Z/
│       └── ...
├── concepts/          ← live wiki
├── entities/
└── ...
archive-meta.json
json
{
  "archived_at": "2026-04-06T10:30:00Z",
  "reason": "rebuild",
  "total_pages": 87,
  "total_sources": 42,
  "total_projects": 6,
  "vault_path": "$OBSIDIAN_VAULT_PATH",
  "manifest_snapshot": ".manifest.json"
}

Mode 1: Archive Only

When the user wants to snapshot the current state without rebuilding.

Steps:
  1. Create archive directory: _archives/YYYY-MM-DDTHH-MM-SSZ/
  2. Copy all category directories, index.md, log.md, .manifest.json, and projects/ into the archive
  3. Write archive-meta.json with reason "snapshot"
  4. Append to log.md:
    - [TIMESTAMP] ARCHIVE reason="snapshot" pages=87 destination="_archives/2026-04-06T10-30-00Z"
  5. Optionally refresh QMD if log.md is indexed and QMD_WIKI_COLLECTION is configured (see "QMD Refresh After Live Wiki Changes").
  6. Report: "Archived 87 pages. Current wiki is untouched."

Mode 2: Archive + Rebuild

When the user wants to start fresh. This is the full sequence:

Step 1: Archive current state

Same as Mode 1 above, but with reason "rebuild".

Step 2: Clear live wiki

Remove all content from the category directories (concepts/, entities/, skills/, etc.) and the projects/ directory. Keep:

  • _archives/ (obviously)
  • .obsidian/ (Obsidian config)
  • .env (if present in vault)

Reset index.md to the empty template. Reset log.md with just the rebuild entry. Delete .manifest.json (it'll be recreated during ingest).

Step 3: Rebuild

Tell the user the vault is cleared and ready for a full re-ingest. They can now run:

  1. wiki-status — to see all sources as "new"
  2. claude-history-ingest — to reprocess Claude history
  3. codex-history-ingest — to reprocess Codex session history
  4. wiki-ingest — to reprocess documents and any other raw data

Each of these will rebuild the manifest as they go.

Important: Don't run the ingest yourself automatically. The user should choose what to re-ingest and in what order. Some sources may no longer be relevant.

Step 4: Log the rebuild

Append to log.md:

- [TIMESTAMP] REBUILD archived_to="_archives/2026-04-06T10-30-00Z" previous_pages=87

Refresh QMD after clearing and logging the live wiki (see "QMD Refresh After Live Wiki Changes"), then report that the vault is ready for selected re-ingest skills.

Mode 3: Restore from Archive

When the user wants to go back to a previous state.

Step 1: List available archives

Read _archives/ directory. For each archive, read archive-meta.json and present:

markdown
## Available Archives

| Date | Reason | Pages | Sources |
|---|---|---|---|
| 2026-04-06 10:30 | rebuild | 87 | 42 |
| 2026-03-15 08:00 | snapshot | 65 | 31 |
Step 2: Confirm which archive to restore

Ask the user which archive they want. Warn them that restoring will overwrite the current live wiki.

Step 3: Archive current state first

Before restoring, archive the current state (reason: "pre-restore") so nothing is lost.

Step 4: Restore
  1. Clear the live wiki (same as Mode 2, Step 2)
  2. Copy all content from the chosen archive back into the live wiki directories
  3. Restore index.md, log.md, and .manifest.json from the archive
  4. Append to log.md:
    - [TIMESTAMP] RESTORE from="_archives/2026-03-15T08-00-00Z" pages_restored=65
Show full SKILL.md (337 more words)Show less
Step 5: Report

Refresh QMD after restore (see "QMD Refresh After Live Wiki Changes"), then tell the user what was restored and suggest running wiki-lint to check for any issues with the restored state.

QMD Refresh After Live Wiki Changes

QMD is a search index, not the source of truth. If QMD refresh fails, do not roll back archive, rebuild, or restore work; report the failure and leave the markdown vault intact.

GUARD: If $QMD_WIKI_COLLECTION is empty or unset, skip this step.

When to run:

ModeRefresh QMD?Reason
Archive onlyOptionalLive wiki content is unchanged except log.md; refresh if log.md is indexed and QMD is configured.
Archive + RebuildRequired after clearing live wikiQMD must forget deleted pages or it will return stale search results. Later ingest skills will refresh again as sources are reprocessed.
RestoreRequired after restoreThe live wiki was replaced with archive content, so QMD must match the restored state.

This refresh currently requires the local QMD CLI. Use $QMD_CLI if set; otherwise use qmd. If the CLI is unavailable, report QMD skipped: qmd CLI unavailable.

For CLI refresh:

bash
${QMD_CLI:-qmd} update

If the output says new hashes need vectors, or if restore replaced live pages and embeddings may be stale, run:

bash
${QMD_CLI:-qmd} embed

Verify the wiki collection reflects the operation:

bash
${QMD_CLI:-qmd} ls "$QMD_WIKI_COLLECTION"

For restore, also verify one restored page if the archive has a known page path:

bash
${QMD_CLI:-qmd} get "qmd://$QMD_WIKI_COLLECTION/<restored-page>.md" -l 5

Record QMD refresh in the final report as one of:

  • QMD refreshed: update + embed + verified
  • QMD refreshed: update only + verified
  • QMD skipped: QMD_WIKI_COLLECTION unset
  • QMD skipped: archive-only live content unchanged
  • QMD skipped: qmd CLI unavailable
  • QMD failed: <short error summary>

Safety Rules

  1. Always archive before destructive operations. No exceptions.
  2. Always confirm with the user before clearing the live wiki.
  3. Never delete archives unless the user explicitly asks. Archives are cheap insurance.
  4. The .obsidian/ directory is sacred. Never touch it during archive/rebuild/restore — it contains the user's Obsidian settings, plugins, and themes.
  5. If something goes wrong mid-rebuild, the archive is there. Tell the user they can restore.

© Ar9av, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .skills/wiki-rebuild of Ar9av/obsidian-wiki.

Open the folder on GitHubat commit 4a0630b

Compare with similar skills

Wiki Rebuild 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.

Wiki Rebuild compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Wiki Rebuild this skillAr9av/obsidian-wiki3.5k—~1.9kAutomated safety check: NotesMIT
LLM Wikilewislulu/llm-wiki-skill655—~3.7kAutomated safety check: PassNone
LLM Wikizosmaai/pi-llm-wiki608—~4.4kAutomated safety check: PassMIT
LLM Wikipraneybehl/llm-wiki-plugin118—~5.7kAutomated safety check: PassMIT
Karpathy WikiSherwinQ/karpathy-wiki114—~967Automated safety check: PassMIT
My LLM WikiMartinLwx/dotfiles140—~2.7kAutomated safety check: PassNone

Similar skills

  • LLM Wiki

    lewislulu/llm-wiki-skill

    Build and maintain a Karpathy-style LLM knowledge base — a self-compiling Obsidian markdown wiki where an Agent ingests raw sources, compiles cross-linked concept/entity/summary pages, answers…

    655 GitHub stars~3.7k tokensUpdated 5 mo ago
    Knowledge ManagementAuto-check passed
  • LLM Wiki

    zosmaai/pi-llm-wiki

    Build and maintain a persistent, interlinked Obsidian-compatible markdown wiki using Karpathy's LLM Wiki pattern.

    608 GitHub stars~4.4k tokensUpdated yesterday
    Knowledge ManagementAuto-check passed
  • LLM Wiki

    praneybehl/llm-wiki-plugin

    Build and maintain an LLM-curated knowledge base from papers, articles, transcripts, notes and project findings.

    118 GitHub stars~5.7k tokensUpdated 27 days ago
    Knowledge ManagementAuto-check passed
  • Karpathy Wiki

    SherwinQ/karpathy-wiki

    A skill your agent uses when building or maintaining a personal knowledge base with LLM assistance.

    114 GitHub stars~967 tokensUpdated 5 mo ago
    Knowledge ManagementAuto-check passed
  • My LLM Wiki

    MartinLwx/dotfiles

    Provides access to the user's personal wiki, including notes, research, project documentation, decisions, and archived knowledge.

    140 GitHub stars~2.7k tokensUpdated 2 days ago
    Knowledge ManagementAuto-check passed
  • Sage Wiki

    xoai/sage-wiki

    Reference skill for sage-wiki — local-first knowledge graph with MCP server, REST API, compiled wiki, and Obsidian-compatible output.

    623 GitHub stars~2.4k tokensUpdated 4 days ago
    Knowledge ManagementAuto-check passed

More from Ar9av/obsidian-wiki

All 39 skills in this repo
  • Codex History Ingest

    Ar9av/obsidian-wiki

    Ingest Codex CLI conversation/session history into Obsidian as distilled knowledge.

    3.5k GitHub stars~2.2k tokensUpdated 2 days ago
    Auto-check: notes
  • Copilot History Ingest

    Ar9av/obsidian-wiki

    Ingest GitHub Copilot CLI/session history into Obsidian as distilled knowledge.

    3.5k GitHub stars~4.4k tokensUpdated 2 days ago
    Auto-check: notes
  • Hermes History Ingest

    Ar9av/obsidian-wiki

    Ingest Hermes agent history into Obsidian as distilled knowledge.

    3.5k GitHub stars~2.2k tokensUpdated 2 days ago
    Auto-check: notes
  • Obsidian Layout Adjustment

    Ar9av/obsidian-wiki

    Adjust the user's Obsidian visual layout with CSS snippets. An agent skill from Ar9av/obsidian-wiki.

    3.5k GitHub stars~2.5k tokensUpdated 2 days ago
    Auto-check passed
  • Openclaw History Ingest

    Ar9av/obsidian-wiki

    Ingest OpenClaw session/history data into Obsidian as distilled knowledge.

    3.5k GitHub stars~2.5k tokensUpdated 2 days ago
    Auto-check: notes
  • Wiki Capture

    Ar9av/obsidian-wiki

    Turn the current conversation or finding into a structured permanent wiki note.

    3.5k GitHub stars~4.3k tokensUpdated 2 days ago
    Auto-check: notes

Works with

Questions about Wiki Rebuild

What does Wiki Rebuild do?

Archive and rebuild wiki knowledge from source, or restore a prior archive. Wiki Rebuild is an agent skill from Ar9av/obsidian-wiki. Archive and rebuild wiki knowledge from source, or restore a prior archive.

When should I use Wiki Rebuild?

Wiki Rebuild fits situations like: full restart/recovery when incremental repair is inappropriate; this is broader and more destructive than ordinary update.

How do I install Wiki Rebuild in Claude Code?

Run `npx skills add Ar9av/obsidian-wiki --skill wiki-rebuild -a claude-code`. Or copy the skill folder (.skills/wiki-rebuild in Ar9av/obsidian-wiki) into .claude/skills/wiki-rebuild in your project. Claude Code loads it when a task matches its description.

How do I install Wiki Rebuild in Codex?

Run `npx skills add Ar9av/obsidian-wiki --skill wiki-rebuild -a codex`. Or copy the skill folder (.skills/wiki-rebuild in Ar9av/obsidian-wiki) into .agents/skills/wiki-rebuild in your project. Codex loads it when a task matches its description.

Can I use Wiki Rebuild in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Ar9av/obsidian-wiki --skill wiki-rebuild -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/wiki-rebuild, .gemini/skills/wiki-rebuild, .github/skills/wiki-rebuild and .opencode/skills/wiki-rebuild in your project.

What does Wiki Rebuild need to run?

SKILL.md names no scripts, command-line tools or credentials: Wiki Rebuild is instructions for the agent only.

Does Wiki Rebuild access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Wiki Rebuild safe to install?

Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Wiki Rebuild use?

Wiki Rebuild is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Wiki Rebuild use?

About 1.9k tokens (SKILL.md is roughly 7.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Wiki Rebuild?

Skills that share tags, products or a category with Wiki Rebuild: LLM Wiki (lewislulu/llm-wiki-skill, 655 stars), LLM Wiki (zosmaai/pi-llm-wiki, 608 stars), LLM Wiki (praneybehl/llm-wiki-plugin, 118 stars) and Karpathy Wiki (SherwinQ/karpathy-wiki, 114 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Wiki Rebuild?

Ar9av (a GitHub user) maintains it in Ar9av/obsidian-wiki, which has 3,544 GitHub stars. The repository holds 39 skills in this directory. The repository was last updated on October 8, 2026.

Source: Ar9av/obsidian-wiki on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.