MCP ROS Bagsのロゴ

MCP ROS Bags

組織
binabik-ai

MCP Server to interface with and analyze rosbags offline

公開者binabik-ai
リポジトリmcp-rosbags
言語Python
フォーク
3
スター
29
利用可能なツール
0
通信方式stdio
カテゴリ
ライセンスApache-2.0
リンク
  • ツールをAIワークフローに接続

    MCP ROS Bagsは、対応するAIクライアントやAIエージェントから利用できるMCP機能を提供します。

  • 利用可能なツール(0個)

    呼び出し可能なアクションを以下で確認できます。サーバーから提供されている場合は、名前や説明も表示されます。

  • コピーして使える設定

    セットアップ用の設定例を使って、お好みのMCPクライアントにこのサーバーを設定できます。

  • オープンソースプロジェクトの注目度

    リンク先のリポジトリには29件のスターと3件のフォークがあります。

MCP ROS Bags

A Model Context Protocol (MCP) server for analyzing and querying ROS bag files. This server enables Claude and other MCP-compatible tools to interact with robot data stored in ROS bags.

Overview

This MCP server provides comprehensive tools for ROS bag analysis, supporting both ROS 1 and ROS 2 bag formats (.bag, .db3, .mcap). It enables AI assistants to query robot trajectories, sensor data, transforms, and logging information from recorded robot sessions.

Key Features

  • Bag Management: List, inspect, and query ROS bag files
  • Message Querying: Get messages by topic, timestamp, or time range
  • Trajectory Analysis: Extract robot paths, waypoints, and motion profiles
  • Sensor Data: Analyze laserscan topics, images
  • Transform Trees: Query coordinate transforms and frame relationships
  • Logging Analysis: Search and analyze ROS log messages
  • Visualization: Generate plots and visual representations of data
  • Search & Discovery: Find objects, patterns, and correlations in data

Installation

  1. Clone the repository:

    bash
    git clone https://github.com/binabik-ai/mcp-rosbags.git
    cd mcp-rosbags
  2. Create and activate a Python virtual environment:

    bash
    python3 -m venv venv
    source venv/bin/activate  # On Windows: venv\Scripts\activate
  3. Install dependencies:

    bash
    pip install -r requirements.txt
  4. Optional: Install with ROS 2 support:

    bash
    pip install -e .[ros2]

Configuration

Claude Desktop Configuration

Add this to your Claude Desktop configuration file:

json
{
  "mcpServers": {
    "rosbag_reader": {
      "command": "/path/to/your/venv/bin/python",
      "args": ["/path/to/mcp-rosbags/src/server.py"],
      "env": {
        "PYTHONPATH": "/path/to/mcp-rosbags/src",
        "MCP_ROSBAG_DIR": "/path/to/your/rosbags",
        "MCP_ROSBAG_CONFIG": "/path/to/mcp-rosbags/src/config"
      }
    }
  }
}

Environment Variables

  • MCP_ROSBAG_DIR: Default directory containing ROS bag files (default: ./rosbags)
  • MCP_ROSBAG_CONFIG: Configuration directory (default: ./config)

Server Configuration

The server uses configuration files in the src/config/ directory:

  • server_config.yaml: Main server configuration (caching, timeouts, etc.)
  • message_schemas.yaml: Schema definitions for message field extraction

Usage

With Claude Desktop

After configuration, restart Claude Desktop and you can interact with your ROS bags:

"List all ROS bags in my directory"
"Show me the trajectory from the /odom topic"
"Find all error messages in the logs"
"Extract an image from the /camera/image topic at timestamp 1234567890 and describe what you see"

Tools Overview

The server provides the following categories of tools:

Core Tools

  • set_bag_path: Set current bag file or directory
  • list_bags: List available ROS bag files
  • bag_info: Get detailed bag information
  • get_message_at_time: Get message at specific timestamp
  • get_messages_in_range: Get messages within time range

Analysis Tools

  • Trajectory: Extract robot paths, analyze motion patterns
  • LiDAR: Process laserscan data, e.g., to detect obstacles
  • Images: Extract and process camera images
  • Transforms: Query coordinate transforms and frame trees
  • Logging: Search and analyze ROS log messages
  • Visualization: Generate plots and visual data representations

Search Tools

  • Pattern matching in message data
  • Correlation analysis between topics
  • Time-based data alignment

Architecture

src/
├── server.py              # Main MCP server
├── config/                # Configuration files
│   ├── server_config.yaml # Server settings
│   └── message_schemas.yaml # Message field schemas
├── core/                  # Core utilities
│   ├── cache_manager.py   # Caching system
│   ├── message_utils.py   # Message processing
│   └── schema_manager.py  # Schema handling
└── extractors/           # Specialized analysis tools
    ├── bag_management.py # Bag operations
    ├── image.py          # Image processing
    ├── lidar.py          # LiDAR analysis
    ├── logging.py        # Log analysis
    ├── search.py         # Search and correlation
    ├── tf_tree.py        # Transform trees
    ├── trajectory.py     # Path analysis
    └── visualization.py  # Data visualization

Supported Message Types

The server supports standard ROS message types including:

  • Navigation: nav_msgs/Odometry, nav_msgs/Path
  • Geometry: geometry_msgs/PoseStamped, geometry_msgs/Twist
  • Sensors: sensor_msgs/LaserScan, sensor_msgs/PointCloud2, sensor_msgs/Image
  • Transforms: tf2_msgs/TFMessage, geometry_msgs/TransformStamped
  • Diagnostics: diagnostic_msgs/DiagnosticArray
  • Logging: rcl_interfaces/Log

Performance Features

  • Intelligent Caching: Configurable caching system for frequently accessed data
  • Schema-based Extraction: Efficient field extraction using predefined schemas

License

This project is licensed under the Apache License 2.0. See LICENSE for details.

Support

Acknowledgments

Built with the Model Context Protocol and the rosbags library.

インストール

TypingMind
前提条件:

Node.js 18+

{
  "mcpServers": {
    "binabik-ai-mcp-rosbags": {
      "command": "",
      "args": []
    }
  }
}

MCP ROS BagsのMCPを複数のAIモデルで活用

TypingMindはワークスペース単位でMCPツールに接続します。そのため、一度MCP ROS Bagsに接続すれば、モデルごとに個別に設定することなく、TypingMind内のさまざまなAIモデルで利用できます。 このMCPは、デバイス上のTypingMind MCPコネクタを通じてローカルで動作します。

ローカルコネクタのセットアップガイド

MCPサーバーが、お使いのコンピューター上のローカルファイル、アプリ、非公開リソースにアクセスする必要がある場合は、この方法を使います。

1

MCP設定を開く

TypingMindで「設定」→「詳細設定」→「Model Context Protocol」の順に進み、「コネクタを設定」を選択してください。

  1. ブラウザでTypingMindを開いてください。
  2. 設定アイコンをクリックしてください。
  3. 「詳細設定」に移動してください。
  4. 「Model Context Protocol」セクションを開いてください。
  5. 「コネクタを設定」をクリックし、「このデバイス」を選択してください。
「このデバイス」が選択されたTypingMindのMCPコネクタ設定画面
2

コネクタのコマンドを実行

「このデバイス」を選択し、TypingMindからコマンドをコピーしてターミナルで実行してください。MCPの使用中は、プロセスを実行したままにしてください。

  1. TypingMindに表示されるセットアップコマンドをコピーしてください。
  2. macOSではターミナルを、WindowsではWindows Terminalを開いてください。
  3. コマンドを貼り付けて実行してください。
  4. ターミナルで続行の確認を求められた場合は、パッケージのインストールを承認してください。
  5. MCPツールの使用中は、ターミナルウィンドウを開いたまま、プロセスの実行を継続してください。
3

MCP ROS Bagsをサーバーとして追加

コネクタのステータスが「準備完了」になったら、「サーバーを編集」をクリックし、MCPサーバーの設定を貼り付けてください。

  1. コネクタのステータスが「準備完了」になるまでお待ちください。
  2. 「サーバーを編集」をクリックしてください。
  3. MCP ROS BagsのMCPサーバー設定を貼り付けてください。
  4. サーバー一覧を保存してください。
  5. コネクタのステータスが「準備完了」のままか確認するには、画面を更新してください。
稼働中のサーバーと「サーバーを編集」ボタンが表示されたTypingMindのMCP設定画面
{
  "mcpServers": {
    "binabik-ai-mcp-rosbags": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-rosbags"
      ]
    }
  }
}
4

複数のモデルで同じ接続を使用

サーバー一覧を保存し、「プラグイン」を開いてMCP ROS BagsのMCPツールを有効にしてください。その後、TypingMindで対応するAIモデルを選択し、チャットでツールを使うか、AIエージェントに割り当ててください。

  1. TypingMindの「プラグイン」ページを開いてください。
  2. MCP ROS BagsのMCPツールを有効にしてください。
  3. チャットを開始し、使用するAIモデルを選択してください。
  4. MCPツールをチャットで使うか、AIエージェントに割り当ててください。
  5. MCPに再接続することなく、必要に応じて別のAIモデルに切り替えられます。
選択したAIモデルと有効なMCPツールを使用したTypingMindのチャット
MCP ROS Bagsを使ってこのタスクを手伝ってもらえますか?
MCP ROS Bags
はい、読みました。
MCP ROS Bagsで調べた結果をお伝えします。

よくある質問

MCP ROS Bags MCPサーバーは何に使いますか?

MCP ROS Bagsは、対応するAIクライアントを外部ツールやコンテキストに接続するためのMCPサーバーです。TypingMindでは、このMCPサーバーを一度追加するだけで、AIワークスペース内でそのツールを利用できるようになります。

TypingMindでは、複数のAIモデルでMCP ROS Bags MCPを利用できますか?

はい。TypingMindはワークスペース単位でMCPツールに接続するため、モデルごとにMCPサーバーを設定する必要はありません。Claude、ChatGPT、Geminiや、TypingMindで設定したその他のAIモデルでMCP ROS Bagsを利用できます。

TypingMindでMCP ROS Bags MCPを使うメリットは何ですか?

TypingMindは、複数のAIモデル、プロンプト、プラグイン、AIエージェント、APIキー、MCPツールを1つのワークスペースにまとめられる、LLMチャット向けのトップクラスのフロントエンドです。MCP ROS Bagsを接続すると、TypingMindでチャットのワークフローを整理しながら、お好みのモデルでそのMCPツールを利用できます。

MCP ROS Bags MCPをTypingMindに接続するにはどうすればよいですか?

MCP ROS BagsはTypingMindのローカルMCPコネクタ経由で動作します。MCPサーバーがコンピューター上のローカルファイル、デスクトップアプリ、コマンドラインツール、プライベートリソースにアクセスする必要がある場合に最適です。

TypingMindでMCP ROS Bags MCPのどのようなツールを利用できますか?

MCP ROS BagsはMCP機能を提供しています。TypingMindのプラグインページで有効にすると、チャットで使用したり、AIエージェントに割り当てたりできます。

MCP ROS Bags MCPを使うには、APIキーをTypingMindと共有する必要がありますか?

いいえ。TypingMindはローカルファーストの設計で、モデルプロバイダー、APIキー、プロンプト、MCP設定をご自身で管理できます。MCP ROS Bagsで認証が必要な場合は、接続の作成時に、そのMCPサーバーに必要なヘッダー、OAuth設定、またはローカル設定を追加してください。

関連するMCPサーバー

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇