# aarthireddyyy/intellitask architecture

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

- Interactive diagram: https://gitdiagram.com/aarthireddyyy/intellitask
- Repository: https://github.com/aarthireddyyy/intellitask

## Overview

IntelliTask accepts a task through a browser interface or the API, then the orchestrator records it and runs a CrewAI workflow with planning, research, analysis, and report-writing agents. Research uses web search; the writer can save a Markdown report. Task status and output are persisted for API polling. The README documents the overall workflow; sampled source confirms the API, orchestration, persistence, and tool wiring, but does not show every agent’s internal execution details.

Main entry points: [`orchestrator.py`](https://github.com/aarthireddyyy/intellitask/blob/main/orchestrator.py) (Crew Orchestrator), [`api/app.py`](https://github.com/aarthireddyyy/intellitask/blob/main/api/app.py) (Task API), [`agents/researcher.py`](https://github.com/aarthireddyyy/intellitask/blob/main/agents/researcher.py) (Market Researcher), [`agents/writer.py`](https://github.com/aarthireddyyy/intellitask/blob/main/agents/writer.py) (Report Writer)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["User Interface"]
  node_browser["Browser UI<br/>[script.js]"]
  node_api["Task API<br/>[app.py]"]
end

subgraph group_workflow["Task Workflow"]
  node_orchestrator["Crew Orchestrator<br/>[orchestrator.py]"]
  node_manager["Task Manager<br/>[manager.py]"]
  node_researcher["Market Researcher<br/>[researcher.py]"]
  node_analyst["Business Analyst<br/>[analyst.py]"]
  node_writer["Report Writer<br/>[writer.py]"]
end

subgraph group_tools["Research And Output"]
  node_search_tool["Web Search Tool<br/>[search_tool.py]"]
  node_file_writer["Markdown File Writer<br/>[file_writer.py]"]
  node_outputs["Generated Reports"]
end

subgraph group_state["Task State"]
  node_task_store["Task Store Logic<br/>[task_store.py]"]
  node_task_json[("Task Records<br/>[task_store.json]")]
end

node_user(("Task Submitter"))
node_web["DuckDuckGo Search"]
node_ollama["Ollama LLM"]

node_user -->|"enters task"| node_browser
node_browser -->|"starts and polls"| node_api
node_api -->|"runs task"| node_orchestrator
node_api -->|"reads status"| node_task_json
node_orchestrator -->|"creates and updates"| node_task_store
node_task_store -->|"loads and saves"| node_task_json
node_orchestrator -->|"creates and assigns"| node_manager
node_orchestrator -->|"creates and assigns"| node_researcher
node_orchestrator -->|"creates and assigns"| node_analyst
node_orchestrator -->|"creates and assigns"| node_writer
node_researcher -->|"uses tool"| node_search_tool
node_search_tool -->|"searches web"| node_web
node_writer -->|"uses tool"| node_file_writer
node_file_writer -->|"writes report"| node_outputs
node_manager -->|"uses model"| node_ollama
node_researcher -->|"uses model"| node_ollama
node_analyst -->|"uses model"| node_ollama
node_writer -->|"uses model"| node_ollama

click node_browser "https://github.com/aarthireddyyy/intellitask/blob/main/frontend/script.js"
click node_api "https://github.com/aarthireddyyy/intellitask/blob/main/api/app.py"
click node_orchestrator "https://github.com/aarthireddyyy/intellitask/blob/main/orchestrator.py"
click node_manager "https://github.com/aarthireddyyy/intellitask/blob/main/agents/manager.py"
click node_researcher "https://github.com/aarthireddyyy/intellitask/blob/main/agents/researcher.py"
click node_analyst "https://github.com/aarthireddyyy/intellitask/blob/main/agents/analyst.py"
click node_writer "https://github.com/aarthireddyyy/intellitask/blob/main/agents/writer.py"
click node_search_tool "https://github.com/aarthireddyyy/intellitask/blob/main/tools/search_tool.py"
click node_file_writer "https://github.com/aarthireddyyy/intellitask/blob/main/tools/file_writer.py"
click node_outputs "https://github.com/aarthireddyyy/intellitask/tree/main/outputs"
click node_task_store "https://github.com/aarthireddyyy/intellitask/blob/main/memory/task_store.py"
click node_task_json "https://github.com/aarthireddyyy/intellitask/blob/main/memory/task_store.json"

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_browser,node_api toneBlue
class node_orchestrator,node_manager,node_researcher,node_analyst,node_writer toneAmber
class node_search_tool,node_file_writer,node_outputs toneMint
class node_task_store,node_task_json,node_user toneRose
class node_web,node_ollama toneIndigo
```

## Components

### User Interface

- [Browser UI](https://github.com/aarthireddyyy/intellitask/blob/main/frontend/script.js): `frontend/script.js`
- [Task API](https://github.com/aarthireddyyy/intellitask/blob/main/api/app.py): `api/app.py`

### Task Workflow

- [Crew Orchestrator](https://github.com/aarthireddyyy/intellitask/blob/main/orchestrator.py): `orchestrator.py`
- [Task Manager](https://github.com/aarthireddyyy/intellitask/blob/main/agents/manager.py): `agents/manager.py`
- [Market Researcher](https://github.com/aarthireddyyy/intellitask/blob/main/agents/researcher.py): `agents/researcher.py`
- [Business Analyst](https://github.com/aarthireddyyy/intellitask/blob/main/agents/analyst.py): `agents/analyst.py`
- [Report Writer](https://github.com/aarthireddyyy/intellitask/blob/main/agents/writer.py): `agents/writer.py`

### Research And Output

- [Web Search Tool](https://github.com/aarthireddyyy/intellitask/blob/main/tools/search_tool.py): `tools/search_tool.py`
- [Markdown File Writer](https://github.com/aarthireddyyy/intellitask/blob/main/tools/file_writer.py): `tools/file_writer.py`
- [Generated Reports](https://github.com/aarthireddyyy/intellitask/tree/main/outputs): `outputs`

### Task State

- [Task Store Logic](https://github.com/aarthireddyyy/intellitask/blob/main/memory/task_store.py): `memory/task_store.py`
- [Task Records](https://github.com/aarthireddyyy/intellitask/blob/main/memory/task_store.json): `memory/task_store.json`

### Other components

- **Task Submitter**
- **DuckDuckGo Search**
- **Ollama LLM**

## Connections

- Task Submitter → Browser UI: enters task (evidence: `frontend/script.js`)
- Browser UI → Task API: starts and polls (evidence: `frontend/script.js`)
- Task API → Crew Orchestrator: runs task (evidence: `api/app.py`)
- Task API → Task Records: reads status (evidence: `api/app.py`)
- Crew Orchestrator → Task Store Logic: creates and updates (evidence: `orchestrator.py`)
- Task Store Logic → Task Records: loads and saves (evidence: `memory/task_store.py`)
- Crew Orchestrator → Task Manager: creates and assigns (evidence: `orchestrator.py`)
- Crew Orchestrator → Market Researcher: creates and assigns (evidence: `orchestrator.py`)
- Crew Orchestrator → Business Analyst: creates and assigns (evidence: `orchestrator.py`)
- Crew Orchestrator → Report Writer: creates and assigns (evidence: `orchestrator.py`)
- Market Researcher → Web Search Tool: uses tool (evidence: `agents/researcher.py`)
- Web Search Tool → DuckDuckGo Search: searches web (evidence: `tools/search_tool.py`)
- Report Writer → Markdown File Writer: uses tool (evidence: `agents/writer.py`)
- Markdown File Writer → Generated Reports: writes report (evidence: `tools/file_writer.py`)
- Task Manager → Ollama LLM: uses model (evidence: `agents/manager.py`)
- Market Researcher → Ollama LLM: uses model (evidence: `agents/researcher.py`)
- Business Analyst → Ollama LLM: uses model (evidence: `agents/analyst.py`)
- Report Writer → Ollama LLM: uses model (evidence: `agents/writer.py`)
