🌊 A next-generation Marine Control System connecting High-Fidelity C++ Physics with GenAI Orchestration.
📺 Watch the full end-to-end demo featuring core functionalities.
Poseidon Link is a full-stack Industrial IoT (IIoT) simulation platform. It bridges the gap between raw hardware telemetry and cognitive operations, simulating a marine vessel's azimuth thruster with real-time physics, voice control, and predictive maintenance.
Modern industrial control systems are often rigid and disconnected from modern AI capabilities. Poseidon Link solves this by demonstrating a unified architecture:
- High-Fidelity Physics Engine: Instead of simple animations, it runs a 60Hz C++ simulation loop to model thermodynamics, fluid resistance, and RPM acceleration curves.
- Low-Latency Concurrency: Uses a Go (Golang) broker to handle high-throughput WebSocket telemetry, ensuring the dashboard reflects the "physical" state in milliseconds.
- Context-Aware AI Co-Pilot: Integrates OpenAI GPT-4o to translate natural language voice commands into machine code and automatically generate formatted "Captain's Logs" from telemetry buffers.
The application is built on a polyglot microservices architecture:
- Vessel Simulation (C++17): A standalone container running the physics calculations. It simulates the engine load, fuel flow, and mechanical stress based on environmental conditions.
- Telemetry Broker (Go): The central nervous system. It manages WebSocket connections, broadcasts state updates, and sanitizes AI JSON responses.
- Command Dashboard (React + TypeScript): An immersive frontend using Vite and Tailwind CSS for real-time visualization and control.
- AI Layer (OpenAI API): Processes unstructured inputs (Speech/Text) into structured commands and analyzes data patterns for anomaly detection.
- Dynamic Weather Simulation: "Storm Mode" alters the physics constants in the C++ engine, increasing load factors and fuel consumption in real-time.
- Predictive Maintenance: AI algorithms analyze vibration and oil temperature history to generate "Health Scores" and maintenance warnings.
- Voice Command Interface: Hands-free vessel control using Speech-to-Text, allowing commands like "Set thrusters to 80% power and rotate North."
- Automated Reporting: Generates maritime-standard "Captain's Logs" automatically, summarizing event history into professional logs.
- Engine: C++17 (Standard Library)
- Build System: CMake, Multi-Stage Docker Builds
- Networking: WebSocket++ (ASIO)
- Data: Nlohmann JSON
- Language: Go (Golang 1.21)
- Concurrency: Goroutines & Channels
- Protocol: WebSockets (Gorilla)
- Framework: React 18, Vite, TypeScript
- Styling: Tailwind CSS
- Visualization: Custom SVG Gauges, Lucide Icons
- Effects: CSS Animations (Rain/Lightning)
- Containerization: Docker, Docker Compose
- Automation: Makefiles for cross-platform build & test orchestration.
- Docker Desktop installed
- OpenAI API Key
- Node.js (Optional, for local UI testing)
-
Clone the repository
git clone https://github.com/Nibir1/Poseidon-Link.git cd Poseidon-Link -
Set Environment Variables Create a
.envfile in the root directory:OPENAI_API_KEY=sk-proj-xxxx...
-
Build and Run
make build
The make command automates the Docker Compose build process. Once complete:
- Dashboard: http://localhost:5173
- Broker API: http://localhost:8080
This project maintains 100% Test Coverage across all three languages. We use a unified Makefile to run tests in isolated containers (for Go/C++) and locally (for React).
The testing suite includes:
- Physics Verification: Ensures RPM acceleration and fuel curves match mathematical models.
- Integration Tests: Verifies WebSocket message broadcasting and JSON cleaning logic.
- Component Tests: Validates UI rendering and prop handling.
To run the full test suite with clean, "demo-ready" output:
make testsThe Physics Loop (thruster.cpp) The C++ engine runs a continuous update(dt) loop 60 times per second.
-
Thermodynamics: Oil temperature rises based on RPM squared (
$RPM^2$ ) and cools via ambient dissipation. - Fluid Dynamics: Fuel flow is calculated as a function of Torque + Weather Load Factor (0.0 for Calm, 0.8 for Storm).
The AI Workflow (main.go)
- Ingestion: User speaks a command via the React UI.
- Translation: Go Broker sends the text to OpenAI with a system prompt defining the vessel's API.
- Execution: AI returns a raw JSON payload (e.g., {"targetRPM": 850}).
- Sanitization: The Broker strips Markdown formatting and forwards the clean command to the C++ Engine.
Poseidon-Link/
├── docker-compose.yml # Orchestration
├── Makefile # Automation Scripts
├── remote-dashboard/ # React Frontend
│ ├── src/
│ │ ├── components/ # Gauges, Weather Overlay, AI Pilot
│ │ ├── hooks/ # WebSocket Logic
│ │ └── App.tsx # Main Layout
│ └── package.json
├── telemetry-broker/ # Go Backend
│ ├── main.go # WebSocket Hub & AI Handler
│ └── main_test.go # Unit Tests
├── vessel-sim/ # C++ Physics Engine
│ ├── src/
│ │ ├── thruster.cpp # Physics Logic
│ │ └── test_suite.cpp # Physics Verification
│ └── Dockerfile # Multi-Stage Build
└── README.md
- Core Physics Engine (60Hz Loop)
- AI Voice Control & JSON Parsing
- Weather Simulation (Physics + Visuals)
- Automated Captain's Logs
- Digital Twin Replay System
- Fleet Management (Multi-Vessel Support)
Poseidon Link is released under the MIT License (see LICENSE).
OpenAI Cloud model weight have their own licenses — please review them before use.
Nahasat Nibir — Building intelligent, high‑performance developer tools and AI‑powered systems in Go and Python.
- GitHub: https://github.com/Nibir1
- LinkedIn: https://www.linkedin.com/in/nibir-1/
- ArtStation: https://www.artstation.com/nibir
🐞 Report Bug · 💡 Request Feature · ⭐ Star the project