knowledge-base
Skill17 starsChanged 5 months agoMITView on GitHub
Set up a knowledge base with search for an MCP project. Creates FAQ tool and ingestion script using the Waniwani KB API via @waniwani/sdk.
- Reads credentials
20 other projects use a version of this.
Adopted by
Most recently taken up by
- theopenco/llmgatewaytheir own version, first seen Oct 1, 2026
- casoon/ai-agent-configtheir own version, first seen Sep 27, 2026
- zeroclaw-labs/zeroclaw-skillstheir own version, first seen Sep 24, 2026
- jramsahai/obsidian-mcp-braintheir own version, first seen Sep 13, 2026
- simstudioai/skillstheir own version, first seen Sep 9, 2026
- byshahriar/skill-forgetheir own version, first seen Aug 29, 2026
Used with
Projects with it also use standup, orchestrator and 3 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
AnthropicSkillstandup
Generate a standup update from recent activity. Use when preparing for daily standup, summarizing yesterday's commits and PRs and ticket moves, formatting work into yesterday/today/blockers, or structuring a few rough notes into a shareable update.
Also in 3 projects that use this
tesla0225Skillorchestrator
Issue/要件を受けたら分解→担当割当→実装→検証→統合を回す手順。未整備なら /repo-init でbootstrap。
Also in 3 projects that use this
Microsoft AzureSkillskill-authoring
Write Agent Skills that comply with the agentskills.io specification. WHEN: "create a skill", "new skill", "write a skill", "skill template", "skill structure", "review skill", "skill PR", "skill compliance", "SKILL.md format", "skill frontmatter", "skill best practices". DO NOT USE FOR: general documentation. INVOKES: vally CLI.
Also in 3 projects that use this
GoogleSkillcode-reviewer
Also in 3 projects that use this
AnthropicSkillverify
Drive the contracts engine's runtime surface (the stdio MCP server) to verify changes end-to-end. Scoped to public-plugins/plugins/healthcare/skills/contracts/ and ../../servers/documents/.
Also in 3 projects that use this
Other versions20 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 20
- theopenco/llmgateway★ 1.7ksame name
- JKHeadley/instar★ 81same name
- svy04/ballast★ 74same name
- zeroclaw-labs/zeroclaw-skills★ 65same name
- shinpr/rashomon★ 19same name
- unisone/openclaw-config★ 13same name
- claude-office-skills/claude-office-plugin★ 9same name
- ingpoc/SKILLS★ 9same name
- jacobrask/claude-skills★ 5same name
- TTflysky/sirenhuisuo★ 4same name
10 more not listed
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.
In this repository24 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- agent-browserSkill
- copySkill
- deploy-prodSkill
- linear-oneshotSkill
- project-planningSkill
- project-updateSkill
- pull-requestSkill
- wani-code-reviewSkill
- create-flow-appSkill
- frontend-designSkill
- release-migrationSkill
- translationsSkill
- visualize-flowSkill
- audit-trackingSkill
- instrument-trackingSkill
- migrate-waniwani-sdk-0.15-to-0.16Skill
- migrate-waniwani-sdk-0.16-to-0.17Skill
- migrate-waniwani-sdk-0.17-to-0.18Skill
- migrate-waniwani-sdk-0.18-to-0.19Skill
- migrate-waniwani-sdk-0.19-to-0.20Skill
- migrate-waniwani-sdk-0.22-to-0.23Skill
- waniwani-sdkSkill
The file
We split this skill into the rules it gives an agent
7 rules. 0 are common, 1 is distinctive, and 6 are very specific to this project.
0
Common
Most of the 16 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 10
Add semantic search over markdown documents to an MCP project using the Waniwani KB API (client.kb).
- Very specific: line 22
Look in lib/ for the directory that isn't shared — that's the MCP name.
- Distinctive: line 28
Ask the user: "Do you have .md files to add to the knowledge base, or should I create an example file?"
- Very specific: line 30
If no files provided, create lib/{MCP_NAME}/knowledge-base/knowledge/example.md:
- Very specific: line 46
Create scripts/kb-ingest.ts (create scripts/ directory if it doesn't exist):
- Very specific: line 148
Call it where the server is built, inside the withWaniwani wrapper:
- Very specific: line 177
Run bun run kb:ingest after adding or updating .md files
“Common” is measured: kept by at least 6 in 10 of the 16 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
Set Up Knowledge Base
Add semantic search over markdown documents to an MCP project using the Waniwani KB API (client.kb).
Prerequisites
- Project must already be initialized (no
{{MCP_NAME}}placeholders) @waniwani/sdkmust be installedWANIWANI_API_KEYmust be set in the environment
Steps
1. Detect MCP name
Look in lib/ for the directory that isn't shared — that's the MCP name. Store as {MCP_NAME}.
2. Create knowledge directory
Create lib/{MCP_NAME}/knowledge-base/knowledge/ directory.
Ask the user: "Do you have .md files to add to the knowledge base, or should I create an example file?"
If no files provided, create lib/{MCP_NAME}/knowledge-base/knowledge/example.md:
# Example Knowledge Base
## What is this?
This is an example knowledge base entry. Replace this file with your own .md files containing information you want your AI assistant to be able to search through.
## How does it work?
Each .md file is split into chunks by H2 headings. The H1 title provides context for each chunk. Run `bun run kb:ingest` to upload your knowledge files to the Waniwani API.3. Create the ingestion script
Create scripts/kb-ingest.ts (create scripts/ directory if it doesn't exist):
import { readdir, readFile } from "node:fs/promises";
import { join } from "node:path";
import { waniwani } from "@waniwani/sdk";
const knowledgeDir = join(import.meta.dirname, "../lib/{MCP_NAME}/knowledge-base/knowledge");
const mdFiles = (await readdir(knowledgeDir)).filter((f) => f.endsWith(".md"));
console.log(`Found ${mdFiles.length} knowledge file(s)`);
const files = await Promise.all(
mdFiles.map(async (filename) => ({
filename,
content: await readFile(join(knowledgeDir, filename), "utf-8"),
})),
);
const client = waniwani();
console.log("Ingesting files into knowledge base...");
console.log("Files land in the agent's draft. Publish it in the WaniWani app to make them live.");
const result = await client.kb.ingest(files);
console.log(`Done: ${result.chunksIngested} chunks from ${result.filesProcessed} files`);4. Add ingest script to package.json
Add to scripts:
"kb:ingest": "bun run scripts/kb-ingest.ts"5. Create the FAQ tool
A KB lookup is a single-shot tool, not a multi-step flow, so register it
directly on the MCP server. withWaniwani wraps the server to capture
tool.called and hand the handler a session-scoped client.
Create lib/{MCP_NAME}/tools/faq.ts:
import { waniwani } from "@waniwani/sdk";
import type { McpServer } from "@waniwani/sdk/mcp";
import { z } from "zod";
const client = waniwani();
export function registerFaqTool(server: McpServer): void {
server.registerTool(
"faq",
{
title: "FAQ",
description:
"Answer frequently asked questions. Use this when users ask general questions about the product or service.",
inputSchema: {
question: z.string().describe("The user's question"),
},
annotations: {
title: "FAQ",
readOnlyHint: true,
openWorldHint: false,
destructiveHint: false,
},
},
async ({ question }) => {
const results = await client.kb.search(question, { topK: 5 });
if (results.length === 0) {
return {
content: [
{
type: "text" as const,
text: "I don't have a specific answer for that question.",
},
],
};
}
const text = results
.map((r) => `**${r.heading}**\n${r.content}`)
.join("\n\n---\n\n");
return { content: [{ type: "text" as const, text }] };
},
);
}annotations.title is required by Claude's Connectors Directory, which flags
the server at submission without it. The top-level title does not satisfy it.
6. Register the FAQ tool
Export from lib/{MCP_NAME}/tools/index.ts:
export { registerFaqTool } from "./faq";Call it where the server is built, inside the withWaniwani wrapper:
import { withWaniwani } from "@waniwani/sdk/mcp";
import { registerFaqTool } from "@/lib/{MCP_NAME}/tools";
const server = withWaniwani(new McpServer({ name: "{MCP_NAME}", version: "1.0.0" }));
registerFaqTool(server);7. Ingest knowledge files
bun run kb:ingestThis requires WANIWANI_API_KEY to be set in the environment.
8. Verify
bun run build9. Print summary
Tell the user:
- Knowledge files go in:
lib/{MCP_NAME}/knowledge-base/knowledge/ - Run
bun run kb:ingestafter adding or updating .md files WANIWANI_API_KEYmust be set in the environment- Markdown files should use
# Title(H1) and## Section(H2) structure - A push replaces only the sources it names and lands in the agent's draft. Publish in the app to make it live.
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.

