/llm-code-wiki:setup-wikifrom llm-code-wiki
Sets up the LLM Code Wiki plugin's data root: scaffolds wiki template, records location, and customizes purpose, scope, and repo registry. User-invoked only via /setup-wiki.
Ships in llm-code-wiki. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Run only when the user invokes /setup-wiki. The wiki and deep-research skills ship with
this plugin and are already installed globally; what's missing is the wiki data — the knowledge
base itself. This wizard scaffolds that data at a location the user picks, records where it lives so
every skill can find it, and customizes it. Be friendly and brief; do the mechanical work yourself
and ask the user only what you genuinely cannot infer. Work through the steps in order.
Throughout, $WIKI_ROOT is the absolute path to the user's wiki data. The plugin's bundled files
live at ${CLAUDE_PLUGIN_ROOT} (Claude Code sets this for you).
The pointer file ~/.llm-code-wiki records the wiki's location. First check whether the wiki is
already set up:
cat ~/.llm-code-wiki 2>/dev/null # if this prints a path, a wiki is already registered
constitution.md, the wiki is already
set up — confirm with the user before changing anything (they may just want to re-run a later
step, e.g. add repos or enable validation).~/llm-code-wiki (a standalone folder they'll manage as its own git repo). Set $WIKI_ROOT to
the confirmed absolute path.Copy the plugin's template skeleton into $WIKI_ROOT and write the pointer file:
WIKI_ROOT="$HOME/llm-code-wiki" # the path confirmed in step 0
mkdir -p "$WIKI_ROOT"
cp -R "${CLAUDE_PLUGIN_ROOT}/template/." "$WIKI_ROOT"/ # constitution, CLAUDE.md, repos, scripts, empty vault, docs, .github
printf '%s\n' "$WIKI_ROOT" > ~/.llm-code-wiki # the pointer every skill reads
Confirm $WIKI_ROOT now contains constitution.md, repos.md, scripts/, and wiki/, and that
cat ~/.llm-code-wiki prints the root. Everything below operates on files under $WIKI_ROOT.
Detect the platform and smoke-test the matching script so staleness detection works here.
macOS / Linux (bash):
chmod +x "$WIKI_ROOT/scripts/hash.sh"
echo "hello" > /tmp/_wiki_t.txt
H=$("$WIKI_ROOT/scripts/hash.sh" /tmp/_wiki_t.txt) # prints a hash
"$WIKI_ROOT/scripts/hash.sh" /tmp/_wiki_t.txt "$H" # FRESH
echo "changed" > /tmp/_wiki_t.txt
"$WIKI_ROOT/scripts/hash.sh" /tmp/_wiki_t.txt "$H" # STALE
rm /tmp/_wiki_t.txt
"$WIKI_ROOT/scripts/hash.sh" /tmp/_wiki_t.txt "$H" # MISSING
Windows (PowerShell):
"hello" | Out-File -Encoding utf8 $env:TEMP\_wiki_t.txt
$H = & "$WIKI_ROOT\scripts\hash.ps1" -File $env:TEMP\_wiki_t.txt # prints a hash
& "$WIKI_ROOT\scripts\hash.ps1" -File $env:TEMP\_wiki_t.txt -Recorded $H # FRESH
"changed" | Out-File -Encoding utf8 $env:TEMP\_wiki_t.txt
& "$WIKI_ROOT\scripts\hash.ps1" -File $env:TEMP\_wiki_t.txt -Recorded $H # STALE
Remove-Item $env:TEMP\_wiki_t.txt
& "$WIKI_ROOT\scripts\hash.ps1" -File $env:TEMP\_wiki_t.txt -Recorded $H # MISSING
Report the four verdicts (hash / FRESH / STALE / MISSING). If the tool is missing:
sha256sum/shasum → tell the user to install coreutils.Get-FileHash ships with PowerShell 4+; if missing, update PowerShell.Ask the user, in one or two questions: What is this knowledge base about — its center of
gravity? (e.g. "our payments platform, with competitor repo X as reference," or "the Linux
kernel networking stack"). Then rewrite the ## Purpose & scope section of
$WIKI_ROOT/constitution.md, replacing the <!-- CUSTOMIZE --> placeholder with a pointed
one-paragraph description.
scope: tagAsk whether their knowledge splits into distinct "worlds" worth tagging. Offer common shapes:
ours/theirs, v1/v2, frontend/backend, or none (single world). Update the
### The scope: tag section of $WIKI_ROOT/constitution.md to list the chosen values (or note that
scope: is unused and may be omitted from frontmatter).
Help the user populate $WIKI_ROOT/repos.md. Offer to scan for git repos to suggest rows — scan
near $WIKI_ROOT and/or the directory the user invoked /setup-wiki from:
for d in "$WIKI_ROOT"/../*/ "$WIKI_ROOT"/../*/*/; do [ -d "$d/.git" ] && echo "$(basename "$d") -> $d"; done
For each repo the user wants to track, add a row: name | scope | path | notes. Paths are
relative to $WIKI_ROOT (where repos.md lives), e.g. ../some-repo. Remove the example rows.
Confirm the table with the user.
$WIKI_ROOT/scripts/validate.py enforces the frontmatter schema, source freshness (re-hashing),
and index presence. If the user doesn't want it, skip this step — the files lie dormant and are safe
to delete.
If they do want it:
command -v python3. If absent, tell the user to install it or
skip this step.python3 "$WIKI_ROOT/scripts/validate.py" # should exit 0 (ok)
git init in step 7):
cd "$WIKI_ROOT" && chmod +x scripts/hooks/pre-commit && git config core.hooksPath scripts/hooks
$WIKI_ROOT/.github/workflows/validate.yml (runs
python3 scripts/validate.py --no-repo-hash, since CI can't see sibling code repos). Keep it if
pushing to GitHub Actions; delete it otherwise.Ask whether to:
$WIKI_ROOT its own git repo so the wiki has its own history:
cd "$WIKI_ROOT" && git init && git add -A && git commit -m "Initialize wiki"
$WIKI_ROOT/wiki/log.md to a fresh first entry dated today.$WIKI_ROOT/docs/example-decision-page.md as a format reference, or delete it once the user
is comfortable with the page format. The vault ships empty otherwise.constitution.md).Summarize what changed. The wiki and deep-research skills are already active (installed with the
plugin) and resolve the wiki via ~/.llm-code-wiki — no restart needed. Reassure the user there are
no commands to memorize: just ask in plain English from any repo. Give examples: "scan / read
<repo>" to map a repo, ask any question to research, "save this" to keep a session insight, "check
the wiki" to health-check for out-of-date pages. Suggest opening $WIKI_ROOT/wiki/ as an Obsidian
vault. Remind them: to track a new source repo later, add it to $WIKI_ROOT/repos.md.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub dylannalex/llm-code-wiki --plugin llm-code-wiki3 skills in this plugin
/deep-researchRun a deep, multi-agent research pass over one or more code repositories and file the findings into the LLM Code Wiki. Use when the user wants to map/inventory/survey some theme across repos (e.g. 'research all the X across these repos', 'map every Y', 'deep dive on Z and write it up'), especially when it warrants parallel sub-agents. Grills the user on scope before starting, reads with Sonnet sub-agents, and writes the wiki with an Opus 4.8[1m] sub-agent. Works from any repo; the wiki root is recorded in ~/.llm-code-wiki./wikiAccess the LLM Code Wiki — a persistent, LLM-maintained knowledge base over living code repositories. Use when the user wants to map/scan/read a repo into the wiki, ask a question answerable from accumulated knowledge, add/import a source (article, ticket, note), file/save a session insight into the wiki, or check/audit the wiki for staleness. Works from any repo; the wiki root is recorded in ~/.llm-code-wiki.Other plugins' skills for the same job