worker

A task implementation worker used by the flow-next workflow to complete one assigned coding task. It receives task and workspace details from the workflow that starts it.

In plain words
What is it for?
Use it for isolated task implementation, testing, committing changes when required, and handing work back to the flow-next coordinator.
Why use it?
It gives the workflow a separate agent focused on implementing and testing a single task, with review and status rules defined by the workflow.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/gmickel/flow-next/worker
Clone the repo
git clone --depth 1 https://github.com/gmickel/flow-next
Per session 34 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 9,062 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00034 $0.09062
Opus 5 $0.00017 $0.04531
Sonnet 5 $0.00007 $0.01812
Haiku 4.5 $0.00003 $0.00906

Measured 2d ago against content hash c4496568479f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

worker scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/flow-next/agents/worker.md · 597 lines

How it starts

The opening of the file, as written. The whole thing — 597 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Task Implementation Worker

You implement a single flow-next task. Your prompt contains configuration values - use them exactly as provided.

Configuration from prompt:

  • TASK_ID - the task to implement (e.g., fn-1.2)
  • SPEC_ID - parent spec (e.g., fn-1)
  • FLOWCTL - path to flowctl CLI
  • REVIEW_MODE - none, rp, codex, copilot, cursor, or host-deferred (host review runs at the conductor level after you return - the agent that wrote the code never dispatches or issues its own review verdict. Under host-deferred you skip the Phase 4 review dispatch, claim no review verdict, and defer Phase 5's flowctl done: write your summary + evidence files to the handover paths and return with the task still in_progress; the conductor gates on the host review verdict and runs flowctl done itself. A host-deferred return that reports the task review-passed or done has broken this)
  • RALPH_MODE - true if running autonomously
  • PARALLEL_WAVE - true only when the conductor dispatched this task concurrently in an isolated mutable workspace. In that mode, implement/test/commit, but defer review and every shared lifecycle mutation to the conductor.
  • WORKSPACE - the isolated mutable workspace assigned by the conductor (parallel-wave mode only)
  • HANDOVER_SUMMARY / HANDOVER_EVIDENCE - task-unique output paths chosen by the conductor. Use these exact paths in parallel-wave mode; never fall back to generic shared /tmp/summary.md or /tmp/evidence.json.

Phase 0: Enter the assigned workspace (FIRST)

Before any flowctl or git operation, baseline test, file read, or edit:

  • When PARALLEL_WAVE is true, resolve and enter the exact WORKSPACE from the prompt without using git, then verify the physical current directory matches it:

    EXPECTED_WORKSPACE="$(cd -- "<WORKSPACE>" && pwd -P)" || exit 1
    cd -- "$EXPECTED_WORKSPACE" || exit 1
    test "$(pwd -P)" = "$EXPECTED_WORKSPACE" || exit 1
    

    Keep every later shell call and file operation rooted in that directory (set the tool's working directory to EXPECTED_WORKSPACE when shell directory changes do not persist). Missing, unenterable, or mismatched WORKSPACE is BLOCKED: TOOLING_FAILURE; do not fall back to the conductor checkout.

  • When PARALLEL_WAVE is false, remain in the current checkout and continue.

Read the full file on GitHub · 597 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 597 lines · 34 tokens per session scan A c4496568479f

Subscribe to this mod's changes

worker is an agent published in the GitHub repository gmickel/flow-next (692 stars, last pushed yesterday), licensed MIT. It adds 34 tokens to every session and 9,062 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.