workflow-authoring
Qué hace
Es una referencia para escribir el script de un flujo de trabajo, que cubre pasos en paralelo y en secuencia, comprobaciones y reanudación. Es para personas que construyen flujos reutilizables de agentes para trabajos grandes, como migraciones o auditorías.
Cuándo usarla
- ✓Cuando escribes un script para un flujo de trabajo que reparte el trabajo entre varios agentes.
- ✓Cuando un trabajo grande, como una migración o una auditoría, necesita pasos paralelos y comprobaciones.
- ✓Cuando necesitas elegir entre ejecutar los pasos en paralelo o en secuencia.
Link de la skill
https://github.com/QwenLM/qwen-code/blob/main/packages/core/src/skills/bundled/workflow-authoring/SKILL.mdCópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.
Cómo usar
La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.
Mensaje listo para pegar
Para Claude Code, Codex o Cursor: ejecútalo en la carpeta del proyecto y la skill queda instalada.
Descarga el SKILL.md y ponlo en la carpeta de skills de tu agente.
Ejemplo de qué pedirle a la IA
“Ayúdame a escribir un script de flujo de trabajo que audite cada módulo de este repositorio en paralelo y después combine los hallazgos.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
La referencia explica cómo estructurar el script, cuándo repartir el trabajo, cómo verificar los resultados y cómo combinarlos. No inicia ninguna ejecución por sí misma.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
Workflow authoring reference
Everything below is about writing the script. Whether a workflow may run at all is decided by the Workflow tool's own opt-in rule — this reference does not authorize a run.
Reach for one to be comprehensive (decompose the work and cover every part in parallel), to be confident (independent perspectives and adversarial checks before an answer is committed to), or to take on scale a single context cannot hold — migrations, audits, broad sweeps. The script is where that structure is encoded: what fans out, what verifies, what synthesizes. Parallelism on its own is not a reason; work that is already one short sequence of edits belongs in the main loop.
Scout first, then orchestrate
The strongest pattern is hybrid: discover the work list in the main loop (list the files, scope the diff, read the failing test), then hand that list to a workflow. You do not need to know the shape of the work before the task — only before the orchestration step. When the work has distinct phases, run several small workflows across turns and read each result before choosing the next, rather than authoring one large script that runs unattended.
Common single-phase shapes: understand (parallel readers over subsystems,
merged into one map), design (independent approaches, judged, then
synthesized), review (dimensions, find, verify each finding), research (broad
sweep, deep read, synthesis), migrate (discover sites, transform each under
isolation: 'worktree', verify).
Script contract
The source is wrapped as an async IIFE, so top-level await and a top-level
return are both legal — and a trailing expression is not a return value.
End every successful path with an explicit return.
It is plain JavaScript, not TypeScript, and it cannot import anything. A
script with a dynamic import() anywhere in it — even in a branch that never
runs — is refused before it starts, so none of its agents runs first; do file,
network, and package work inside an agent instead.
The script may start with a literal export const meta = {...} declaration
with name, description, and optionally whenToUse and
phases: [{ title, detail? }]. It must be a pure literal — no variables,
calls, or interpolation — and it is stripped before execution, so nothing in
the script body can read it. Fields outside that list are dropped. The
approval dialog prints the name, the description, and each phase title with
its detail as a one-line explanation beside it: give every phase a detail,
because for a run that may dispatch hundreds of agents it is what the user
reads before approving. In a workflow an extension ships, whenToUse also lists
the workflow for the model to start when a request matches it; leave it out and
the workflow runs only when someone asks for it by name.
Injected globals, and nothing else:
phase(title)— open a phase. Everything dispatched afterwards is attributed to it in the live phase tree, until the next phase opens.log(msg)— one line into the run log the user watches.agent(prompt, opts?)— dispatch one subagent. See agent() options.parallel(thunks)— run thunks through the shared concurrency window, resolving to a position-aligned array.parallel()itself rejects on invalid arguments.pipeline(items, ...stages)— run each item through the stages independently. See Default topipeline().workflow(nameOrRef, args?, { stepId }?)— run a saved workflow inline. See Saved workflows and workflow().args— the structured value the caller passed, orundefined.budget—{ total, spent(), remaining() }. See Scaling to the token budget.
Pass THUNKS to parallel(), not eager calls: parallel([() => agent(...)]),
not parallel([agent(...)]). The eager form is refused outright: a
non-function element rejects the whole batch, and by then every agent() in it
has already been admitted, counted against the caps, and spent — with its
result discarded.
Each list a single call takes — the thunks of parallel(), and the items and
the stages of pipeline() — holds at most 4096 entries. A longer list rejects
the whole call before any of its thunks or stages runs; it is never truncated.
Like any invalid argument, that rejection can be caught, and inside an outer
parallel()/pipeline() it becomes that slot's null. The limit is per call,
not per run: split a larger input into batches of thunks and await each in
turn. Batching does not
Preguntas frecuentes
¿Leer esto inicia un flujo de trabajo?
No. Explica cómo escribir el script, y una ejecución sigue necesitando tu aprobación.
¿Cuándo no debo usar un flujo de trabajo?
Cuando el trabajo es una secuencia corta de ediciones, pertenece al bucle normal.
¿Puedo ejecutar el trabajo por fases?
Sí. La referencia sugiere ejecutar flujos pequeños en varios turnos y leer cada resultado antes del siguiente.
Detalles
Descripción original del autor
Reference for writing a Workflow tool script (script API and gotchas, agent() options, pipeline() vs parallel(), verification and convergence patterns, resume, worked example). Load before authoring a script for a workflow the user already opted into; it does not itself authorize running one.
repo: QwenLM/qwen-code
Popularidad
- Estrellas en GitHub
- 29 mil
- Posición en el ranking
- #9788
- Licencia
- Apache-2.0
- Actualizada
- 2/11/2026
Comentarios
- …
Más skills de este repositorio
codegraph
29 milAyuda a tu agente a analizar una base de código indexada mediante su grafo de llamadas, dependencias, código muerto, puntos críticos y búsqueda semántica.
qwen-code-claw
29 milAyuda a tu agente a delegar tareas de código a Qwen Code, como entender una base de código, corregir errores, refactorizar o generar un proyecto nuevo.
structured-debugging
29 milEnseña a tu agente a depurar errores difíciles paso a paso: plantear una hipótesis, hacer comprobaciones puntuales y encontrar la causa real antes de corregir.
tmux-real-user-testing
29 milAyuda a tu agente a probar una app de terminal como un usuario real dentro de tmux, guardando un registro legible con una captura de cada acción.
Skills parecidas
add-model-provider
394 milPermite que tu agente conecte un nuevo proveedor de modelos de IA a OpenClaw con comandos de configuración seguros, mantenga las claves API fuera del texto plano y haga una prueba en vivo.
acp-router
394 milAyuda a tu agente a enviar una tarea a un asistente de programación como Claude Code o Cursor a través de OpenClaw, para que el trabajo se ejecute en esa herramienta.
browser-automation
394 milEnseña a tu agente a controlar páginas web paso a paso, incluidos los inicios de sesión, las pestañas y la recuperación cuando una página deja de responder.