collection/automations.md
Automations
What happens by itself: an event, an action in response and a limit on how many times per hour and per day.
An automation is an event and a reaction to it: when trigger fires, reaction runs. It is not a norm: a norm says what must be there, and an automation is one way to get there after an event.
trigger: {kind: clock, at: "03:00"} # or every: 15m, cron: "0 3 * * *"
reaction: {action: /actions/nightly-check} # or {agent: /agents/worker}
limits: {perHour: 1, perDay: 1}
mode: manual # auto: the executor runs it
Kinds of event (trigger.kind):
| Kind | What else to give |
|---|---|
clock (or schedule) | at, every or cron |
change | within: the folder to watch for changes |
phase | contour and phase: a record entered the phase |
sensor | sensor: the sensor page |
run-finished | automation: whose run ended |
manual (or hand) | nothing: a person runs it |
answer | nothing: a person's answer to a run question |
mode: manual is an instruction for a person or an agent: the executor does not run it by itself. mode: auto is run by the executor (for example the Shtukbase node) by itself, but no more often than the limits limits allow.
Norm ACT-R02 makes sure an automation says when, what and how many times.
The package Actions and automations puts this page at
/automations.md.Source text