Claude Code Workflows: Critical Analysis and Issues
Analyzing Claude Code workflows, script orchestration mechanics, model selection challenges, and token cost constraints.

Stock photo for illustration only, not from the actual event
- Workflow tool creates a JavaScript dialect script executed inside a special runtime without Date.now().
- Orchestration is managed by the Claude Code harness rather than the main Claude session.
- Enabling ultracode can cause token costs to skyrocket due to harness triggers.
- The definition emphasizes that pipelines are favored over parallel execution due to latency.
The workflow tool creates a script—a dialect of JavaScript executed inside a specialized runtime. The script is wrapped in an async function, allowing top-level async / await and return statements, while banning certain functions like Date.now() because they break resumability.
The script features primitives governing the orchestration layer, breaking workflows into phases such as design, implementation, and verification, which primarily serve a presentational purpose. While multi-agent orchestration is not entirely new, the key difference here is that workflows are orchestrated by the Claude Code harness rather than Claude itself. Once authored and launched, the Claude Code application manages the orchestration while the main session model consumes minimal tokens.
This approach differs from Agent Teams, where Claude must act as the team leader babysitting other agents, and surpasses independent subagent fleets that require constant handoff mediation by Claude.

Stock photo for illustration only, not from the actual event
This represents a fundamental shift rather than a mere pattern improvement, operating similarly to hooks by working outside the agentic loop. They do not burn the main session's context window or rely on models for difficult long-horizon decisions. Despite this, workflows are often viewed as impractical and expensive. While plugins allow users to ship saved workflows, most resources instead implement secondary emulators or ports to other systems.
An in-depth analysis reveals that shifting orchestration away from the AI model to the harness aims to mitigate context window bottlenecks and conserve tokens during long tasks. However, the primary challenge remains that models and users alike can easily bypass cost constraints if explicit reminders or hard-coded configurations are omitted.
A recurring problem in workflow definitions involves model selection per phase. The guidelines recommend defaulting to the main session model unless highly confident, yet in practice, models like Fable or Opus frequently neglect cost-optimizing configurations unless explicitly prompted during invocation.
Furthermore, enabling ultracode often discards token cost constraints, and the harness currently fails to distinguish between mentioning a term and utilizing it, sometimes triggering workflows unintentionally. Finally, the documentation stresses that pipelines outperform parallel execution, as barrier latency forces fast agents to waste idle time waiting for the slowest worker.
Source: Dev.to
Found something wrong in this article? Report an issue with this article
Comments
Leave a Comment