[{"data":1,"prerenderedAt":494},["ShallowReactive",2],{"page-\u002Fworkflows\u002Fai-generation":3,"all-pages":163},{"id":4,"title":5,"body":6,"description":153,"extension":154,"meta":155,"navigation":156,"path":157,"robots":158,"seo":159,"sitemap":160,"stem":161,"__hash__":162},"content\u002F01.workflows\u002F13.ai-generation.md","Generate with AI",{"type":7,"value":8,"toc":146},"minimark",[9,17,20,36,39,42,47,74,78,81,91,94],[10,11,12,13,16],"p",{},"The workflow editor's ",[14,15,5],"strong",{}," panel drafts a workflow from a plain\ndescription and suggests any dataset schemas the workflow needs. Nothing is\nsaved, created, or executed until you review the draft and choose to insert it.",[10,18,19],{},"The panel has two modes:",[21,22,23,30],"ul",{},[24,25,26,29],"li",{},[14,27,28],{},"Assistant"," — a conversation. It can list existing datasets, propose a\ndataset schema for approval, and regenerate the workflow after you edit the\nproposal. Dataset and project creation always stop at an approval card.",[24,31,32,35],{},[14,33,34],{},"One-shot generation"," — a single prompt that returns a draft plus suggested\ndataset schemas.",[10,37,38],{},"Both modes produce the same validated workflow. The generated source is compiled\nand checked, so a draft that cannot compile is repaired or reported instead of\nbeing inserted.",[10,40,41],{},"The assistant can also design a dataset from a workflow you already have: ask\nsomething like \"create the dataset table this workflow writes\". It reads the\ncurrent editor buffer, derives the columns from the workflow's dataset and\nagent steps, and opens the usual schema approval card. Approving creates only\nthe dataset; the workflow is left untouched.",[43,44,46],"h2",{"id":45},"before-you-start","Before you start",[21,48,49,52,60],{},[24,50,51],{},"AI must be configured on the server (otherwise the panel says it is not\navailable).",[24,53,54,55,59],{},"Agent steps need a provider key enabled for the project. If none is enabled\nyet, the generator uses the explicit ",[56,57,58],"code",{},"provider.key(\"bountyhub\u002Fnot-configured\")","\nplaceholder; enable a provider before running the workflow.",[24,61,62,63,68,69,73],{},"Refer to project modules and configuration by their real names. Read\n",[64,65,67],"a",{"href":66},"\u002Fworkflows\u002Fconfig","config"," and ",[64,70,72],{"href":71},"\u002Fworkflows\u002Fmodules","modules"," for the shapes\nthe generator understands.",[43,75,77],{"id":76},"example-prompt","Example prompt",[10,79,80],{},"This prompt exercises activities, artifacts, datasets, and an agent output\ncontract, and reliably produces a workflow the compiler accepts. Paste it as-is\n(adjust the target), or use it as a template for your own requests.",[82,83,89],"pre",{"className":84,"code":86,"language":87,"meta":88},[85],"language-text","Build a daily reconnaissance workflow for example.com.\n\nUse three activities:\n\n1. discover\n- Trigger: trigger.cron(\"0 2 * * *\")\n- Run the bountyhub\u002Fsubfinder module against the target.\n- Store each discovered subdomain in the dataset \"subdomains\" with these columns:\n  - subdomain (text)\n  - source (text, literal \"subfinder\")\n- Upload the subdomain list as artifact \"subdomains\".\n\n2. probe\n- Trigger: trigger.on(discover.succeeded())\n- Download the \"subdomains\" artifact.\n- Run the bountyhub\u002Fhttpx module on it.\n- Store each live service in the dataset \"live-hosts\" with these columns:\n  - host (text)\n  - status_code (integer)\n  - title (text)\n- Upload the live-host list as artifact \"live\".\n\n3. triage\n- Trigger: trigger.on(probe.succeeded())\n- Download the \"live\" artifact.\n- Run a step.agent that reviews the live hosts and identifies admin, dev, staging and login surfaces.\n- The agent must write JSONL with exactly these fields: host, reason, confidence.\n- Store the agent output in the dataset \"triage-results\" with these columns:\n  - host (text)\n  - reason (text)\n  - confidence (text)\n- If the project has no provider key configured yet, use provider.key(\"bountyhub\u002Fnot-configured\") as the placeholder.\n\nIf any of those datasets do not exist, return them in suggested_datasets with exactly those columns.\nDo not invent dataset tables or columns.\nDo not use run.timestamp or any other invented run attribute; if a timestamp is required, omit it.\nUse one activity per tool and pass data between activities only with artifacts.\n","text","",[56,90,86],{"__ignoreMap":88},[10,92,93],{},"Why it works:",[21,95,96,107,113,119,136],{},[24,97,98,101,102,106],{},[14,99,100],{},"One activity per tool."," Each stage names a single tool and its own trigger,\nmatching the shape in ",[64,103,105],{"href":104},"\u002Fworkflows\u002Fsteps","Steps"," instead of one large activity.",[24,108,109,112],{},[14,110,111],{},"Artifacts are the only hand-off."," Each producer uploads and each consumer\ndownloads the same artifact name; no activity reads another one's workspace.",[24,114,115,118],{},[14,116,117],{},"Datasets are fully specified."," Table names, column names, kinds, and the\nliteral source value leave nothing to invent. A missing dataset is returned as\na schema proposal, not a broken reference.",[24,120,121,124,125,128,129,128,132,135],{},[14,122,123],{},"The agent output is a contract."," ",[56,126,127],{},"host",", ",[56,130,131],{},"reason",[56,133,134],{},"confidence"," as JSONL\nmatches the dataset columns one-to-one.",[24,137,138,141,142,145],{},[14,139,140],{},"Forbidden shortcuts are named."," Banning ",[56,143,144],{},"run.timestamp"," and invented\ncolumns removes the two most common repair loops.",{"title":88,"searchDepth":147,"depth":148,"links":149},5,4,[150,152],{"id":45,"depth":151,"text":46},2,{"id":76,"depth":151,"text":77},"Use the editor's AI assistant or one-shot generator, and start from an example prompt that reliably produces a valid workflow.","md",{},true,"\u002Fworkflows\u002Fai-generation",null,{"title":5,"description":153},{"loc":157},"01.workflows\u002F13.ai-generation","MqathIQms5N5EJ1gahRij_sJLMQKcZIjUJ9uomuiH6k",[164,220,236,255,290,306,318,329,340,351,375,394,414,425,436],{"title":165,"path":166,"stem":167,"children":168},"Workflows","\u002Fworkflows","01.workflows",[169,171,175,179,183,185,189,193,197,201,204,208,212,215,219],{"title":165,"path":166,"stem":170},"01.workflows\u002Findex",{"title":172,"path":173,"stem":174},"Workflow Quick Reference","\u002Fworkflows\u002Fquick-reference","01.workflows\u002F00.quick-reference",{"title":176,"path":177,"stem":178},"Workflows Overview","\u002Fworkflows\u002Foverview","01.workflows\u002F01.overview",{"title":180,"path":181,"stem":182},"Workflow Syntax Reference","\u002Fworkflows\u002Fsyntax-reference","01.workflows\u002F02.syntax-reference",{"title":105,"path":104,"stem":184},"01.workflows\u002F03.steps",{"title":186,"path":187,"stem":188},"Step Outputs","\u002Fworkflows\u002Fstep-outputs","01.workflows\u002F04.step-outputs",{"title":190,"path":191,"stem":192},"Concurrency","\u002Fworkflows\u002Fconcurrency","01.workflows\u002F05.concurrency",{"title":194,"path":195,"stem":196},"Transforms","\u002Fworkflows\u002Ftransforms","01.workflows\u002F06.transforms",{"title":198,"path":199,"stem":200},"For Each","\u002Fworkflows\u002Ffor-each","01.workflows\u002F07.for-each",{"title":202,"path":71,"stem":203},"Modules","01.workflows\u002F08.modules",{"title":205,"path":206,"stem":207},"Agents","\u002Fworkflows\u002Fagents","01.workflows\u002F09.agents",{"title":209,"path":210,"stem":211},"Decisions","\u002Fworkflows\u002Fdecisions","01.workflows\u002F10.decisions",{"title":213,"path":66,"stem":214},"Configuration References","01.workflows\u002F11.config",{"title":216,"path":217,"stem":218},"Comparison With Other Automation Systems","\u002Fworkflows\u002Fcomparison","01.workflows\u002F12.comparison",{"title":5,"path":157,"stem":161},{"title":221,"path":222,"stem":223,"children":224},"Projects","\u002Fprojects","02.projects",[225,228,232],{"title":226,"path":222,"stem":227},"Projects & Runs","02.projects\u002Findex",{"title":229,"path":230,"stem":231},"Projects Overview","\u002Fprojects\u002Foverview","02.projects\u002F1.overview",{"title":233,"path":234,"stem":235},"Runs & Artifacts","\u002Fprojects\u002Fruns-artifacts","02.projects\u002F2.runs-artifacts",{"title":237,"path":238,"stem":239,"children":240},"Runners","\u002Frunners","03.runners",[241,243,247,251],{"title":237,"path":238,"stem":242},"03.runners\u002Findex",{"title":244,"path":245,"stem":246},"Runner Overview","\u002Frunners\u002Foverview","03.runners\u002F1.overview",{"title":248,"path":249,"stem":250},"Getting Started with Runners","\u002Frunners\u002Fgetting-started","03.runners\u002F2.getting-started",{"title":252,"path":253,"stem":254},"Custom Runner Images","\u002Frunners\u002Fcustom-image","03.runners\u002F3.custom-image",{"title":256,"path":257,"stem":258,"children":259},"Datasets","\u002Fdatasets","04.datasets",[260,262,266,270,274,278,282,286],{"title":256,"path":257,"stem":261},"04.datasets\u002Findex",{"title":263,"path":264,"stem":265},"Datasets Overview","\u002Fdatasets\u002Foverview","04.datasets\u002F1.overview",{"title":267,"path":268,"stem":269},"Dataset Schemas and Identity","\u002Fdatasets\u002Fschema","04.datasets\u002F2.schema",{"title":271,"path":272,"stem":273},"Pushing and Reading Dataset Rows","\u002Fdatasets\u002Fworkflows","04.datasets\u002F3.workflows",{"title":275,"path":276,"stem":277},"Dataset SQL Reference","\u002Fdatasets\u002Fsql","04.datasets\u002F4.sql",{"title":279,"path":280,"stem":281},"Dataset Structured Filters","\u002Fdatasets\u002Ffilters","04.datasets\u002F5.filters",{"title":283,"path":284,"stem":285},"Dataset Saved Views","\u002Fdatasets\u002Fviews","04.datasets\u002F6.views",{"title":287,"path":288,"stem":289},"Datasets API and CLI","\u002Fdatasets\u002Fapi-cli","04.datasets\u002F7.api-cli",{"title":291,"path":292,"stem":293,"children":294},"Agent","\u002Fagent","05.agent",[295,298,302],{"title":296,"path":292,"stem":297},"BH Agent","05.agent\u002Findex",{"title":299,"path":300,"stem":301},"BH Agent Overview","\u002Fagent\u002Foverview","05.agent\u002F1.overview",{"title":303,"path":304,"stem":305},"MCP servers","\u002Fagent\u002Fmcp-servers","05.agent\u002F2.mcp-servers",{"title":307,"path":308,"stem":309,"children":310},"Bhlast","\u002Fbhlast","06.bhlast",[311,314],{"title":312,"path":308,"stem":313},"Bhlast Servers","06.bhlast\u002Findex",{"title":315,"path":316,"stem":317},"Bhlast servers overview","\u002Fbhlast\u002Foverview","06.bhlast\u002F1.overview",{"title":319,"path":320,"stem":321,"children":322},"Notifications","\u002Fnotifications","07.notifications",[323,325],{"title":319,"path":320,"stem":324},"07.notifications\u002Findex",{"title":326,"path":327,"stem":328},"Notifications Overview","\u002Fnotifications\u002Foverview","07.notifications\u002F1.overview",{"title":330,"path":331,"stem":332,"children":333},"Blob Storage","\u002Fblob-storage","08.blob-storage",[334,336],{"title":330,"path":331,"stem":335},"08.blob-storage\u002Findex",{"title":337,"path":338,"stem":339},"Blob Storage Overview","\u002Fblob-storage\u002Foverview","08.blob-storage\u002F1.overview",{"title":341,"path":342,"stem":343,"children":344},"Payloads","\u002Fpayloads","09.payloads",[345,347],{"title":341,"path":342,"stem":346},"09.payloads\u002Findex",{"title":348,"path":349,"stem":350},"Payloads overview","\u002Fpayloads\u002Foverview","09.payloads\u002F1.overview",{"title":352,"path":353,"stem":354,"children":355},"Cve Watcher","\u002Fcve-watcher","10.cve-watcher",[356,359,363,367,371],{"title":357,"path":353,"stem":358},"CVE Watcher","10.cve-watcher\u002Findex",{"title":360,"path":361,"stem":362},"CVE Watcher Overview","\u002Fcve-watcher\u002Foverview","10.cve-watcher\u002F1.overview",{"title":364,"path":365,"stem":366},"CVE Watcher Search and Filters","\u002Fcve-watcher\u002Fsearch","10.cve-watcher\u002F2.search",{"title":368,"path":369,"stem":370},"CVE Watcher Push Notifications","\u002Fcve-watcher\u002Fnotifications","10.cve-watcher\u002F3.notifications",{"title":372,"path":373,"stem":374},"CVE Watcher API and Scopes","\u002Fcve-watcher\u002Fapi","10.cve-watcher\u002F4.api",{"title":376,"path":377,"stem":378,"children":379},"Developer","\u002Fdeveloper","11.developer",[380,382,386,390],{"title":376,"path":377,"stem":381},"11.developer\u002Findex",{"title":383,"path":384,"stem":385},"Developer Overview","\u002Fdeveloper\u002Foverview","11.developer\u002F1.overview",{"title":387,"path":388,"stem":389},"Personal Access Token Scopes","\u002Fdeveloper\u002Fscopes","11.developer\u002F2.scopes",{"title":391,"path":392,"stem":393},"Personal Access Tokens","\u002Fdeveloper\u002Fpersonal-access-tokens","11.developer\u002F3.personal-access-tokens",{"title":395,"path":396,"stem":397,"children":398},"Bh","\u002Fbh","12.bh",[399,402,406,410],{"title":400,"path":396,"stem":401},"BH CLI","12.bh\u002Findex",{"title":403,"path":404,"stem":405},"BH CLI Overview","\u002Fbh\u002Foverview","12.bh\u002F1.overview",{"title":407,"path":408,"stem":409},"BH CLI Commands","\u002Fbh\u002Fcommands","12.bh\u002F2.commands",{"title":411,"path":412,"stem":413},"BH CLI Examples","\u002Fbh\u002Fexamples","12.bh\u002F3.examples",{"title":415,"path":416,"stem":417,"children":418},"Billing","\u002Fbilling","13.billing",[419,421],{"title":415,"path":416,"stem":420},"13.billing\u002Findex",{"title":422,"path":423,"stem":424},"Billing Overview","\u002Fbilling\u002Foverview","13.billing\u002F1.overview",{"title":426,"path":427,"stem":428,"children":429},"Tools","\u002Ftools","14.tools",[430,432],{"title":426,"path":427,"stem":431},"14.tools\u002Findex",{"title":433,"path":434,"stem":435},"Cookie Lab","\u002Ftools\u002Fcookie-lab","14.tools\u002F1.cookie-lab",{"title":437,"path":438,"stem":439,"children":440},"Site Policies","\u002Fsite-policies","99.site-policies",[441,443,456,460,464,468,472,476,480],{"title":437,"path":438,"stem":442},"99.site-policies\u002Findex",{"title":444,"path":445,"stem":446,"children":447},"Privacy Policy","\u002Fsite-policies\u002Fprivacy-policy","99.site-policies\u002F1.privacy-policy",[448,452],{"title":449,"path":450,"stem":451},"Company Processors","\u002Fsite-policies\u002Fprivacy-policy\u002Fcompany-processors","99.site-policies\u002Fprivacy-policy\u002F1.company-processors",{"title":453,"path":454,"stem":455},"Data Export Instructions","\u002Fsite-policies\u002Fprivacy-policy\u002Fdata-export-instructions","99.site-policies\u002Fprivacy-policy\u002F2.data-export-instructions",{"title":457,"path":458,"stem":459},"Terms of Service","\u002Fsite-policies\u002Fterms-of-service","99.site-policies\u002F2.terms-of-service",{"title":461,"path":462,"stem":463},"California Resident Notice at Collection","\u002Fsite-policies\u002Fccpa","99.site-policies\u002F3.ccpa",{"title":465,"path":466,"stem":467},"Cancellation Policy","\u002Fsite-policies\u002Fcancellation-policy","99.site-policies\u002F4.cancellation-policy",{"title":469,"path":470,"stem":471},"Refund Policy","\u002Fsite-policies\u002Frefund-policy","99.site-policies\u002F5.refund-policy",{"title":473,"path":474,"stem":475},"Taxes on Services","\u002Fsite-policies\u002Ftaxes-on-services","99.site-policies\u002F6.taxes-on-services",{"title":477,"path":478,"stem":479},"Disclaimer","\u002Fsite-policies\u002Fdisclaimer","99.site-policies\u002F7.disclaimer",{"title":481,"path":482,"stem":483,"children":484},"Security","\u002Fsite-policies\u002Fsecurity","99.site-policies\u002Fsecurity\u002Findex",[485,486,490],{"title":481,"path":482,"stem":483},{"title":487,"path":488,"stem":489},"Security Overview","\u002Fsite-policies\u002Fsecurity\u002Fsecurity-overview","99.site-policies\u002Fsecurity\u002F1.security-overview",{"title":491,"path":492,"stem":493},"Security Response","\u002Fsite-policies\u002Fsecurity\u002Fsecurity-response","99.site-policies\u002Fsecurity\u002F2.security-response",1794410312376]