Workflow SDK 5.8 Rebuilt Engine Cuts Step Latency 12x

Vercel BlogVercel Blog·Original
Operator Bae ChangHyun

Key point

Workflow SDK 5.8's rebuilt engine cuts step-to-step latency 12x and uses 14x less function time outside step code for large fan-outs.

Details

  • Workflow SDK 5.8 runs workflows on a rebuilt execution engine, with 12x lower step-to-step latency and 14x less function time outside step code for large fan-outs.
  • In benchmarks comparing 5.2.0 with 5.8.0, p75 step-to-step overhead fell from 85 ms to 7 ms; a median run with 102 seconds of step work finished in 111 seconds instead of 3.0 minutes.
  • For 256 parallel steps, fan-out overhead fell 5.5x, from 13.5 seconds to 2.5 seconds; median time in functions beyond step work fell 14x, from 1,446 seconds to 105 seconds.
  • A five-turn agent loop with streamed tokens and tool calls added 0.9 seconds of overhead instead of 3.0 seconds, 3.3x less; resuming after 1 second idle fell from 425 ms to 184 ms, 2.3x faster.

Upgrade and compatibility

  • Upgrade to [email protected] or later; new runs use the new engine by default, while runs already started on an older version continue on that version.
  • Set WORKFLOW_SPEC_VERSION=8 to keep new runs on the previous engine; users on 4.x should start with the upgrade guide because v5 is a major release.
  • Vercel-maintained Worlds support the new engine; third-party Worlds need World spec version 9, or upgrades will not provide these improvements.

Retry safety and resume time

  • The performance gains rely partly on speculative execution, which is safe only for idempotent Steps; pass stepId as an idempotency key where possible.
  • Set maxRetries=0 for sensitive Steps that cannot be retried, so they run at most once.
  • Resumptions after more than 5 seconds idle may have slightly more overhead; keeping functions warm longer can improve time-to-resume at the cost of additional compute time.

This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.

Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.