Building Workflows

This guide covers the practical process of building effective multi-agent workflows in Modular9 — from designing your agent team to connecting nodes and testing execution.

Planning Your Workflow

Before placing any nodes, answer these questions:

  1. What is the starting input? — Text typed by a user, a scheduled trigger, or a webhook payload?
  2. What is the desired output? — A document, an API action, a Slack message, a database entry?
  3. What specialized processing is needed between input and output? — Research, writing, review, formatting, translation?
  4. Which agents have that expertise? — Browse the plugin packs to find the right specialists.

Specialist match matters

The quality of your workflow output is heavily influenced by how well you match the specialist to the task. A blog post through the Blog Writer plugin will outperform the same task run through a generic engineer. Use domain-specific plugins for domain-specific tasks.

Common Workflow Patterns

Linear Chain

The simplest pattern: each node receives the full output of the previous node.

Trigger → Agent A → Agent B → Agent C → Connector

Best for: Sequential tasks where each step builds on the last — research → draft → edit → publish.

Fan-Out (Parallel Delivery)

One specialist node feeds multiple connector nodes simultaneously.

Trigger → Blog Writer → [LinkedIn Connector]
                     → [Twitter Connector]
                     → [Mailchimp Connector]

Best for: Distributing AI-generated content to multiple channels at once.

Quality Gate Chain

Use look-ahead filters on edges to skip downstream nodes conditionally.

Trigger → Security Auditor →[only if HIGH severity]→ Dependency Scanner → Slack

Best for: Conditional processing — run expensive steps only when the upstream result warrants it.

Step-by-Step: Building a Content Pipeline

Let's build a complete SEO content pipeline: research → write → optimize → publish to LinkedIn.

Step 1: Add a Chat Trigger

Every new canvas starts with a Chat trigger. Click the gear icon on the Trigger node and set a sample prompt:

Write an article about the future of multi-agent AI systems

Step 2: Add the Blog Writer Node

  1. Open the ContentPack in the left sidebar.
  2. Drag Blog Writer onto the canvas.
  3. Position it to the right of the Trigger node.
  4. Connect: drag from the Trigger's right handle to the Blog Writer's left handle.

Step 3: Add the SEO Optimizer Node

  1. Expand GrowthPack.
  2. Drag SEO Strategist onto the canvas.
  3. Position it to the right of Blog Writer.
  4. Connect: Blog Writer → SEO Strategist.

Step 4: Configure the Blog Writer

  1. Click Blog Writer to select it.
  2. Click the gear icon → Advanced Settings.
  3. Under LLM Configuration:
    • Temperature: 0.8 (higher creativity for writing tasks)
    • Max Tokens: 8192 (long-form content needs more tokens)
  4. Under Logic Configuration (optional), set Reasoning Strategy to chain-of-thought for structured writing.

Step 5: Add the LinkedIn Connector

  1. Click the Connectors tab in the right panel.
  2. Drag LinkedIn onto the canvas.
  3. Connect: SEO Strategist → LinkedIn.
  4. Click the gear icon on the LinkedIn connector.
  5. Enter your LinkedIn API credentials and select action: create_post.

Step 6: Add a Look-Ahead Filter (Optional)

To only publish if the SEO score is high:

  1. Click the edge between SEO Strategist and LinkedIn.
  2. Enable the look-ahead filter.
  3. Set the condition: Only continue if the SEO optimization score is above 7 out of 10

Step 7: Test the Workflow

  1. Click Run in the toolbar.
  2. Watch the Output tab — each node's result appears as it completes.
  3. Verify the final LinkedIn post looks correct before saving.

Step 8: Save

Press Cmd+S to save. Name your workflow descriptively: "SEO Content → LinkedIn".

Configuring Node Behavior

Temperature

Controls creativity vs. consistency:

  • 0.0 – 0.3: Highly deterministic — ideal for code review, analysis, structured outputs
  • 0.5 – 0.7: Balanced — good for most tasks (default: 0.7)
  • 0.8 – 1.0: High creativity — writing, brainstorming, creative tasks

Max Tokens

Sets the maximum response length. Be aware of model context windows:

  • Short analytical tasks: 2048
  • Standard content: 4096 (default)
  • Long-form documents: 8192+

System Prompt Override

Each specialist node has a pre-written expert system prompt. You can override or extend it in Advanced Settings. Override examples:

  • "You are a technical writer specializing in developer documentation. Always use code examples."
  • "Respond in Spanish."
  • "Format all responses as bullet points with a summary at the top."

Multi-Node Data Flow Tips

Text flows as plain text

Node output is plain text (often markdown). The next node receives this text as its user message. If you need to pass structured data (JSON), include it inline in the text — downstream nodes can extract it.

Prefix context in prompts: If downstream nodes need to know they're receiving output from a previous step, configure the node's look-ahead instruction to add context:

The following is a security audit report. Extract only the CRITICAL severity items and suggest fixes.

Keep chains focused: Long chains (6+ nodes) can lose context fidelity. If quality degrades, break the workflow into two shorter workflows and chain them via webhook.

Testing and Debugging

Test with Sample Input

Before connecting real services (Slack, LinkedIn), test the AI pipeline alone:

  1. Remove connector nodes temporarily
  2. Run with sample input
  3. Inspect each node's output in the accordion
  4. Verify each agent is producing the expected quality
  5. Re-add connectors when satisfied

Inspect Node Output

Click any completed node row in the Output tab to expand its full response. Check:

  • Is the output structured as expected?
  • Are there any hallucinations or off-topic content?
  • Does the output length make sense for the next node's expected input?

Use the Trace Inspector

If you have LOGIC.md reasoning configured on a node, the Trace Inspector shows step-by-step reasoning: confidence scores, branch decisions, quality gate results.

Saving as a Template

Once you've built a useful workflow, you can share it as a template (coming soon). Currently, saved workflows can be shared by exporting the workflow JSON from the database.

Next Steps