Skip to content

Run a task under a formula, and reference everything by name

A formula declares things once, each with a name: agents, skills, connectors, goals, tasks. Everything else names them. You can run one task under a formula without applying it (nothing is left behind), and every name a task gives is checked first, with what there is when it names nothing.

review.wisp.yml
wisp: 1
variables:
model: { type: string, default: opus }
agents:
critic: { harness: claude, model: "${var.model}", instructions: Be strict about tests }
goals:
green: { text: npm test passes }
tasks:
release: { prompt: "Release {version}: changelog, bump, tag", agent: "${agent.critic}", goal: green }

agent: "${agent.critic}" and agent: critic are the same: a field that names a thing takes its name or a reference, and an agent field also takes a harness (codex) or auto.

Try a setup on one task

In New task, press + → Formula or task file… and pick review.wisp.yml. It shows as a Formula: chip by the prompt; the task you send runs under it (its agents, skills, connectors and goals are that task’s), and ✕ on the chip takes it off. Pick a task file instead and its prompt, agent and goal fill New task. A name the file gives that names nothing is said in a toast, with what there is, and nothing is attached.

Task files that point at your formula

wisp task export <id> > fix.task.yml writes what a task was asked. Instead of the copy of the setup it carries, point it at your formula: a file beside it, a module of the folder’s .wisp/, or a list of them.

wisp: 1
task: { prompt: Fix the flaky login test, agent: critic, goal: green }
formula: [./review.wisp.yml, module.team]
Terminal window
wisp run -f fix.task.yml

Its agent, goal, connectors, crew member, team and project are read against those files and what this wisp has. One that names nothing stops it before anything runs:

✗ fix.task.yml: no agent named critc: agents has critic (or claude, codex, auto)

A file named twice, or the task file itself, is refused too.

Checked before anything runs

wisp validate (and wisp apply, Setup → Import, a grid deploy) checks every name in every kind: a trigger’s task:, a crew member’s agent: and who they delegate to, a notification’s channel, a connector’s agents, a setting such as channels.project. A loop of delegations (ada → bo → ada) is refused, and so is taking away something another thing still names. The formulas page has the details.