# abhishek-nadagiri/halomechanics architecture

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

- Interactive diagram: https://gitdiagram.com/abhishek-nadagiri/halomechanics
- Repository: https://github.com/abhishek-nadagiri/halomechanics

## Overview

HoloMechanix is a webcam-driven 3D engineering learning platform. In the web workflow, a user interacts through the browser; the FastAPI server provides model and learning APIs plus a real-time spatial endpoint, while camera and hand-tracking modules interpret movement and the browser presents the 3D experience. Model metadata and hierarchy underpin component inspection and dismantling; simulation and education provide additional capabilities. A separate desktop mode processes camera frames and renders an OpenCV HUD. The server excerpt omits much of the WebSocket loop, so some runtime links are documented rather than source-verified.

Main entry points: [`app/web/server.py`](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/web/server.py) (Web API And Stream), [`app/main.py`](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/main.py) (Application Entry), [`app/vision/gesture_engine.py`](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/gesture_engine.py) (Gesture Engine), [`app/vision/hand_tracker.py`](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/hand_tracker.py) (Hand Tracking)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_perception["Spatial Perception"]
  node_camera["Camera Capture<br/>[camera.py]"]
  node_hands["Hand Tracking<br/>[hand_tracker.py]"]
  node_fingers["Finger Tracking<br/>[finger_tracker.py]"]
  node_gestures["Gesture Engine<br/>[gesture_engine.py]"]
  node_spatial["Spatial Mapping<br/>[spatial_mapper.py]"]
end

subgraph group_domain["Models And Simulation"]
  node_metadata["Model Metadata<br/>[metadata.py]"]
  node_catalog[("Model Registry<br/>[registry.py]")]
  node_hierarchy["Assembly Hierarchy<br/>[hierarchy.py]"]
  node_components["Component State<br/>[component.py]"]
  node_mechanisms["Kinematic Simulation<br/>[mechanisms.py]"]
  node_manipulation["Gesture Manipulation<br/>[manipulation.py]"]
end

subgraph group_learning["Engineering Learning"]
  node_education["Learning And Diagnostics"]
end

subgraph group_experience["User Experiences"]
  node_entry["Application Entry<br/>[main.py]"]
  node_webserver["Web API And Stream<br/>[server.py]"]
  node_webclient["3D Browser Interface"]
  node_renderer["Desktop Renderer"]
  node_desktopui["Desktop HUD"]
end

node_user(("Engineer Or Learner"))

node_user -->|"interacts with"| node_webclient
node_webclient -.->|"streams interaction"| node_webserver
node_webserver -->|"serves static files"| node_webclient
node_entry -->|"launches web mode"| node_webserver
node_entry -->|"reads frames"| node_camera
node_entry -->|"tracks hands"| node_hands
node_entry -->|"evaluates gestures"| node_gestures
node_entry -->|"renders desktop"| node_renderer
node_entry -->|"uses HUD"| node_desktopui
node_camera -.->|"provides frames"| node_hands
node_gestures -->|"reads landmarks"| node_hands
node_gestures -->|"uses finger tracker"| node_fingers
node_webserver -.->|"captures frames"| node_camera
node_webserver -.->|"tracks hands"| node_hands
node_webserver -.->|"evaluates gestures"| node_gestures
node_webserver -.->|"maps interaction"| node_spatial
node_webserver -->|"serves model data"| node_catalog
node_catalog -->|"loads schemas"| node_metadata
node_hierarchy -->|"builds assembly tree"| node_metadata
node_manipulation -->|"updates dismantling"| node_hierarchy
node_manipulation -->|"dispatches gestures"| node_components
node_webserver -->|"serves learning features"| node_education
node_webserver -.->|"uses simulation"| node_mechanisms
node_user -->|"starts desktop mode"| node_entry

click node_entry "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/main.py"
click node_camera "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/camera.py"
click node_hands "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/hand_tracker.py"
click node_fingers "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/finger_tracker.py"
click node_gestures "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/gesture_engine.py"
click node_spatial "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/spatial_mapper.py"
click node_metadata "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/models/metadata.py"
click node_catalog "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/models/registry.py"
click node_hierarchy "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/models/hierarchy.py"
click node_components "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/simulation/component.py"
click node_mechanisms "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/simulation/mechanisms.py"
click node_manipulation "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/interaction/manipulation.py"
click node_education "https://github.com/abhishek-nadagiri/halomechanics/tree/main/app/education"
click node_webserver "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/web/server.py"
click node_webclient "https://github.com/abhishek-nadagiri/halomechanics/tree/main/app/web/static/js"
click node_renderer "https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/rendering/desktop_renderer.py"
click node_desktopui "https://github.com/abhishek-nadagiri/halomechanics/tree/main/app/ui"

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_camera,node_hands,node_fingers,node_gestures,node_spatial toneBlue
class node_metadata,node_catalog,node_hierarchy,node_components,node_mechanisms,node_manipulation toneAmber
class node_education toneMint
class node_entry,node_webserver,node_webclient,node_renderer,node_desktopui toneRose
class node_user toneIndigo
```

## Components

### Spatial Perception

- [Camera Capture](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/camera.py): `app/vision/camera.py`
- [Hand Tracking](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/hand_tracker.py): `app/vision/hand_tracker.py`
- [Finger Tracking](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/finger_tracker.py): `app/vision/finger_tracker.py`
- [Gesture Engine](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/gesture_engine.py): `app/vision/gesture_engine.py`
- [Spatial Mapping](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/vision/spatial_mapper.py): `app/vision/spatial_mapper.py`

### Models And Simulation

- [Model Metadata](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/models/metadata.py): `app/models/metadata.py`
- [Model Registry](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/models/registry.py): `app/models/registry.py`
- [Assembly Hierarchy](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/models/hierarchy.py): `app/models/hierarchy.py`
- [Component State](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/simulation/component.py): `app/simulation/component.py`
- [Kinematic Simulation](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/simulation/mechanisms.py): `app/simulation/mechanisms.py`
- [Gesture Manipulation](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/interaction/manipulation.py): `app/interaction/manipulation.py`

### Engineering Learning

- [Learning And Diagnostics](https://github.com/abhishek-nadagiri/halomechanics/tree/main/app/education): `app/education`

### User Experiences

- [Application Entry](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/main.py): `app/main.py`
- [Web API And Stream](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/web/server.py): `app/web/server.py`
- [3D Browser Interface](https://github.com/abhishek-nadagiri/halomechanics/tree/main/app/web/static/js): `app/web/static/js`
- [Desktop Renderer](https://github.com/abhishek-nadagiri/halomechanics/blob/main/app/rendering/desktop_renderer.py): `app/rendering/desktop_renderer.py`
- [Desktop HUD](https://github.com/abhishek-nadagiri/halomechanics/tree/main/app/ui): `app/ui`

### Other components

- **Engineer Or Learner**

## Connections

- Engineer Or Learner → 3D Browser Interface: interacts with (evidence: `README.md`)
- 3D Browser Interface → Web API And Stream: streams interaction (evidence: `README.md`)
- Web API And Stream → 3D Browser Interface: serves static files (evidence: `app/web/server.py`)
- Application Entry → Web API And Stream: launches web mode (evidence: `app/main.py`)
- Application Entry → Camera Capture: reads frames (evidence: `app/main.py`)
- Application Entry → Hand Tracking: tracks hands (evidence: `app/main.py`)
- Application Entry → Gesture Engine: evaluates gestures (evidence: `app/main.py`)
- Application Entry → Desktop Renderer: renders desktop (evidence: `app/main.py`)
- Application Entry → Desktop HUD: uses HUD (evidence: `app/main.py`)
- Camera Capture → Hand Tracking: provides frames
- Gesture Engine → Hand Tracking: reads landmarks (evidence: `app/vision/gesture_engine.py`)
- Gesture Engine → Finger Tracking: uses finger tracker (evidence: `app/vision/gesture_engine.py`)
- Web API And Stream → Camera Capture: captures frames (evidence: `app/web/server.py`)
- Web API And Stream → Hand Tracking: tracks hands (evidence: `app/web/server.py`)
- Web API And Stream → Gesture Engine: evaluates gestures (evidence: `app/web/server.py`)
- Web API And Stream → Spatial Mapping: maps interaction (evidence: `app/web/server.py`)
- Web API And Stream → Model Registry: serves model data (evidence: `app/web/server.py`)
- Model Registry → Model Metadata: loads schemas (evidence: `app/models/registry.py`)
- Assembly Hierarchy → Model Metadata: builds assembly tree (evidence: `app/models/hierarchy.py`)
- Gesture Manipulation → Assembly Hierarchy: updates dismantling (evidence: `app/interaction/manipulation.py`)
- Gesture Manipulation → Component State: dispatches gestures (evidence: `app/interaction/manipulation.py`)
- Web API And Stream → Learning And Diagnostics: serves learning features (evidence: `app/web/server.py`)
- Web API And Stream → Kinematic Simulation: uses simulation (evidence: `app/web/server.py`)
- Engineer Or Learner → Application Entry: starts desktop mode (evidence: `README.md`)
