deepwiki-to-skill/SKILL.md
Converts DeepWiki documentation from a GitHub repository into a reusable local skill (Cursor, Agent Zero, OpenCode, or any harness using SKILL.md + references/). Verifies DeepWiki tool access, captures raw wiki structure and contents, splits pages into stable reference files, rebuilds a linked hierarchy, and generates a concise SKILL.md with progressive disclosure. Use when the user asks to "convert DeepWiki to a skill", "make a skill from this repo's wiki", "turn DeepWiki into references", "document this GitHub repo as a skill", or wants reusable per-repo documentation derived from DeepWiki output. Do NOT use when the repo has no DeepWiki coverage, when generating skills from source code (use create-skill instead), or for ad hoc repo Q&A (call DeepWiki MCP directly).
npx skillsauth add pottedmeat/skills deepwiki-to-skillInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Convert DeepWiki wiki structure and wiki content output into a local skill (Cursor, Agent Zero, OpenCode, or any harness consuming a SKILL.md + references/ layout) with progressive disclosure: a concise SKILL.md plus references/*.md files loaded on demand.
references/_slug-map.json. Never recompute slugs independently in step 4.--- inside page bodies as content. Strip only the synthetic page-boundary separator (a trailing --- immediately before the next # heading).scripts/split-pages.js or scripts/build-structure.js is missing or fails, stop and ask the user to restore it. Re-deriving slug rules across runs breaks determinism and silently corrupts structure links.name and description. Harness-specific fields (allowed-tools, version, etc.) are not portable across Cursor / OpenCode / Agent Zero / Claude Code.Use this skill when the user:
Do not use this skill when:
owner/repo form.cursor/skills/<skill-dir>/) or a personal skill (~/.cursor/skills/<skill-dir>/)<skill-dir>/SKILL.md already exists at the chosen destination, warn before overwritingBefore doing any conversion work:
wiki or deepwiki.repoName, returns a hierarchical bullet list (typically read_wiki_structure).repoName, returns a single markdown blob with # Page: markers (typically read_wiki_contents)..cursor/skills/<skill-dir>/ vs ~/.cursor/skills/<skill-dir>/, or the equivalent for Agent Zero / OpenCode / Claude Code).<skill-dir>/SKILL.md already exists at the chosen destination, warn before overwriting.Call the DeepWiki MCP tools that read:
repoName: "owner/repo"repoName: "owner/repo"Create the output directory at the user-selected destination:
<chosen-skill-root>/<skill-dir>/
├── raw/
│ ├── wiki-structure.txt
│ └── wiki-contents.md
Directory naming rule:
react-native-gifted-charts, next.js, or prisma<owner>-<repo> only when the repo name is generic or ambiguous, such as vercel-ai for vercel/aiSave the structure output to raw/wiki-structure.txt and the content output to raw/wiki-contents.md.
Stop immediately and report the exact problem if either MCP call:
Do not continue with partial input.
Split raw/wiki-contents.md by # Page: [Title] markers into references/*.md.
Required invariants:
\n# Page: and the first page starts at line 1 with no leading delimiter# Overviewslug.md, slug-2.md, slug-3.md--- only when it is the synthetic DeepWiki page separator at the page boundary before the next page body begins with #Run the bundled splitter from the chosen skill directory:
node <skill-dir>/scripts/split-pages.js raw/wiki-contents.md references
The script writes the reference files plus references/_slug-map.json. If the script is missing or fails, stop and report the failure — do not reimplement it inline. Re-deriving slug rules across runs breaks determinism and silently corrupts structure links.
After splitting:
references/_slug-map.json exists and is non-emptyProduce a hierarchical Markdown list linking each structure item to the correct reference file.
Required invariants:
references/_slug-map.json; if it is missing, stop and rerun step 3references/*.mdSKILL.mdRun the bundled structure builder and capture its stdout:
node <skill-dir>/scripts/build-structure.js raw/wiki-structure.txt references
If the script is missing or fails, stop and report the failure — do not reimplement it inline. Recomputing slugs in this step (instead of consuming _slug-map.json) is the most common cause of broken structure links.
Before continuing, verify that every generated link target exists on disk.
Choose 1 to 3 reference files that best represent what an LLM needs in order to understand the project.
Selection (deterministic):
/architecture|overview|concepts|design|internals/i./api|schema|model|data|reference/i.Validation (after selection):
references/.Before proceeding, confirm that all selected reference paths resolve to real files.
SKILL.mdRead the selected reference files and the generated structure list, then write the final SKILL.md into the chosen skill directory.
Required frontmatter:
---
name: <skill-name>
description: <what the skill does>. Use when <trigger scenarios>.
---
Frontmatter rules:
Body rules:
references/*.mdReference-file enhancement:
Before you consider the conversion complete, verify all of the following:
raw/wiki-structure.txt exists and is non-emptyraw/wiki-contents.md exists and is non-emptyreferences/*.md file existsreferences/_slug-map.json exists and is non-emptyreferences/*.md fileSKILL.md contains valid YAML frontmatterSKILL.md body stays under 500 linesSKILL.md includes the hierarchical reference listIf any validation check fails, stop and fix it before returning success.
These rules apply during page splitting:
# Page: [Page Title] marks the start of each page in the wiki-contents output--- inside page content is valid markdown and must not be treated as a delimiter by default--- as the synthetic DeepWiki page separator only when the current page ends with --- and the immediately following content begins with a # heading for the next page bodyInput (raw/wiki-contents.md):
# Page: Overview
# Overview
Intro paragraph.
---
# Page: Architecture
# Architecture
Layered system…
Output:
references/overview.md — body starts with # Overview. The trailing --- is stripped because it preceded a # heading (synthetic page boundary).references/architecture.md — body starts with # Architecture.references/_slug-map.json — { "entries": [ { "title": "Overview", "filename": "overview.md", ... }, { "title": "Architecture", "filename": "architecture.md", ... } ] }Helper scripts live in the same skill directory as this SKILL.md. They are required, not optional — if a script is missing, stop and ask the user to restore it (e.g. from a fresh checkout) rather than reimplementing inline:
scripts/split-pages.js — splits wiki contents into reference files and writes references/_slug-map.jsonscripts/build-structure.js — reads references/_slug-map.json and produces the hierarchical markdown listscripts/reference.md — load on demand for the page-delimiter, structure-list, and slug rulesAppend a one-line note to docs/learnings.md recording the failure mode and the repo. This builds a lightweight retrospective so future runs can anticipate edge cases (e.g. "vercel/ai — slug collision on three Reference pages", "supabase/supabase — # Page: markers missing from contents output").
tools
Ports a Claude-style plugin folder into another agent harness (Cursor, OpenCode, Agent Zero, Codex CLI, etc.) by scanning for Claude-specific constructs, researching the target harness's conventions, and rewriting files in place. Use when the user asks to "port this plugin to {harness}", "adapt this Claude plugin for {harness}", "convert plugin to {harness}", "install this plugin in {harness}", "migrate plugin to {harness}", "translate plugin for {harness}", or "retarget plugin to {harness}". Do NOT use for creating new skills (use create-skill instead), installing a Claude plugin inside Claude Code itself, or general code refactoring unrelated to plugin format conversion.
testing
Analyzes version control diffs and generates pull request descriptions optimized for senior engineer audiences. Provides structured descriptions with context, specific changes, testing plans, and breaking change detection.
development
A persistent, curious discussion partner that keeps settled understanding in `docs/brainstorm/[topic].md` while the real exploration stays in chat. Use when exploring options, thinking through decisions, or fleshing out ideas before implementation. Triggers: "help me think through", "let's brainstorm", "what are my options", "trying to decide". Not for implementation or code review.
tools
Use when work should span one or more detached tasks but still behave like one job with a single owner context. TaskFlow is the durable flow substrate under authoring layers like Lobster, ACPX, plugins, or plain code. Keep conditional logic in the caller; use TaskFlow for flow identity, child-task linkage, waiting state, revision-checked mutations, and user-facing emergence.