/ ディレクトリ / プレイグラウンド / Nanobot
● コミュニティ HKUDS ⚡ 即起動

Nanobot

作者 HKUDS · HKUDS/nanobot

If FastMCP and Upsonic feel heavy: Nanobot is a few hundred lines of Python that gives you a working personal agent with MCP support.

Nanobot is an academic-style minimal agent framework. Strips most abstraction; you bring tools and an LLM, it gives you the loop. Use it when you want a teachable, hackable baseline for an MCP-aware agent.

なぜ使うのか

主な機能

ライブデモ

実際の動作

準備完了

インストール

クライアントを選択

~/Library/Application Support/Claude/claude_desktop_config.json  · Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "nanobot-mcp": {
      "command": "uvx",
      "args": [
        "nanobot",
        "serve",
        "--mcp"
      ]
    }
  }
}

Claude Desktop → Settings → Developer → Edit Config を開く。保存後、アプリを再起動。

~/.cursor/mcp.json · .cursor/mcp.json
{
  "mcpServers": {
    "nanobot-mcp": {
      "command": "uvx",
      "args": [
        "nanobot",
        "serve",
        "--mcp"
      ]
    }
  }
}

Cursor は Claude Desktop と同じ mcpServers スキーマを使用。プロジェクト設定はグローバルより優先。

VS Code → Cline → MCP Servers → Edit
{
  "mcpServers": {
    "nanobot-mcp": {
      "command": "uvx",
      "args": [
        "nanobot",
        "serve",
        "--mcp"
      ]
    }
  }
}

Cline サイドバーの MCP Servers アイコンをクリックし、"Edit Configuration" を選択。

~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "nanobot-mcp": {
      "command": "uvx",
      "args": [
        "nanobot",
        "serve",
        "--mcp"
      ]
    }
  }
}

Claude Desktop と同じ形式。Windsurf を再起動して反映。

~/.continue/config.json
{
  "mcpServers": [
    {
      "name": "nanobot-mcp",
      "command": "uvx",
      "args": [
        "nanobot",
        "serve",
        "--mcp"
      ]
    }
  ]
}

Continue はマップではなくサーバーオブジェクトの配列を使用。

~/.config/zed/settings.json
{
  "context_servers": {
    "nanobot-mcp": {
      "command": {
        "path": "uvx",
        "args": [
          "nanobot",
          "serve",
          "--mcp"
        ]
      }
    }
  }
}

context_servers に追加。保存時に Zed がホットリロード。

claude mcp add nanobot-mcp -- uvx nanobot serve --mcp

ワンライナー。claude mcp list で確認、claude mcp remove で削除。

ユースケース

実用的な使い方: Nanobot

Learn the agent loop by reading the source

👤 Developers ⏱ ~15 min intermediate

使うタイミング: You want to understand what FastMCP / Upsonic do under the hood.

フロー
  1. Read
    Open the main module — single-file core.✓ コピーしました
    → Mental model
  2. Run
    Start the bot; call its MCP tools from Claude.✓ コピーしました
    → Works
  3. Modify
    Add a tool or change the planner.✓ コピーしました
    → Fork ready

結果: Working hackable baseline for your own agent.

組み合わせ

他のMCPと組み合わせて10倍の力を

nanobot-mcp + fastmcp-prefect

Prototype with Nanobot; harden with FastMCP for production

Combine nanobot-mcp with fastmcp-prefect: Prototype with Nanobot; harden with FastMCP for production✓ コピーしました

ツール

このMCPが提供する機能

ツール入力呼び出すタイミングコスト
run (see docs) Run a task through the nanobot loop 1 call

コストと制限

運用コスト

APIクォータ
Bound by LLM
呼び出しあたりのトークン
Normal
金額
Free OSS
ヒント
Keep tool sets small — Nanobot is minimal, not magical

セキュリティ

権限、シークレット、影響範囲

認証情報の保管: LLM keys in env
データ送信先: Configured provider

トラブルシューティング

よくあるエラーと対処法

Planner gets stuck

Add a step budget; minimal planners need explicit halts

代替案

Nanobot 他との比較

代替案代わりに使う場面トレードオフ
FastMCPProduction serverMore framework

その他

リソース

📖 GitHub の公式 README を読む

🐙 オープンな issue を見る

🔍 400以上のMCPサーバーとSkillsを見る