# brenoxbr/jarvis-ai architecture

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

- Interactive diagram: https://gitdiagram.com/brenoxbr/jarvis-ai
- Repository: https://github.com/brenoxbr/jarvis-ai

## Overview

J.A.R.V.I.S. is a Windows-oriented personal assistant for developers, offering chat, voice interaction, system automation, screen analysis, debugging help, and persistent memory. The documented primary launch path initializes logging, system actions, and the assistant core, then opens the GUI. A second Qt-based interface and threaded voice/AI runtime appear in the repository as a separate integration path. The README documents additional capabilities, but their wiring to the primary launcher is not established by the sampled excerpts; those branches are shown without guessed connections.

Main entry points: [`jarvis_threads.py`](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_threads.py) (Thread Manager), [`main.py`](https://github.com/brenoxbr/jarvis-ai/blob/main/main.py) (Application Launcher), [`action_handler.py`](https://github.com/brenoxbr/jarvis-ai/blob/main/action_handler.py) (Command Handling), [`actions.py`](https://github.com/brenoxbr/jarvis-ai/blob/main/actions.py) (System Actions)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["User Interfaces"]
  node_launcher["Application Launcher<br/>[main.py]"]
  node_desktop_ui["Desktop Chat UI<br/>[gui.py]"]
  node_qt_ui["Qt Assistant UI<br/>[jarvis_gui.py]"]
end

subgraph group_runtime["Assistant Runtime"]
  node_logger["Logging<br/>[logger.py]"]
  node_core["Assistant Core<br/>[core.py]"]
  node_thread_manager["Thread Manager<br/>[jarvis_threads.py]"]
end

subgraph group_capabilities["Assistant Capabilities"]
  node_command_handler["Command Handling<br/>[action_handler.py]"]
  node_system_actions["System Actions<br/>[actions.py]"]
  node_system_control["Windows Controls"]
  node_vision["Screen Vision<br/>[jarvis_vision.py]"]
  node_debugger["Assisted Debugging<br/>[debug_mode.py]"]
  node_code_gen["Python Code Generation<br/>[code_generator.py]"]
  node_multi_code["Multi-Language Code"]
  node_cleanup["Workspace Cleanup<br/>[jarvis_cleanup.py]"]
  node_mobile["Mobile Bridge<br/>[mobile_bridge.py]"]
end

subgraph group_state["State and Integrations"]
  node_memory[("Long-Term Memory<br/>[jarvis_memory.py]")]
  node_configuration["Configuration<br/>[config.py]"]
end

node_user(("User"))
node_gemini{{"Google Gemini"}}
node_windows{{"Windows System"}}
node_memory_files[("Local Memory Files")]

node_user -->|"starts"| node_launcher
node_launcher -->|"creates"| node_logger
node_launcher -->|"creates"| node_system_actions
node_launcher -->|"creates"| node_core
node_launcher -->|"opens"| node_desktop_ui
node_user -.->|"uses"| node_desktop_ui
node_user -.->|"uses"| node_qt_ui
node_qt_ui -->|"submits commands"| node_thread_manager
node_thread_manager -->|"initializes"| node_vision
node_thread_manager -->|"initializes"| node_cleanup
node_thread_manager -->|"initializes"| node_memory
node_thread_manager -->|"initializes"| node_command_handler
node_thread_manager -->|"initializes"| node_mobile
node_command_handler -->|"configures"| node_gemini
node_command_handler -.->|"uses"| node_code_gen
node_command_handler -.->|"uses"| node_multi_code
node_multi_code -->|"references"| node_debugger
node_system_actions -->|"imports"| node_configuration
node_system_actions -->|"controls"| node_windows
node_system_control -->|"controls"| node_windows
node_vision -.->|"captures screen"| node_windows
node_memory -.->|"persists JSON"| node_memory_files
node_core -.->|"uses"| node_gemini
node_user -.->|"requests analysis"| node_debugger
node_user -.->|"requests automation"| node_system_actions

click node_launcher "https://github.com/brenoxbr/jarvis-ai/blob/main/main.py"
click node_desktop_ui "https://github.com/brenoxbr/jarvis-ai/blob/main/gui.py"
click node_qt_ui "https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_gui.py"
click node_logger "https://github.com/brenoxbr/jarvis-ai/blob/main/logger.py"
click node_core "https://github.com/brenoxbr/jarvis-ai/blob/main/core.py"
click node_thread_manager "https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_threads.py"
click node_command_handler "https://github.com/brenoxbr/jarvis-ai/blob/main/action_handler.py"
click node_system_actions "https://github.com/brenoxbr/jarvis-ai/blob/main/actions.py"
click node_system_control "https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_system_controller.py"
click node_vision "https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_vision.py"
click node_debugger "https://github.com/brenoxbr/jarvis-ai/blob/main/debug_mode.py"
click node_code_gen "https://github.com/brenoxbr/jarvis-ai/blob/main/code_generator.py"
click node_multi_code "https://github.com/brenoxbr/jarvis-ai/blob/main/multi_language_generator.py"
click node_memory "https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_memory.py"
click node_cleanup "https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_cleanup.py"
click node_mobile "https://github.com/brenoxbr/jarvis-ai/blob/main/mobile_bridge.py"
click node_configuration "https://github.com/brenoxbr/jarvis-ai/blob/main/config.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_launcher,node_desktop_ui,node_qt_ui,node_user toneBlue
class node_logger,node_core,node_thread_manager,node_memory_files toneAmber
class node_command_handler,node_system_actions,node_system_control,node_vision,node_debugger,node_code_gen,node_multi_code,node_cleanup,node_mobile toneMint
class node_memory,node_configuration toneRose
class node_gemini,node_windows toneIndigo
```

## Components

### User Interfaces

- [Application Launcher](https://github.com/brenoxbr/jarvis-ai/blob/main/main.py): `main.py`
- [Desktop Chat UI](https://github.com/brenoxbr/jarvis-ai/blob/main/gui.py): `gui.py`
- [Qt Assistant UI](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_gui.py): `jarvis_gui.py`

### Assistant Runtime

- [Logging](https://github.com/brenoxbr/jarvis-ai/blob/main/logger.py): `logger.py`
- [Assistant Core](https://github.com/brenoxbr/jarvis-ai/blob/main/core.py): `core.py`
- [Thread Manager](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_threads.py): `jarvis_threads.py`

### Assistant Capabilities

- [Command Handling](https://github.com/brenoxbr/jarvis-ai/blob/main/action_handler.py): `action_handler.py`
- [System Actions](https://github.com/brenoxbr/jarvis-ai/blob/main/actions.py): `actions.py`
- [Windows Controls](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_system_controller.py): `jarvis_system_controller.py`
- [Screen Vision](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_vision.py): `jarvis_vision.py`
- [Assisted Debugging](https://github.com/brenoxbr/jarvis-ai/blob/main/debug_mode.py): `debug_mode.py`
- [Python Code Generation](https://github.com/brenoxbr/jarvis-ai/blob/main/code_generator.py): `code_generator.py`
- [Multi-Language Code](https://github.com/brenoxbr/jarvis-ai/blob/main/multi_language_generator.py): `multi_language_generator.py`
- [Workspace Cleanup](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_cleanup.py): `jarvis_cleanup.py`
- [Mobile Bridge](https://github.com/brenoxbr/jarvis-ai/blob/main/mobile_bridge.py): `mobile_bridge.py`

### State and Integrations

- [Long-Term Memory](https://github.com/brenoxbr/jarvis-ai/blob/main/jarvis_memory.py): `jarvis_memory.py`
- [Configuration](https://github.com/brenoxbr/jarvis-ai/blob/main/config.py): `config.py`

### Other components

- **User**
- **Google Gemini**
- **Windows System**
- **Local Memory Files**

## Connections

- User → Application Launcher: starts
- Application Launcher → Logging: creates (evidence: `main.py`)
- Application Launcher → System Actions: creates (evidence: `main.py`)
- Application Launcher → Assistant Core: creates (evidence: `main.py`)
- Application Launcher → Desktop Chat UI: opens (evidence: `main.py`)
- User → Desktop Chat UI: uses
- User → Qt Assistant UI: uses
- Qt Assistant UI → Thread Manager: submits commands (evidence: `jarvis_gui.py`)
- Thread Manager → Screen Vision: initializes (evidence: `jarvis_threads.py`)
- Thread Manager → Workspace Cleanup: initializes (evidence: `jarvis_threads.py`)
- Thread Manager → Long-Term Memory: initializes (evidence: `jarvis_threads.py`)
- Thread Manager → Command Handling: initializes (evidence: `jarvis_threads.py`)
- Thread Manager → Mobile Bridge: initializes (evidence: `jarvis_threads.py`)
- Command Handling → Google Gemini: configures (evidence: `action_handler.py`)
- Command Handling → Python Code Generation: uses
- Command Handling → Multi-Language Code: uses
- Multi-Language Code → Assisted Debugging: references (evidence: `multi_language_generator.py`)
- System Actions → Configuration: imports (evidence: `actions.py`)
- System Actions → Windows System: controls (evidence: `actions.py`)
- Windows Controls → Windows System: controls (evidence: `jarvis_system_controller.py`)
- Screen Vision → Windows System: captures screen
- Long-Term Memory → Local Memory Files: persists JSON
- Assistant Core → Google Gemini: uses
- User → Assisted Debugging: requests analysis
- User → System Actions: requests automation
