# liseami/ccbaga architecture

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

- Interactive diagram: https://gitdiagram.com/liseami/ccbaga
- Repository: https://github.com/liseami/ccbaga

## Overview

CCBaga is a native macOS/Linux toolkit paired with an isolated fingerprint Chromium browser. The main workflow runs through CCBaga-A: users choose a region or maintenance task, invoke native operations, then inspect results; browser measurements return through a local session bridge. The graph preserves the documented cleanup, browser verification, system settings, SSH/VPS setup, CLI management, and updates. Some UI-to-command wiring and unsampled subsystem internals are represented only where documented; evidence is limited to the supplied README and source excerpts/index.

Main entry points: [`src/main.tsx`](https://github.com/liseami/ccbaga/blob/main/src/main.tsx) (CCBaga-A shell), [`src-tauri/src/browser/mod.rs`](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/mod.rs) (Browser orchestration), [`src/cleaner.tsx`](https://github.com/liseami/ccbaga/blob/main/src/cleaner.tsx) (Claude cleanup), [`src/quick-actions.tsx`](https://github.com/liseami/ccbaga/blob/main/src/quick-actions.tsx) (Easy setup)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application shell"]
  node_shell["CCBaga-A shell<br/>[main.tsx]"]
  node_quick["Easy setup<br/>[quick-actions.tsx]"]
end

subgraph group_browser["Browser environment"]
  node_browser_ui["Browser controls<br/>[browser.tsx]"]
  node_browser_core["Browser orchestration<br/>[mod.rs]"]
  node_browser_config["Fingerprint config<br/>[config.rs]"]
  node_profile["Browser profile<br/>[profile.rs]"]
  node_network_checks["Environment checks<br/>[network.rs]"]
  node_local_bridge["Local session bridge<br/>[server.rs]"]
end

subgraph group_maintenance["Cleanup and system"]
  node_cleaner_ui["Claude cleanup<br/>[cleaner.tsx]"]
  node_cleaner_core["Cleanup engine<br/>[cleaner.rs]"]
  node_cli["Claude CLI tools<br/>[claude_cli.rs]"]
  node_system_ui["System controls<br/>[system.tsx]"]
  node_system_core["System settings<br/>[system.rs]"]
  node_platform["Platform adapter<br/>[native.rs]"]
end

subgraph group_network["Network setup"]
  node_vps_ui["Network setup<br/>[vps.tsx]"]
  node_vps_core["VPS provisioning<br/>[vps.rs]"]
  node_keys["SSH key selection<br/>[vps_keys.rs]"]
end

subgraph group_shared["Shared services"]
  node_regions["Region catalog<br/>[regions.rs]"]
  node_activity["Operation activity"]
  node_language["Interface language<br/>[i18n.ts]"]
  node_updater["App updates<br/>[app-update.tsx]"]
end

node_user(("Desktop user"))
node_browser_actor(("CCBaga-B Chromium"))
node_os(("Host operating system"))
node_vps(("Remote Debian VPS"))

node_user -->|"opens"| node_shell
node_shell -->|"shows setup"| node_quick
node_shell -->|"routes to"| node_cleaner_ui
node_shell -->|"routes to"| node_browser_ui
node_shell -->|"routes to"| node_system_ui
node_shell -->|"routes to"| node_vps_ui
node_quick -->|"selects region"| node_regions
node_quick -->|"starts cleanup"| node_cleaner_ui
node_quick -->|"rotates fingerprint"| node_browser_core
node_cleaner_ui -->|"scans and removes"| node_cleaner_core
node_cleaner_ui -->|"manages CLI"| node_cli
node_cleaner_ui -->|"reports progress"| node_activity
node_browser_ui -->|"controls browser"| node_browser_core
node_browser_core -->|"uses settings"| node_browser_config
node_browser_core -->|"manages profile"| node_profile
node_browser_core -->|"evaluates report"| node_network_checks
node_browser_core -->|"serves session"| node_local_bridge
node_browser_core -->|"launches"| node_browser_actor
node_browser_actor -->|"posts measurements"| node_local_bridge
node_browser_ui -->|"shows results"| node_activity
node_system_ui -->|"applies settings"| node_system_core
node_system_core -->|"uses region data"| node_regions
node_system_core -->|"uses native bridge"| node_platform
node_system_ui -->|"shows operations"| node_activity
node_vps_ui -->|"starts setup"| node_vps_core
node_vps_ui -->|"selects key files"| node_keys
node_vps_core -->|"configures and checks"| node_vps
node_vps_core -->|"reports progress"| node_activity
node_shell -->|"offers updates"| node_updater
node_shell -->|"provides language"| node_language
node_language -->|"translates interface"| node_shell
node_cleaner_core -->|"uses native operations"| node_platform
node_user -.->|"measures environment"| node_browser_actor
node_browser_core -->|"matches region"| node_regions

click node_shell "https://github.com/liseami/ccbaga/blob/main/src/main.tsx"
click node_quick "https://github.com/liseami/ccbaga/blob/main/src/quick-actions.tsx"
click node_regions "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/regions.rs"
click node_cleaner_ui "https://github.com/liseami/ccbaga/blob/main/src/cleaner.tsx"
click node_cleaner_core "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/cleaner.rs"
click node_cli "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/claude_cli.rs"
click node_browser_ui "https://github.com/liseami/ccbaga/blob/main/src/browser.tsx"
click node_browser_core "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/mod.rs"
click node_browser_config "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/config.rs"
click node_profile "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/profile.rs"
click node_network_checks "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/network.rs"
click node_local_bridge "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/server.rs"
click node_system_ui "https://github.com/liseami/ccbaga/blob/main/src/system.tsx"
click node_system_core "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/system.rs"
click node_platform "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/native.rs"
click node_vps_ui "https://github.com/liseami/ccbaga/blob/main/src/vps.tsx"
click node_vps_core "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/vps.rs"
click node_keys "https://github.com/liseami/ccbaga/blob/main/src-tauri/src/vps_keys.rs"
click node_activity "https://github.com/liseami/ccbaga/blob/main/src/cleaner-activity.tsx"
click node_language "https://github.com/liseami/ccbaga/blob/main/src/i18n.ts"
click node_updater "https://github.com/liseami/ccbaga/blob/main/src/app-update.tsx"

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_shell,node_quick,node_user toneBlue
class node_browser_ui,node_browser_core,node_browser_config,node_profile,node_network_checks,node_local_bridge toneAmber
class node_cleaner_ui,node_cleaner_core,node_cli,node_system_ui,node_system_core,node_platform toneMint
class node_vps_ui,node_vps_core,node_keys toneRose
class node_regions,node_activity,node_language,node_updater,node_browser_actor,node_os,node_vps toneIndigo
```

## Components

### Application shell

- [CCBaga-A shell](https://github.com/liseami/ccbaga/blob/main/src/main.tsx): `src/main.tsx`
- [Easy setup](https://github.com/liseami/ccbaga/blob/main/src/quick-actions.tsx): `src/quick-actions.tsx`

### Browser environment

- [Browser controls](https://github.com/liseami/ccbaga/blob/main/src/browser.tsx): `src/browser.tsx`
- [Browser orchestration](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/mod.rs): `src-tauri/src/browser/mod.rs`
- [Fingerprint config](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/config.rs): `src-tauri/src/browser/config.rs`
- [Browser profile](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/profile.rs): `src-tauri/src/browser/profile.rs`
- [Environment checks](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/network.rs): `src-tauri/src/browser/network.rs`
- [Local session bridge](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/browser/server.rs): `src-tauri/src/browser/server.rs`

### Cleanup and system

- [Claude cleanup](https://github.com/liseami/ccbaga/blob/main/src/cleaner.tsx): `src/cleaner.tsx`
- [Cleanup engine](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/cleaner.rs): `src-tauri/src/cleaner.rs`
- [Claude CLI tools](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/claude_cli.rs): `src-tauri/src/claude_cli.rs`
- [System controls](https://github.com/liseami/ccbaga/blob/main/src/system.tsx): `src/system.tsx`
- [System settings](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/system.rs): `src-tauri/src/system.rs`
- [Platform adapter](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/native.rs): `src-tauri/src/native.rs`

### Network setup

- [Network setup](https://github.com/liseami/ccbaga/blob/main/src/vps.tsx): `src/vps.tsx`
- [VPS provisioning](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/vps.rs): `src-tauri/src/vps.rs`
- [SSH key selection](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/vps_keys.rs): `src-tauri/src/vps_keys.rs`

### Shared services

- [Region catalog](https://github.com/liseami/ccbaga/blob/main/src-tauri/src/regions.rs): `src-tauri/src/regions.rs`
- [Operation activity](https://github.com/liseami/ccbaga/blob/main/src/cleaner-activity.tsx): `src/cleaner-activity.tsx`
- [Interface language](https://github.com/liseami/ccbaga/blob/main/src/i18n.ts): `src/i18n.ts`
- [App updates](https://github.com/liseami/ccbaga/blob/main/src/app-update.tsx): `src/app-update.tsx`

### Other components

- **Desktop user**
- **CCBaga-B Chromium**
- **Host operating system**
- **Remote Debian VPS**

## Connections

- Desktop user → CCBaga-A shell: opens
- CCBaga-A shell → Easy setup: shows setup (evidence: `src/main.tsx`)
- CCBaga-A shell → Claude cleanup: routes to (evidence: `src/main.tsx`)
- CCBaga-A shell → Browser controls: routes to (evidence: `src/main.tsx`)
- CCBaga-A shell → System controls: routes to (evidence: `src/main.tsx`)
- CCBaga-A shell → Network setup: routes to (evidence: `src/main.tsx`)
- Easy setup → Region catalog: selects region
- Easy setup → Claude cleanup: starts cleanup
- Easy setup → Browser orchestration: rotates fingerprint
- Claude cleanup → Cleanup engine: scans and removes
- Claude cleanup → Claude CLI tools: manages CLI (evidence: `src/cleaner.tsx`)
- Claude cleanup → Operation activity: reports progress (evidence: `src/cleaner.tsx`)
- Browser controls → Browser orchestration: controls browser
- Browser orchestration → Fingerprint config: uses settings (evidence: `src-tauri/src/browser/mod.rs`)
- Browser orchestration → Browser profile: manages profile (evidence: `src-tauri/src/browser/mod.rs`)
- Browser orchestration → Environment checks: evaluates report (evidence: `src-tauri/src/browser/mod.rs`)
- Browser orchestration → Local session bridge: serves session (evidence: `src-tauri/src/browser/mod.rs`)
- Browser orchestration → CCBaga-B Chromium: launches
- CCBaga-B Chromium → Local session bridge: posts measurements
- Browser controls → Operation activity: shows results (evidence: `src/browser.tsx`)
- System controls → System settings: applies settings
- System settings → Region catalog: uses region data (evidence: `src-tauri/src/system.rs`)
- System settings → Platform adapter: uses native bridge (evidence: `src-tauri/src/system.rs`)
- System controls → Operation activity: shows operations (evidence: `src/system.tsx`)
- Network setup → VPS provisioning: starts setup
- Network setup → SSH key selection: selects key files
- VPS provisioning → Remote Debian VPS: configures and checks
- VPS provisioning → Operation activity: reports progress (evidence: `src-tauri/src/vps.rs`)
- CCBaga-A shell → App updates: offers updates (evidence: `src/main.tsx`)
- CCBaga-A shell → Interface language: provides language (evidence: `src/main.tsx`)
- Interface language → CCBaga-A shell: translates interface (evidence: `src/i18n.ts`)
- Cleanup engine → Platform adapter: uses native operations (evidence: `src-tauri/src/cleaner.rs`)
- Desktop user → CCBaga-B Chromium: measures environment
- Browser orchestration → Region catalog: matches region (evidence: `src-tauri/src/browser/mod.rs`)
