How dimensionalos/dimos works
1. Overall shape
- This repository is a robotics OS/framework built around a module graph. Most functionality is expressed as composable Python modules, wired together into blueprints and executed under a central coordination/runtime layer.
- The key architectural idea is: sensors, agents, planners, controllers, and recorders are all modules connected by typed streams and RPC, rather than one monolithic application.
2. Runtime and orchestration layer
- dimos.core is the foundation: it provides the module abstraction, blueprint composition, coordination/coordinator, process lifecycle, RPC, streaming, daemon/CLI runtime, and run registry.
- This layer is what turns a set of modules into a running system, handles process boundaries, worker management, and supports reloading/monitoring.
- The dimos/robot/cli and top-level dimos command are the user-facing control plane for starting runs, checking status, tailing logs, sending agent commands, and invoking MCP tools.
3. Data exchange boundaries
- The system separates communication into:
- Streams/pub-sub for continuous data such as images, lidar, odometry, joint state, paths, detections, etc.
- RPC for discrete commands and lifecycle actions.
- dimos.protocol contains transport implementations and protocol adapters: LCM, ROS, DDS, Redis, SHM, JPEG-over-transport, plus TF-related support.
- This means the architecture is transport-agnostic at the module level: the same module graph can run over shared memory, ROS 2, LCM, or other backends depending on the blueprint.
4. Robot abstraction layer
- dimos.robot defines platform-specific blueprints, connections, configs, and catalog entries for supported robots.
- It is the boundary between the generic OS and actual hardware families: Unitree Go2/B1/G1, XArm, Piper, drones, and some DIY/misc setups.
- These robot packages assemble sensors, effectors, teleop, navigation, perception, and agent modules into specific “runfiles” such as unitree-go2, unitree-g1-sim, or drone-agentic.
5. Hardware adapters
- dimos.hardware contains the low-level interfaces for hardware classes:
- Drive trains
- Manipulators
- Sensors (camera, lidar, whole-body interfaces)
- Each hardware family typically has a spec/registry plus concrete adapters for real devices and mocks/sim variants.
- This is where vendor-specific logic lives, while higher layers consume standardized robot-state and command messages.
6. Sensor ingestion and streaming
- dimos.hardware.sensors and dimos.stream form the ingestion pipeline for raw robot data.
- Cameras, lidar, RTSP/ROS video providers, audio pipelines, and frame processors feed standardized message streams into the rest of the system.
- The stream layer also provides operators, mergers, quality filters, and temporal alignment, which is important because many downstream modules assume synchronized multimodal input.
7. Perception stack
- dimos.perception handles object detection, tracking, re-identification, fiducials, spatial perception, and experimental temporal memory.
- The perception boundary is: raw sensor streams in, semantic detections / object state / markers / spatial memory out.
- It includes both 2D and 3D detection types, object databases, person tracking, and a temporal-memory subsystem that turns frame windows into durable entity/state graphs.
8. Mapping and spatial reasoning
- dimos.mapping is responsible for occupancy grids, point-cloud occupancy, voxel maps, loop closure, relocalization, ray tracing, and Google Maps / OSM integration.
- This layer consumes perception and localization signals to produce maps, costs, paths, and geo context.
- It is a key bridge between raw robot sensing and navigation: occupancy and topology outputs feed planning modules, while external map providers add global spatial context.
9. Navigation and autonomy
- dimos.navigation contains multiple navigation paradigms:
- nav stack with planners, local planners, path followers, terrain analysis, PGO, and evaluation tooling
- replanning A\* and other path-planning logic
- patrolling routers and frontier-based exploration
- visual servoing and detection-driven navigation
- This subsystem sits between mapping/perception and motor control, producing actionable trajectories or velocity commands.
- The navigation/nav_stack subtree also includes C++ extensions for performance-critical planning components.
10. Control and actuation
- dimos.control and dimos.manipulation.control are the execution layer for robot motion.
- They implement task abstractions such as velocity, trajectory, servo, teleop, and Cartesian IK tasks, plus coordinators and tick loops.
- For robots with arms or whole-body actuation, these controllers convert higher-level goals into joint, twist, or motor commands, typically consuming state feedback from sensors and planning outputs from navigation/manipulation.
11. Manipulation and grasping
- dimos.manipulation provides the higher-level arm/gripper side of the stack: kinematics, planning, world monitoring, trajectory generation, grasp generation, pick-and-place, and module wrappers.
- It depends on both perception and hardware: world models and robot state inform planning; low-level arm drivers execute the motion.
- This subsystem is distinct from navigation but shares the same module/runtime infrastructure, so manipulation can be orchestrated alongside mobility and perception.
12. Agent and MCP layer
- dimos.agents is the agentic interface layer: Ollama/VLM-based agents, demo agents, skill wrappers, prompts, annotations, and MCP client/server pieces.
- dimos.agents.mcp exposes robot capabilities as tools that an LLM-driven agent can call.
- The data flow here is typically: human input or model output → agent reasoning → skill/tool invocation → robot/navigation/control modules → feedback streams.
- This is one of the repository’s core differentiators: natural-language-driven robot behavior over the same module graph.
13. Skills and cross-cutting behaviors
- dimos.skills and dimos.agents.skills define reusable behaviors like speak, rest, manipulation actions, navigation helpers, person-follow, and demo skills.
- Skills are the bridge between agent intent and concrete robot actions; they package domain operations into a form suitable for direct invocation by agents or blueprints.
- In diagrams, skills belong between the agent layer and the hardware/control layers.
14. Simulation and replay
- dimos.simulation supports MuJoCo, Unity, Isaac, Genesis, and DimSim-style simulation backends.
- There are also replay/data-driven workflows in data/, dimos.memory2, and various replay/testing utilities that let the system operate on recorded sessions without live hardware.
- This means the architecture supports three execution modes: real robot, simulation, and replay/offline analysis.
15. Memory, storage, and visualization
- dimos.memory2 is a separate memory architecture for observation storage, vector search, blob storage, codecs, streaming, replay, and visualization.
- It is used for durable spatio-temporal memory and makes heavy use of SQLite/memory/file-backed storage, embeddings, and visual tools.
- dimos.visualization, dimos.web, and dimos.utils.cli provide observability surfaces such as rerun/websocket dashboards, web interfaces, and command-line inspection tools.
16. Native extension and tooling boundaries
- Performance-critical or interoperable parts are implemented in C++, Rust, and some Nix/Docker tooling, especially around lidar processing, planning, and native module support.
- The repository also includes extensive test suites, fixtures, and LFS-backed datasets/models, which indicate that many subsystems are validated using recorded sensor streams and integration runs.
- For an architecture diagram, it is useful to draw a boundary around the Python orchestration layer and another around native/simulation/vendor-specific runtime dependencies.
Main entry points: core Core runtime · stream Streams · perception Perception · agents Agents
Components 20
Runtime
Module graph, orchestration, RPC, streams, and run lifecycle.
- Core runtime · Module abstraction, blueprints, coordination, workers, lifecycle, daemon, and run registry.
dimos/core - Protocols · Pub/sub, RPC, service, and TF transports across LCM, ROS, DDS, Redis, and SHM.
dimos/protocol - Message types · Shared robot, sensor, navigation, perception, and geometry message definitions.
dimos/msgs - Streams · Video, audio, merging, operators, and frame processing for continuous sensor data.
dimos/stream
Robotics Stack
Hardware-facing subsystems from sensors through actuation.
- Hardware · Low-level adapters and registries for drives, manipulators, sensors, and whole-body interfaces.
dimos/hardware - Sensors · Camera and lidar ingestion modules, device adapters, and sensor-specific blueprints.
dimos/hardware/sensors - Perception · Detection, tracking, re-identification, fiducials, spatial perception, and temporal memory.
dimos/perception - Mapping · Occupancy, point-cloud maps, loop closure, relocalization, ray tracing, and map services.
dimos/mapping - Navigation · Nav stack, replanning A*, patrol/exploration, visual servoing, and movement management.
dimos/navigation - Control · Task abstractions, tick loops, coordinators, and command execution for motion control.
dimos/control - Manipulation · Kinematics, world monitoring, grasp generation, pick-and-place, and arm control.
dimos/manipulation - Memory · Observation storage, vector search, blob storage, replay, codecs, and visualization.
dimos/memory2
Agentic Layer
LLM-driven agents, skills, and tool invocation.
Robot Platforms
Platform-specific blueprints and robot family assemblies.
- Robot blueprints · Platform catalog, robot-specific blueprints, connection modules, and runfile assembly.
dimos/robot
Execution Modes
Simulation, replay, and offline/session-backed workflows.
- Simulation · MuJoCo, Unity, Isaac, Genesis, and DimSim execution backends.
dimos/simulation - Native code · Performance-critical extensions and interoperability layers for planning and hardware integration.
native
Operations
CLI, web, visualization, and observability surfaces.
- Robot CLI · User-facing command line entrypoints for starting runs, status, logs, and tool calls.
dimos/robot/cli - Web UI · FastAPI/Flask/websocket interfaces and browser dashboards for robot interaction and monitoring.
dimos/web - Visualization · Rerun/websocket visualization bridge and rendering modules.
dimos/visualization
Connections 28
- Core runtime → Protocols: uses · Core runtime relies on transports for pub/sub and RPC.
- Core runtime → Message types: exchanges · Runtime modules communicate through shared typed messages.
- Core runtime → Streams: hosts · Stream modules are executed and coordinated by the runtime.
- Core runtime → Robot CLI: drives · CLI triggers run lifecycle, monitoring, and control actions.
- Core runtime → Robot blueprints: loads · Blueprints and runfiles are composed into runnable systems.
- Protocols → Message types: encodes · Transports serialize shared message schemas.
- Streams → Perception: feeds · Sensor streams are consumed by perception modules.
- Sensors → Streams: publishes · Camera and lidar adapters emit continuous streams.
- Hardware → Control: adapts · Hardware interfaces expose actuation and state feedback.
- Perception → Mapping: provides · Semantic outputs inform maps and spatial context.
- Mapping → Navigation: informs · Occupancy and path context drive planning and autonomy.
- Navigation → Control: commands · Planners and followers produce executable motion commands.
- Control → Hardware: executes · Control tasks send commands to robot interfaces.
- Manipulation → Perception: consumes · Grasping and world modeling use perception outputs.
- Manipulation → Control: executes via · Manipulation planners rely on low-level arm control.
- Agents → Skills: invokes · Agents call reusable behaviors and tools.
- Skills → Navigation: uses · Skills wrap navigation behaviors and helpers.
- Skills → Manipulation: uses · Skills wrap arm and pick-and-place behaviors.
- Agents → Robot CLI: exposed by · Agent and MCP workflows are surfaced through the CLI/control plane.
- Agents → Perception: consumes · Agentic behaviors can reason over detections and spatial state.
- Memory → Perception: stores · Observation storage persists semantic and visual history.
- Memory → Streams: replays · Recorded data can be streamed back through the pipeline.
- Simulation → Hardware: mocks · Simulators stand in for physical devices and sensors.
- Simulation → Streams: publishes · Simulation emits the same stream interfaces as hardware.
- Native code → Navigation: accelerates · Performance-critical planning components use native extensions.
- Native code → Hardware: supports · Native code underpins low-level device and transport integration.
- Visualization → Web UI: renders · Visualization is served through web and websocket surfaces.
- Web UI → Agents: interfaces · Web frontends interact with agent and command flows.