mcp-knowledge-base
mcp-knowledge-base
Model Context Protocol (MCP) サーバーで、ノートのナレッジベースを MCP クライアント(Claude Desktop、IDE、または任意のエージェント)に公開します。MCP サーバーが提供する2つの機能、ツール(モデルが呼び出せるアクション)とリソース(モデルが読み取れるデータ)を示しています。TypeScript で書かれ、stdio 上で動作します。
公開内容
ツール (src/server.ts):
ツール | 目的 |
| ナレッジベース全体のキーワード検索(タイトル/タグ/本文を重み付け) |
| 新しいノートを追加 |
| ID で1件のノートを取得 |
リソース: 各ノートは note://{id} で読み取れ、一覧も提供されます。つまりクライアントはツールを呼び出すだけでなく、ナレッジベースをデータとして閲覧できます。
ドメインロジック(ノートストアと検索ランキング)は src/notes.ts にあり、プロトコル層から分離されています。
Related MCP server: simple-mcp-example
MCP クライアントで使う
ビルドしてから、クライアントをバイナリに向けます。たとえば Claude Desktop の claude_desktop_config.json では:
{
"mcpServers": {
"knowledge-base": { "command": "node", "args": ["/abs/path/to/dist/index.js"] }
}
}npm install && npm run build
node dist/index.js # speaks MCP over stdioテスト
npm test2つの層があり、どちらもオフラインで動作します:
ユニット — ノートストアと検索ランキング。
統合 — 実際の MCP
Clientがインメモリトランスポートを介してサーバーと通信します(stdio 経由のクライアントと同じ方法)。ツールの一覧表示、search_notes/add_note/get_noteの呼び出し、note://リソースの読み取りを行います。合計9テスト。
ライセンス
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
Search, read, write, and organize your Scratchpad notes from any MCP client.
Read and write your Caliu notes from any MCP client: search, create, tag, remind, attach files.
Notes, files, GitHub, and Drive through one MCP connection.
Notes, files, GitHub, and Drive through one MCP connection.
Related MCP Servers
- -licenseCqualityDmaintenanceEnables creating and managing text notes through MCP resources and tools. Provides note creation capabilities and automatic summarization of all stored notes.1-
- FlicenseNot gradedqualityBmaintenanceEnables managing local Markdown notes by creating, viewing, listing, and searching notes and their contents through MCP tools.-
- AlicenseNot gradedqualityCmaintenanceEnables creating, retrieving, updating, deleting, and listing notes through a simple MCP interface, with configurable note storage.MIT
- FlicenseNot gradedqualityCmaintenanceEnables managing notes through add, get, update, delete, and list tools via MCP.-