# Wiki

Bootstrap or reorganize a Markdown knowledge base as an LLM Wiki and multi-repo Home Repo. Use for initializing a knowledge base, migrating an existing wiki to a shared layout, or planning that migration.

**Canonical URL:** https://skillshunter.net/skills/discovered-281f2931d563141eb06ea72dc4eb01d8fdffc4cfcc83006f

**JSON URL:** https://skillshunter.net/api/public/v1/skills/discovered-281f2931d563141eb06ea72dc4eb01d8fdffc4cfcc83006f

**Markdown URL:** https://skillshunter.net/skills/discovered-281f2931d563141eb06ea72dc4eb01d8fdffc4cfcc83006f.md

**Instructions download URL:** https://skillshunter.net/skills/discovered-281f2931d563141eb06ea72dc4eb01d8fdffc4cfcc83006f/download

**Category:** Content & Editorial

**Source URL:** https://github.com/yanmxa/skills/blob/70106f3e2d6d370f1b285da422235e15663bafac/skills/setup/wiki/SKILL.md

**Source commit:** 70106f3e2d6d370f1b285da422235e15663bafac

**Listing approved at:** 2026-12-02

**Created at:** 2026-11-30T08:50:00.000000Z

**Updated at:** 2026-12-02T09:15:01.000000Z

## Catalog information

The following descriptions are catalog information. Listing approval does not mean the skill has been tested or is safe for every environment.

### Editor's note

Before running the command, confirm the target, audience, and whether to plan or apply. Inspect only that target's Git state, rules, and wiki structure. Do not open secrets or unauthorized originals. For plan-only requests, write nothing.

### When to use it

- Initializing a knowledge base
- Migrating an existing wiki to a shared layout
- Planning a wiki migration

## Skill instructions

---
name: wiki
description: Bootstrap or reorganize a Markdown knowledge base as an LLM Wiki and multi-repo Home Repo. Use for initializing a knowledge base, migrating an existing wiki to a shared layout, or planning that migration. Not for routine lookups, single-page edits, or live project status.
---

# Home Repo Wiki

Use a Home Repo to route work across repositories. Use an LLM Wiki to maintain sourced, linked conclusions without copying raw material or live status.

## Layout

| Path | Purpose |
| --- | --- |
| `AGENTS.md` | Cross-repo rules, source authority, sharing boundaries, and wiki maintenance. |
| `index.md` | Find pages by topic, with one line per entry. |
| `log.md` | Append meaningful changes and why they happened. Skip routine lookups. |
| `repos.md` | Verified repo roles, checkout paths, and clone sources. |
| `references.md` | Shareable sources, external references, and evidence limits. |
| `docs/topics/`, `docs/guides/` | Synthesis and reusable procedures. Create on demand. |
| `raw/`, `repos.local.md` | Optional local originals and restricted pointers; keep out of Git. Git ignore is not access control. |

Keep code and repo-specific rules in their own repos. Preserve existing skill loading conventions; if the host only reads `CLAUDE.md`, point it to `AGENTS.md` rather than duplicating rules.

## Workflow

1. **Scope.** Confirm the target, audience, and whether to plan or apply. Inspect only that target's Git state, rules, and wiki structure. Do not open secrets or unauthorized originals. For plan-only requests, write nothing.
2. **Initialize an empty target.** Create the named directory if needed, then run the command below. A target containing only `.git` is allowed. Without Python 3, copy the [starter files](assets/starter/AGENTS.md) and replace `{{TITLE}}` and `{{DATE}}`. Do not invent sources or repos, create empty content directories, initialize Git, clone siblings, commit, or push.
3. **Migrate an existing wiki.** Map each affected file to its destination, backlinks, and sharing scope. Merge rules and content instead of overwriting them. Preserve evidence, contradictions, log history, originals, and unrelated changes. Move only authorized pages; ask before deleting a page. Keep restricted pointers out of shared files and reports. If private content is already tracked, pause that part and ask how to handle it.
4. **Finish.** Update affected links, index entries, and references. Record actual changes in `log.md` as `## [YYYY-MM-DD] lint | Title` (or `ingest` or `query` as appropriate). Leave a compliant wiki unchanged. Check the layout and diff, verify that local-only paths are ignored and untracked, then report changes and open decisions.

```sh
python3 "<skill-dir>/scripts/wiki_layout.py" init "<target>" --title "<wiki title>"
python3 "<skill-dir>/scripts/wiki_layout.py" check "<target>"
```

Use the skill's installed path for `<skill-dir>`. `check` is read-only and verifies required files, index coverage, and local inline links. It does not certify permissions or verify source claims.

## Split only when needed

- **Index:** keep `index.md` as the entry point; add category indexes when the flat list is hard to scan. Update validation to follow explicit subindexes.
- **Log:** keep recent entries and archive links in `log.md`; archive by time, preserving dates, order, and links.
- **References:** keep `references.md` as the entry point and split lists by evidence domain. Cite authoritative documents or versions from the claims they support.

Do not scaffold these splits up front. When approved, keep root entry points, repair links, and extend validation to the new files.

Based on [Karpathy's LLM Wiki](https://gist.github.com/karpathy/442a6bf555914893e9891c11519de94f) and [The Home Repo Pattern](https://www.aihero.dev/the-home-repo-pattern).

