aik-mcp
Enables AI agents to discover, read, search, and install Markdown-based knowledge (rules, skills, workflows) from a local directory via MCP tools.
README
<p align="center"> <h1 align="center">aik-mcp</h1> <p align="center"> <em>AI Knowledge Repository — MCP Server</em> </p> <p align="center"> <a href="https://www.npmjs.com/package/@headwood/aik-mcp"><img src="https://img.shields.io/npm/v/@headwood/aik-mcp?style=flat-square&logo=npm" alt="npm version"></a> <a href="https://github.com/openhoat/aik-mcp/actions/workflows/ci.yml"><img src="https://img.shields.io/github/actions/workflow/status/openhoat/aik-mcp/ci.yml?branch=main&style=flat-square&logo=github&label=CI" alt="CI"></a> <a href="https://github.com/openhoat/aik-mcp/blob/main/LICENSE"><img src="https://img.shields.io/npm/l/@headwood/aik-mcp?style=flat-square" alt="license"></a> <a href="https://nodejs.org/"><img src="https://img.shields.io/node/v/@headwood/aik-mcp?style=flat-square" alt="node version"></a> <a href="https://github.com/openhoat/aik-mcp"><img src="https://img.shields.io/github/last-commit/openhoat/aik-mcp?style=flat-square&logo=git" alt="last commit"></a> <a href="https://github.com/openhoat/aik-mcp/issues"><img src="https://img.shields.io/badge/PRs-welcome-brightgreen?style=flat-square" alt="PRs welcome"></a> </p> </p>
aik-mcp is an MCP server that turns a directory of Markdown files into a queryable knowledge base for any MCP-compatible AI agent — opencode, Claude Code, Cline, and others.
Write rules, skills, workflows, and templates as plain Markdown files with frontmatter. Your AI agent can then discover, read, search, and install them at runtime.
Table of Contents
- Installation
- Quick start
- Client configuration
- Environment
- CLI options
- MCP tools
- Resources
- Content structure
- Development
- Contributing
- License
Installation
# Run directly (no install)
npx aik-mcp
# Install globally
npm install -g aik-mcp
aik-mcp
# From a local build
git clone https://github.com/openhoat/aik-mcp.git
cd aik-mcp
npm install
npm run build
Quick start
1. Create a content directory
mkdir -p my-knowledge/rules my-knowledge/skills my-knowledge/workflows
2. Add a rule
cat > my-knowledge/rules/typescript.md << 'EOF'
---
title: TypeScript Conventions
description: Coding standards for TypeScript projects
tags: [typescript, conventions]
version: "1.0.0"
compatibility: [opencode, claude-code, cline]
---
# TypeScript Conventions
- Use explicit types for public API surfaces
- Prefer `interface` over `type` for object shapes
- Use `const` assertions for literal values
EOF
3. Start the server
AIK_CONTENT_DIR=./my-knowledge aik-mcp
4. Configure your AI agent
See Client configuration below.
5. Ask your agent
Once connected, your agent can use tools like aik_search and aik_get to find and apply your knowledge.
Client configuration
opencode
Add to your project's .mcp.json:
{
"mcpServers": {
"aik": {
"command": "npx",
"args": ["aik-mcp"],
"env": {
"AIK_CONTENT_DIR": "/path/to/your/content",
"LOG_LEVEL": "info"
}
}
}
}
Claude Code
Add to your project's .mcp.json (or ~/.claude/settings.json for global use):
{
"mcpServers": {
"aik": {
"command": "npx",
"args": ["aik-mcp"],
"env": {
"AIK_CONTENT_DIR": "/path/to/your/content",
"LOG_LEVEL": "info"
}
}
}
}
Cline
Add to your cline.json or project .mcp.json:
{
"mcpServers": {
"aik": {
"command": "npx",
"args": ["aik-mcp"],
"env": {
"AIK_CONTENT_DIR": "/path/to/your/content",
"LOG_LEVEL": "info"
}
}
}
}
Tip: Set
AIK_CONTENT_DIRto a shared location (Dropbox, git repo, etc.) to use the same knowledge base across projects and agents.
Environment
| Variable | Description |
|---|---|
AIK_CONTENT_DIR |
Path to the content directory (default: current working directory) |
LOG_LEVEL |
Log level: trace, debug, info, warn, error, silent (default: info) |
CLI options
| Flag | Description |
|---|---|
--http |
Start in HTTP mode (default: stdio) |
--port <n> |
HTTP port (default: 3456) |
--no-watch |
Disable file watching |
MCP tools
| Tool | Description |
|---|---|
aik_list |
List content items, optionally filtered by category or tag |
aik_get |
Retrieve a specific item by path (e.g. rules/typescript) |
aik_search |
Full-text fuzzy search across all content |
aik_write |
Create or update a content item |
aik_delete |
Delete a content item |
aik_install |
Install an item into the project's agent config |
aik_reinstall |
Uninstall + reinstall the latest version of an item |
aik_uninstall |
Remove an installed item from the project |
aik_uninstall_all |
Remove all aik-installed items from the project |
aik_list_installed |
List items currently installed in the project |
Resources
aik://{category}— list items in a category (e.g.aik://rules)aik://search?q=...— search items by keyword
When working on a task
- Use
aik_listoraik_searchto find relevant content - Use
aik_getto read specific items - Apply the relevant rules, follow the workflows, and invoke skills as needed
Content structure
Content items are organized by category:
| Directory | Content |
|---|---|
rules/ |
Coding standards, workflows, conventions |
skills/ |
Reusable instruction blocks |
workflows/ |
Multi-step workflow definitions |
agents/ |
Specialized agent definitions |
commands/ |
Custom command definitions |
templates/ |
Project/component templates |
Adding content
Create a .md file with frontmatter in the appropriate category directory:
---
title: "My Rule"
description: "Description of the rule"
tags: [tag1, tag2]
version: "1.0.0"
compatibility: [opencode, claude-code, cline]
---
# My Rule
Content here...
Development
npm install
npm run build
npm run test
npm run qa
Commands reference
| Script | Description |
|---|---|
npm run build |
Compile TypeScript to dist/ |
npm test |
Run Jest test suite |
npm run qa |
Lint + format check (Biome + markdownlint) |
npm run qa:fix |
Auto-fix lint and formatting issues |
npm run validate |
Run qa + build + test (same as CI) |
Contributing
Contributions are welcome! Please open an issue or submit a PR.
See the changelog for release history.
License
MIT
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。