# FlowDrop Module Dependency Graph

This document provides a visual representation of the FlowDrop module dependencies and relationships using Mermaid.js.

## Module Dependency Graph

The arrows indicate dependency direction: `A --> B` means "B depends on A".

!!!note
    This diagram shows only direct dependencies. Transitive dependencies (grandparent relationships) are omitted for clarity.


```mermaid
graph TD

    %% Base modules (no flowdrop dependencies)
    FD_UI_COMP[flowdrop_ui_components]
    FD_JOB[flowdrop_job]

    %% Main module
    FD_UI_COMP --> FD[flowdrop]

    %% Core modules
    FD --> FD_ORCH[flowdrop_orchestration]
    FD --> FD_NODE_CAT[flowdrop_node_category]
    FD_NODE_CAT --> FD_NODE_TYPE[flowdrop_node_type]

    %% Entity modules
    FD_NODE_TYPE --> FD_WORKFLOW[flowdrop_workflow]

    %% Pipeline module
    FD_JOB --> FD_PIPELINE[flowdrop_pipeline]
    FD_WORKFLOW --> FD_PIPELINE

    %% Execution foundation
    FD_ORCH --> FD_SESSION[flowdrop_session]
    FD_PIPELINE --> FD_SESSION
    FD_ORCH --> FD_RUNTIME[flowdrop_runtime]
    FD_PIPELINE --> FD_RUNTIME

    %% Execution layer
    FD_SESSION --> FD_INTERRUPT[flowdrop_interrupt]
    FD_RUNTIME --> FD_INTERRUPT

    %% Feature modules
    FD_RUNTIME --> FD_TRIGGER[flowdrop_trigger]
    FD_WORKFLOW --> FD_CHAT[flowdrop_chat]

    FD_RUNTIME --> FD_STATEGRAPH[flowdrop_stategraph]

    FD_STATEGRAPH --> FD_PLAYGROUND[flowdrop_playground]

    %% Integration modules
    FD_TRIGGER --> FD_ORCH_CONN[flowdrop_orchestration_connector]

    %% Styling
    classDef baseModule fill:#c8e6c9,stroke:#2e7d32,stroke-width:2px
    classDef coreModule fill:#e1f5fe,stroke:#01579b,stroke-width:2px
    classDef uiModule fill:#e8f577,stroke:#1b5e20,stroke-width:2px
    classDef executionModule fill:#fff3e0,stroke:#e65100,stroke-width:2px
    classDef featureModule fill:#e3f2fd,stroke:#1565c0,stroke-width:2px
    classDef integrationModule fill:#efefef,stroke:#2e2e2e,stroke-width:2px
    class FD,FD_NODE_CAT,FD_NODE_TYPE,FD_WORKFLOW,FD_ORCH baseModule
    class FD_UI_COMP uiModule
    class FD_PIPELINE,FD_JOB,FD_RUNTIME,FD_INTERRUPT,FD_SESSION executionModule
    class FD_ORCH_CONN,FD_CHAT integrationModule
    class FD_TRIGGER,FD_STATEGRAPH,FD_PLAYGROUND featureModule
```

## Module Summary

| Module | Direct Dependencies | Full Dependencies (info.yml) |
| --- | --- | --- |
| `flowdrop` | ui_components | flowdrop_ui_components |
| `flowdrop_ui_components` | (base module) | — |
| `flowdrop_node_category` | flowdrop | flowdrop |
| `flowdrop_job` | (base module) | drupal:options, drupal:text |
| `flowdrop_orchestration` | flowdrop | flowdrop |
| `flowdrop_node_type` | node_category | flowdrop, flowdrop_node_category |
| `flowdrop_workflow` | node_type | flowdrop, flowdrop_node_type, flowdrop_node_category |
| `flowdrop_pipeline` | job, node_type, workflow | flowdrop_job, flowdrop_node_type, flowdrop_workflow, drupal:options, drupal:text |
| `flowdrop_runtime` | orchestration, pipeline | flowdrop, flowdrop_orchestration, flowdrop_workflow, flowdrop_pipeline, flowdrop_job, flowdrop_node_type |
| `flowdrop_interrupt` | session, runtime | flowdrop, flowdrop_orchestration, flowdrop_pipeline, flowdrop_job, flowdrop_runtime, flowdrop_session, drupal:user |
| `flowdrop_session` | orchestration, pipeline | flowdrop_workflow, flowdrop_pipeline, flowdrop_orchestration, drupal:user |
| `flowdrop_trigger` | orchestration, runtime | flowdrop, flowdrop_node_type, flowdrop_orchestration, flowdrop_workflow, flowdrop_runtime, flowdrop_pipeline |
| `flowdrop_stategraph` | orchestration, runtime | flowdrop, flowdrop_orchestration, flowdrop_runtime, flowdrop_workflow, flowdrop_pipeline, flowdrop_job, flowdrop_node_type, flowdrop_node_category |
| `flowdrop_playground` | stategraph | flowdrop_session, flowdrop_stategraph, flowdrop_ui_components |
| `flowdrop_workflow_executor` | session | flowdrop, flowdrop_workflow, flowdrop_session |
| `flowdrop_orchestration_connector` | orchestration, trigger | flowdrop_orchestration, flowdrop_workflow, flowdrop_trigger, flowdrop_runtime, drupal:orchestration |

## Legend

| Color | Category | Description |
| --- | --- | --- |
| Green | Base | Foundation modules with minimal dependencies |
| Light blue | Core | Central modules defining key abstractions |
| Yellow-green | UI | User interface modules |
| Orange | Execution | Workflow execution and runtime modules |
| Gray | Integration | External platform connectors |
| Blue | Feature | Optional feature modules |
