See llms.txt for all machine-readable content.

Back to Templates

Supervise ROV commands using multi-agent OpenAI planners and Telegram

Quick overview

This workflow receives ROV telemetry via webhook, derives safety and navigation metrics, then uses OpenAI multi-agent planning plus an independent safety validator to recommend or issue commands, notifying operators through Telegram, logging decisions in an n8n Data Table, and posting final commands to a topside control HTTP endpoint.

How it works

  1. Receives ROV telemetry in a POST webhook request.
  2. Validates required fields, derives metrics (distance to target, thruster margin, nearest sonar contact), and flags conditions and hard safety limit breaches.
  3. If a hard limit is breached, generates an emergency safe command and immediately alerts the operator in Telegram.
  4. Otherwise, loads recent mission decision history from an n8n Data Table and sends the telemetry plus history to an OpenAI supervisor agent that consults mission planning, navigation, perception, and safety specialist tools to produce a structured recommended command.
  5. Runs an independent OpenAI safety validator to approve, modify, or veto the proposed command and packages the final decision with merged risk and alerts.
  6. Posts a live status update to Telegram and routes the decision to either auto-execute, request operator approval via a Telegram form (with timeout defaulting to hold station), or issue a critical safe action with an alert.
  7. Logs the final command to the n8n Data Table, sends it to the ROV topside control system via HTTP, and confirms the control system response in Telegram.

Setup

  1. Add OpenAI API credentials for the supervisor, specialist, validator, liaison, and debrief agents.
  2. Add Telegram bot credentials, replace all Telegram chat ID placeholders, and configure the bot to message the intended operator chat.
  3. Create or select an n8n Data Table for the mission log (rov_mission_log) and set its ID in all Data Table nodes used for history and logging.
  4. Set the ROV topside control system command endpoint URL in the HTTP Request node that sends commands to the vehicle.
  5. Copy the webhook URL for the rov-telemetry endpoint into your telemetry source and send a test payload (including mission_id, depth_m, visibility_m, battery_or_power_pct, and tether_tension_kN) to verify the auto/approval/critical routes.

Customization

  • Swap models per agent, change authority rules in Decision Package, add Slack or email alerts, connect another vehicle API, adjust safety limits in the telemetry body, or change the debrief interval.