Skip to main content
Glama

AI Optimizer MCP 🧠🔧 - マルチタスクMCPサーバー

開発者: Barack Ndenga ♥️

PyPI version Tests Coverage

詳細

VSCode/Cursor、CLI、自律型エージェント向けのマルチタスクMCPサーバー。AIコード最適化 + テスト + 拡張性。

  • トランスポート: Stdio (VSCode)、subprocess、HTTP (将来対応予定)

  • ユースケース: VSCodeチャット、エージェントループ、CI/CD、リモートサーバー

  • セキュリティ: 環境変数、サンドボックス実行

Related MCP server: VegaMCP

マニフェスト (マルチタスク機能)

  • 🛠️ 3つ以上のツール: コードテスト/最適化/目標管理 (+拡張可能)

  • 🔌 VSCode/Cursor: ネイティブな mcp.json

  • 🖥️ CLIスタンドアロン: ai-optimizer-mcp run

  • 🤖 エージェント: examples/agent.py ループ

  • ⚙️ マルチ環境: .env を介したローカル/開発/本番環境

  • 📊 メモリ/履歴: JSON永続化

  • 🔄 反復ループ: 自動改善

マルチプラットフォーム設定

1. VSCode/Cursor (推奨)

.vscode/mcp.json ファイル (マルチサーバー):

{
  "servers": {
    "ai-optimizer": {
      "command": "python",
      "args": ["-m", "ai_optimizer_mcp.server"]
    },
    "ai-optimizer-dev": {
      "command": "python",
      "args": ["-m", "ai_optimizer_mcp.cli", "run", "--dev"]
    }
  }
}

マルチタスク: チャット内でサーバーを切り替え可能!

2. CLI / スクリプト / エージェント

ai-optimizer-mcp run  # Stdio server (pipes)
ai-optimizer-mcp run --dev  # Debug
ai-optimizer-mcp --install-mcp  # Print mcp.json

3. 自律型エージェント / サブプロセス

# examples/agent.py
import asyncio
from mcp.client.stdio import stdio_client

async def agent_loop():
    async with stdio_client(command=["python", "-m", "ai_optimizer_mcp.server"]) as client:
        # Multi-task calls
        score = await client.call_tool("run_tests", {"code_snippet": code})
        improved = await client.call_tool("generate_improvement", {"code": code, "test_result": score})

前提条件 (.env)

cp .env.example .env
# OPENAI_API_KEY=sk-...
# OBJECTIVE="Your custom goal"

マルチタスクの使用方法

  1. VSCodeチャット: use_mcp_tool("ai-optimizer", "run_tests", ...)

  2. CLIパイプ: echo code | ai-optimizer-mcp run

  3. エージェントループ: python examples/agent.py

  4. CI/CD: GitHub Actions/Jenkins内でのサブプロセス

ツール応答の例:

run_tests → "Tests passed: score=4/4 (f(2)=4)"
generate_improvement → "def f(x): return 2 * x"

マルチ環境のトラブルシューティング

  • VSCode: mcp.json 編集後にウィンドウをリロード

  • APIキーなし: ValueError → .env を確認

  • タイムアウト: .env に TEST_TIMEOUT=10 を設定

  • メモリ: rm memory.json

  • ログ: --dev または LOG_LEVEL=DEBUG

開発

pip install -e .[dev]
pre-commit install
pytest

MCPツール (拡張可能)

ツール

引数

ユースケース

run_tests

code_snippet: str

VSCode/CLIでのコードテスト

generate_improvement

code, test_result

自動最適化

get_objective

-

あらゆるコンテキストで目標を読み取る

Apache 2.0 - マルチタスク対応!VSCode、CLI、エージェント、CIで利用可能。貢献を歓迎します!

CHANGELOG

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

No tool schema history has been recorded yet.

Maintenance

ActivityInactive
ResponsivenessSyncing

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    A lightweight MCP server that enhances AI agents with tools for codebase analysis, task delegation to sub-agents, multi-agent coordination through chatrooms, and project todo management.
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    MCP server that enables AI coding agents to communicate, share state, and coordinate work in real time via MCP tools or REST API.
    159
    5
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Multi-agent AI orchestrator that runs parallel coding agents in isolated sessions with self-improving intelligence, exposed via an MCP server for task execution and management.
    MIT

Latest Blog Posts

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/BarackNdenga/AI-Task-Optimizer-MCP'

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