skill2mcp
skill2mcp

skill2mcpは、SKILL.mdドキュメントをMCP対応のツール定義に変換し、単一のファイルまたはスキルディレクトリ全体から最小限のデプロイ可能なMCPサーバーパッケージを生成するTypeScript CLI/ライブラリです。
生成されたサーバーは公式のMCP TypeScript SDK (@modelcontextprotocol/sdk) を使用し、stdio、http、またはboth(両方)のトランスポートをサポートしています。
このプロジェクトの目的
SKILLドキュメントは通常、半構造化されたマークダウン(フロントマター + 本文 + テーブル)です。MCPツールには厳密なコントラクト(name、description、inputSchema)が必要です。
skill2mcpは、以下の階層化されたパイプラインでそのギャップを埋めます:
マークダウンを安定した中間表現(IR)に解析する
IRをMCPツール定義に変換する
ハンドラスタブを含むデプロイ可能なMCPサーバーパッケージを生成する
Related MCP server: Skillz
現在のステータス
MVP(実用最小限の製品)が実装され、動作しています:
決定論的パーサー (
strict,tolerant)不足しているメタデータのフォールバック用カスケードセマンティックモード (
semantic)ツール変換 (
SchemaBuilder,ToolMapper,ToolValidator)MCPスタイルのツールJSONを出力する
inspectコマンドデプロイ可能なMCPサーバーパッケージを出力する
buildコマンド生成されたサーバーは
stdio+httpをサポート反復的な再生成のための
build --watch
インストール
要件
Node.js 20以上
npm 10以上
ローカルインストール
npm installCLIのビルド
npm run buildクイックスタート
1. 単一のSKILLを解析する
npm run parse -- ./fixtures/skills/valid-skill.md --mode strict2. 生成されたツール定義を検査する
npm run inspect -- ./fixtures/skills --mode tolerant3. デプロイ可能なMCPサーバーパッケージを生成する
npm run gen -- ./fixtures/skills --out ./generated/mcp-server --transport both --mode tolerant4. 生成されたサーバーを実行する
cd ./generated/mcp-server
npm install
npm run build
npm run start:stdio
# or
npm run start:httpHTTPエンドポイント:
POST /mcpCLIリファレンス
parse
SKILLマークダウンをIR JSONに変換します。
skill2mcp parse <input> [--mode strict|tolerant|semantic]引数:
<input>:.mdファイルまたはディレクトリへのパス
オプション:
--mode: パーサーモード(デフォルトはtolerant)--format: 現在はjson
出力:
解析された
SkillDocumentを含むresults[]ソースファイルごとの
diagnostics[]
inspect
解析されたIRをMCPライクなツール定義に変換します。
skill2mcp inspect <input> [--mode strict|tolerant|semantic]出力:
tools[]: 生成されたツール定義 (name,description,inputSchema)results[]: ソースごとのツール + 診断情報
build
1つまたは複数のスキルからデプロイ可能なMCPサーバーパッケージを生成します。
skill2mcp build <input> --out <dir> [--transport stdio|http|both] [--mode strict|tolerant|semantic] [--watch]引数:
<input>:.mdファイルまたはディレクトリへのパス
必須オプション:
--out: 生成されたパッケージの出力ディレクトリ
オプション:
--transport: デフォルトの生成サーバートランスポート(デフォルトはboth)--mode: 解析モード(デフォルトはtolerant)--watch: ソース変更時にパッケージを再生成する
出力:
生成されたパッケージファイル (
package.json,tools.json,src/server.ts, ハンドラ)JSON形式の診断サマリー
解析モード
strict
必須のメタデータ/スキーマが不足している場合に失敗します
CIの品質ゲートに最適です
tolerant
フィールドが不足していても警告を出して続行します
品質の混在するスキルをバッチ処理するのに最適です
semantic
tolerant解析から開始しますOpenRouter(設定時)を通じてセマンティック抽出を試みます
未解決のフィールドに対して決定論的なフォールバック推論を適用します
診断トレース (
SEMANTIC_*コード) を保持します
semantic モードのためのOpenRouter設定
環境変数:
OPENROUTER_API_KEY: リモートセマンティック抽出を有効にしますOPENROUTER_MODEL(オプション): デフォルトはanthropic/claude-3.5-sonnetSKILL2MCP_CACHE_DIR(オプション): キャッシュディレクトリを上書きしますOPENROUTER_HTTP_REFERER(オプション): OpenRouterヘッダーとして転送されますOPENROUTER_X_TITLE(オプション): OpenRouterヘッダーとして転送されます
キャッシュの動作:
セマンティック応答はコンテンツハッシュによって
.skill2mcp-cache/semantic-openrouter-cache.jsonにキャッシュされますキャッシュが存在する場合、セマンティックモードはキャッシュを再利用し、余分なリモート呼び出しを回避します
標準的な SKILL.md フォーマット(推奨)
---
name: docx-generator
version: 1.0.0
description: Generate Word docs from structured markdown
tags: [documents, office]
---
## Parameters
| Name | Type | Required | Default | Description |
|------|------|----------|---------|-------------|
| content | string | yes | | Markdown content |
| title | string | yes | | Document title |
## Examples
**Input:** `{ content: "# Hello", title: "Report" }`
**Output:** report.docx generated at /outputs/
## Triggers
- "generate document"
- "create report"生成されるパッケージ構造
generated/mcp-server/
package.json
tsconfig.json
README.md
tools.json
src/
server.ts
generated-tools.ts
handlers/
index.ts
<tool_name>.ts開発
スクリプト
npm run build # compile TypeScript
npm run test # run test suite
npm run parse # parse command entry
npm run inspect # inspect command entry
npm run gen # build command entryテストスイート
現在の自動化されたカバレッジには以下が含まれます:
パーサーの動作 (
strict,tolerant,semantic)スキーマビルダーとツールマッピング
inspectコマンドの出力コントラクト
エンドツーエンドのビルド成果物生成
エンジニアリングの慣習
AGENTS.mdのリポジトリコラボレーションルールに従うこと製品/ビジネスの指示は
ROADMAP.mdに準拠することAIが生成したコミットメッセージには
[AI]プレフィックスを使用すること
リリース成果物
このリポジトリには以下が含まれます:
デュアルライセンス配布:
MIT OR Apache-2.0CHANGELOG.mdCONTRIBUTING.mdRELEASE_CHECKLIST.md
コラボレーションモデル
ガバナンスと決定ルール:
GOVERNANCE.md行動規範:
CODE_OF_CONDUCT.mdセキュリティ報告:
SECURITY.mdサポートチャンネル:
SUPPORT.md
既知の制限事項
パラメータ解析は現在
## Parameters内のマークダウンテーブル形式を前提としていますセマンティックモードは不足しているメタデータを優先し、抽出が可能な場合は不足しているパラメータを補完する可能性があります
ウォッチモードは現在のツリーを追跡します。後から深くネストされたフォルダが追加された場合は、完全にカバーするためにウォッチを再起動してください
ロードマップの整合性
アクティブな実装は ROADMAP.md の段階的な配信に従います。
GenAI統合ポリシー(有効時)は、ロードマップの指示で定義されている通り、デフォルトのプロバイダ戦略としてOpenRouterを優先します。
ライセンス
以下いずれかのライセンスの下でライセンスされています:
MIT License (
LICENSE-MIT)Apache License 2.0 (
LICENSE-APACHE)
ご自身の選択によります。
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityCmaintenanceConverts AI Skills (following Claude Skills format) into MCP server resources, enabling LLM applications to discover, access, and utilize self-contained skill directories through the Model Context Protocol. Provides tools to list available skills, retrieve skill details and content, and read supporting files with security protections.327Apache 2.0
- Alicense-qualityDmaintenanceTurns Claude-style skills (SKILL.md files with resources) into callable MCP tools for any agent. Discovers skills from a directory, exposes their instructions and resources, and can execute bundled helper scripts.398MIT
- Alicense-qualityDmaintenanceTurns Claude-style skill folders into MCP tools, resources, and prompts for discovering and using skills.81MIT
- Alicense-qualityAmaintenanceExposes an agent's skills as MCP tools, allowing any MCP client to route requests and load skills on demand from a single .3md file.91MIT
Related MCP Connectors
MCP server for skill documentation, generated by doc2mcp.
Generate AGENTS.md, AP2 compliance docs, checkout rules, debug playbook & MCP configs from any repo.
Markdown-first MCP server for Notion API with 8 composite tools and 39 actions.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/agenttic-ai-dev/skill2mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server