MCP Anthropic Server

MCP Anthropic サーバー ( mcp-anthropic )

Anthropic の実験的なプロンプト エンジニアリング API と対話するためのツールを提供する MCP (Model Context Protocol) サーバー。

特徴

次のツールを提供します:

  • generate_prompt : タスクの説明に基づいてプロンプトを生成します。
  • improve_prompt : フィードバックに基づいて既存のプロンプトを改善します。
  • templatize_prompt : 具体的なプロンプトの例を再利用可能なテンプレートに変換します。

設定

  1. リポジトリをクローンする(該当する場合)
  2. プロジェクト ディレクトリに移動します。
    cd mcp-anthropic
  3. 依存関係をインストールします:
    npm install
  4. API キーを設定します。
    • プロジェクト ルートに.envファイル ( ./mcp-anthropic/.env ) を作成します。
    • Anthropic API キーを.envファイルに追加します。
      ANTHROPIC_KEY=your_anthropic_api_key_here
    • このファイルがバージョン管理にコミットされていないことを確認してください ( .gitignoreでカバーされている必要があります)。
    • **LibreChat 統合に関する注意:**このサーバーを LibreChat 内の子プロセスとして設定および実行する具体的な手順 (API キーの処理を含む) については、 documentation.mdファイルを参照してください。

サーバーの実行

  1. TypeScript コードをビルドします。
    npm run build
  2. サーバーを起動します。
    npm start
    サーバーが起動し、MCP接続を待機します。サーバーの起動と登録されているツールを示す出力が表示されます。

ツールドキュメント

generate_prompt

タスクの説明に基づいてプロンプトを生成します。

入力スキーマ:

{ "type": "object", "properties": { "task": { "type": "string", "description": "A description of the task the prompt should be designed for (e.g., \"a chef for a meal prep planning service\")." }, "target_model": { "type": "string", "description": "The target Anthropic model identifier (e.g., \"claude-3-opus-20240229\")." } }, "required": ["task", "target_model"] }

improve_prompt

フィードバックに基づいて既存のプロンプトを改善します。

入力スキーマ:

{ "type": "object", "properties": { "messages": { "type": "array", "items": { "type": "object", "properties": { "role": { "type": "string", "description": "Role (e.g., 'user', 'assistant')." }, "content": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string", "description": "Content type (e.g., 'text')." }, "text": { "type": "string", "description": "Text content." } }, "required": ["type", "text"] }, "description": "Content blocks." } }, "required": ["role", "content"] }, "description": "The sequence of messages representing the prompt conversation." }, "system": { "type": "string", "description": "(Optional) A system prompt to guide the model." }, "feedback": { "type": "string", "description": "Specific feedback on how to improve the prompt (e.g., \"Make it more detailed\")." }, "target_model": { "type": "string", "description": "The target Anthropic model identifier (e.g., \"claude-3-opus-20240229\")." } }, "required": ["messages", "feedback", "target_model"] }

templatize_prompt

具体的なプロンプトの例を再利用可能なテンプレートに変換します。

入力スキーマ:

{ "type": "object", "properties": { "messages": { "type": "array", "items": { "type": "object", "properties": { "role": { "type": "string", "description": "Role (e.g., 'user', 'assistant')." }, "content": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string", "description": "Content type (e.g., 'text')." }, "text": { "type": "string", "description": "Text content." } }, "required": ["type", "text"] }, "description": "Content blocks." } }, "required": ["role", "content"] }, "description": "The sequence of messages representing the prompt conversation example." }, "system": { "type": "string", "description": "(Optional) A system prompt associated with the example." } }, "required": ["messages"] }
-
security - not tested
-
license - not tested
-
quality - not tested

Anthropic のプロンプト エンジニアリング API と対話するためのツールを提供する MCP サーバー。これにより、ユーザーはタスクの説明とフィードバックに基づいてプロンプトを生成、改善、テンプレート化できます。

  1. Features
    1. Setup
      1. Running the Server
        1. Tools Documentation
          1. generate_prompt
          2. improve_prompt
          3. templatize_prompt
        ID: v6kgdiyi2s