Skip to main content
Glama

CoRT MCP Server

CoRT MCP サーバー

これはChain-of-Recursive-Thoughts (CORT) MCPサーバーです。元のプロジェクトは以下の通りです。元の作品に深く感謝いたします。

オリジナル: PhialsBasement/Chain-of-Recursive-Thoughts: AIに何度も自己議論をさせることで、より深く考えさせるようにしました。驚くほどうまく動作します。
https://github.com/PhialsBasement/Chain-of-Recursive-Thoughts

リリースノート

0.2.0 LLMリスト更新 0.1.0 初回リリース

特徴

  • MCPサーバー経由で利用可能なCoRTメソッドは、AIに繰り返し自己議論をさせることで、AIの思考を困難にします。驚くほどうまく機能します。

作業済みチェック

ルーコード / クライン

MCPホスト構成

300秒のタイムアウトを推奨します。(予想よりも時間がかかる場合があります) OPENROUTER_API_KEYが必要です。https ://openrouter.ai/

例: ログ記録が無効

"CoRT-chain-of-recursive-thinking": { "command": "pipx", "args": ["run", "cort-mcp", "--log=off"], "env": { "OPENAI_API_KEY": "{apikey}", "OPENROUTER_API_KEY": "{apikey}" } }

例: ログ記録が有効 (ログファイルの絶対パスが必要)

"CoRT-chain-of-recursive-thinking": { "command": "pipx", "args": ["run", "cort-mcp", "--log=on", "--logfile=/workspace/logs/cort-mcp.log"], "env": { "OPENAI_API_KEY": "{apikey}", "OPENROUTER_API_KEY": "{apikey}" } }
  • --log=off : すべてのログ記録を無効にする(ログは書き込まれません)
  • --log=on --logfile=/absolute/path/to/logfile.log : ログ記録を有効にし、指定された絶対ファイルパスにログを書き込みます。
  • ログ記録を有効にする場合は、両方の引数が必須です。どちらかが欠落している場合、パスが絶対パスでない場合、または無効な値が指定された場合、サーバーはエラーで終了します。

注記:

  • ログ記録を有効にすると、ログは指定された絶対ファイルパスにのみ書き込まれます。相対パスを指定したり、 --logfileを省略したりするとエラーが発生します。
  • ログ記録が無効になっている場合、ログは出力されません。
  • 必要な引数が欠落しているか無効である場合、サーバーは起動せず、エラー メッセージが表示されます。
  • ログ ファイルは、MCP サーバー プロセスによってアクセスおよび書き込み可能である必要があります。
  • このサーバーの実行に問題がある場合は、cort-mcpの古いバージョンがキャッシュされている可能性があります。以下の設定で、cort-mcpの最新バージョン( xyzを最新バージョンに設定)で実行してみてください。
"CoRT-chain-of-recursive-thinking": { "command": "pipx", "args": ["run", "cort-mcp==x.y.z", "--log=off"], "env": { "OPENAI_API_KEY": "{apikey}", "OPENROUTER_API_KEY": "{apikey}" } }

利用可能なツール

  • {toolname}.simple 詳細はなく、最終的に選択された代替案のみを出力します。
  • {toolname}.details LLM 応答履歴の詳細を含めます。
  • {toolname}.mixed.llm マルチ LLM 推論。
  • {toolname}.neweval 新しい評価プロンプト。

以下の詳細を確認してください。

CoRT とは何ですか?

オリジナルからの大幅な強化

オリジナルの CoRT 方法論からいくつかの機能が強化されています。

  1. マルチ LLM 推論: 各選択肢は、異なる LLM (モデル + プロバイダー) を使用してランダムに生成されます。
  2. 評価強化:AIに推論の説明を求めるプロンプトを追加することで、プロンプト評価が更新されました。(元のプロンプトはツールで利用可能です)

マルチLLM推論

**概要:**従来のCoRT思考フローに、「選択肢ごとに異なるLLM(モデル+プロバイダ)をランダムに選択する」という探索戦略を追加した新しいツールです。これにより、異種モデルの知識やアイデアを最大限に活用し、より幅広い選択肢から最適な解を選択することが可能になります。

  • この機能は混合 LLM ツールで利用できます。

LLMのリスト

  • より良いユーザーエクスペリエンスを実現するために、適度に軽量で高速なモデルが選択されます。
MIXED_LLM_LIST = [ {"provider": "openai", "model": "gpt-4.1-nano"}, {"provider": "openrouter", "model": "meta-llama/llama-4-scout:free"}, {"provider": "openrouter", "model": "google/gemini-2.0-flash-exp:free"}, {"provider": "openrouter", "model": "mistralai/mistral-small-3.1-24b-instruct:free"}, {"provider": "openrouter", "model": "meta-llama/llama-3.2-3b-instruct:free"}, {"provider": "openrouter", "model": "thudm/glm-4-9b:free"}, ]

混合 LLM ツール プロセス。

  • 各選択肢について、上記のリストからLLM(モデル+プロバイダー)を1つランダムに選択します。
  • 生成された代替案ごとに「どのモデルとプロバイダが使用されたか」を常にログに記録します。
  • 詳細モードでは、応答履歴情報に「各代替案に使用されたモデルとプロバイダー」を明示的に含めます。

評価強化

**概要:**評価プロンプトをより充実したものに変更しました。(元のプロンプトはツールで利用できます) AI に推論を説明するよう求める {toolname}.neweval のプロンプトを使用します。

元のプロンプト

f"""Original message: {prompt} Evaluate these responses and choose the best one: Current best: {current_best} Alternatives: {chr(10).join([f"{i+1}. {alt}" for i, alt in enumerate(alternatives)])} Which response best addresses the original message? Consider accuracy, clarity, and completeness. First, respond with ONLY 'current' or a number (1-{len(alternatives)}). Then on a new line, explain your choice in one sentence."""

強化されたプロンプト

f""" Original message: {prompt} You are an expert evaluator tasked with selecting the response that best fulfills the user's true needs, considering multiple perspectives. Current best: {current_best} Alternatives: {chr(10).join([f"{i+1}. {alt}" for i, alt in enumerate(alternatives)])} Please follow this evaluation process: Intent Analysis: What is the user REALLY seeking? What underlying needs might be present beyond the surface question? Context Consideration: What possible situations or backgrounds could this question arise from? Diversity Assessment: Does the response consider different viewpoints or possible interpretations? Practicality Evaluation: How useful would the response be in the user's real-world context? Consistency Check: Is the response internally consistent and logically coherent? For each response (including the current best): Does it solve the user's TRUE problem? Does it balance accuracy and usefulness? Does it avoid unnecessary assumptions or biases? Is it flexible enough to apply in various contexts or situations? Does it account for exceptions or special cases? After completing your evaluation: Indicate your choice with ONLY 'current' or a number (1-{len(alternatives)}). On the next line, explain specifically why this response best meets the user's true needs. """

パラメータの指定とフォールバック処理

この API は、指定されたprovidermodelパラメータに基づいて実際に使用するモデルを決定し、エラーの場合はフォールバック処理を実行します。

  1. プロバイダー( provider )解決
    • 指定しない場合はopenrouterがデフォルトのプロバイダーとして使用されます。
    • 無効な値が指定された場合( openaiまたはopenrouter以外): デフォルトのプロバイダーopenrouterにフォールバックします。
  2. モデル( model )解像度
    • 指定しない場合
      • 解決されたプロバイダーがopenrouterの場合: デフォルト モデルmistralai/mistral-small-3.1-24b-instruct:freeが使用されます。
      • 解決されたプロバイダーがopenaiの場合: デフォルトの OpenAI モデルが使用されます。
    • 指定する場合(有効なプロバイダーを使用)
      • 指定されたモデル名は、解決されたプロバイダーでそのまま使用されます。
      • 重要: この段階では、指定されたモデル名がプロバイダーに実際に存在するかどうかは検証されません。
  3. API呼び出しとエラーフォールバック
    • 最初に、上記のルールによって解決されたプロバイダーとモデルの組み合わせを使用して API 呼び出しが試行されます。
    • API 呼び出し中にエラーが発生した場合(例: 指定されたモデルがプロバイダーに存在しない、API キー認証エラーなど)。
      • 条件 1 : 最初に試行された呼び出しのプロバイダーはopenaiありません
      • 条件2 : システムに環境変数OPENAI_API_KEYが設定されている。
      • 上記の両方の条件が満たされた場合、システムは**openaiプロバイダーのデフォルト モデルを使用してプロセスを自動的に再試行します**(これがフォールバック処理です)。
      • 上記の条件のいずれかまたは両方が満たされていない場合(たとえば、最初の試行がopenaiであった、またはOPENAI_API_KEYが設定されていない)、初期エラーが最終結果として返され、このタイプのフォールバックは発生しません。

環境変数に関する注意事項:

  • openrouter使用するにはOPENROUTER_API_KEYが必要です。
  • openai使用する場合、または上記のフォールバック機能を利用する場合は、 OPENAI_API_KEY必要です。
  • 対応する API キーが設定されていない場合、API 呼び出しは失敗します (フォールバック条件によっては OpenAI へのフォールバックも失敗します)。

ライセンス

マサチューセッツ工科大学

思いっきり楽しんで

-
security - not tested
A
license - permissive license
-
quality - not tested

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

複数回の代替生成と評価を通じて AI 自身と繰り返し議論させることで AI の思考を困難にする Chain-of-Recursive-Thoughts (CoRT) 方法論を実装した MCP サーバー。

  1. リリースノート
    1. 特徴
      1. 作業済みチェック
        1. MCPホスト構成
          1. 例: ログ記録が無効
          2. 例: ログ記録が有効 (ログファイルの絶対パスが必要)
        2. 利用可能なツール
          1. CoRT とは何ですか?
            1. オリジナルからの大幅な強化
              1. マルチLLM推論
              2. LLMのリスト
              3. 混合 LLM ツール プロセス。
            2. 評価強化
              1. 元のプロンプト
              2. 強化されたプロンプト
              3. パラメータの指定とフォールバック処理
            3. ライセンス

              Related MCP Servers

              • A
                security
                A
                license
                A
                quality
                This is a MCP server that implements an unreasonable thinking system. It helps generate unconventional solutions: Generating unreasonable thoughts that challenge conventional wisdom. Creating branches of thinking in different directions
                Last updated -
                3
                16
                JavaScript
                MIT License
                • Apple
              • -
                security
                A
                license
                -
                quality
                An MCP server that implements the 'think' tool, providing Claude with a dedicated space for structured thinking during complex problem-solving tasks to improve reasoning capabilities.
                Last updated -
                48
                Python
                MIT License
                • Linux
                • Apple
              • -
                security
                A
                license
                -
                quality
                A minimal MCP Server that provides Claude AI models with the 'think' tool capability, enabling better performance on complex reasoning tasks by allowing the model to pause during response generation for additional thinking steps.
                Last updated -
                525
                1
                TypeScript
                MIT License
                • Apple
              • -
                security
                F
                license
                -
                quality
                An advanced MCP server that implements sophisticated sequential thinking using a coordinated team of specialized AI agents (Planner, Researcher, Analyzer, Critic, Synthesizer) to deeply analyze problems and provide high-quality, structured reasoning.
                Last updated -
                124
                Python
                • Linux
                • Apple

              View all related MCP servers

              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/KunihiroS/cort-mcp'

              If you have feedback or need assistance with the MCP directory API, please join our Discord server