Llm Wiki logo

Llm Wiki

Community
staruhub
llm-wiki

Build and maintain a structured LLM-generated wiki for any codebase. Use when the user asks to analyze/understand/document a codebase, build a code wiki, create project documentation from source, or update an existing .llm-wiki. Triggers on phrases like "build wiki", "analyze this codebase", "document this project", "update wiki", "llm-wiki", or when entering an unfamiliar project that has no .llm-wiki yet.

Overview

Publisherstaruhub
RepositoryClaudeSkills
Skill namellm-wiki
Stars
728
Forks
131
Bundled files
2
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 2 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by staruhub on GitHub. Read the source before you install it.

Installation

Install the Llm Wiki AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/staruhub/ClaudeSkills/tree/main/llm-wiki
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/staruhub/ClaudeSkills.git /tmp/ClaudeSkills
mkdir -p .claude/skills
cp -r /tmp/ClaudeSkills/llm-wiki .claude/skills/llm-wiki
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Llm Wiki in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Llm Wiki on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Llm Wiki is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

LLM Wiki for Codebases

Build a persistent, interlinked markdown wiki that captures the architecture, modules, patterns, and APIs of a codebase. The wiki lives in .llm-wiki/ at the project root. Humans curate and direct; the LLM handles all bookkeeping.

Based on Andrej Karpathy's LLM Wiki pattern: raw sources are "compiled" into a structured wiki that compounds over time.

Mode Detection

Determine the mode based on current state:

  • No .llm-wiki/ directory exists -> Full Build mode
  • .llm-wiki/ exists -> Update mode (diff and refresh)

Full Build Workflow

Phase 1: Reconnaissance

  1. Read top-level files: README, package.json/Cargo.toml/go.mod/pyproject.toml/build.gradle etc.
  2. Run find or Glob to map the directory tree (ignore node_modules, .git, vendor, dist, build, pycache, .venv)
  3. Identify: language(s), framework(s), build system, entry point(s), test framework
  4. Count files per directory to gauge module boundaries
  5. Read CLAUDE.md / AGENTS.md / .cursor/rules if present - they contain valuable architectural context

Record findings in .llm-wiki/_schema.md (see references/wiki-schema.md for format).

Phase 2: Skeleton

Create the directory structure:

.llm-wiki/
  _schema.md          # Wiki conventions and project metadata
  _index.md           # Content-oriented catalog by category
  _log.md             # Chronological build/update log
  architecture/       # High-level design docs
  modules/            # Per-module deep dives
  concepts/           # Cross-cutting concepts (auth, caching, error handling...)
  apis/               # API surface docs (REST endpoints, CLI commands, exported functions)
  guides/             # How-to guides (setup, deployment, testing)

Phase 3: Core Articles

Write articles in priority order. See references/article-templates.md for templates.

Priority 1 - Architecture:

  • architecture/overview.md - System architecture, component diagram (ASCII), tech stack
  • architecture/data-flow.md - How data flows through the system
  • architecture/directory-structure.md - Annotated directory tree

Priority 2 - Modules:

  • One modules/<name>.md per major module/package/directory
  • Cover: purpose, key files, public interface, internal patterns, dependencies

Priority 3 - Concepts:

  • Cross-cutting concerns that span modules (auth, logging, error handling, state management, config)
  • One concepts/<name>.md per concept

Priority 4 - APIs:

  • External-facing API surfaces (REST routes, CLI commands, SDK exports)
  • One apis/<name>.md per API group

Priority 5 - Guides:

  • guides/setup.md - Dev environment setup
  • guides/testing.md - How to run and write tests
  • Other guides as relevant

Phase 4: Index and Cross-link

  1. Build _index.md - organized by category with one-line descriptions and links
  2. Ensure every article has a ## See Also section linking to related articles
  3. Add backlinks: if A references B, B should reference A

Phase 5: Lint

Run a health check over the wiki:

  • Broken internal links (references to non-existent .md files)
  • Orphan pages (not linked from _index.md or any other page)
  • Missing coverage (directories/modules with no corresponding article)
  • Stale references (mentions of files/functions that don't exist in codebase)
  • Inconsistent terminology

Fix issues found. Log the lint run in _log.md.

Update Workflow

When .llm-wiki/ already exists:

  1. Read _schema.md to understand project metadata and conventions
  2. Read _log.md to see last update timestamp
  3. Detect changes since last wiki build:
    • git log --since="<last_update>" --name-status if git available
    • Otherwise, compare directory tree against architecture/directory-structure.md
  4. Triage changes:
    • New files/directories -> create new articles or update existing ones
    • Modified files -> re-read and update affected articles
    • Deleted files -> remove references, mark articles for cleanup
    • Renamed/moved files -> update paths in all referencing articles
  5. Update affected articles - re-read source, rewrite sections as needed
  6. Update _index.md if new articles added or old ones removed
  7. Run lint (same as Phase 5 above)
  8. Append to _log.md with timestamp, summary of changes

Writing Guidelines

  • Be factual: describe what the code does, not what it should do. Cite file paths and line ranges.
  • Use code snippets: short inline examples from actual source, not invented ones.
  • Link aggressively: every mention of another module/concept should be a markdown link to its article.
  • Keep articles focused: one topic per article, 100-500 lines. Split if longer.
  • Frontmatter: every article starts with a YAML frontmatter block:
    yaml
    ---
    title: Module Name
    updated: 2026-04-09
    sources:
      - src/module/index.ts
      - src/module/utils.ts
    ---
  • ASCII diagrams over external images - they live in version control and render anywhere.
  • Language: match the project's primary language. If the codebase comments are in English, write in English. If Chinese, write in Chinese.

Agent Coordination

For large codebases (>500 source files), consider dispatching parallel agents:

  • Agent per top-level module to write module articles concurrently
  • One agent for architecture overview after modules are documented
  • One agent for cross-linking and lint

Gitignore

Add .llm-wiki/ to .gitignore only if the user prefers it. By default, the wiki is intended to be committed alongside the code so the team benefits.

Key Principles (from Karpathy)

  1. The wiki is the LLM's domain - humans rarely edit it directly
  2. Knowledge compounds - each query and exploration enriches the wiki
  3. Index files are critical - _index.md enables the LLM to navigate efficiently
  4. Lint regularly - catch rot before it spreads
  5. Log everything - _log.md provides temporal context for future updates

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Llm Wiki AI skill do?

Build and maintain a structured LLM-generated wiki for any codebase. Use when the user asks to analyze/understand/document a codebase, build a code wiki, create project documentation from source, or update an existing .llm-wiki. Triggers on phrases like "build wiki", "analyze this codebase", "document this project", "update wiki", "llm-wiki", or when entering an unfamiliar project that has no .llm-wiki yet.

Why use Llm Wiki on TypingMind?

Because you install it once and use it with any model. Llm Wiki is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Llm Wiki in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/staruhub/ClaudeSkills/tree/main/llm-wiki. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Llm Wiki?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Llm Wiki?

As many as you like. As long as a model supports skills, you can use Llm Wiki with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Llm Wiki AI skill free?

Yes. It is published on GitHub by staruhub under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇