SakuttoWorks-Data-Normalizer
Agent-Commerce-OS MCP サーバー
Sakutto Works データ正規化インフラストラクチャのための公式 Model Context Protocol (MCP) サーバーです。
🚀 概要
このリポジトリは、Project GHOST SHIP (Agent-Commerce-OS) の公式 MCP サーバーを提供します。AI エージェント(Claude Desktop など)が、Polar.sh を介して管理されるゼロトラストな従量課金制 API に自律的に接続できるようにします。この統合により、エージェントは非構造化 Web データを抽出し、クリーンでトークン最適化された Markdown または JSON 形式に正規化できます。
Related MCP server: deltav-edge-mcp-server
✨ 主な機能
🛡️ ゼロトラスト・エッジセキュリティ: Cloudflare エッジでの厳格なプロンプトインジェクション遮断と境界防御。
🧩 MCP ネイティブ: Claude Desktop などの Model Context Protocol クライアントと即座にシームレスな統合が可能。
⚡ Lite GraphQL フィルタリング: オプションの
fields配列を渡すことで、エージェントが必要とする正確なデータノードのみを抽出し、コンテキストウィンドウのトークン消費を劇的に最小化します。💳 完全従量課金制: Polar.sh を利用し、成功した呼び出し 1 回につき $0.10 です。隠れた手数料や強制的なサブスクリプションはありません。
🤖 自律的なエラー復旧: MCP 標準のエラーフォーマット (
isError: true) に厳密に従います。エッジゲートウェイからの402 Payment Requiredや429 Too Many Requestsをインテリジェントに中継し、AI エージェントが予算不足の解決や無限ループの停止を人間に自律的に促すことができます。🔍 分散トレーシングと可観測性: すべてのリクエストには一意の
trace_idが割り当てられ、インフラ全体(ゲートウェイ -> エンジン -> R2 監査ログ)に伝播します。エラー発生時には、この Trace ID がエージェントのテキスト応答に直接挿入されるため、手動でログを探すことなく、即座にピンポイントでデバッグやエンタープライズレベルのサポートが可能です。🔄 高度なルーティング (同期/非同期 & ティアリング): AI エージェントは抽出パイプラインを動的に指示できます。
target_tier(例: Actionable Data, Compliance Check)を指定することで、エンジンはスキーマを適応させます。さらに、webhookURL を渡すことで、エージェントは重い抽出タスクをバックグラウンドにオフロードし(即座に202 Acceptedとジョブ ID を受け取る)、MCP のタイムアウト制限を回避できます。Webhook が提供されない場合、システムは自動的に同期実行にフォールバックします。
🏗️ アーキテクチャ
当社のインフラストラクチャは、3 層のゼロトラストモデルで動作します。全体像については、関連リポジトリをご覧ください。
レイヤー C (本リポジトリ): ローカルの AI エージェントとリモートネットワークを橋渡しするステートレスな MCP サーバー。
レイヤー A (agent-commerce-gateway): ゼロトラスト認証、ルーティング、従量課金請求を処理する Cloudflare Workers。
レイヤー B (agent-commerce-core): 高度な RAG 最適化セマンティックデータ正規化を実行する Google Cloud Run エンジン。
⚙️ 前提条件
Node.js (v18 以上推奨) および npm がインストールされていること。
有効な Polar.sh API Key (従量課金 $0.10 / リクエスト)。公式 API Key チェックアウトから取得してください。
Claude Desktop または標準的な MCP 互換クライアント。
🔌 セットアップと設定 (Claude Desktop)
AI エージェントに正規化ツールへのアクセス権を付与するには、claude_desktop_config.json に以下の設定を追加してください。
macOS
~/Library/Application Support/Claude/claude_desktop_config.json
Windows
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"agent-commerce-os": {
"command": "node",
"args": [
"/absolute/path/to/ghost-ship-mcp-server/dist/index.js"
],
"env": {
"POLAR_API_KEY": "your_polar_api_key_here",
"GATEWAY_URL": "https://api.sakutto.works/v1/normalize_web_data"
}
}
}
}(注: /absolute/path/to/ghost-ship-mcp-server はクローンしたリポジトリの実際の絶対パスに、your_polar_api_key_here は有効な Polar.sh API キーに置き換えてください。)
🧠 自律型 AI エージェント向け
AI エージェントまたは LLM が当社のツールを統合するためにこのリポジトリを解析している場合:
完全なセマンティックコンテキストと機能については、llms.txt をお読みください。
正確なツールスキーマは mcp.json に完全に定義されています。
URL を推測したり合成したりしないでください。必ず公式の Sakutto Works ポータル を参照してください。
🤖 利用可能なツール
StdioServerTransport を介して接続すると、AI エージェントは @modelcontextprotocol/sdk を使用して McpServer インスタンスによって動的に公開されるツールを自動的に検出します。(これらの機能は、外部レジストリ用の mcp.json マニフェストにもカタログ化されています):
normalize_web_data: 非構造化 Web コンテンツを抽出し、LLM コンテキストウィンドウに最適化されたクリーンでセマンティックな Markdown または JSON 形式に正規化します。スキーマフィルタリング (
fields): オプションのfieldsパラメータを介して Lite GraphQL スタイルのフィールド選択をサポートします。これにより、AI エージェントは特定のデータノードのみを要求でき、トークン消費と応答遅延を大幅に最小化できます。指定された場合、サーバーはリクエストをゲートウェイにルーティングする前に、これらのフィールドを URL クエリパラメータとして自動的に追加します。動的抽出ティア (
target_tier): AI エージェントはターゲットスキーマティア(a1,a2など)を指定して、抽出ロジックをその場で変更できます(例: 厳密なアクション可能な可用性データの抽出 vs 標準的な Markdown)。非同期 Webhook (
webhook): 長時間実行される抽出タスクの場合、エージェントはターゲット URL を含むwebhookオブジェクトを提供できます。サーバーは即座にjob_idを返し、エージェントは待機することなく操作を継続できます。耐障害性設計: エージェントが Webhook URL を空にするか完全に省略した場合、サーバーは Webhook ペイロードを安全に無視し、リクエストを同期的に実行して抽出データをリアルタイムで返します。厳格なバリデーション: すべてのツール入力は
zodを使用して厳密に定義および検証され、レイヤー B の基礎となる仕様への堅牢な準拠を保証します。検証後、サーバーはPOLAR_API_KEYを使用して認証された HTTP POST を介して、リクエストをゲートウェイに安全に中継します。
💻 ローカル開発とセットアップ
サーバーをローカルで実行したり、開発環境を準備したりするには:
リポジトリをクローンし、ディレクトリに移動します:
git clone https://github.com/SakuttoWorks/ghost-ship-mcp-server.git cd ghost-ship-mcp-server必要な依存関係(
@modelcontextprotocol/sdkおよびzodを含む)をインストールします:npm install環境変数を設定します:
cp .env.example .env(新しく作成された
.envファイルを開き、POLAR_API_KEYを挿入し、GATEWAY_URLがhttps://api.sakutto.worksまたはhttps://api.sakutto.works/v1/normalize_web_dataのような特定のエンドポイントパスに設定されていることを確認してください。)TypeScript ソースコードをコンパイルします:
npm run buildMCP サーバーを起動します:
npm start
🤝 貢献
オープンソースコミュニティからの貢献を歓迎し、奨励しています!プルリクエストを送信する際は、以下を確認してください:
コードが正常にビルドされること (
npm run build)。すべてのテストがローカルでパスすること (
npx vitestまたは好みのテストランナーを使用)。既存のコードスタイルと標準的な TypeScript の慣習に従っていること。
このプロジェクトは標準的なオープンソース行動規範に従っています。参加することで、敬意を持って協力的なコミュニケーションを維持することが求められます。
🌍 リソースと課題追跡
公式ポータルとエージェントドキュメント: Sakutto Works
GitHub 組織: SakuttoWorks
開発者プロフィール: SakuttoWorks Profile
バグ報告と機能リクエスト: バグの報告や新しい抽出機能の提案には、GitHub Issues ページをご利用ください。
📄 ライセンス
このプロジェクトは ISC ライセンスの下でライセンスされています。責任および自律型エージェントの使用に関する詳細については、LEGAL.md をお読みください。
💖 プロジェクトのサポート
Agent-Commerce-OS がエンジニアリング時間を節約したり、AI ワークフローの拡張に役立った場合は、スポンサーになるか、一度限りのチップを検討してください。皆様の貢献は、サーバーコストの直接的な資金となり、エッジゲートウェイの高可用性を確保し、継続的なオープンソース開発を促進します。
© 2026 Sakutto Works. エージェント経済のためのセマンティック Web の標準化。
Available Tools
1 toolnormalize_web_dataA
Extracts, sanitizes, and normalizes unstructured web content into clean Markdown or JSON. Highly optimized for LLM context windows. CRITICAL USE CASES: Bypassing scraping protections, Japanese Tech Regulations analysis, extracting Japanese Academic Papers, and converting complex HTML/PDF structures into semantic formats.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The target URL to extract and normalize. | |
| format_type | No | Desired output format. Supported values: 'json', 'markdown'. | |
| fields | No | Schema Filtering (Lite GraphQL): Array of fields to extract, minimizing token consumption. | |
| target_tier | No | Extraction schema tier (e.g., 'a1' for async processing, 'a2' for actionable data, 'a3' for compliance). Defaults to standard. | |
| webhook | No | Webhook configuration for asynchronous processing. Required if target_tier is 'a1'. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries burden. It notes it's 'optimized for LLM context windows' and mentions 'bypassing scraping protections', which implies potential risk. But does not disclose auth needs, rate limits, or side effects beyond the listed use cases.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Description is front-loaded with core function and lists use cases in a structured way. Slightly verbose with capitalized 'CRITICAL USE CASES', but overall efficient and readable.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema, but description explains output formats (Markdown/JSON) and use cases. It lacks error handling, size limits, or rate limit info, but for a web extraction tool, it provides sufficient context for an AI agent to decide usage.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with descriptions for each parameter. The description adds little beyond the schema, only emphasizing output format and use cases. Baseline 3 is appropriate as the schema already provides sufficient meaning.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states it extracts, sanitizes, and normalizes web content into Markdown/JSON, with specific use cases listed. Verb+resource+output are explicit, and no sibling tools exist to confuse.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides critical use cases (bypassing scraping protections, Japanese content, complex conversions), giving context on when to use. However, no explicit when-not-to-use or alternatives are mentioned, but since no siblings, it's adequate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
1 tool update
- Changed
normalize_web_data5 fields changed- changed
Input schema / properties / fields / descriptionPrevious value: -"Schema Filtering (Lite GraphQL): Comma-separated list of fields to extract, minimizing token consumption (e.g., 'title,content')."New value: +"Schema Filtering (Lite GraphQL): Array of fields to extract, minimizing token consumption." - added
Input schema / properties / fields / itemsAdded value: +{ + "type": "string" +} - changed
Input schema / properties / fields / typePrevious value: -"string"New value: +"array" - added
Input schema / properties / target_tierAdded value: +{ + "description": "Extraction schema tier (e.g., 'a1' for async processing, 'a2' for actionable data, 'a3' for compliance). Defaults to standard.", + "type": "string" +} - added
Input schema / properties / webhookAdded value: +{ + "additionalProperties": false, + "description": "Webhook configuration for asynchronous processing. Required if target_tier is 'a1'.", + "properties": { + "url": { + "description": "The webhook endpoint URL to receive async results.", + "type": "string" + } + }, + "type": "object" +}
1 tool update
v1.0.0- First observed
normalize_web_data
TDQS
Scored across 1 tool
With only one tool, there is no possibility of confusion between tools. The single tool has a clear, comprehensive purpose.
A single tool name presents no inconsistency issues. The naming is clear and descriptive of its function.
One tool for a broad scope that includes multiple specialized use cases (bypassing scraping protections, extracting academic papers, etc.) feels insufficient. The tool is expected to handle a wide range of operations, likely warranting a few more focused tools.
The tool covers the core extraction, sanitization, and normalization workflow. Minor gaps could exist around configuration options or error handling, but the main domain is addressed.
Maintenance
Related MCP Connectors
Cross-OEM industrial machine intelligence: identity, normalization, automation, attestation.
Security gateway for AI agents: policy, approval, and audited execution, no secrets shared.
Edge content delivery for autonomous agents — signed manifests, A2A authentication
Blockchain SSN for AI agents. MCP gateway that blocks at the point of action, tamper evident audit.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceA centralized gateway platform for aggregating and managing multiple Model Context Protocol (MCP) servers through a single Electron-based interface. It provides enterprise-grade security features including policy-based access control, human-in-the-loop approval workflows, and comprehensive audit logging.-
- AlicenseNot gradedqualityDmaintenanceSafety-conscious MCP server for read-only access to Emerson DeltaV Edge systems, enabling engineering investigation workflows and offline artifact generation.2GPL 3.0
- FlicenseAqualityAmaintenanceCross-OEM industrial machine intelligence. Normalizes telemetry across 16 manufacturer families (Fanuc, Siemens, Haas, DMG Mori, Mazak), enables plain-English operational automation, and produces tamper-evident work records. 14 MCP tools.14-
- AlicenseBqualityAmaintenanceProvides AI agents with safe, governed read access to industrial control systems (OPC-UA, Modbus, S7, Mitsubishi, MTConnect, MQTT/Sparkplug) plus cross-protocol diagnostics for troubleshooting data breaks, alarm floods, and unhealthy tags.21531MIT