{"id":43218338,"url":"https://github.com/nttcom/chakoshi-mcp-server","last_synced_at":"2026-02-01T08:30:45.358Z","repository":{"id":301993208,"uuid":"1008769726","full_name":"nttcom/chakoshi-mcp-server","owner":"nttcom","description":"chakoshiをMCPクライアントから利用するためのMCPサーバ","archived":false,"fork":false,"pushed_at":"2025-06-30T01:15:02.000Z","size":18,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-30T02:26:38.967Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nttcom.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-26T04:29:45.000Z","updated_at":"2025-06-30T01:15:07.000Z","dependencies_parsed_at":"2025-06-30T02:26:44.458Z","dependency_job_id":"fb0e3f8a-05f9-4fb5-bac9-d85ad0828fc6","html_url":"https://github.com/nttcom/chakoshi-mcp-server","commit_stats":null,"previous_names":["nttcom/chakoshi-mcp-server"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nttcom/chakoshi-mcp-server","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nttcom%2Fchakoshi-mcp-server","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nttcom%2Fchakoshi-mcp-server/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nttcom%2Fchakoshi-mcp-server/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nttcom%2Fchakoshi-mcp-server/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nttcom","download_url":"https://codeload.github.com/nttcom/chakoshi-mcp-server/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nttcom%2Fchakoshi-mcp-server/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28974117,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-01T08:16:14.655Z","status":"ssl_error","status_checked_at":"2026-02-01T08:06:51.373Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-02-01T08:30:45.277Z","updated_at":"2026-02-01T08:30:45.350Z","avatar_url":"https://github.com/nttcom.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# chakoshi MCP Server\n\n  \n\nMCPクライアントアプリケーションと、[chakoshi API](https://chakoshi.ntt.com) を連携するMCP (Model Context Protocol) サーバーです。\n\nClaude Desktop などからchakoshiを利用して日本語テキストのモデレーション(有害性チェック)を実行できます。\n\n  \n\n## chakoshiとは\n\n  \n\nchakoshiとは、NTT ドコモビジネスが提供するLLM向けのガードレールです。詳細は以下をご覧ください。\n\n[chakoshi 製品ページ](https://chakoshi.ntt.com)\n\n[chakoshi 技術詳細](https://www.anlp.jp/proceedings/annual_meeting/2025/pdf_dir/P7-7.pdf)\n\n[chakoshi ドキュメントサイト](https://docs.chakoshi.ntt.com)\n\n  \n\n## リポジトリに含まれるツール\n\n### 本リポジトリの構成\n\n```\n\nchakoshi-mcp-server/\n\n├── main.py # エントリポイント\n\n├── chakoshi_server/\n\n│ ├── __init__.py\n\n│ ├── config.py # 環境変数の管理\n\n│ └── server.py # MCP サーバーの実装部分\n\n├── pyproject.toml # プロジェクト設定\n\n└── .env # 環境変数（要作成）\n\n```\n\n### moderate_text\n\n \nテキストコンテンツの有害性をチェックするツールです。\n\n  \n\n**入力パラメータ:**\n\n-  `text` (string, 必須): チェックしたいテキスト\n\n  \n\n**出力:**\n\n- chakoshi API からのモデレーション結果をJSON形式で返します\n\n  \n\n**使用プロンプト例:**\n\n```\n\nchakoshi を使ってこのテキストをチェックしてください: \"問題のあるコンテンツの例\"\n\n```\n\n  \n\n## chakoshi API の設定\n\n  \n### API キーの取得\n1. [chakoshiのプレイグラウンド](https://platform.beta.chakoshi.ntt.com/playground)にアクセスし、画面に従って新規登録フローを進めてください。\n\n2. 新規登録、およびログイン完了後、プレイグラウンドの設定をクリックします。\n\n3. その後、設定画面からAPIキーを新規に発行します。\n\n  \n\n### カテゴリセットの設定\n1. プレイグラウンドにアクセスし、「新しいカスタム検知項目の追加」をクリックし、検知項目名とカスタム検知項目の定義を入力します。 \n\n2. 別名で保存を選択し、新しくカスタム検知項目セットを保存します。\n\n3. 保存後、「選択中の検知項目セットIDをコピー」の項目からカテゴリセットIDをコピーします。\n\n\n## 必要要件\n\n  \n\n- Python 3.10 以上\n\n- chakoshi のユーザ登録、および、APIキー\n\n- MCPクライアントアプリケーション (Claude Desktopなど)\n\n  \n\n## インストール\n\n  \n\n### 1. リポジトリのクローン\n\n  \n\n```bash\n\ngit clone https://github.com/nttcom/chakoshi-mcp-server.git\n\ncd chakoshi-mcp-server\n\n```\n\n  \n\n### 2. 依存関係のインストール\n\n  \n\n```bash\n\n# uvのインストール\ncurl -LsSfhttps://astral.sh/uv/install.sh | sh\n\n\n# PATHの設定\nsource $HOME/.local/bin/env\n\n\n# uv を使用する場合（推奨）\n\nuv sync\n\n\n# pip を使用する場合\n\npip install -e .\n\n```\n\n  \n\n### 3. 環境変数の設定\n\n  \n\n`.env` ファイルを作成し、以下の環境変数を設定してください：\n\n  \n\n```env\n\nCHAKOSHI_API_KEY=your_chakoshi_api_key\n\nCHAKOSHI_API_URL=https://api.beta.chakoshi.ntt.com/v1/judge/text\n\nCHAKOSHI_MODEL_ID=chakoshi-moderation-241223\n\nCHAKOSHI_CATEGORY_SET_ID=your_category_set_id\n\nCHAKOSHI_TIMEOUT_SEC=5\n\n```\n\n  \n\n**注意**: 実際の APIキーとカテゴリセットID はchakoshiプレイグラウンドの管理画面から取得してください。\n\n  \n\n## 使用方法\n\n### サーバの起動\n```\nuv run main.py\n```\n\n\n\n### Claude Desktop との連携\n\n  \n\nClaude Desktop の設定ファイル（`claude_desktop_config.json`）に以下を追加：\n\n  \n\n```json\n\n{\n\n\"mcpServers\": {\n\n\"command\": \"/PATH_to_uv/uv\",\n        \"args\": [\n          \"--directory\",\n          \"/PATH_to_chakoshi/chakoshi-mcp-server\",\n          \"run\",\n          \"main.py\"\n        ],\n        \"env\": {\n          \"CHAKOSHI_API_KEY\": \"YOUR_CHAKOSHI_API_KEY\"\n        }\n\n}\n\n}\n\n```\n\n  \n\nその後、Claude Desktop 内で以下のように使用できます：\n\n  \n\n```\n\nchakoshiを使ってこのテキストをチェックしてください：「問題のあるコンテンツの例」\n\n```\n\n  \n\nClaude が自動的に `moderate_text` ツールを使用してモデレーション結果を返します。\n\n  \n\n## API レスポンス例\n\n  \n\n```json\n\n\n{\n  \"category1\": {\n    \"score\": 0.05,\n    \"threshold\": 0.5,\n    \"result\": \"safe\"\n  },\n  \"category2\": {\n    \"score\": 0.02,\n    \"threshold\": 0.3,\n    \"result\": \"safe\"\n  }\n}\n\n\n```\n  \n\n## 注意事項\n\n\n- chakoshi API は現在ベータ版です。本番環境などでは使用しないでください。\n\n- APIキーは適切に管理し、決して公開しないでください。\n\n- APIキーのレート制限などについては[公式ドキュメント](https://docs.chakoshi.ntt.com)を参照してください。\n\n\n## ライセンス\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnttcom%2Fchakoshi-mcp-server","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnttcom%2Fchakoshi-mcp-server","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnttcom%2Fchakoshi-mcp-server/lists"}