# moesnow/march7thassistant architecture

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

- Interactive diagram: https://gitdiagram.com/moesnow/march7thassistant
- Repository: https://github.com/moesnow/march7thassistant

## Overview

March7thAssistant automates Honkai: Star Rail tasks through a CLI or graphical interface. The principal runtime path is user-selected task → command dispatch → task implementation → game automation and screen/OCR support; task outcomes can be sent through configured notification channels. The README also documents cloud play, custom workflows, update support, toolbox functions, and scheduled or conditional startup. Source excerpts and the index support the main runtime and several internal links; other documented capabilities are included with only README-backed connections where implementation wiring was not sampled.

Main entry points: [`main.py`](https://github.com/moesnow/march7thassistant/blob/main/main.py) (CLI dispatcher), [`module/automation/automation.py`](https://github.com/moesnow/march7thassistant/blob/main/module/automation/automation.py) (Input automation), [`tasks/weekly`](https://github.com/moesnow/march7thassistant/tree/main/tasks/weekly) (Weekly challenges), [`module/notification/notification.py`](https://github.com/moesnow/march7thassistant/blob/main/module/notification/notification.py) (Notification routing)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["User interfaces"]
  node_gui["Desktop GUI<br/>[app.py]"]
  node_cli["CLI dispatcher<br/>[main.py]"]
end

subgraph group_tasks["Task automation"]
  node_workflow["Custom workflows"]
  node_daily["Daily tasks"]
  node_power["Power farming<br/>[power.py]"]
  node_weekly["Weekly challenges"]
  node_challenge["Challenge modes"]
  node_activity["Activity tasks"]
  node_rewards["Reward tasks"]
  node_toolbox["Task toolbox"]
  node_taskbase["Task base<br/>[base.py]"]
end

subgraph group_runtime["Game runtime"]
  node_automation["Input automation<br/>[automation.py]"]
  node_screenshots["Screenshot capture<br/>[screenshot.py]"]
  node_screen["Screen recognition<br/>[screen.py]"]
  node_ocr["OCR engine<br/>[ocr.py]"]
  node_game["Game launchers<br/>[base.py]"]
  node_cloud["Cloud game<br/>[cloud.py]"]
end

subgraph group_services["Supporting services"]
  node_config[("Configuration<br/>[config.py]")]
  node_notifications["Notification routing<br/>[notification.py]"]
  node_channels["Notification channels"]
  node_updates["Update engine<br/>[update_engine.py]"]
  node_localization["Localization<br/>[languages.py]"]
  node_logs["Logging<br/>[logger.py]"]
  node_telemetry["Telemetry<br/>[telemetry.py]"]
end

node_user(("Player"))
node_externalgame(("Star Rail"))
node_pushservices(("Push providers"))

node_user -->|"selects task"| node_cli
node_user -->|"opens interface"| node_gui
node_cli -->|"dispatches"| node_daily
node_cli -->|"dispatches"| node_power
node_cli -->|"dispatches"| node_weekly
node_cli -->|"dispatches"| node_challenge
node_cli -->|"starts workflow"| node_workflow
node_cli -->|"initializes"| node_notifications
node_cli -->|"tracks runs"| node_telemetry
node_workflow -->|"uses screen state"| node_screen
node_daily -->|"uses input"| node_automation
node_taskbase -->|"uses input"| node_automation
node_taskbase -->|"sends updates"| node_notifications
node_weekly -->|"controls game"| node_automation
node_weekly -->|"checks screens"| node_screen
node_weekly -->|"extends task base"| node_taskbase
node_automation -->|"captures frames"| node_screenshots
node_automation -->|"recognizes text"| node_ocr
node_screen -->|"uses input"| node_automation
node_game -->|"provides cloud mode"| node_cloud
node_cloud -->|"uses CDP input"| node_automation
node_notifications -->|"dispatches notifications"| node_channels
node_channels -->|"sends messages"| node_pushservices
node_gui -->|"configures tasks"| node_config
node_updates -.->|"updates game"| node_externalgame
node_game -.->|"launches game"| node_externalgame
node_config -->|"configures channels"| node_notifications
node_localization -->|"localizes labels"| node_cli

click node_gui "https://github.com/moesnow/march7thassistant/blob/main/app.py"
click node_cli "https://github.com/moesnow/march7thassistant/blob/main/main.py"
click node_workflow "https://github.com/moesnow/march7thassistant/tree/main/module/workflow"
click node_daily "https://github.com/moesnow/march7thassistant/tree/main/tasks/daily"
click node_power "https://github.com/moesnow/march7thassistant/blob/main/tasks/power/power.py"
click node_weekly "https://github.com/moesnow/march7thassistant/tree/main/tasks/weekly"
click node_challenge "https://github.com/moesnow/march7thassistant/tree/main/tasks/challenge"
click node_activity "https://github.com/moesnow/march7thassistant/tree/main/tasks/activity"
click node_rewards "https://github.com/moesnow/march7thassistant/tree/main/tasks/reward"
click node_toolbox "https://github.com/moesnow/march7thassistant/tree/main/tasks/tool"
click node_taskbase "https://github.com/moesnow/march7thassistant/blob/main/tasks/base/base.py"
click node_automation "https://github.com/moesnow/march7thassistant/blob/main/module/automation/automation.py"
click node_screenshots "https://github.com/moesnow/march7thassistant/blob/main/module/automation/screenshot.py"
click node_screen "https://github.com/moesnow/march7thassistant/blob/main/module/screen/screen.py"
click node_ocr "https://github.com/moesnow/march7thassistant/blob/main/module/ocr/ocr.py"
click node_game "https://github.com/moesnow/march7thassistant/blob/main/module/game/base.py"
click node_cloud "https://github.com/moesnow/march7thassistant/blob/main/module/game/cloud.py"
click node_config "https://github.com/moesnow/march7thassistant/blob/main/module/config/config.py"
click node_notifications "https://github.com/moesnow/march7thassistant/blob/main/module/notification/notification.py"
click node_channels "https://github.com/moesnow/march7thassistant/tree/main/module/notification"
click node_updates "https://github.com/moesnow/march7thassistant/blob/main/module/update/update_engine.py"
click node_localization "https://github.com/moesnow/march7thassistant/blob/main/module/localization/languages.py"
click node_logs "https://github.com/moesnow/march7thassistant/blob/main/utils/logger/logger.py"
click node_telemetry "https://github.com/moesnow/march7thassistant/blob/main/module/telemetry/telemetry.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_gui,node_cli toneBlue
class node_workflow,node_daily,node_power,node_weekly,node_challenge,node_activity,node_rewards,node_toolbox,node_taskbase toneAmber
class node_automation,node_screenshots,node_screen,node_ocr,node_game,node_cloud toneMint
class node_config,node_notifications,node_channels,node_updates,node_localization,node_logs,node_telemetry toneRose
class node_user,node_externalgame,node_pushservices toneIndigo
```

## Components

### User interfaces

- [Desktop GUI](https://github.com/moesnow/march7thassistant/blob/main/app.py): `app.py`
- [CLI dispatcher](https://github.com/moesnow/march7thassistant/blob/main/main.py): `main.py`

### Task automation

- [Custom workflows](https://github.com/moesnow/march7thassistant/tree/main/module/workflow): `module/workflow`
- [Daily tasks](https://github.com/moesnow/march7thassistant/tree/main/tasks/daily): `tasks/daily`
- [Power farming](https://github.com/moesnow/march7thassistant/blob/main/tasks/power/power.py): `tasks/power/power.py`
- [Weekly challenges](https://github.com/moesnow/march7thassistant/tree/main/tasks/weekly): `tasks/weekly`
- [Challenge modes](https://github.com/moesnow/march7thassistant/tree/main/tasks/challenge): `tasks/challenge`
- [Activity tasks](https://github.com/moesnow/march7thassistant/tree/main/tasks/activity): `tasks/activity`
- [Reward tasks](https://github.com/moesnow/march7thassistant/tree/main/tasks/reward): `tasks/reward`
- [Task toolbox](https://github.com/moesnow/march7thassistant/tree/main/tasks/tool): `tasks/tool`
- [Task base](https://github.com/moesnow/march7thassistant/blob/main/tasks/base/base.py): `tasks/base/base.py`

### Game runtime

- [Input automation](https://github.com/moesnow/march7thassistant/blob/main/module/automation/automation.py): `module/automation/automation.py`
- [Screenshot capture](https://github.com/moesnow/march7thassistant/blob/main/module/automation/screenshot.py): `module/automation/screenshot.py`
- [Screen recognition](https://github.com/moesnow/march7thassistant/blob/main/module/screen/screen.py): `module/screen/screen.py`
- [OCR engine](https://github.com/moesnow/march7thassistant/blob/main/module/ocr/ocr.py): `module/ocr/ocr.py`
- [Game launchers](https://github.com/moesnow/march7thassistant/blob/main/module/game/base.py): `module/game/base.py`
- [Cloud game](https://github.com/moesnow/march7thassistant/blob/main/module/game/cloud.py): `module/game/cloud.py`

### Supporting services

- [Configuration](https://github.com/moesnow/march7thassistant/blob/main/module/config/config.py): `module/config/config.py`
- [Notification routing](https://github.com/moesnow/march7thassistant/blob/main/module/notification/notification.py): `module/notification/notification.py`
- [Notification channels](https://github.com/moesnow/march7thassistant/tree/main/module/notification): `module/notification`
- [Update engine](https://github.com/moesnow/march7thassistant/blob/main/module/update/update_engine.py): `module/update/update_engine.py`
- [Localization](https://github.com/moesnow/march7thassistant/blob/main/module/localization/languages.py): `module/localization/languages.py`
- [Logging](https://github.com/moesnow/march7thassistant/blob/main/utils/logger/logger.py): `utils/logger/logger.py`
- [Telemetry](https://github.com/moesnow/march7thassistant/blob/main/module/telemetry/telemetry.py): `module/telemetry/telemetry.py`

### Other components

- **Player**
- **Star Rail**
- **Push providers**

## Connections

- Player → CLI dispatcher: selects task
- Player → Desktop GUI: opens interface
- CLI dispatcher → Daily tasks: dispatches (evidence: `main.py`)
- CLI dispatcher → Power farming: dispatches (evidence: `main.py`)
- CLI dispatcher → Weekly challenges: dispatches (evidence: `main.py`)
- CLI dispatcher → Challenge modes: dispatches (evidence: `main.py`)
- CLI dispatcher → Custom workflows: starts workflow (evidence: `main.py`)
- CLI dispatcher → Notification routing: initializes (evidence: `main.py`)
- CLI dispatcher → Telemetry: tracks runs (evidence: `main.py`)
- Custom workflows → Screen recognition: uses screen state (evidence: `module/workflow/__init__.py`)
- Daily tasks → Input automation: uses input (evidence: `tasks/daily/tasks.py`)
- Task base → Input automation: uses input (evidence: `tasks/base/base.py`)
- Task base → Notification routing: sends updates (evidence: `tasks/base/base.py`)
- Weekly challenges → Input automation: controls game (evidence: `tasks/weekly/divergent_universe.py`)
- Weekly challenges → Screen recognition: checks screens (evidence: `tasks/weekly/divergent_universe.py`)
- Weekly challenges → Task base: extends task base (evidence: `tasks/weekly/divergent_universe.py`)
- Input automation → Screenshot capture: captures frames (evidence: `module/automation/automation.py`)
- Input automation → OCR engine: recognizes text (evidence: `module/automation/automation.py`)
- Screen recognition → Input automation: uses input (evidence: `module/screen/screen.py`)
- Game launchers → Cloud game: provides cloud mode (evidence: `module/game/__init__.py`)
- Cloud game → Input automation: uses CDP input (evidence: `module/game/cloud.py`)
- Notification routing → Notification channels: dispatches notifications (evidence: `module/notification/notification.py`)
- Notification channels → Push providers: sends messages
- Desktop GUI → Configuration: configures tasks
- Update engine → Star Rail: updates game
- Game launchers → Star Rail: launches game
- Configuration → Notification routing: configures channels
- Localization → CLI dispatcher: localizes labels
