Skip to content

Instantly share code, notes, and snippets.

@myui
Last active November 5, 2025 01:16
Show Gist options
  • Select an option

  • Save myui/ded0bfdf8765c315d51a94d043664437 to your computer and use it in GitHub Desktop.

Select an option

Save myui/ded0bfdf8765c315d51a94d043664437 to your computer and use it in GitHub Desktop.
Agentic Workflow
marp theme paginate backgroundColor backgroundImage style
true
default
true
linear-gradient(135deg,
section { background-color: white; color: #1a202c; padding: 50px; border-radius: 20px; } h1 { color: #4F46E5; text-align: center; font-size: 2.5rem; } h2 { color: #4F46E5; text-align: center; font-size: 2rem; margin-bottom: 1.5rem; } .thesis { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; padding: 2rem; border-radius: 15px; font-size: 1.5rem; text-align: center; margin: 2rem 0; font-weight: 600; } .highlight { color: #4F46E5; font-weight: 600; } .conclusion-box { background: linear-gradient(135deg, #10B981 0%, #059669 100%); color: white; padding: 1.5rem; border-radius: 15px; text-align: center; font-size: 1.1rem; margin: 1.5rem 0; } table { font-size: 0.9rem; } th { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; } .autonomy-none { background: #fee2e2; color: #991b1b; padding: 0.2rem 0.6rem; border-radius: 12px; font-size: 0.8rem; font-weight: 600; } .autonomy-moderate { background: #fef3c7; color: #92400e; padding: 0.2rem 0.6rem; border-radius: 12px; font-size: 0.8rem; font-weight: 600; } .autonomy-high { background: #d1fae5; color: #065f46; padding: 0.2rem 0.6rem; border-radius: 12px; font-size: 0.8rem; font-weight: 600; } .mermaid { background: #ffffff; border: none; font-size: 18px; font-family: 'Hiragino Sans', 'Yu Gothic', sans-serif; } .mermaid svg { display: block; min-width: 100%; max-width: 100%; max-height: 100%; margin: 0 auto; font-size: 18px; font-family: 'Hiragino Sans', 'Yu Gothic', sans-serif; } .mermaid text { font-size: 12px !important; font-weight: 600 !important; font-family: 'Hiragino Sans', 'Yu Gothic', sans-serif !important; fill: #333 !important; } .mermaid .node rect { fill: #f9f9f9 !important; stroke: #333 !important; stroke-width: 2px !important; rx: 5px !important; ry: 5px !important; } .mermaid .node { padding: 10px !important; } .mermaid .edgeLabel { background-color: #ffffff !important; color: #333 !important; font-size: 10px !important; } .fontsize-03 { font-size: 0.3em; } .fontsize-05 { font-size: 0.5em; } .fontsize-07 { font-size: 0.7em; } .fontsize-08 { font-size: 0.8em; } .fontsize-09 { font-size: 0.9em; } .fontsize-12 { font-size: 1.2em; } .fontsize-15 { font-size: 1.5em; } .fontsize-20 { font-size: 2.0em; }
<script type="module"> import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@latest/dist/mermaid.esm.min.mjs'; mermaid.initialize({ startOnLoad: true, theme: 'default', themeVariables: { fontFamily: 'Hiragino Sans, Yu Gothic, sans-serif', fontSize: '12px', primaryColor: '#f9f9f9', primaryTextColor: '#333', primaryBorderColor: '#333', lineColor: '#333' }, flowchart: { nodeSpacing: 50, rankSpacing: 80, curve: 'basis' } }); </script>

LLM Workflow vs. Agentic Workflow vs. AI Agent

Why Workflows Still Matter

Agentic Workflow = SuperAgent × Deterministic Workflow

Workflows provide reliability, observability, and guardrails.

Agents add reasoning and exploration.

Use a hybrid: structure for safety & scale, autonomy for adaptability.

Aproach ① Deterministic Workflow

LLM as a Single Step | Autonomy: None

flowchart LR
    D1["⚡ Trigger"] --> D2["📊 Get Data"]
    D2 --> D3["🤖 LLM"]
    D3 --> D4["📝 Format"]
    D4 --> D5["📧 Send"]

Control: Fully predefined
Description: The entire logic is fully orchestrated; LLM has no autonomy. Each step is explicitly defined. Deterministic and efficient.


Aproach ② Agentic Workflow

Super-Agent Within Workflow | Autonomy: Moderate

flowchart TB
    AG1["⚡ Trigger"] --> AG2["🤖 Research Agent"]
    AG2 --> AG3["💬 Chat Model"]
    AG2 --> AG4["📊 Get Data"]
    AG2 --> AG5["🔧 API Call"]
    AG3 --> AG6["📝 Markdown"]
    AG4 --> AG6
    AG5 --> AG6
    AG6 --> AG7["📧 Send"]

Control: Structured orchestration
Description: Agent orchestrated within workflow with tool access. Agent has moderate autonomy for tool calls, but workflow provides structure.


Aproach ③ SuperAgent

Self-Planning & Tool Use | Autonomy: High

flowchart TB
    SA1["⚡ Trigger"] --> SA2["🤖 SuperAgent"]
    SA2 --> SA3["💬 Chat Model"]
    SA2 --> SA4["📊 Get Data"]
    SA2 --> SA5["🔧 API"]
    SA2 --> SA6["💭 Think"]
    SA2 --> SA7["📧 Send Email"]
    SA2 -.-> SA8["🔄 Sub Agent"]
    SA2 -.-> SA9["🔧 Tool N"]

Control: Emergent control
Description: All tool calls and sub-agent invocations managed by agent. Non-deterministic and exploratory. High autonomy with emergent behavior.


Detailed Comparison

Type Control Autonomy Use Cases Primary Strength
Deterministic Workflow Fully predefined None ETL, RPA, prompt chains Reliable & auditable
Agentic Workflow Structured orchestration Moderate Research, synthesis, decision support Balanced control & reasoning
SuperAgent Emergent control High Open-ended planning, long tasks Autonomous & exploratory

Key Insight: The choice between these approaches depends on your specific requirements for control, predictability, and flexibility. More autonomy isn't always better—it comes with trade-offs in cost, speed, and determinism.


Performance Comparison (GPT-5)

Total Tokens (Context Consumption / Cost)

  • Deterministic: 4,543 tokens (15% of max)
  • Agentic: 15,605 tokens (52% of max)
  • SuperAgent: 30,204 tokens (100% of max)

Time (Processing Efficiency)

  • Deterministic: 41s (59% of max)
  • Agentic: 1m 09s (100%)
  • SuperAgent: 1m 09s (100%)

Task Success (Accuracy / Reproducibility)

  • Deterministic: 100%
  • Agentic: 100%
  • SuperAgent: 100%

Why Workflows Still Matter

Determinism & Reproducibility Predictable paths, safe retries. Critical for production systems where reliability is paramount.

Observability & Auditing
Step-level traces and HITL checkpoints. Essential for debugging and compliance.

Guardrails & Compliance
Policies enforced as code, not prompts. Ensures consistent application of business rules.

Cost & Latency Control
Minimize tokens by invoking LLMs only when necessary. Significant savings at scale.

Progressive Autonomy
Embed agents inside workflows; scale freedom with confidence. Start deterministic, add autonomy where it adds value.


Best Practices

Deterministic Workflow

✓ Repetitive tasks with well-defined steps
✓ Cost-sensitive operations at scale
✓ High-reliability requirements
✓ Regulatory compliance needs

Agentic Workflow

✓ Complex research and synthesis
✓ Decision support systems
✓ Balance between control & flexibility
✓ Tasks requiring reasoning with guardrails

SuperAgent

✓ Open-ended exploration tasks
✓ Long-running complex projects
✓ Creative problem-solving needs
✓ Outcomes matter more than predictability

The future of AI automation isn't about choosing between workflows and agents—it's about intelligently combining them to maximize value.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment