# fararen/humanoidth architecture

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

- Interactive diagram: https://gitdiagram.com/fararen/humanoidth
- Repository: https://github.com/fararen/humanoidth

## Overview

Thailand Humanoid Atlas is a research database and interactive map of Thailand’s humanoid and social-robotics ecosystem. Its user workflow is to collect records from external sources or community submissions, review and store them, then explore the resulting perspectives, contributions, robot registry, and physical inventory through the atlas, map, network, and analytics views. The graph includes documented product capabilities and the sampled API/network implementation. Most page-to-data wiring and the Python pipeline internals were not sampled, so uncertain links are omitted.

Main entry points: [`src/humanoid_atlas/adapters/__init__.py`](https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/adapters/__init__.py) (Source adapters), [`lib/network-graph.ts`](https://github.com/fararen/humanoidth/blob/main/lib/network-graph.ts) (Graph builder), [`src/humanoid_atlas/cli.py`](https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/cli.py) (Atlas CLI), [`app/page.tsx`](https://github.com/fararen/humanoidth/blob/main/app/page.tsx) (Overview)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Atlas interface"]
  node_overview["Overview<br/>[page.tsx]"]
  node_registry["Robot registry<br/>[page.tsx]"]
  node_perspectives["Perspectives<br/>[page.tsx]"]
  node_contributions["Contributions<br/>[page.tsx]"]
  node_inventory["Asset inventory<br/>[page.tsx]"]
  node_map["Contribution map<br/>[page.tsx]"]
  node_mapdata["Map data actions<br/>[actions.ts]"]
  node_networkui["Network explorer"]
  node_analytics["Analytics<br/>[page.tsx]"]
end

subgraph group_collection["Collection and review"]
  node_pulls["Data pulls<br/>[page.tsx]"]
  node_ingestapi["Ingest endpoint<br/>[route.ts]"]
  node_adapters["Ingest adapters<br/>[adapters.ts]"]
  node_submission["Community submission<br/>[page.tsx]"]
  node_admin["Submission review<br/>[page.tsx]"]
  node_export["CSV export<br/>[route.ts]"]
end

subgraph group_data["Data and analysis"]
  node_networkapi["Network API<br/>[route.ts]"]
  node_networkdetail["Network detail APIs<br/>[route.ts]"]
  node_graphbuilder["Graph builder<br/>[network-graph.ts]"]
  node_database[("Atlas database<br/>[prisma.ts]")]
end

subgraph group_research["Research pipeline"]
  node_python_cli["Atlas CLI<br/>[cli.py]"]
  node_python_adapters["Source adapters<br/>[__init__.py]"]
  node_python_pipeline["Analysis pipeline<br/>[nlp.py]"]
  node_python_repos["Data repositories<br/>[repos.py]"]
end

node_visitor(("Atlas visitor"))
node_external_sources{{"Research sources"}}

node_visitor -->|"browses"| node_overview
node_visitor -->|"starts pulls"| node_pulls
node_visitor -->|"submits records"| node_submission
node_ingestapi -->|"runs adapter"| node_adapters
node_adapters -.->|"retrieves records"| node_external_sources
node_networkui -->|"fetches graph"| node_networkapi
node_networkapi -->|"builds graph"| node_graphbuilder
node_networkdetail -->|"looks up detail"| node_graphbuilder
node_graphbuilder -->|"reads records"| node_database
node_overview -->|"reads metrics"| node_database
node_map -->|"requests points"| node_mapdata
node_python_cli -->|"runs collection"| node_python_adapters
node_python_cli -->|"runs analysis"| node_python_pipeline
node_python_adapters -.->|"collects records"| node_external_sources
node_python_pipeline -->|"uses data"| node_python_repos
node_python_adapters -->|"stores records"| node_python_repos

click node_overview "https://github.com/fararen/humanoidth/blob/main/app/page.tsx"
click node_registry "https://github.com/fararen/humanoidth/blob/main/app/robots/page.tsx"
click node_perspectives "https://github.com/fararen/humanoidth/blob/main/app/perspectives/page.tsx"
click node_contributions "https://github.com/fararen/humanoidth/blob/main/app/contributions/page.tsx"
click node_inventory "https://github.com/fararen/humanoidth/blob/main/app/inventory/page.tsx"
click node_map "https://github.com/fararen/humanoidth/blob/main/app/map/page.tsx"
click node_mapdata "https://github.com/fararen/humanoidth/blob/main/app/map/actions.ts"
click node_networkui "https://github.com/fararen/humanoidth/blob/main/app/network/NetworkGraphClient.tsx"
click node_analytics "https://github.com/fararen/humanoidth/blob/main/app/analytics/page.tsx"
click node_pulls "https://github.com/fararen/humanoidth/blob/main/app/data-pulls/page.tsx"
click node_ingestapi "https://github.com/fararen/humanoidth/blob/main/app/api/ingest/%5Badapter%5D/route.ts"
click node_adapters "https://github.com/fararen/humanoidth/blob/main/lib/ingest/adapters.ts"
click node_submission "https://github.com/fararen/humanoidth/blob/main/app/submit-data/page.tsx"
click node_admin "https://github.com/fararen/humanoidth/blob/main/app/admin/submitted-data/page.tsx"
click node_export "https://github.com/fararen/humanoidth/blob/main/app/api/export/route.ts"
click node_networkapi "https://github.com/fararen/humanoidth/blob/main/app/api/network/graph/route.ts"
click node_networkdetail "https://github.com/fararen/humanoidth/blob/main/app/api/network/node/%5Bnode_id%5D/route.ts"
click node_graphbuilder "https://github.com/fararen/humanoidth/blob/main/lib/network-graph.ts"
click node_database "https://github.com/fararen/humanoidth/blob/main/lib/prisma.ts"
click node_python_cli "https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/cli.py"
click node_python_adapters "https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/adapters/__init__.py"
click node_python_pipeline "https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/pipeline/nlp.py"
click node_python_repos "https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/db/repos.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_overview,node_registry,node_perspectives,node_contributions,node_inventory,node_map,node_mapdata,node_networkui,node_analytics toneBlue
class node_pulls,node_ingestapi,node_adapters,node_submission,node_admin,node_export toneAmber
class node_networkapi,node_networkdetail,node_graphbuilder,node_database toneMint
class node_python_cli,node_python_adapters,node_python_pipeline,node_python_repos toneRose
class node_visitor,node_external_sources toneIndigo
```

## Components

### Atlas interface

- [Overview](https://github.com/fararen/humanoidth/blob/main/app/page.tsx): `app/page.tsx`
- [Robot registry](https://github.com/fararen/humanoidth/blob/main/app/robots/page.tsx): `app/robots/page.tsx`
- [Perspectives](https://github.com/fararen/humanoidth/blob/main/app/perspectives/page.tsx): `app/perspectives/page.tsx`
- [Contributions](https://github.com/fararen/humanoidth/blob/main/app/contributions/page.tsx): `app/contributions/page.tsx`
- [Asset inventory](https://github.com/fararen/humanoidth/blob/main/app/inventory/page.tsx): `app/inventory/page.tsx`
- [Contribution map](https://github.com/fararen/humanoidth/blob/main/app/map/page.tsx): `app/map/page.tsx`
- [Map data actions](https://github.com/fararen/humanoidth/blob/main/app/map/actions.ts): `app/map/actions.ts`
- [Network explorer](https://github.com/fararen/humanoidth/blob/main/app/network/NetworkGraphClient.tsx): `app/network/NetworkGraphClient.tsx`
- [Analytics](https://github.com/fararen/humanoidth/blob/main/app/analytics/page.tsx): `app/analytics/page.tsx`

### Collection and review

- [Data pulls](https://github.com/fararen/humanoidth/blob/main/app/data-pulls/page.tsx): `app/data-pulls/page.tsx`
- [Ingest endpoint](https://github.com/fararen/humanoidth/blob/main/app/api/ingest/%5Badapter%5D/route.ts): `app/api/ingest/[adapter]/route.ts`
- [Ingest adapters](https://github.com/fararen/humanoidth/blob/main/lib/ingest/adapters.ts): `lib/ingest/adapters.ts`
- [Community submission](https://github.com/fararen/humanoidth/blob/main/app/submit-data/page.tsx): `app/submit-data/page.tsx`
- [Submission review](https://github.com/fararen/humanoidth/blob/main/app/admin/submitted-data/page.tsx): `app/admin/submitted-data/page.tsx`
- [CSV export](https://github.com/fararen/humanoidth/blob/main/app/api/export/route.ts): `app/api/export/route.ts`

### Data and analysis

- [Network API](https://github.com/fararen/humanoidth/blob/main/app/api/network/graph/route.ts): `app/api/network/graph/route.ts`
- [Network detail APIs](https://github.com/fararen/humanoidth/blob/main/app/api/network/node/%5Bnode_id%5D/route.ts): `app/api/network/node/[node_id]/route.ts`
- [Graph builder](https://github.com/fararen/humanoidth/blob/main/lib/network-graph.ts): `lib/network-graph.ts`
- [Atlas database](https://github.com/fararen/humanoidth/blob/main/lib/prisma.ts): `lib/prisma.ts`

### Research pipeline

- [Atlas CLI](https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/cli.py): `src/humanoid_atlas/cli.py`
- [Source adapters](https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/adapters/__init__.py): `src/humanoid_atlas/adapters/__init__.py`
- [Analysis pipeline](https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/pipeline/nlp.py): `src/humanoid_atlas/pipeline/nlp.py`
- [Data repositories](https://github.com/fararen/humanoidth/blob/main/src/humanoid_atlas/db/repos.py): `src/humanoid_atlas/db/repos.py`

### Other components

- **Atlas visitor**
- **Research sources**

## Connections

- Atlas visitor → Overview: browses
- Atlas visitor → Data pulls: starts pulls
- Atlas visitor → Community submission: submits records
- Ingest endpoint → Ingest adapters: runs adapter
- Ingest adapters → Research sources: retrieves records
- Network explorer → Network API: fetches graph
- Network API → Graph builder: builds graph
- Network detail APIs → Graph builder: looks up detail
- Graph builder → Atlas database: reads records
- Overview → Atlas database: reads metrics
- Contribution map → Map data actions: requests points
- Atlas CLI → Source adapters: runs collection
- Atlas CLI → Analysis pipeline: runs analysis
- Source adapters → Research sources: collects records
- Analysis pipeline → Data repositories: uses data
- Source adapters → Data repositories: stores records
