Workflow templates
A template gives you a complete, working workflow to start from. You pick one, fill in its parameters, and get an ordinary YAML definition you can read, edit and run. Templates are also the quickest way to learn the format; the YAML reference explains every field they use.
Create a workflow from a template
tangle workflows templates
tangle workflows init pr-review --param lens=security --file pr-review.ymltemplates lists each template’s id, name, category, the providers it uses and a summary.
init creates a workflow from the template with your --param key=value values (repeat the flag for each one) and prints its YAML, or writes it to --file.
Every template starts disabled, so nothing runs until you turn it on.
If the template needs a provider you have not connected, init creates nothing, lists each connection it needs with its link, and exits with code 1. Connect them, for example with tangle hub connect github, and run the same command again.
Edit it and turn it on
tangle workflows get <id> --yaml > wf.yml
tangle workflows validate wf.yml
tangle workflows update <id> wf.yml
tangle workflows enable <id>get --yaml prints the current definition. Edit the file, check it with validate, then save it as a new revision with update.
Review the trigger, connections and steps before you enable it. A manual tangle workflows run <id> --wait works whether or not the trigger has fired.
You can also create a workflow from a template in the Platform app, which shows the same parameters as a form.
The templates
| Template id | Name | Trigger | Needs |
|---|---|---|---|
pr-review | PR Review | Pull request opened or marked ready | GitHub |
issue-triage | Issue Triage | Issue opened | GitHub |
email-security-digest | Daily digest | Daily schedule | Gmail; GitHub to post to an issue |
ralph-loop | Ralph loop | Weekday schedule | Nothing |
fanout-review | Fanout review | Manual run or webhook | Nothing |
code-mode-supervisor | Code-mode supervisor | Webhook | Nothing |
engineering-audit | Senior engineering audit | Manual run or webhook | GitHub |
design-audit | Senior design audit | Manual run or webhook | Nothing; GitHub to file an issue |
PR Review (pr-review)
Reviews each pull request that is opened or marked ready, and skips drafts until they are ready.
Four reviewers work in parallel, each in its own sandbox on the pull request head: correctness, security, tests and design. Each reviewer is followed by a verifier that re-reads the code behind every finding and marks it confirmed or refuted. A final step joins the four verified lists and posts one review with only the confirmed findings, as the Tangle Hub GitHub App.
| Parameter | Values |
|---|---|
lens | all (default), correctness, security, tests or design. One lens runs that reviewer and its verifier only |
model | The Router model every reviewer, verifier and the final step use; the template sets a default |
It starts up to four sandboxes at once, so your plan must allow that many concurrent sandboxes; on a plan that allows fewer, the extra sandboxes are refused with CONCURRENT_LIMIT and those steps fail.
Issue Triage (issue-triage)
Each newly opened GitHub issue is read by an agent with access to your GitHub connection. The agent triages it and posts a short assessment back as a comment, deciding and acting in one step. It has no parameters.
Daily digest (email-security-digest)
Every day an agent reads your recent email, writes one digest with a security or operations focus, and delivers it to a GitHub issue, a webhook, or both. With neither, the digest stays in the run’s output.
| Parameter | Values |
|---|---|
schedule | A cron expression in UTC; the default runs daily at 08:00 |
focus | security (default) or operations |
query | The Gmail search; default newer_than:1d |
owner, repo, issueNumber | Optional. Set all three to post the digest as a comment on that issue |
notifyUrl | Optional. An HTTPS endpoint that receives the digest |
Ralph loop (ralph-loop)
A draft, review and steer loop with no connections. A drafter writes release notes from your changes, a reviewer answers VERDICT: approve or VERDICT: revise, and a steering editor turns each revise into notes for the next draft.
The loop repeats through a guarded back-edge until the reviewer approves, then posts the final draft to notifyUrl if you set one. It shows needs[].when, if routing and maxNodeVisits in one short file.
| Parameter | Values |
|---|---|
changes | The changes the notes are written from, on one line, up to 2048 characters. The default is a sample to replace |
notifyUrl | Optional. An HTTPS endpoint the approved draft is posted to, such as a Slack or Discord incoming webhook |
Fanout review (fanout-review)
One builder drafts a short report on a topic, accuracy, clarity and tone reviewers score it in parallel, and a final step returns the report with a SHIP or REVISE verdict. Every step is a single model call with no sandbox. It shows a graph that fans out with needs and joins again.
| Parameter | Values |
|---|---|
topic | What the report is about. A manual run uses it; a webhook call can pass its own topic in the body |
model | The Router model the builder, reviewers and final step use; the template sets a default |
Code-mode supervisor (code-mode-supervisor)
Post a brief to the workflow’s webhook URL. One script.run step sends it to three sandbox workers with the bundled sandbox SDK and agent-runtime loop functions, scores their answers and returns the best one.
Use it when your orchestration is easier to write as code than as YAML. It has no parameters; the posted body’s brief field is the input.
Senior engineering audit (engineering-audit)
Audits a repository when you run it. Five reviewers work in parallel, each in its own sandbox: architecture, reliability, security, performance, and tests and operability. Each is followed by a verifier that re-checks its findings against the code. A final step ranks the confirmed findings, each with a number to beat, and files them as one GitHub issue on the repository.
| Parameter | Values |
|---|---|
owner | The organization or user that owns the repository |
repo | The repository name, without the owner |
model | The Router model every reviewer, verifier and the final step use; the template sets a default |
It starts several sandboxes at once, with the same plan requirement as PR Review.
Senior design audit (design-audit)
Audits a public web page when you run it. One fetch step captures the page’s HTML, its stylesheets from the same host and its asset details, as both a desktop and an iPhone browser; it is the only step with network access, and it may reach only the domain you name. Five reviewers then audit that capture in parallel: hierarchy and typography, interaction, accessibility, responsive layout, and copy. Each is followed by a verifier, and a final step writes one ranked report. Findings cite HTML, CSS and copy, not screenshots.
| Parameter | Values |
|---|---|
url | The public https:// page to audit |
domain | The page’s exact host, such as example.com; it must match url |
model | The Router model the reviewers, verifiers and final step use; the template sets a default |
notifyUrl | Optional. An HTTPS endpoint the report is posted to |
owner, repo | Optional. Set both to also file the report as one issue on that repository |
It starts several sandboxes at once, with the same plan requirement as PR Review.
Run a manual-run template with tangle workflows run <id> --wait, or with Run now on its page in the Platform app. A template with a webhook trigger also gets its own URL and token when it is created; see Run, inspect and trace workflows.