# iflow-ai/iflow-cli architecture

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

- Interactive diagram: https://gitdiagram.com/iflow-ai/iflow-cli
- Repository: https://github.com/iflow-ai/iflow-cli

## Overview

This repository exposes iFlow CLI mainly through product documentation; its only sampled source is a Homebrew formula that installs the separately distributed npm package, so it is not part of the runtime map. The documented user journey is to launch the terminal assistant in a workspace, provide a request, and receive AI-assisted analysis or actions. Nodes below represent documented capabilities, not inspected implementation modules; their paths are null because the tree contains no corresponding runtime source. Relationships are limited to README statements.

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_assistant["Assistant workflow"]
  node_cli["iFlow CLI"]
  node_conversation["Natural-language interaction"]
  node_project_context["Project understanding"]
  node_ai_models["AI model access"]
end

subgraph group_execution["Task execution"]
  node_planning["Planning and plan mode"]
  node_coding_tasks["Coding and file tasks"]
  node_terminal_tools["Terminal commands"]
  node_multimodal["Multimodal input"]
end

subgraph group_extensions["Extensions"]
  node_subagents["SubAgents"]
  node_mcp["MCP integrations"]
  node_open_market["Open Market"]
  node_custom_commands["Custom commands"]
  node_workflows["Workflow automation"]
end

subgraph group_continuity["Continuity and integrations"]
  node_conversation_history[("Conversation recovery")]
  node_memory["Memory compression"]
  node_ide_plugins["IDE plugins"]
end

node_user(("Terminal user"))
node_external_model{{"iFlow or compatible API"}}

node_user -->|"launches"| node_cli
node_user -->|"describes task"| node_conversation
node_cli -->|"accepts requests"| node_conversation
node_cli -->|"scans workspace"| node_project_context
node_cli -->|"uses models"| node_ai_models
node_ai_models -->|"connects to"| node_external_model
node_conversation -->|"requests planning"| node_planning
node_conversation -->|"requests tasks"| node_coding_tasks
node_conversation -->|"requests commands"| node_terminal_tools
node_conversation -->|"provides images"| node_multimodal
node_cli -->|"supports"| node_subagents
node_cli -->|"integrates"| node_mcp
node_open_market -->|"installs"| node_subagents
node_open_market -->|"installs"| node_mcp
node_cli -->|"provides access"| node_open_market
node_cli -->|"supports"| node_custom_commands
node_cli -->|"automates"| node_workflows
node_cli -->|"saves and resumes"| node_conversation_history
node_cli -->|"compresses context"| node_memory
node_cli -->|"supports"| node_ide_plugins

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_cli,node_conversation,node_project_context,node_ai_models,node_user toneBlue
class node_planning,node_coding_tasks,node_terminal_tools,node_multimodal toneAmber
class node_subagents,node_mcp,node_open_market,node_custom_commands,node_workflows,node_external_model toneMint
class node_conversation_history,node_memory,node_ide_plugins toneRose
```

## Components

### Assistant workflow

- **iFlow CLI**
- **Natural-language interaction**
- **Project understanding**
- **AI model access**

### Task execution

- **Planning and plan mode**
- **Coding and file tasks**
- **Terminal commands**
- **Multimodal input**

### Extensions

- **SubAgents**
- **MCP integrations**
- **Open Market**
- **Custom commands**
- **Workflow automation**

### Continuity and integrations

- **Conversation recovery**
- **Memory compression**
- **IDE plugins**

### Other components

- **Terminal user**
- **iFlow or compatible API**

## Connections

- Terminal user → iFlow CLI: launches (evidence: `README.md`)
- Terminal user → Natural-language interaction: describes task (evidence: `README.md`)
- iFlow CLI → Natural-language interaction: accepts requests (evidence: `README.md`)
- iFlow CLI → Project understanding: scans workspace (evidence: `README.md`)
- iFlow CLI → AI model access: uses models (evidence: `README.md`)
- AI model access → iFlow or compatible API: connects to (evidence: `README.md`)
- Natural-language interaction → Planning and plan mode: requests planning (evidence: `README.md`)
- Natural-language interaction → Coding and file tasks: requests tasks (evidence: `README.md`)
- Natural-language interaction → Terminal commands: requests commands (evidence: `README.md`)
- Natural-language interaction → Multimodal input: provides images (evidence: `README.md`)
- iFlow CLI → SubAgents: supports (evidence: `README.md`)
- iFlow CLI → MCP integrations: integrates (evidence: `README.md`)
- Open Market → SubAgents: installs (evidence: `README.md`)
- Open Market → MCP integrations: installs (evidence: `README.md`)
- iFlow CLI → Open Market: provides access (evidence: `README.md`)
- iFlow CLI → Custom commands: supports (evidence: `README.md`)
- iFlow CLI → Workflow automation: automates (evidence: `README.md`)
- iFlow CLI → Conversation recovery: saves and resumes (evidence: `README.md`)
- iFlow CLI → Memory compression: compresses context (evidence: `README.md`)
- iFlow CLI → IDE plugins: supports (evidence: `README.md`)
