# omi-kalix/multi-agent-ai-workflow-for-content-creation architecture

> Architecture diagram of the GitHub repository omi-kalix/multi-agent-ai-workflow-for-content-creation, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-07-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/omi-kalix/multi-agent-ai-workflow-for-content-creation
- Repository: https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation

## Overview

1. **Repository purpose**
   This repo is not a traditional application codebase; it is a **workflow-as-code package** for a multi-agent content creation system. The main deliverable is an **n8n workflow definition** that automates LinkedIn post creation end to end.

2. **Primary runtime boundary**
   The core execution environment is **n8n**. The repository stores the workflow configuration, while execution happens inside n8n’s orchestrator. That means the repo defines the automation graph, but the actual runtime depends on n8n plus external APIs and credentials.

3. **Main orchestration flow**
   The system follows a linear content pipeline:
   **form input → research → content generation → image creation → email delivery**.
   This is the central data flow to represent in an architecture diagram.

4. **Workflow subsystem**
   The file `workflows/Multi-Agent-AI-Workflow-for-Content-Creation.json` is the key artifact. It likely contains the node graph, branching logic, and service integrations that implement the multi-agent sequence. This is the “control plane” of the repo.

5. **Prompt subsystem**
   `prompts/prompts.md` is the prompt library for the AI agents. Architecturally, this is the layer that separates **agent behavior/specification** from the workflow wiring. The prompts define how research, writing, and possibly packaging behave without embedding that logic directly in the workflow definition.

6. **Research boundary**
   The research step is an external data acquisition stage using **Crawleo.dev** as the search/research service. This is the first place where live web context enters the system, and it feeds structured input into the downstream content-generation agent.

7. **AI generation boundary**
   The content-writing agent uses a local or self-hosted model stack centered on **Ollama / Llama 3.2** per the README. This is the main text-generation boundary and represents the system’s reasoning/content synthesis layer.

8. **Visual generation boundary**
   The visual agent produces a custom image using external image-generation services such as **DALL·E** or **Imagen 4**. In architecture terms, this is a separate modality pipeline: it consumes the topic/context and outputs a post image asset.

9. **Delivery subsystem**
   The final step packages the generated post and image and sends them through an email service such as **Gmail** or **SendGrid**. This is the output boundary of the automation, turning workflow results into a deliverable artifact for the user.

10. **Assets directory**
   `assets/` contains screenshots and example outputs, including workflow diagrams and generated post images. These are documentation artifacts only; they support understanding and validation but are not part of the runtime path.

11. **Operational dependencies**
   The README indicates the system depends on **API keys and credentials** for AI, web search, and email. These external secrets are a key architectural dependency because they gate access to each stage of the pipeline.

12. **Deployment/usage model**
   The repo is designed for import into an n8n environment rather than being built and deployed like a software service. The practical deployment unit is the workflow import plus configuration of connected services.

13. **What to emphasize in a diagram**
   A clear diagram should show:
   the user submitting a topic into n8n, n8n coordinating separate research/content/image/delivery stages, and each stage calling an external service. The most important boundaries are **n8n orchestration**, **research API**, **LLM generation**, **image generation**, and **email delivery**.

14. **Overall architecture summary**
   This is a **multi-agent, service-oriented automation workflow** with a single orchestrator and several specialized external providers. The repo’s job is to capture that orchestration and the prompts that shape the agents, not to implement custom application logic.

Main entry points: [`prompts/prompts.md`](https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/blob/main/prompts/prompts.md) (Prompt Library), [`workflows/Multi-Agent-AI-Workflow-for-Content-Creation.json`](https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/blob/main/workflows/Multi-Agent-AI-Workflow-for-Content-Creation.json) (Workflow JSON)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_repo_artifacts["Repo Artifacts"]
  node_workflow_json["Workflow JSON<br/>n8n workflow"]
  node_prompts["Prompt Library<br/>prompt set<br/>[prompts.md]"]
  node_assets["Assets<br/>examples"]
  node_credentials{{"API Keys<br/>secrets"}}
end

subgraph group_n8n_runtime["n8n Runtime"]
  node_n8n["n8n<br/>orchestrator"]
  node_intake["Topic Intake<br/>form input"]
  node_research["Research Agent<br/>research stage"]
  node_writer["Writing Agent<br/>text generation"]
  node_image_agent["Image Agent<br/>image stage"]
  node_delivery["Delivery Agent<br/>delivery stage"]
end

subgraph group_external_services["External Services"]
  node_crawleo[("Crawleo.dev<br/>search API")]
  node_ollama[("Ollama / Llama 3.2<br/>llm runtime")]
  node_image_api[("DALL·E / Imagen 4<br/>image API")]
  node_email_api[("Gmail / SendGrid<br/>email API")]
end

node_workflow_json -->|"imports"| node_n8n
node_n8n -->|"starts"| node_intake
node_intake -->|"feeds"| node_research
node_research -->|"queries"| node_crawleo
node_research -->|"context"| node_writer
node_prompts -->|"instructs"| node_writer
node_writer -->|"generates"| node_ollama
node_writer -->|"handoff"| node_image_agent
node_prompts -->|"guides"| node_image_agent
node_image_agent -->|"renders"| node_image_api
node_image_agent -->|"asset"| node_delivery
node_delivery -->|"sends"| node_email_api
node_credentials -.->|"auth"| node_crawleo
node_credentials -.->|"auth"| node_ollama
node_credentials -.->|"auth"| node_image_api
node_credentials -.->|"auth"| node_email_api

click node_workflow_json "https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/blob/main/workflows/Multi-Agent-AI-Workflow-for-Content-Creation.json"
click node_prompts "https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/blob/main/prompts/prompts.md"
click node_assets "https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/tree/main/assets"

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_workflow_json,node_prompts,node_assets,node_credentials toneBlue
class node_n8n,node_intake,node_research,node_writer,node_image_agent,node_delivery toneAmber
class node_crawleo,node_ollama,node_image_api,node_email_api toneMint
```

## Components

### Repo Artifacts

Workflow package contents and supporting documentation.

- [Workflow JSON](https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/blob/main/workflows/Multi-Agent-AI-Workflow-for-Content-Creation.json): n8n workflow · Main n8n workflow definition for the content-creation pipeline. · `workflows/Multi-Agent-AI-Workflow-for-Content-Creation.json`
- [Prompt Library](https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/blob/main/prompts/prompts.md): prompt set · Agent instructions and behavior spec separated from workflow wiring. · `prompts/prompts.md`
- [Assets](https://github.com/omi-kalix/multi-agent-ai-workflow-for-content-creation/tree/main/assets): examples · Screenshots and sample outputs used for documentation and validation. · `assets`
- **API Keys**: secrets · Operational credentials required for research, generation, and delivery.

### n8n Runtime

The orchestrated automation flow that executes inside n8n.

- **n8n**: orchestrator · Execution boundary that runs the workflow graph and coordinates all stages.
- **Topic Intake**: form input · Starting point where the user submits a topic or content request.
- **Research Agent**: research stage · Collects web context and structured notes for downstream generation.
- **Writing Agent**: text generation · Synthesizes the LinkedIn post content from topic and research inputs.
- **Image Agent**: image stage · Creates a custom visual asset for the post.
- **Delivery Agent**: delivery stage · Packages the generated post and image for email delivery.

### External Services

Third-party APIs and model providers used by the workflow.

- **Crawleo.dev**: search API · External research service used to gather live web context.
- **Ollama / Llama 3.2**: llm runtime · Local or self-hosted model stack used for post generation.
- **DALL·E / Imagen 4**: image API · External image-generation service used for the visual asset.
- **Gmail / SendGrid**: email API · Outbound delivery service for sending the finished package.

## Connections

- Workflow JSON → n8n: imports · Workflow definition is imported into the n8n execution environment.
- n8n → Topic Intake: starts · n8n receives the submitted topic and begins orchestration.
- Topic Intake → Research Agent: feeds · Topic input is handed to the research stage.
- Research Agent → Crawleo.dev: queries · Research stage pulls external context from Crawleo.dev.
- Research Agent → Writing Agent: context · Structured research notes are passed into the writing agent.
- Prompt Library → Writing Agent: instructs · Prompt library shapes post style, structure, and behavior.
- Writing Agent → Ollama / Llama 3.2: generates · Writing agent calls the LLM runtime for content synthesis.
- Writing Agent → Image Agent: handoff · Generated topic and copy context are forwarded to the visual stage.
- Prompt Library → Image Agent: guides · Prompt library can also define image-generation behavior.
- Image Agent → DALL·E / Imagen 4: renders · Image stage requests the external image provider.
- Image Agent → Delivery Agent: asset · Generated image is packaged with the post for delivery.
- Delivery Agent → Gmail / SendGrid: sends · Final package is delivered through the email service.
- API Keys → Crawleo.dev: auth · API credentials gate access to the research service.
- API Keys → Ollama / Llama 3.2: auth · API credentials or local access gate the model runtime.
- API Keys → DALL·E / Imagen 4: auth · API credentials gate access to image generation.
- API Keys → Gmail / SendGrid: auth · API credentials gate outbound email delivery.
