# cevo1466/open-ios-studio architecture

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

- Interactive diagram: https://gitdiagram.com/cevo1466/open-ios-studio
- Repository: https://github.com/cevo1466/open-ios-studio

## Overview

Open iOS Studio is a Linux desktop IDE for building and installing iOS apps without a Mac. The main workflow is to open and edit a project, check prerequisites and policies, then run xtool builds or device operations; optional AI can propose changes for review. The UI reaches native Rust capabilities through Tauri IPC. The README documents terminal, device, update, and project-skill features too. Some subsystem wiring is unsampled, so those relationships are omitted or marked unverified rather than inferred.

Main entry points: [`src/App.tsx`](https://github.com/cevo1466/open-ios-studio/blob/main/src/App.tsx) (IDE Interface), [`src/ipc.ts`](https://github.com/cevo1466/open-ios-studio/blob/main/src/ipc.ts) (Tauri IPC), [`src/app/usePreflight.ts`](https://github.com/cevo1466/open-ios-studio/blob/main/src/app/usePreflight.ts) (Preflight Controller), [`src/ai/useAi.ts`](https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/useAi.ts) (AI Chat)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workspace["Workspace IDE"]
  node_app["IDE Interface<br/>[App.tsx]"]
  node_editor["Editor State<br/>[store.ts]"]
end

subgraph group_build["Build and Checks"]
  node_xtool_hook["Build Controls<br/>[useXtool.ts]"]
  node_xtool_adapter["xtool Adapter<br/>[xtool.rs]"]
  node_device_view["Device Views<br/>[deviceView.ts]"]
  node_preflight_hook["Preflight Controller<br/>[usePreflight.ts]"]
  node_preflight["Preflight Checks<br/>[run.ts]"]
  node_policy["Policy Analysis<br/>[index.ts]"]
end

subgraph group_assistant["AI Assistance"]
  node_ai_ui["AI Chat<br/>[useAi.ts]"]
  node_ai_engine["AI Context and Changes<br/>[engine.ts]"]
  node_ai_storage["Conversation Storage<br/>[storage.ts]"]
end

subgraph group_native["Native Services"]
  node_filesystem["Project Files<br/>[fs_engine.rs]"]
  node_terminal["Embedded Terminal<br/>[pty.rs]"]
  node_runner["Process Runner<br/>[runner.rs]"]
  node_ai_native["AI Providers<br/>[http.rs]"]
  node_cli_ai["AI CLI Sessions<br/>[cli_ai.rs]"]
  node_ipc["Tauri IPC<br/>[ipc.ts]"]
  node_rust_commands["Native Commands<br/>[lib.rs]"]
  node_lsp_native["LSP Relay<br/>[lsp.rs]"]
  node_updates["App Updates<br/>[update.rs]"]
  node_skills["Agent Skills<br/>[skills.rs]"]
end

subgraph group_language["Swift Language Tools"]
  node_lsp_hook["Swift LSP Controller<br/>[useSwiftLsp.ts]"]
  node_lsp_client["Language Client<br/>[client.ts]"]
end

node_developer(("Developer"))

node_developer -->|"uses"| node_app
node_app -->|"offers build controls"| node_xtool_hook
node_xtool_hook -->|"invokes operations"| node_ipc
node_ipc -.->|"dispatches commands"| node_rust_commands
node_rust_commands -->|"registers adapter"| node_xtool_adapter
node_xtool_adapter -.->|"runs processes"| node_runner
node_app -->|"shows device status"| node_device_view
node_developer -->|"starts checks"| node_preflight_hook
node_preflight_hook -->|"runs checks"| node_preflight
node_preflight_hook -->|"scans workspace"| node_ipc
node_preflight_hook -->|"requests policy analysis"| node_policy
node_app -->|"offers AI chat"| node_ai_ui
node_ai_ui -->|"prepares changes"| node_ai_engine
node_ai_engine -->|"checks proposed changes"| node_policy
node_ai_ui -->|"loads and saves conversations"| node_ai_storage
node_ai_ui -->|"requests provider operations"| node_ipc
node_ipc -.->|"streams provider requests"| node_ai_native
node_ipc -.->|"streams CLI requests"| node_cli_ai
node_app -.->|"enables Swift services"| node_lsp_hook
node_lsp_hook -->|"starts language client"| node_lsp_client
node_lsp_client -.->|"uses native relay"| node_lsp_native
node_developer -->|"opens terminal"| node_terminal
node_developer -->|"checks for updates"| node_updates
node_developer -->|"opens coding agent"| node_skills
node_app -.->|"browses project files"| node_filesystem

click node_app "https://github.com/cevo1466/open-ios-studio/blob/main/src/App.tsx"
click node_editor "https://github.com/cevo1466/open-ios-studio/blob/main/src/state/store.ts"
click node_filesystem "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/fs_engine.rs"
click node_terminal "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/pty.rs"
click node_xtool_hook "https://github.com/cevo1466/open-ios-studio/blob/main/src/app/useXtool.ts"
click node_xtool_adapter "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/xtool.rs"
click node_runner "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/runner.rs"
click node_device_view "https://github.com/cevo1466/open-ios-studio/blob/main/src/xtool/deviceView.ts"
click node_preflight_hook "https://github.com/cevo1466/open-ios-studio/blob/main/src/app/usePreflight.ts"
click node_preflight "https://github.com/cevo1466/open-ios-studio/blob/main/src/preflight/run.ts"
click node_policy "https://github.com/cevo1466/open-ios-studio/blob/main/src/policy/index.ts"
click node_ai_ui "https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/useAi.ts"
click node_ai_engine "https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/engine.ts"
click node_ai_storage "https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/storage.ts"
click node_ai_native "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/ai/http.rs"
click node_cli_ai "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/cli_ai.rs"
click node_ipc "https://github.com/cevo1466/open-ios-studio/blob/main/src/ipc.ts"
click node_rust_commands "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/lib.rs"
click node_lsp_hook "https://github.com/cevo1466/open-ios-studio/blob/main/src/app/useSwiftLsp.ts"
click node_lsp_client "https://github.com/cevo1466/open-ios-studio/blob/main/src/lsp/client.ts"
click node_lsp_native "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/lsp.rs"
click node_updates "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/update.rs"
click node_skills "https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/skills.rs"

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_editor toneBlue
class node_xtool_hook,node_xtool_adapter,node_device_view,node_preflight_hook,node_preflight,node_policy toneAmber
class node_ai_ui,node_ai_engine,node_ai_storage toneMint
class node_filesystem,node_terminal,node_runner,node_ai_native,node_cli_ai,node_ipc,node_rust_commands,node_lsp_native,node_updates,node_skills toneRose
class node_lsp_hook,node_lsp_client,node_developer toneIndigo
```

## Components

### Workspace IDE

- [IDE Interface](https://github.com/cevo1466/open-ios-studio/blob/main/src/App.tsx): `src/App.tsx`
- [Editor State](https://github.com/cevo1466/open-ios-studio/blob/main/src/state/store.ts): `src/state/store.ts`

### Build and Checks

- [Build Controls](https://github.com/cevo1466/open-ios-studio/blob/main/src/app/useXtool.ts): `src/app/useXtool.ts`
- [xtool Adapter](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/xtool.rs): `src-tauri/src/xtool.rs`
- [Device Views](https://github.com/cevo1466/open-ios-studio/blob/main/src/xtool/deviceView.ts): `src/xtool/deviceView.ts`
- [Preflight Controller](https://github.com/cevo1466/open-ios-studio/blob/main/src/app/usePreflight.ts): `src/app/usePreflight.ts`
- [Preflight Checks](https://github.com/cevo1466/open-ios-studio/blob/main/src/preflight/run.ts): `src/preflight/run.ts`
- [Policy Analysis](https://github.com/cevo1466/open-ios-studio/blob/main/src/policy/index.ts): `src/policy/index.ts`

### AI Assistance

- [AI Chat](https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/useAi.ts): `src/ai/useAi.ts`
- [AI Context and Changes](https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/engine.ts): `src/ai/engine.ts`
- [Conversation Storage](https://github.com/cevo1466/open-ios-studio/blob/main/src/ai/storage.ts): `src/ai/storage.ts`

### Native Services

- [Project Files](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/fs_engine.rs): `src-tauri/src/fs_engine.rs`
- [Embedded Terminal](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/pty.rs): `src-tauri/src/pty.rs`
- [Process Runner](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/runner.rs): `src-tauri/src/runner.rs`
- [AI Providers](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/ai/http.rs): `src-tauri/src/ai/http.rs`
- [AI CLI Sessions](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/cli_ai.rs): `src-tauri/src/cli_ai.rs`
- [Tauri IPC](https://github.com/cevo1466/open-ios-studio/blob/main/src/ipc.ts): `src/ipc.ts`
- [Native Commands](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/lib.rs): `src-tauri/src/lib.rs`
- [LSP Relay](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/lsp.rs): `src-tauri/src/lsp.rs`
- [App Updates](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/update.rs): `src-tauri/src/update.rs`
- [Agent Skills](https://github.com/cevo1466/open-ios-studio/blob/main/src-tauri/src/skills.rs): `src-tauri/src/skills.rs`

### Swift Language Tools

- [Swift LSP Controller](https://github.com/cevo1466/open-ios-studio/blob/main/src/app/useSwiftLsp.ts): `src/app/useSwiftLsp.ts`
- [Language Client](https://github.com/cevo1466/open-ios-studio/blob/main/src/lsp/client.ts): `src/lsp/client.ts`

### Other components

- **Developer**

## Connections

- Developer → IDE Interface: uses (evidence: `README.md`)
- IDE Interface → Build Controls: offers build controls (evidence: `README.md`)
- Build Controls → Tauri IPC: invokes operations (evidence: `src/app/useXtool.ts`)
- Tauri IPC → Native Commands: dispatches commands
- Native Commands → xtool Adapter: registers adapter (evidence: `src-tauri/src/lib.rs`)
- xtool Adapter → Process Runner: runs processes
- IDE Interface → Device Views: shows device status (evidence: `README.md`)
- Developer → Preflight Controller: starts checks (evidence: `README.md`)
- Preflight Controller → Preflight Checks: runs checks (evidence: `src/app/usePreflight.ts`)
- Preflight Controller → Tauri IPC: scans workspace (evidence: `src/app/usePreflight.ts`)
- Preflight Controller → Policy Analysis: requests policy analysis (evidence: `src/app/usePreflight.ts`)
- IDE Interface → AI Chat: offers AI chat (evidence: `README.md`)
- AI Chat → AI Context and Changes: prepares changes (evidence: `src/ai/useAi.ts`)
- AI Context and Changes → Policy Analysis: checks proposed changes (evidence: `src/ai/engine.ts`)
- AI Chat → Conversation Storage: loads and saves conversations (evidence: `src/ai/useAi.ts`)
- AI Chat → Tauri IPC: requests provider operations (evidence: `src/ai/useAi.ts`)
- Tauri IPC → AI Providers: streams provider requests
- Tauri IPC → AI CLI Sessions: streams CLI requests
- IDE Interface → Swift LSP Controller: enables Swift services (evidence: `src/App.tsx`)
- Swift LSP Controller → Language Client: starts language client (evidence: `src/app/useSwiftLsp.ts`)
- Language Client → LSP Relay: uses native relay
- Developer → Embedded Terminal: opens terminal (evidence: `README.md`)
- Developer → App Updates: checks for updates (evidence: `README.md`)
- Developer → Agent Skills: opens coding agent (evidence: `README.md`)
- IDE Interface → Project Files: browses project files
