# aayansh54/isl-translator architecture

> Architecture diagram of the GitHub repository aayansh54/isl-translator, 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/aayansh54/isl-translator
- Repository: https://github.com/aayansh54/isl-translator

## Overview

This is a browser-based Indian Sign Language interpreter with live recognition, guided landmark collection, and model-evaluation results. The main user workflow is to open the live screen, load model assets, capture hand landmarks (or use mock input), process predictions through the recognition pipeline, and display recognition feedback; the app also supports speech output and sentence building. Collection and evaluation are separate product workflows. Source excerpts establish several internal calls, but do not show every screen’s runtime wiring, so uncertain relationships are omitted or marked unverified.

Main entry points: [`frontend/src/App.tsx`](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/App.tsx) (App Router), [`frontend/src/screens/live/LiveScreen.tsx`](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/live/LiveScreen.tsx) (Live Interpreter), [`frontend/src/api/client.ts`](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/api/client.ts) (API Client), [`frontend/src/pipeline/pipeline.ts`](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/pipeline/pipeline.ts) (Frame Pipeline)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application UI"]
  node_app["App Router<br/>[App.tsx]"]
  node_live["Live Interpreter<br/>[LiveScreen.tsx]"]
  node_navbar["Navigation<br/>[Navbar.tsx]"]
  node_settings_ui["Settings Drawer<br/>[SettingsDrawer.tsx]"]
  node_signs["Sign Reference"]
end

subgraph group_recognition["Recognition Runtime"]
  node_tracker["Hand Tracker<br/>[tracker.ts]"]
  node_pipeline["Frame Pipeline<br/>[pipeline.ts]"]
  node_features["Feature Extraction<br/>[features.ts]"]
  node_model["Model Inference<br/>[model.ts]"]
  node_gate["Prediction Gate<br/>[gate.ts]"]
  node_mock["Mock Controller<br/>[mockController.ts]"]
  node_model_assets["Model Assets"]
  node_mock_assets["Fallback Assets"]
end

subgraph group_data["Collection And Evaluation"]
  node_collect["Data Collection<br/>[CollectScreen.tsx]"]
  node_results["Evaluation Results<br/>[ResultsScreen.tsx]"]
end

subgraph group_services["Preferences And Services"]
  node_api["API Client<br/>[client.ts]"]
  node_settings[("Settings Store<br/>[settings.ts]")]
  node_sentence["Sentence Buffer<br/>[sentence.ts]"]
  node_speech["Speech Output<br/>[tts.ts]"]
end

node_user(("User"))
node_backend["API Service"]
node_browser_speech["Browser Speech API"]

node_user -->|"uses"| node_app
node_app -->|"renders"| node_navbar
node_app -->|"routes to"| node_live
node_app -->|"routes to"| node_collect
node_app -->|"routes to"| node_results
node_app -->|"renders"| node_settings_ui
node_app -->|"renders"| node_signs
node_app -->|"loads vocabulary"| node_api
node_live -.->|"uses"| node_pipeline
node_live -->|"starts tracking"| node_tracker
node_live -->|"loads model"| node_model
node_live -->|"starts mock input"| node_mock
node_live -.->|"updates"| node_sentence
node_live -.->|"speaks signs"| node_speech
node_pipeline -->|"computes features"| node_features
node_pipeline -->|"predicts"| node_model
node_pipeline -.->|"filters predictions"| node_gate
node_pipeline -.->|"subscribes frames"| node_tracker
node_settings_ui -->|"lists cameras"| node_tracker
node_settings_ui -->|"lists voices"| node_speech
node_settings_ui -.->|"edits preferences"| node_settings
node_collect -->|"draws landmarks"| node_tracker
node_collect -.->|"uploads records"| node_api
node_results -.->|"loads metrics"| node_api
node_api -.->|"sends requests"| node_backend
node_api -->|"loads model files"| node_model_assets
node_api -->|"falls back to"| node_mock_assets
node_speech -->|"uses"| node_browser_speech

click node_app "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/App.tsx"
click node_live "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/live/LiveScreen.tsx"
click node_collect "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/collect/CollectScreen.tsx"
click node_results "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/results/ResultsScreen.tsx"
click node_navbar "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/components/Navbar.tsx"
click node_settings_ui "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/components/SettingsDrawer.tsx"
click node_signs "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/components/SignsReferencePanel.tsx"
click node_tracker "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/tracker/tracker.ts"
click node_pipeline "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/pipeline/pipeline.ts"
click node_features "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/core/features.ts"
click node_model "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/core/model.ts"
click node_gate "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/core/gate.ts"
click node_mock "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/mock/mockController.ts"
click node_model_assets "https://github.com/aayansh54/isl-translator/tree/main/frontend/public/model"
click node_mock_assets "https://github.com/aayansh54/isl-translator/tree/main/frontend/public/mock"
click node_api "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/api/client.ts"
click node_settings "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/store/settings.ts"
click node_sentence "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/store/sentence.ts"
click node_speech "https://github.com/aayansh54/isl-translator/blob/main/frontend/src/speech/tts.ts"

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_app,node_live,node_navbar,node_settings_ui,node_signs,node_user,node_browser_speech toneBlue
class node_tracker,node_pipeline,node_features,node_model,node_gate,node_mock,node_model_assets,node_mock_assets toneAmber
class node_collect,node_results,node_backend toneMint
class node_api,node_settings,node_sentence,node_speech toneRose
```

## Components

### Application UI

- [App Router](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/App.tsx): `frontend/src/App.tsx`
- [Live Interpreter](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/live/LiveScreen.tsx): `frontend/src/screens/live/LiveScreen.tsx`
- [Navigation](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/components/Navbar.tsx): `frontend/src/components/Navbar.tsx`
- [Settings Drawer](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/components/SettingsDrawer.tsx): `frontend/src/components/SettingsDrawer.tsx`
- [Sign Reference](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/components/SignsReferencePanel.tsx): `frontend/src/components/SignsReferencePanel.tsx`

### Recognition Runtime

- [Hand Tracker](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/tracker/tracker.ts): `frontend/src/tracker/tracker.ts`
- [Frame Pipeline](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/pipeline/pipeline.ts): `frontend/src/pipeline/pipeline.ts`
- [Feature Extraction](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/core/features.ts): `frontend/src/core/features.ts`
- [Model Inference](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/core/model.ts): `frontend/src/core/model.ts`
- [Prediction Gate](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/core/gate.ts): `frontend/src/core/gate.ts`
- [Mock Controller](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/mock/mockController.ts): `frontend/src/mock/mockController.ts`
- [Model Assets](https://github.com/aayansh54/isl-translator/tree/main/frontend/public/model): `frontend/public/model`
- [Fallback Assets](https://github.com/aayansh54/isl-translator/tree/main/frontend/public/mock): `frontend/public/mock`

### Collection And Evaluation

- [Data Collection](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/collect/CollectScreen.tsx): `frontend/src/screens/collect/CollectScreen.tsx`
- [Evaluation Results](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/screens/results/ResultsScreen.tsx): `frontend/src/screens/results/ResultsScreen.tsx`

### Preferences And Services

- [API Client](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/api/client.ts): `frontend/src/api/client.ts`
- [Settings Store](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/store/settings.ts): `frontend/src/store/settings.ts`
- [Sentence Buffer](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/store/sentence.ts): `frontend/src/store/sentence.ts`
- [Speech Output](https://github.com/aayansh54/isl-translator/blob/main/frontend/src/speech/tts.ts): `frontend/src/speech/tts.ts`

### Other components

- **User**
- **API Service**
- **Browser Speech API**

## Connections

- User → App Router: uses
- App Router → Navigation: renders (evidence: `frontend/src/App.tsx`)
- App Router → Live Interpreter: routes to (evidence: `frontend/src/App.tsx`)
- App Router → Data Collection: routes to (evidence: `frontend/src/App.tsx`)
- App Router → Evaluation Results: routes to (evidence: `frontend/src/App.tsx`)
- App Router → Settings Drawer: renders (evidence: `frontend/src/App.tsx`)
- App Router → Sign Reference: renders (evidence: `frontend/src/App.tsx`)
- App Router → API Client: loads vocabulary (evidence: `frontend/src/App.tsx`)
- Live Interpreter → Frame Pipeline: uses (evidence: `frontend/src/screens/live/LiveScreen.tsx`)
- Live Interpreter → Hand Tracker: starts tracking (evidence: `frontend/src/screens/live/LiveScreen.tsx`)
- Live Interpreter → Model Inference: loads model (evidence: `frontend/src/screens/live/LiveScreen.tsx`)
- Live Interpreter → Mock Controller: starts mock input (evidence: `frontend/src/screens/live/LiveScreen.tsx`)
- Live Interpreter → Sentence Buffer: updates (evidence: `frontend/src/screens/live/LiveScreen.tsx`)
- Live Interpreter → Speech Output: speaks signs (evidence: `frontend/src/screens/live/LiveScreen.tsx`)
- Frame Pipeline → Feature Extraction: computes features (evidence: `frontend/src/pipeline/pipeline.ts`)
- Frame Pipeline → Model Inference: predicts (evidence: `frontend/src/pipeline/pipeline.ts`)
- Frame Pipeline → Prediction Gate: filters predictions (evidence: `frontend/src/pipeline/pipeline.ts`)
- Frame Pipeline → Hand Tracker: subscribes frames (evidence: `frontend/src/pipeline/pipeline.ts`)
- Settings Drawer → Hand Tracker: lists cameras (evidence: `frontend/src/components/SettingsDrawer.tsx`)
- Settings Drawer → Speech Output: lists voices (evidence: `frontend/src/components/SettingsDrawer.tsx`)
- Settings Drawer → Settings Store: edits preferences
- Data Collection → Hand Tracker: draws landmarks (evidence: `frontend/src/screens/collect/CollectScreen.tsx`)
- Data Collection → API Client: uploads records (evidence: `frontend/src/screens/collect/CollectScreen.tsx`)
- Evaluation Results → API Client: loads metrics (evidence: `frontend/src/screens/results/ResultsScreen.tsx`)
- API Client → API Service: sends requests
- API Client → Model Assets: loads model files (evidence: `frontend/src/api/client.ts`)
- API Client → Fallback Assets: falls back to (evidence: `frontend/src/api/client.ts`)
- Speech Output → Browser Speech API: uses (evidence: `frontend/src/speech/tts.ts`)
