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.
npx skills add wan-huiyan/agent-traffic-control --skill flatten-workflow-parallel-arrays-before-collectinggit clone --depth 1 https://github.com/wan-huiyan/agent-traffic-controlWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/wan-huiyan/agent-traffic-control/flatten-workflow-parallel-arrays-before-collecting)<a href="https://agentmods.dev/skills/wan-huiyan/agent-traffic-control/flatten-workflow-parallel-arrays-before-collecting"><img src="https://agentmods.dev/badge/skills/wan-huiyan/agent-traffic-control/flatten-workflow-parallel-arrays-before-collecting/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/wan-huiyan/agent-traffic-control/flatten-workflow-parallel-arrays-before-collecting"><img src="https://agentmods.dev/badge/skills/wan-huiyan/agent-traffic-control/flatten-workflow-parallel-arrays-before-collecting.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00216 | $0.01271 |
| Opus 5 | $0.00108 | $0.00635 |
| Sonnet 5 | $0.00043 | $0.00254 |
| Haiku 4.5 | $0.00022 | $0.00127 |
Grade A, and why
flatten-workflow-parallel-arrays-before-collecting 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 11d 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.
How it starts
The opening of the file, as written. The whole thing — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Workflow pipeline(): a stage returning parallel() is a bare array the collector silently drops
Problem
In the Claude Code Workflow tool, pipeline(items, stage1, stage2, …) runs each item
through the stages. A common fan-out-then-verify shape makes stage-2 return different
shapes per item:
const per = await pipeline(DIMENSIONS,
d => agent(findPrompt, {schema: FINDINGS}), // stage 1
(findings, d) => {
if (!findings.confirmed.length)
return { dimension: d.key, verified: [] }; // OBJECT shape (no findings)
return parallel(findings.confirmed.map(f => () => // BARE ARRAY shape (has findings)
agent(verifyPrompt(f), {schema: VERDICT}).then(v => ({...f, verdict: v}))));
});
per[i] is now an object {verified: […]} for dimensions that found nothing, but a
bare array [{…verdict…}, …] for dimensions that DID find candidates (because
parallel() resolves to an array). A collector written for only the object shape:
const all = per.flatMap(p => Array.isArray(p?.verified) ? p.verified : []); // BUG
evaluates Array.isArray(undefined) → false for every array-shaped element → returns []
→ silently drops all verdicts from exactly the dimensions that found bypasses. The
workflow returns confirmed: 0, refuted: 0 — a false "all clear." The real tell:
agentCount is high and the journal shows verify/v2: agents both started AND
result-ed, yet confirmed_count + refuted_count == 0 (verify agents only spawn for
candidates, so candidates existed).
Context / Trigger Conditions
- A
Workflowscript usingpipeline()where a later stage conditionally returnsparallel(...)(adversarial-verify / review / loop-until-dry patterns). - The workflow result is "0 confirmed / 0 refuted" or "0 findings" — suspiciously clean.
- The completion summary's
agentCount(or the journal under…/subagents/workflows/wf_*/journal.jsonl) shows verify agents ran, contradicting "0".
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.
- 11d ago First seen · 97 lines · 216 tokens per session scan A cebd7d83c252
flatten-workflow-parallel-arrays-before-collecting is a skill published in the GitHub repository wan-huiyan/agent-traffic-control (3 stars, last pushed 6d ago), licensed MIT. It adds 216 tokens to every session and 1,271 once invoked, about $0.0011 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.
Other skills, from other repositories
codex-coplan
Bring in an external model (Codex) to co-develop a plan — both models draft independently, align on disagreements, and merge into one plan. Load this only when the user explicitly names Codex (e.g. "let's discuss this with Codex," "what does Codex think about this approach") — don't auto-trigger just because a plan…
codex-orchestrator
Delegate execution tasks to Codex (Claude plans and reviews). Load this only when the user names Codex explicitly — no matter how big the task is, if the user hasn't mentioned Codex, do it yourself.
good-bad-ugly
Use when the user asks to "orchestrate", "conduct", invoke "good bad ugly" / "gbu", or tackle a large multi-part coding task (audits, refactor sweeps, multi-feature sessions, "clean this up and fix everything") — anything too big for one linear pass. Runs the tiered orchestration workflow: The Good (brain) plans and…
orchestrate
Use only when the user explicitly types /orchestrate:orchestrate to decompose a large task, spawn a tree of parallel worker/subplanner/verifier subagents, and collect structured handoffs. Do not invoke autonomously.
api-testing
HTTP API testing for TypeScript (Supertest) and Python (httpx, pytest). Test REST APIs, GraphQL, request/response validation, authentication, and error handling.
bun-test-coverage
Use for test coverage with Bun, --coverage flag, lcov reports, thresholds, and CI integration.