[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6CCNSA684PA7S3NSET4022S":3,"skill-same:01M6CCNSA684PA7S3NSET4022S":69},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":23,"publishedAt":42,"linkOnly":43,"markdownContent":44,"markdownBody":45,"frontMatter":46,"refName":47,"commitSha":48,"skillDirectory":49,"forksCount":50,"repositoryHtmlUrl":51,"repositoryHomepageUrl":52,"ownerHtmlUrl":53,"ownerBlogUrl":52,"ownerDescription":6,"updatedAt":54,"install":55,"resources":68},"01M6CCNSA684PA7S3NSET4022S","run-workflow",null,"Orchestrate parallel subagent pipelines from a JavaScript workflow script. Fan out work across many items (tickers, filings, findings) then synthesize, or run a saved workflow by name. Unlocks the RunWorkflow tool.","ginlix-ai\u002FLangAlpha","ginlix-ai","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F255505137?v=4","01M6CCJK39A1C27GHF9AP4XWY0","Ginlix AI","01M6CCJK7GR7P1AWNRTPZYDJZY",2303,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Fplugins\u002Flangalpha_service\u002Fskills\u002Frun-workflow\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41],"workflow","run","run workflow","by name","fan out","saved","script","filings","name","across","synthesize","pipelines","work","parallel","tool","subagent","orchestrate","javascript","2026-11-10 10:12:30",false,"---\nname: run-workflow\ndescription: Orchestrate parallel subagent pipelines from a JavaScript workflow script. Fan out work across many items (tickers, filings, findings) then synthesize, or run a saved workflow by name. Unlocks the RunWorkflow tool.\n---\n\n# Programmatic Workflows (RunWorkflow)\n\nUse `RunWorkflow` when a deterministic pipeline should orchestrate multiple subagents — fan-out research then synthesize, classify then act per item, generate then verify. Prefer it over issuing many `Task` calls yourself when the dispatches are data-driven (one per ticker, per filing, per finding). Do NOT use it for a single subagent (use `Task`) or for code that dispatches nothing (use `ExecuteCode`).\n\n## The script\n\nYou write JavaScript (ES2020). It executes server-side: the script itself cannot touch the workspace filesystem — the subagents it dispatches can. The script must declare a pure object literal first:\n\n```js\nexport const meta = { name: 'ticker-briefs', description: 'Fan out research, synthesize' }\n```\n\n`name` (letters, digits, `-`, `_`) and `description` are required; no variables or function calls inside the literal. The rest of the body is free-form async JS — top-level `await` and `return` both work, and the `return` value (JSON-serializable) becomes the run result. Return a synthesis rather than the raw children: a large result is clipped for display, and a clipped object is unparseable.\n\n## Built-ins\n\n- `await agent(prompt, opts?)` — dispatch one subagent, resolve to its result text. The child starts blank: it sees nothing of this conversation, of the script, or of its sibling children, so the prompt must carry everything it needs — and its final text is the whole of what comes back. `opts`: `agentType` (default `'general-purpose'`; same types as `Task`), `label` (display name), `phase` (progress group), `schema` (JSON Schema — the child answers as matching JSON and the resolved value is the **parsed object**, or `null` if it cannot).\n- `await pipeline(items, ...stages)` — **the default for multi-stage work.** Each item flows through every stage independently, with NO barrier between stages: item A can be in stage 3 while item B is still in stage 1, so the run costs the slowest single chain rather than the sum of each stage's slowest item. Each stage receives `(prevResult, originalItem, index)`; a throwing stage nulls that item and skips its remaining stages.\n- `await parallel(thunks)` — run an array of `() => Promise` thunks concurrently, resolving to results in order; already-started promises (`parallel([agent(...), ...])`) work too. Use it for a single fan-out, or where the next step genuinely needs the whole set at once — dedup across all results, an early exit when the count is zero, one child weighing the others. Needing to `map`\u002F`filter` between stages is not such a case: do that inside a pipeline stage.\n- `phase(title)` \u002F `log(message)` — progress markers streamed live to the user.\n- `args` — the `params` value passed to `RunWorkflow`, verbatim.\n\nFailure semantics:\n\n- A failed slot resolves to **`null`** — the child errored, timed out, or the run had already spent its dispatch cap. Read `null` as \"no result from this call\", never as \"the child ran and found nothing\": a run whose children all return `null` has produced nothing, so check before reporting success and write the synthesis to survive partial results.\n- A call your script got wrong — unknown `agentType`, an oversized prompt or schema — is a bug rather than a failure, and so is an ordinary typo or a wrong shape handed to a helper. Those end the run with the real error, in a `parallel` slot or a `pipeline` stage too, instead of leaving you a silent list of nulls to explain.\n\nLimits (defaults): 64 dispatches per run, 8 running at once — extra `agent()` calls queue, so fan out freely — and 30 minutes per child.\n\n## Examples\n\nSingle fan-out — one dispatch per item, synthesized in JS:\n\n```js\nexport const meta = { name: 'ticker-briefs', description: 'Research each ticker, then synthesize' }\n\nphase('Research')\nconst briefSchema = {\n  type: 'object',\n  properties: { summary: { type: 'string' }, risks: { type: 'array', items: { type: 'string' } } },\n  required: ['summary'],\n}\nconst results = await parallel(args.tickers.map((t) => () =>\n  agent(`Research ${t}: fundamentals, recent news, key risks.`, { agentType: 'research', label: t, schema: briefSchema })))\n\nphase('Synthesize')\nconst briefs = {}\nconst failed = []\nresults.forEach((r, i) => { if (r !== null) briefs[args.tickers[i]] = r; else failed.push(args.tickers[i]) })\nlog(`${Object.keys(briefs).length} briefs, ${failed.length} failed`)\nreturn { briefs, failed }\n```\n\nTwo stages per item, no barrier — a slow filing never holds up the others:\n\n```js\nexport const meta = { name: 'filing-risk-sweep', description: 'Summarize each filing, then stress-test it' }\n\nconst reviewed = await pipeline(\n  args.tickers,\n  (ticker) => agent(`Summarize ${ticker}'s latest 10-Q: segment results, guidance changes, new risk language.`,\n    { agentType: 'research', label: ticker, phase: 'Read' }),\n  (summary, ticker) => summary === null ? null : agent(\n    `Challenge this ${ticker} summary — what does it overstate, omit, or take on trust?\\n\\n${summary}`,\n    { agentType: 'equity-analyst', label: `${ticker} review`, phase: 'Challenge' }),\n)\n\nlog(`${reviewed.filter((r) => r !== null).length}\u002F${args.tickers.length} reviewed`)\nreturn Object.fromEntries(args.tickers.map((t, i) => [t, reviewed[i]]))\n```\n\nSet `phase` per dispatch rather than calling `phase()` inside a stage: items run concurrently, so a global marker set mid-pipeline reflects whichever item reached it last. Guard each stage on its input, and test against `null` rather than truthiness — `0`, `false` and `\"\"` are answers a child succeeded with, and `summary && agent(...)` would drop them as failures.\n\n## Saved workflows\n\n- Workflows live at `.agents\u002Fworkflows\u002F\u003Cname>.js` — the file is the whole script, `meta` included, and `meta.name` must equal `\u003Cname>`. List what is already there with `ls .agents\u002Fworkflows\u002F`; run one with `RunWorkflow(workflow=\"\u003Cname>\", params={...})`.\n- Write `.agents\u002Fworkflows\u002F\u003Cname>.js` to save a workflow you expect to run again; it stays available across threads.\n\n## Running\n\n`RunWorkflow(script=..., params={...})` (or `script_path=...`, or `workflow=\"\u003Cname>\"`) returns a task id immediately and runs in the background. You are notified when the run finishes. Each dispatched child is a real background task: drill into a truncated result with `TaskOutput(task_id=\"\u003Cchild task_id>\")`. Run artifacts (per-child records, `result.json`) land under `.agents\u002Fthreads\u002F\u003Cthread>\u002Fworkflows\u002F\u003Crun-id>\u002F`.\n","# Programmatic Workflows (RunWorkflow)\n\nUse `RunWorkflow` when a deterministic pipeline should orchestrate multiple subagents — fan-out research then synthesize, classify then act per item, generate then verify. Prefer it over issuing many `Task` calls yourself when the dispatches are data-driven (one per ticker, per filing, per finding). Do NOT use it for a single subagent (use `Task`) or for code that dispatches nothing (use `ExecuteCode`).\n\n## The script\n\nYou write JavaScript (ES2020). It executes server-side: the script itself cannot touch the workspace filesystem — the subagents it dispatches can. The script must declare a pure object literal first:\n\n```js\nexport const meta = { name: 'ticker-briefs', description: 'Fan out research, synthesize' }\n```\n\n`name` (letters, digits, `-`, `_`) and `description` are required; no variables or function calls inside the literal. The rest of the body is free-form async JS — top-level `await` and `return` both work, and the `return` value (JSON-serializable) becomes the run result. Return a synthesis rather than the raw children: a large result is clipped for display, and a clipped object is unparseable.\n\n## Built-ins\n\n- `await agent(prompt, opts?)` — dispatch one subagent, resolve to its result text. The child starts blank: it sees nothing of this conversation, of the script, or of its sibling children, so the prompt must carry everything it needs — and its final text is the whole of what comes back. `opts`: `agentType` (default `'general-purpose'`; same types as `Task`), `label` (display name), `phase` (progress group), `schema` (JSON Schema — the child answers as matching JSON and the resolved value is the **parsed object**, or `null` if it cannot).\n- `await pipeline(items, ...stages)` — **the default for multi-stage work.** Each item flows through every stage independently, with NO barrier between stages: item A can be in stage 3 while item B is still in stage 1, so the run costs the slowest single chain rather than the sum of each stage's slowest item. Each stage receives `(prevResult, originalItem, index)`; a throwing stage nulls that item and skips its remaining stages.\n- `await parallel(thunks)` — run an array of `() => Promise` thunks concurrently, resolving to results in order; already-started promises (`parallel([agent(...), ...])`) work too. Use it for a single fan-out, or where the next step genuinely needs the whole set at once — dedup across all results, an early exit when the count is zero, one child weighing the others. Needing to `map`\u002F`filter` between stages is not such a case: do that inside a pipeline stage.\n- `phase(title)` \u002F `log(message)` — progress markers streamed live to the user.\n- `args` — the `params` value passed to `RunWorkflow`, verbatim.\n\nFailure semantics:\n\n- A failed slot resolves to **`null`** — the child errored, timed out, or the run had already spent its dispatch cap. Read `null` as \"no result from this call\", never as \"the child ran and found nothing\": a run whose children all return `null` has produced nothing, so check before reporting success and write the synthesis to survive partial results.\n- A call your script got wrong — unknown `agentType`, an oversized prompt or schema — is a bug rather than a failure, and so is an ordinary typo or a wrong shape handed to a helper. Those end the run with the real error, in a `parallel` slot or a `pipeline` stage too, instead of leaving you a silent list of nulls to explain.\n\nLimits (defaults): 64 dispatches per run, 8 running at once — extra `agent()` calls queue, so fan out freely — and 30 minutes per child.\n\n## Examples\n\nSingle fan-out — one dispatch per item, synthesized in JS:\n\n```js\nexport const meta = { name: 'ticker-briefs', description: 'Research each ticker, then synthesize' }\n\nphase('Research')\nconst briefSchema = {\n  type: 'object',\n  properties: { summary: { type: 'string' }, risks: { type: 'array', items: { type: 'string' } } },\n  required: ['summary'],\n}\nconst results = await parallel(args.tickers.map((t) => () =>\n  agent(`Research ${t}: fundamentals, recent news, key risks.`, { agentType: 'research', label: t, schema: briefSchema })))\n\nphase('Synthesize')\nconst briefs = {}\nconst failed = []\nresults.forEach((r, i) => { if (r !== null) briefs[args.tickers[i]] = r; else failed.push(args.tickers[i]) })\nlog(`${Object.keys(briefs).length} briefs, ${failed.length} failed`)\nreturn { briefs, failed }\n```\n\nTwo stages per item, no barrier — a slow filing never holds up the others:\n\n```js\nexport const meta = { name: 'filing-risk-sweep', description: 'Summarize each filing, then stress-test it' }\n\nconst reviewed = await pipeline(\n  args.tickers,\n  (ticker) => agent(`Summarize ${ticker}'s latest 10-Q: segment results, guidance changes, new risk language.`,\n    { agentType: 'research', label: ticker, phase: 'Read' }),\n  (summary, ticker) => summary === null ? null : agent(\n    `Challenge this ${ticker} summary — what does it overstate, omit, or take on trust?\\n\\n${summary}`,\n    { agentType: 'equity-analyst', label: `${ticker} review`, phase: 'Challenge' }),\n)\n\nlog(`${reviewed.filter((r) => r !== null).length}\u002F${args.tickers.length} reviewed`)\nreturn Object.fromEntries(args.tickers.map((t, i) => [t, reviewed[i]]))\n```\n\nSet `phase` per dispatch rather than calling `phase()` inside a stage: items run concurrently, so a global marker set mid-pipeline reflects whichever item reached it last. Guard each stage on its input, and test against `null` rather than truthiness — `0`, `false` and `\"\"` are answers a child succeeded with, and `summary && agent(...)` would drop them as failures.\n\n## Saved workflows\n\n- Workflows live at `.agents\u002Fworkflows\u002F\u003Cname>.js` — the file is the whole script, `meta` included, and `meta.name` must equal `\u003Cname>`. List what is already there with `ls .agents\u002Fworkflows\u002F`; run one with `RunWorkflow(workflow=\"\u003Cname>\", params={...})`.\n- Write `.agents\u002Fworkflows\u002F\u003Cname>.js` to save a workflow you expect to run again; it stays available across threads.\n\n## Running\n\n`RunWorkflow(script=..., params={...})` (or `script_path=...`, or `workflow=\"\u003Cname>\"`) returns a task id immediately and runs in the background. You are notified when the run finishes. Each dispatched child is a real background task: drill into a truncated result with `TaskOutput(task_id=\"\u003Cchild task_id>\")`. Run artifacts (per-child records, `result.json`) land under `.agents\u002Fthreads\u002F\u003Cthread>\u002Fworkflows\u002F\u003Crun-id>\u002F`.\n",{"name":5,"description":7},"main","f5d250aa1bedbf685a23b5220f50f9192f76289a","plugins\u002Flangalpha_service\u002Fskills\u002Frun-workflow",387,"https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha","https:\u002F\u002Flangalpha.ai","https:\u002F\u002Fgithub.com\u002Fginlix-ai","2026-11-15 02:14:56",{"source":8,"skillName":5,"commands":56,"prompt":66,"zipAvailable":67},[57,60,63],{"tool":58,"command":59},"npx","npx skills add ginlix-ai\u002FLangAlpha --skill run-workflow",{"tool":61,"command":62},"bunx","bunx skills add ginlix-ai\u002FLangAlpha --skill run-workflow",{"tool":64,"command":65},"pnpm","pnpm dlx skills add ginlix-ai\u002FLangAlpha --skill run-workflow","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Fplugins\u002Flangalpha_service\u002Fskills\u002Frun-workflow\u002FSKILL.md",true,[],[70,78,91,100,108,118],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":76,"publishedAt":77},"01M743D4A5JN1KT6ZFH64N893X","dashboard-page","The user's own LangAlpha Dashboard: build or change the page they see when they open LangAlpha, with live market data and custom data refreshed on a schedule","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Fplugins\u002Flangalpha_deliverables\u002Fskills\u002Fdashboard-page\u002FSKILL.md",[],[],"2026-11-11 15:11:14",{"skillNo":79,"name":80,"nameZh":6,"description":81,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":82,"categories":83,"keywords":85,"publishedAt":42},"01M6CCP2R7FYQ1DHW1D59NR7CR","fx-notes","Fixture skill fx-notes","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fplugins\u002Fvalid-full\u002Fskills\u002Ffx-notes\u002FSKILL.md",[84],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[86,87,88,89,90],"fx","fx notes","notes","fixture skill","fixture",{"skillNo":92,"name":93,"nameZh":6,"description":94,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":95,"categories":96,"keywords":98,"publishedAt":42},"01M6CCP16MF4A5J06320JAV03Z","good","Fixture skill good","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fplugins\u002Fskill-defects\u002Fskills\u002Fgood\u002FSKILL.md",[97],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[93,99,89,90],"skill good",{"skillNo":101,"name":102,"nameZh":6,"description":103,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":104,"categories":105,"keywords":107,"publishedAt":42},"01M6CCNZAYQT0RT73XFTFPTJC0","survivor","Fixture skill survivor","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fplugins\u002Fmcp-doc-invalid\u002Fskills\u002Fsurvivor\u002FSKILL.md",[106],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[102,89,90],{"skillNo":109,"name":110,"nameZh":6,"description":111,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":112,"categories":113,"keywords":114,"publishedAt":42},"01M6CCNX73ZH4DY2W1K0CH5BNP","alpha-notes","Notes on alpha things.","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fplugins\u002Fmarketplace-mixed\u002Fplugins\u002Falpha\u002Fskills\u002Falpha-notes\u002FSKILL.md",[],[115,116,88,117],"alpha","alpha notes","things",{"skillNo":119,"name":120,"nameZh":6,"description":121,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":122,"categories":123,"keywords":124,"publishedAt":42},"01M6CCNVK5ZV4CZ2T0M6SH8QB9","cli-tips","Tips for the command line.","https:\u002F\u002Fgithub.com\u002Fginlix-ai\u002FLangAlpha\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fplugins\u002Fdialect-cursor\u002Fskills\u002Fcli-tips\u002FSKILL.md",[],[125,126,127,128,129,130,131],"cli tips","tips","cli","line","for","command line","command"]