Agent skill · posthog

dynamic-workflows

Designs and runs task-specific JavaScript harnesses with the `workflow` tool. Use for broad, long-running, highly structured, or adversarial work that benefits from many isolated agents: exhaustive audits, root-cause investigations, research, large triage queues, competing proposals, repeated verification, and independent changes across disjoint files. Covers decomposition patterns, agent and model routing, structured handoffs, failure handling, and the workflow runtime API.

What it needs

About 9k tokens when loaded.

What this skill does

Dynamic workflows The workflow tool runs a JavaScript program that coordinates isolated subagents. Use the program as a task-specific harness: JavaScript owns iteration, routing, barriers, and completion checks, while each agent() call handles one focused unit of work in a fresh context window. Only the script's return value enters the parent context. Intermediate results stay inside the workflow, while structured progress and logs remain visible in the tool call. End broad workflows with a compact synthesis instead of returning every worker transcript. This separation is useful when one long conversation would make it hard to remain complete, impartial, or faithful to the original goal. It is not a default for ordinary work. More agents mean more latency and token use. Decide whether a workflow earns its cost Use a workflow when at least one of these is true: Breadth: the task covers many independent files, records, systems, claims, or alternatives. Structure: the work needs explicit stages, routing, aggregation, or a completion condition. Independent judgment: a result should be challenged by an agent that did not produce it. Competing approaches: several agents should attempt the same problem before a separate judge chooses. Unknown work size: the task should repeat until no unresolved items or new findings remain. Context isolation: each unit benefits from a clean context that contains only its evidence and rubric. Good requests include: Audit every ingestion stage for one invariant, then verify each reported violation. Form independent explanations for a production symptom and try to disprove each one. Generate several migration plans, compare their risks, and return one tested recommendation. Classify a large issue backlog, deduplicate related reports, and prepare actions for confirmed groups. Check every factual statement in a technical report against primary evidence. Apply the same independent change across disjoint packages, then review the combined diff. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills posthog/dynamic-workflows--000c4d

View the source on GitHub

Browse the @skills marketplace