# paulinotech1/atlas architecture

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

- Interactive diagram: https://gitdiagram.com/paulinotech1/atlas
- Repository: https://github.com/paulinotech1/atlas

## Overview

Atlas is a loopback-only network observatory whose main workflow is local TCP discovery, evidence collection, and browser-based inspection. Separate capabilities import BLE captures, accept authenticated sensor observations, generate alerts and identity history, and run offline capture/network research. The Python service owns orchestration and SQLite-backed inventory; a bounded subprocess boundary delegates BLE parsing and investigation queries to Rust. Android is a separate application and is not included here. Evidence is limited to the supplied excerpts, source index references, and README; unshown UI/API wiring is omitted where not documented.

Main entry points: [`native/src/investigate/mod.rs`](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/mod.rs) (Investigation dispatch), [`atlaslib/service.py`](https://github.com/paulinotech1/atlas/blob/main/atlaslib/service.py) (Service orchestration), [`atlaslib/http.py`](https://github.com/paulinotech1/atlas/blob/main/atlaslib/http.py) (HTTP API), [`atlaslib/storage.py`](https://github.com/paulinotech1/atlas/blob/main/atlaslib/storage.py) (SQLite store)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Runtime and API"]
  node_cli["CLI entry<br/>[atlas.py]"]
  node_http["HTTP API<br/>[http.py]"]
  node_service["Service orchestration<br/>[service.py]"]
  node_engine["Rust boundary<br/>[engine.py]"]
end

subgraph group_network["Network observation"]
  node_collector["TCP collectors<br/>[collectors.py]"]
  node_observer["Observation runner<br/>[observer.py]"]
  node_network_context["Network contexts<br/>[wifi_context.py]"]
end

subgraph group_capture["Capture and research"]
  node_ble_import["BLE import<br/>[ble_bridge.py]"]
  node_rust_runtime["Native dispatcher<br/>[main.rs]"]
  node_ble_parse["BLE parser<br/>[capture.rs]"]
  node_investigation["Investigation dispatch<br/>[mod.rs]"]
  node_capture_store["Capture queries<br/>[captures.rs]"]
  node_research["Research analysis<br/>[research.rs]"]
  node_network_research["TCP timing research"]
  node_kernels["Analysis kernels<br/>[kernels.rs]"]
end

subgraph group_records["Evidence and history"]
  node_alerts["Alerts<br/>[alerts.rs]"]
  node_sensor_gateway["Sensor gateway<br/>[sensors.rs]"]
  node_overview["Inventory overview<br/>[overview.rs]"]
  node_reports["Device reports<br/>[reports.rs]"]
  node_storage[("SQLite store<br/>[storage.py]")]
end

subgraph group_interface["Browser workspaces"]
  node_dashboard["Network dashboard<br/>[app.js]"]
  node_investigate_ui["Investigation workspace<br/>[investigate.js]"]
  node_api_client["API client<br/>[api-client.js]"]
end

node_operator(("Operator"))
node_browser(("Browser"))
node_sensors(("Sensor clients"))
node_network_env(("Local network"))

node_operator -->|"starts"| node_cli
node_cli -->|"starts service"| node_service
node_cli -->|"starts server"| node_http
node_browser -->|"uses"| node_dashboard
node_dashboard -.->|"requests API"| node_http
node_investigate_ui -.->|"requests API"| node_http
node_api_client -.->|"API access"| node_http
node_http -->|"routes operations"| node_service
node_http -->|"routes ingestion"| node_sensor_gateway
node_sensors -->|"submits observations"| node_http
node_service -->|"reads and writes"| node_storage
node_service -->|"runs collection"| node_collector
node_service -->|"updates observations"| node_observer
node_service -->|"tracks context"| node_network_context
node_collector -->|"probes TCP"| node_network_env
node_service -->|"imports captures"| node_ble_import
node_ble_import -->|"invokes analysis"| node_engine
node_engine -->|"runs subprocess"| node_rust_runtime
node_rust_runtime -->|"parses captures"| node_ble_parse
node_rust_runtime -->|"dispatches queries"| node_investigation
node_investigation -->|"dispatches capture ops"| node_capture_store
node_investigation -->|"dispatches research"| node_research
node_investigation -->|"dispatches network research"| node_network_research
node_investigation -->|"dispatches alert ops"| node_alerts
node_investigation -->|"dispatches sensor ops"| node_sensor_gateway
node_investigation -->|"dispatches overview"| node_overview
node_investigation -->|"dispatches reports"| node_reports
node_research -->|"uses kernels"| node_kernels
node_network_research -->|"uses kernels"| node_kernels
node_sensor_gateway -.->|"stores observations"| node_storage
node_alerts -.->|"reads history"| node_storage
node_overview -.->|"reads inventory"| node_storage
node_reports -.->|"reads evidence"| node_storage

click node_cli "https://github.com/paulinotech1/atlas/blob/main/atlas.py"
click node_http "https://github.com/paulinotech1/atlas/blob/main/atlaslib/http.py"
click node_service "https://github.com/paulinotech1/atlas/blob/main/atlaslib/service.py"
click node_engine "https://github.com/paulinotech1/atlas/blob/main/atlaslib/engine.py"
click node_collector "https://github.com/paulinotech1/atlas/blob/main/atlaslib/collectors.py"
click node_observer "https://github.com/paulinotech1/atlas/blob/main/atlaslib/observer.py"
click node_network_context "https://github.com/paulinotech1/atlas/blob/main/atlaslib/wifi_context.py"
click node_ble_import "https://github.com/paulinotech1/atlas/blob/main/ble_bridge.py"
click node_rust_runtime "https://github.com/paulinotech1/atlas/blob/main/native/src/main.rs"
click node_ble_parse "https://github.com/paulinotech1/atlas/blob/main/native/src/capture.rs"
click node_investigation "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/mod.rs"
click node_capture_store "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/captures.rs"
click node_research "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/research.rs"
click node_network_research "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/research_network.rs"
click node_kernels "https://github.com/paulinotech1/atlas/blob/main/native/src/kernels.rs"
click node_alerts "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/alerts.rs"
click node_sensor_gateway "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/sensors.rs"
click node_overview "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/overview.rs"
click node_reports "https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/reports.rs"
click node_storage "https://github.com/paulinotech1/atlas/blob/main/atlaslib/storage.py"
click node_dashboard "https://github.com/paulinotech1/atlas/blob/main/static/app.js"
click node_investigate_ui "https://github.com/paulinotech1/atlas/blob/main/static/investigate.js"
click node_api_client "https://github.com/paulinotech1/atlas/blob/main/static/api-client.js"

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_cli,node_http,node_service,node_engine,node_browser,node_sensors toneBlue
class node_collector,node_observer,node_network_context toneAmber
class node_ble_import,node_rust_runtime,node_ble_parse,node_investigation,node_capture_store,node_research,node_network_research,node_kernels toneMint
class node_alerts,node_sensor_gateway,node_overview,node_reports,node_storage toneRose
class node_dashboard,node_investigate_ui,node_api_client,node_operator,node_network_env toneIndigo
```

## Components

### Runtime and API

- [CLI entry](https://github.com/paulinotech1/atlas/blob/main/atlas.py): `atlas.py`
- [HTTP API](https://github.com/paulinotech1/atlas/blob/main/atlaslib/http.py): `atlaslib/http.py`
- [Service orchestration](https://github.com/paulinotech1/atlas/blob/main/atlaslib/service.py): `atlaslib/service.py`
- [Rust boundary](https://github.com/paulinotech1/atlas/blob/main/atlaslib/engine.py): `atlaslib/engine.py`

### Network observation

- [TCP collectors](https://github.com/paulinotech1/atlas/blob/main/atlaslib/collectors.py): `atlaslib/collectors.py`
- [Observation runner](https://github.com/paulinotech1/atlas/blob/main/atlaslib/observer.py): `atlaslib/observer.py`
- [Network contexts](https://github.com/paulinotech1/atlas/blob/main/atlaslib/wifi_context.py): `atlaslib/wifi_context.py`

### Capture and research

- [BLE import](https://github.com/paulinotech1/atlas/blob/main/ble_bridge.py): `ble_bridge.py`
- [Native dispatcher](https://github.com/paulinotech1/atlas/blob/main/native/src/main.rs): `native/src/main.rs`
- [BLE parser](https://github.com/paulinotech1/atlas/blob/main/native/src/capture.rs): `native/src/capture.rs`
- [Investigation dispatch](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/mod.rs): `native/src/investigate/mod.rs`
- [Capture queries](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/captures.rs): `native/src/investigate/captures.rs`
- [Research analysis](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/research.rs): `native/src/investigate/research.rs`
- [TCP timing research](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/research_network.rs): `native/src/investigate/research_network.rs`
- [Analysis kernels](https://github.com/paulinotech1/atlas/blob/main/native/src/kernels.rs): `native/src/kernels.rs`

### Evidence and history

- [Alerts](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/alerts.rs): `native/src/investigate/alerts.rs`
- [Sensor gateway](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/sensors.rs): `native/src/investigate/sensors.rs`
- [Inventory overview](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/overview.rs): `native/src/investigate/overview.rs`
- [Device reports](https://github.com/paulinotech1/atlas/blob/main/native/src/investigate/reports.rs): `native/src/investigate/reports.rs`
- [SQLite store](https://github.com/paulinotech1/atlas/blob/main/atlaslib/storage.py): `atlaslib/storage.py`

### Browser workspaces

- [Network dashboard](https://github.com/paulinotech1/atlas/blob/main/static/app.js): `static/app.js`
- [Investigation workspace](https://github.com/paulinotech1/atlas/blob/main/static/investigate.js): `static/investigate.js`
- [API client](https://github.com/paulinotech1/atlas/blob/main/static/api-client.js): `static/api-client.js`

### Other components

- **Operator**
- **Browser**
- **Sensor clients**
- **Local network**

## Connections

- Operator → CLI entry: starts (evidence: `README.md`)
- CLI entry → Service orchestration: starts service (evidence: `atlas.py`)
- CLI entry → HTTP API: starts server (evidence: `atlas.py`)
- Browser → Network dashboard: uses (evidence: `README.md`)
- Network dashboard → HTTP API: requests API
- Investigation workspace → HTTP API: requests API
- API client → HTTP API: API access
- HTTP API → Service orchestration: routes operations (evidence: `atlaslib/http.py`)
- HTTP API → Sensor gateway: routes ingestion (evidence: `README.md`)
- Sensor clients → HTTP API: submits observations (evidence: `README.md`)
- Service orchestration → SQLite store: reads and writes (evidence: `atlaslib/service.py`)
- Service orchestration → TCP collectors: runs collection (evidence: `atlaslib/service.py`)
- Service orchestration → Observation runner: updates observations (evidence: `atlaslib/service.py`)
- Service orchestration → Network contexts: tracks context (evidence: `atlaslib/service.py`)
- TCP collectors → Local network: probes TCP (evidence: `README.md`)
- Service orchestration → BLE import: imports captures (evidence: `atlaslib/service.py`)
- BLE import → Rust boundary: invokes analysis (evidence: `ble_bridge.py`)
- Rust boundary → Native dispatcher: runs subprocess (evidence: `atlaslib/engine.py`)
- Native dispatcher → BLE parser: parses captures (evidence: `native/src/main.rs`)
- Native dispatcher → Investigation dispatch: dispatches queries (evidence: `native/src/main.rs`)
- Investigation dispatch → Capture queries: dispatches capture ops (evidence: `native/src/investigate/mod.rs`)
- Investigation dispatch → Research analysis: dispatches research (evidence: `native/src/investigate/mod.rs`)
- Investigation dispatch → TCP timing research: dispatches network research (evidence: `native/src/investigate/mod.rs`)
- Investigation dispatch → Alerts: dispatches alert ops (evidence: `native/src/investigate/mod.rs`)
- Investigation dispatch → Sensor gateway: dispatches sensor ops (evidence: `native/src/investigate/mod.rs`)
- Investigation dispatch → Inventory overview: dispatches overview (evidence: `native/src/investigate/mod.rs`)
- Investigation dispatch → Device reports: dispatches reports (evidence: `native/src/investigate/mod.rs`)
- Research analysis → Analysis kernels: uses kernels (evidence: `native/src/investigate/research.rs`)
- TCP timing research → Analysis kernels: uses kernels (evidence: `native/src/investigate/research_network.rs`)
- Sensor gateway → SQLite store: stores observations
- Alerts → SQLite store: reads history
- Inventory overview → SQLite store: reads inventory
- Device reports → SQLite store: reads evidence
