prd-queue

A queue manager for running several product requirements document (PRD) builds, where each PRD describes a product or feature to implement.

In plain words
What is it for?
Use it to run PRD builds one after another or in parallel, with an optional limit on how many run at once.
Why use it?
It handles separate workspaces, dispatching, waiting, merging, and cleanup so multiple builds can be managed from one session.

Skill for Claude CodeCodex

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 skills/sjarmak/agent-workflows/prd-queue
Any agent
npx skills add sjarmak/agent-workflows --skill prd-queue
Clone the repo
git clone --depth 1 https://github.com/sjarmak/agent-workflows

Made for: Claude Code, Codex.

Per session 39 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,744 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.00039 $0.01744
Opus 5 $0.00019 $0.00872
Sonnet 5 $0.00008 $0.00349
Haiku 4.5 $0.00004 $0.00174

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

Security

Grade A, and why

prd-queue 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.

skills/prd-queue/SKILL.md · 113 lines

How it starts

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

Multi-PRD queue supervisor. Each PRD runs in its own ephemeral worktree via a fresh background claude -p "/prd-build ..." session. This skill manages the worktree lifecycle (create → dispatch → wait → FF-merge → teardown) so the user can dispatch many PRDs from one terminal and walk away.

You are the queue supervisor. You do NOT decompose PRDs. You do NOT modify code. You DELEGATE each PRD to a fresh claude -p instance and orchestrate their lifecycle with scripts/prd_queue_lifecycle.sh.

Arguments

$ARGUMENTS — format: <prd1> [<prd2> ...] [--parallel] [--max-parallel N]

  • One or more PRD paths (relative to repo root, e.g. docs/prd/prd_foo.md)
  • --parallel — dispatch all PRDs concurrently (caps at --max-parallel if set)
  • --max-parallel N — limit concurrent jobs (default: unbounded if --parallel, else 1)
  • Default: sequential (one PRD at a time, in arg order)

Pre-flight (fail fast before any worktree creation)

  1. Resolve each PRD path. If any file is missing, print MISSING: <path> for each and stop. Do not create any worktrees.
  2. Check git -C <primary-repo> status --porcelain is clean (ignore the ads_metadata_by_year_picard symlink and any .claude/prd-build* line). If dirty, refuse with: "primary repo has uncommitted changes; commit or stash before running /prd-queue."
  3. Verify scripts/prd_queue_lifecycle.sh exists and is executable.
  4. Verify claude is on PATH (which claude succeeds).
  5. Print the queue plan (PRD list + mode + max_parallel) before starting.

Per-PRD lifecycle

For each PRD (in order for sequential; all-at-once-up-to-N for parallel):

1. Setup

scripts/prd_queue_lifecycle.sh setup <prd-path>

Captures stdout: <slug>\t<worktree_path>\t<branch_name>. Parse into variables. Save to your in-skill state table.

2. Dispatch (background bash)

Use the Bash tool with run_in_background=true:

cd <worktree_path> && \
  claude -p "/prd-build <prd-path>" \
  > /tmp/prd-queue-<slug>.log 2>&1

Read the full file on GitHub · 113 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 · 113 lines · 39 tokens per session scan A b309f8499c56

Subscribe to this mod's changes

prd-queue is a skill published in the GitHub repository sjarmak/agent-workflows (9 stars, last pushed 1mo ago), licensed MIT. It adds 39 tokens to every session and 1,744 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-31.