Skip to main content
The AgentWorkflow CRD lets you describe a multi-step AI pipeline entirely in YAML. When you apply an AgentWorkflow, the Flokoa operator compiles it into an Argo WorkflowTemplate — a reusable, versioned pipeline definition managed by Argo Workflows. Your pipeline can call deployed Agent CRs via the A2A protocol, run Marvin-powered tasks in ephemeral containers, execute arbitrary container workloads, make HTTP requests, and branch conditionally — all wired together as a directed acyclic graph (DAG) through dependsOn declarations.
AgentWorkflow requires Argo Workflows to be installed in your cluster. The operator compiles each AgentWorkflow into an Argo WorkflowTemplate. Individual pipeline runs are triggered by creating Argo Workflow resources that reference the generated template.

API reference


Spec fields

params

Each parameter in spec.params has:

tasks

Each task in spec.tasks must have a name and exactly one task type: Each task also supports:

Basic example

The following workflow takes a topic as input, calls a research agent to gather information, and then passes that output to a summarisation agent:
Apply it with:

Multi-task pipeline with conditional branching


Retry strategy

You can define a default retry strategy at the workflow level and override it per task:

Status fields

After the operator compiles the AgentWorkflow into an Argo WorkflowTemplate, it updates the following status fields:

kubectl operations


Best practices

  1. Install Argo Workflows before creating AgentWorkflows — the operator depends on Argo CRDs being present. Verify with kubectl get crd workflowtemplates.argoproj.io.
  2. Name tasks clearly — task names appear in Argo’s UI and logs; descriptive names like classify-intent make pipelines much easier to debug than task-1.
  3. Use params for runtime inputs — avoid hard-coding values that change between runs directly in task text fields; parameterise them instead.
  4. Set workflow and task timeouts — unbounded workflows can consume cluster resources indefinitely; always define a maximum duration.
  5. Define retryStrategy at the workflow level and override only for tasks with special requirements — this keeps retry logic consistent and reduces verbosity.
  6. Use dependsOn to express ordering explicitly — do not rely on list order; the DAG is the source of truth for execution order.
  7. Keep serviceAccountName in a dedicated ServiceAccount with the minimum RBAC permissions needed by workflow pods.
  8. Version-control your AgentWorkflow manifests alongside the Agent CRs they call — changing an agent’s API without updating the workflow that calls it will cause runtime failures.