kb-search
Skill80 starsChanged 6 months agoMITView on GitHub
Search a project's markdown knowledge base (docs/, README files, *.md) via the GitMark CLI — FTS5 ranking (bm25) plus trigram/fuzzy matching — instead of grepping across files. Use when you need to find where something is documented, "where do the docs say X", before reading files at random, or to generate an HTML overview/graph of the knowledge base. Handles substrings, typos, and non-Latin scripts.
5 other projects use a version of this.
Adopted by
Most recently taken up by
- EthanReedLabs/suldetheir own version, first seen Sep 13, 2026
- dingshuxin353/ai-knowledge-vaulttheir own version, first seen Sep 8, 2026
- Azure/azure-sdk-toolstheir own version, first seen Aug 31, 2026
- gumbertnntu-cloud/hermes-kb-searchtheir own version, first seen Jun 24, 2026
- GoogleCloudPlatform/knowledge-catalogtheir own version, first seen May 13, 2026
Other versions5 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 5
- GoogleCloudPlatform/knowledge-catalog★ 9.4ksame name
- Azure/azure-sdk-tools★ 134same name
- EthanReedLabs/sulde★ 99same name
- dingshuxin353/ai-knowledge-vault★ 18same name
- gumbertnntu-cloud/hermes-kb-search★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 1 is distinctive, and 1 is very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 20
Before reading files at random — locate the exact spots first.
- Very specific: line 39
If the index may be stale (docs changed) → gitmark index.
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
GitMark — knowledge-base search
This plugin treats the repo's markdown as a md + README(index) + git knowledge base.
Markdown is the source of truth; the search index and HTML map are derived and
regenerated from md (.gitmark/ is gitignored). The CLI is pure Python stdlib.
Script: ${CLAUDE_PLUGIN_ROOT}/skills/kb-search/gitmark.py (when run as a project-local
copy, it's .claude/skills/kb-search/gitmark.py).
When to use
- You need to find where something is documented →
gitmark search, not agrep/rgfan-out. Results arefile:line · heading · snippet. - "How does X work here", "where are the docs for Y".
- Before reading files at random — locate the exact spots first.
- Want an overview/graph of the KB →
gitmark map.
Commands
G="python3 ${CLAUDE_PLUGIN_ROOT:-.claude/plugins/gitmark}/skills/kb-search/gitmark.py"
$G index # (re)build .gitmark/index.db (fast)
$G search "<query>" # bm25 + trigram(substring) + fuzzy(3-gram); -k N, --json
$G map -o docs-map.html # self-contained HTML: tree + rendered md + radial graph
$G serve -p 8799 # local http server to view the map
$G stat # files/chunks/links/index state
$G lint [paths…] # ontology check (frontmatter/links/README/broken links)
$G versionWorkflow
- If the index may be stale (docs changed) →
gitmark index. gitmark search "<terms>"— typos and morphology are tolerated (trigram/fuzzy).[bm25]= exact term,[trigram]= substring,[fuzzy]= n-gram (typos/forms).- Open the returned
file:lineand read the exact place. --jsonfor machine-readable results.
Principles
- Markdown is the source of truth. Edit knowledge in
.md, never the index. - Don't commit
.gitmark/(it's in.gitignore). - Index is a cache — if results look stale, rebuild with
gitmark index --force. - How to maintain the KB (ontology, file placement) — see the
kb-curateskill.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

