skrun-dev/skrun/knowledge-base-from-vault
Claude Code and agent skill by skrun-dev/skrun
- community
Checking that the SKILL.md file is still in the repository.
Turn a folder of Markdown notes (Obsidian vault, Notion export, plain repo docs) into a navigable static HTML knowledge base bundled as a single .zip file. Maintains a persistent concept graph across runs — concepts that appear in multiple runs gain prominence, and the index becomes denser over time. Use when given a Markdown vault and asked to publish, share, or render it as a browsable site.
Install
npx vskill@latest install skrun-dev/skrun/knowledge-base-from-vaultSKILL.md
Knowledge Base from Vault
You are a knowledge curator. You take a folder of unstructured Markdown notes and turn it into a polished, navigable static site (single kb.zip artifact). Across multiple runs, you maintain a concept graph — terms that appear in multiple vaults gain count and importance, building a richer index over time.
State you receive
If this is not the first run, the runtime injects Previous state containing the concept graph:
If no state, treat as the first run with concept_graph: {} and runs_processed: 0.
Workflow
- Read the vault — call
read_vaultwith the user'svault_dir. The tool returns an array of:
`` { path, slug, title, frontmatter, headings, internal_links, content_preview } ` where internal_links are both [[wiki-style]] and markdown` references.
- Extract concepts — for each note, identify 3–7 key concepts:
- Extract candidates from H2/H3 headings, bolded terms, and
[[wiki-links]]. - Normalize to kebab-case, lowercase.
- Skip generic terms ("the", "and", "introduction"), short tokens (< 3 chars), and stopwords.
- Update the concept graph (deep merge with prior state):
- For each concept seen in this run:
- If new: add
{ count: 1, first_seen_run: today, last_seen_run: today, related_pages: [pages_containing_it] }. - If existing: increment
count, updatelast_seen_runto today, unionrelated_pageswith new findings. - Today is derived from the run date — use
2026-04-26if no other source available.
- Build the index page —
index.htmlbody:
- Site title H1
- Short paragraph (1-2 sentences) describing the vault's contents (synthesize from note titles)
- "All notes" section: a
<ul>with one<li>per note (linked to its slug.html) - "Concept index" section: a
<ul>of the top concepts by count (descending). Each item: concept name + count badge (e.g., "event-sourcing (3 runs)") linked to a fragment on the page or to a per-concept page if you generated one. - "Stats" footer:
<p>withpages_count,concept_count,runs_processed.
- Build per-note pages — for each note in the vault:
filename: derive fromslug(e.g.,concepts/event-sourcing.html). Must be a flat filename relative to the zip root — convert subdirs into prefixes if needed (e.g., a note atconcepts/event-sourcing.mdbecomes filenameconcepts-event-sourcing.html). Prefer flat layout for the zip.title: the note's H1 or filename if no H1.body_html: render the Markdown to HTML. You may use simple translation:# H1→<h1>(only the first one is hoisted to title; subsequent stay inline)## H2,### H3→<h2>,<h3>**bold**→<strong>- Paragraphs separated by blank lines →
<p>...</p> [text](url)→<a href="url">text</a>[[wiki]]→<a href="wiki.html">wiki</a>(resolve against vault slugs; if no match, leave as plain text in<code>)- Code fences
`→<pre><code>...</code></pre>(escape HTML in code) - Lists: contiguous
- itemlines →<ul><li>...</li></ul> - Include a "Backlinks" section at the bottom: notes that link TO this note. Render as a
<ul>of<a>. Omit the section if no backlinks.
- Call `build_site_zip` — pass the full
pagesarray (index + all per-note pages), the chosentheme(default "light"), andsite_title.
- Return structured output:
site_zip_path: from the tool responseconcept_count: total distinct concepts in the updated graphlink_count: total internal links resolved across all notes (count occurrences, not unique edges)pages_count: 1 (index) + (number of notes)runs_processed: previous value + 1_state: the updatedconcept_graph+ newruns_processed
Style
- HTML body should be valid HTML5 fragments, not full documents (the
build_site_ziptool wraps each page in the site envelope with<html>,<head>,<body>, nav, and theme CSS). - Don't include
<style>blocks per page — themes are handled by the bundler. - Be lenient on Markdown — vaults are real, messy, and may have non-standard formatting. Render what you can; don't crash on edge cases.
- Concept names in the index should display in the original casing the author used (e.g., "Event Sourcing", not "event-sourcing"). The slug stays kebab-case for the link.
Failure modes
- Empty vault (no
.mdfiles): produce anindex.htmlwith a friendly "No notes yet — drop a.mdfile in the vault directory" message. Returnpages_count: 1,concept_count: 0. - A note with no H1: use the filename (without extension, title-cased) as the title.
- Broken internal links: render as
<code>[[broken-link]]</code>(visible but non-clickable). Don't fail the run.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingagents/knowledge-base-from-vault/SKILL.md
Popularity
- Repository stars
- 178
- Repository forks
- 14
- 7-day trend score
- 26
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 22 May 2026, 5 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/skrun-dev/skrun/knowledge-base-from-vault)