# applied-ai-lab/ramp architecture

> Architecture diagram of the GitHub repository applied-ai-lab/ramp, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-11). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/applied-ai-lab/ramp
- Repository: https://github.com/applied-ai-lab/ramp

## Overview

RAMP is a baseline for robotic assembly manipulation: the user selects an assembly, the agent generates abstract, coarse, and fine plans, then dispatches actions through a ROS robot interface to assemble parts. The README also identifies a separate high-level planner dependency and ROS robot bring-up. The sampled sources establish the agent/interface and utility relationships; camera and controller wiring beyond the shown ROS subscriptions and robot API calls is not detailed.

Main entry points: [`core/action_interface.py`](https://github.com/applied-ai-lab/ramp/blob/main/core/action_interface.py) (Action interface), [`core/agent.py`](https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py) (Assembly agent), [`main.py`](https://github.com/applied-ai-lab/ramp/blob/main/main.py) (Run assembly), [`core/const.py`](https://github.com/applied-ai-lab/ramp/blob/main/core/const.py) (Part geometry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Entry"]
  node_main["Run assembly<br/>[main.py]"]
end

subgraph group_planning["Planning"]
  node_agent["Assembly agent<br/>[agent.py]"]
  node_abstract["Abstract planning<br/>[agent.py]"]
  node_coarse["Coarse planning<br/>[agent.py]"]
  node_fine["Fine planning<br/>[agent.py]"]
end

subgraph group_execution["Robot execution"]
  node_action["Action interface"]
end

subgraph group_support["Geometry and models"]
  node_constants["Part geometry<br/>[const.py]"]
  node_general["Attribute helpers<br/>[general_utils.py]"]
  node_transforms["Pose mathematics<br/>[transform_utils.py]"]
  node_ros_transforms["ROS frame transforms"]
end

node_user(("Assembly operator"))
node_planner["SPARC planner"]
node_markers(("AprilTag cameras"))
node_robot["ROS robot controller"]

node_user -->|"selects assembly"| node_main
node_main -->|"creates agent"| node_agent
node_agent -->|"generates plan"| node_abstract
node_abstract -.->|"guides planning"| node_coarse
node_coarse -.->|"refines plan"| node_fine
node_agent -->|"requests plans"| node_planner
node_agent -->|"dispatches actions"| node_action
node_action -->|"commands motion"| node_robot
node_markers -->|"sends detections"| node_action
node_action -->|"uses part geometry"| node_constants
node_action -->|"uses pose math"| node_transforms
node_action -->|"uses frame transforms"| node_ros_transforms
node_constants -->|"uses attributes"| node_general

click node_main "https://github.com/applied-ai-lab/ramp/blob/main/main.py"
click node_agent "https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py"
click node_abstract "https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py"
click node_coarse "https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py"
click node_fine "https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py"
click node_action "https://github.com/applied-ai-lab/ramp/blob/main/core/action_interface.py"
click node_constants "https://github.com/applied-ai-lab/ramp/blob/main/core/const.py"
click node_general "https://github.com/applied-ai-lab/ramp/blob/main/core/utils/general_utils.py"
click node_transforms "https://github.com/applied-ai-lab/ramp/blob/main/core/utils/transform_utils.py"
click node_ros_transforms "https://github.com/applied-ai-lab/ramp/blob/main/core/utils/ros_transform_utils.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_main toneBlue
class node_agent,node_abstract,node_coarse,node_fine toneAmber
class node_action toneMint
class node_constants,node_general,node_transforms,node_ros_transforms toneRose
class node_user,node_planner,node_markers,node_robot toneIndigo
```

## Components

### Entry

- [Run assembly](https://github.com/applied-ai-lab/ramp/blob/main/main.py): `main.py`

### Planning

- [Assembly agent](https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py): `core/agent.py`
- [Abstract planning](https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py): `core/agent.py`
- [Coarse planning](https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py): `core/agent.py`
- [Fine planning](https://github.com/applied-ai-lab/ramp/blob/main/core/agent.py): `core/agent.py`

### Robot execution

- [Action interface](https://github.com/applied-ai-lab/ramp/blob/main/core/action_interface.py): `core/action_interface.py`

### Geometry and models

- [Part geometry](https://github.com/applied-ai-lab/ramp/blob/main/core/const.py): `core/const.py`
- [Attribute helpers](https://github.com/applied-ai-lab/ramp/blob/main/core/utils/general_utils.py): `core/utils/general_utils.py`
- [Pose mathematics](https://github.com/applied-ai-lab/ramp/blob/main/core/utils/transform_utils.py): `core/utils/transform_utils.py`
- [ROS frame transforms](https://github.com/applied-ai-lab/ramp/blob/main/core/utils/ros_transform_utils.py): `core/utils/ros_transform_utils.py`

### Other components

- **Assembly operator**
- **SPARC planner**
- **AprilTag cameras**
- **ROS robot controller**

## Connections

- Assembly operator → Run assembly: selects assembly (evidence: `README.md`)
- Run assembly → Assembly agent: creates agent (evidence: `main.py`)
- Assembly agent → Abstract planning: generates plan (evidence: `core/agent.py`)
- Abstract planning → Coarse planning: guides planning (evidence: `core/agent.py`)
- Coarse planning → Fine planning: refines plan (evidence: `core/agent.py`)
- Assembly agent → SPARC planner: requests plans (evidence: `core/agent.py`)
- Assembly agent → Action interface: dispatches actions (evidence: `core/agent.py`)
- Action interface → ROS robot controller: commands motion (evidence: `core/action_interface.py`)
- AprilTag cameras → Action interface: sends detections (evidence: `core/action_interface.py`)
- Action interface → Part geometry: uses part geometry (evidence: `core/action_interface.py`)
- Action interface → Pose mathematics: uses pose math (evidence: `core/action_interface.py`)
- Action interface → ROS frame transforms: uses frame transforms (evidence: `core/action_interface.py`)
- Part geometry → Attribute helpers: uses attributes (evidence: `core/const.py`)
