fix(agent): trim leading whitespace from agent output before frontmatter extraction #570

Merged
xiaoju merged 1 commits from fix/567-trim-leading-whitespace into main 2026-05-28 00:42:23 +00:00
Owner

What

Trim leading whitespace from agent output before frontmatter extraction to prevent false negatives.

Why

Observed uwf-hermes returning output with leading newlines before ---, causing tryFrontmatterFastPath() to fail and waste 2 retries. (#567)

Changes

  • workflow-util-agent/src/run.ts.trimStart() on agentResult.output after initial run and after each retry

Ref

Fixes #567

小橘 🍊(NEKO Team)

## What Trim leading whitespace from agent output before frontmatter extraction to prevent false negatives. ## Why Observed uwf-hermes returning output with leading newlines before `---`, causing `tryFrontmatterFastPath()` to fail and waste 2 retries. (#567) ## Changes - `workflow-util-agent/src/run.ts` — `.trimStart()` on `agentResult.output` after initial run and after each retry ## Ref Fixes #567 小橘 🍊(NEKO Team)
xiaoju added 1 commit 2026-05-28 00:40:30 +00:00
xiaoju merged commit abc9dcfc5a into main 2026-05-28 00:42:23 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/workflow#570