Skip to main content
Blitz
Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

023 · Jobs

Jobs (scheduled, unattended workflows) (spec_023_workers)

Called workers until v0.8.0; jobs since (the owner’s decision, 2026-10-19: “worker” read as something that does the work, an agent or a process; Spanish trabajos, French jobs, since “tâches” are tasks). The app, the tray, the CLI’s help and the docs say jobs; blitz jobs is the command, and blitz workers still works. Files, settings and code keep the old name: .agents/workers/<name>/WORKER.md, ~/.blitz/workers, [workers.policy], WorkerService, blitz://workers, the desktop.workers.* keys, and this file’s.

Status Implemented, first version. Reverse-engineered from 53f8c53 (2026-09-24) and kept with the code since; its paths checked 2026-09-27 (//tools/specs).
Source pkg/engine/workers/{worker,schedule,permission,policy,state,runs}.go; pkg/engine/workers.go; pkg/service/server/{scheduler,worker}.go; apps/cli/workers.go
Tests pkg/engine/workers/*_test.go, pkg/engine/workers_test.go, pkg/service/server/worker_test.go, apps/cli/workers_test.go
Depends on spec_005_approvals (unattended approvals), spec_018_workspace, spec_021_service

1. Purpose

A workspace defines jobs in .agents/workers/<name>/WORKER.md (or workers/<name>/WORKER.md). The service runs enabled jobs on their schedules, unattended, with exactly the permissions they declare (capped by host policy). Nothing runs until a person reviews and enables the exact content; editing disables it again.

2. Definition (WORKER.md)

---
description: Report outdated Go modules
schedule: Weekdays at 9:30            # cron "30 9 * * 1-5", "@every 2h", or a phrase
timezone: Europe/Paris                # optional; default the machine's
permissions: ["shell:go list -m -u all", "write:reports/"]
limits: { max_turns: 30, max_cost_usd: 0.50, timeout: 20m }
catch_up: once                        # none (default) | once
runs_on: here                         # here (default) | service: the organization's service runs it (spec_053_enterprise EN-40)
overlap: skip                         # only "skip"
agent: qa                             # optional: runs as this agent
model: anthropic/claude-haiku-4-5     # optional: runs on this model
---
Check for outdated Go modules and write reports/deps.md.
  • WK-01 Job roots: [workers] paths (default .agents/workers, then workers) relative to the workspace; a later root doesn’t override an earlier job of the same name. Directories without WORKER.md are ignored.

  • WK-01a CreateWorker(spec) writes a new job from a form’s fields (api.WorkerSpec: name, description, schedule, time zone, agent, model, permissions, limits, catch-up, workflow) in the first root: workers.Render writes the frontmatter with only the fields set (YAML, so text is quoted as needed) and the workflow. It is loaded from a temporary copy first, as the scheduler would read it, and an agent that isn’t defined is a problem too: with problems nothing is written and they’re returned. A name any root already has is ErrWorkerExists (WORKER_EXISTS). The new job is new (disabled) until reviewed and enabled (WK-10).

  • WK-01b 2026-10-01. Editing. GetWorkerSpec(name) returns a job’s WORKER.md as written (workers.ReadSpec: the schedule, time zone, permissions and limits as given, not as understood or capped by the policy) with the hash of its files. It reads what it can of a file that isn’t valid, so a broken job can be fixed from the form: unknown keys are ignored, and a file whose frontmatter can’t be read comes back whole as the workflow. UpdateWorker(spec, hash) rewrites WORKER.md in the job’s directory only if its files still have that hash (ErrHashMismatch, HASH_MISMATCH: changed since they were read), and only if the result passes WK-01a’s checks (otherwise its problems, nothing written). The name, which is the directory and keys the run log and the enabled state, can’t change. The file is replaced atomically (a temporary dot file beside the job’s directory, never in its hash). The new content has a new hash, so an enabled job becomes changed and stops running until it’s enabled again, as after any edit (WK-10); the service rescans at once. Writing the file drops YAML comments, keys Blitz doesn’t know and overlap (only skip, the default).

  • WK-01c 2026-10-02. Deleting. DeleteWorker(name) (WorkerService.DeleteWorker) removes the job’s directory (its WORKER.md and anything beside it, os.RemoveAll) and forgets it in the store (Store.Forget: it’s new if it comes back; a workspace with none left isn’t watched). Its past runs stay in the run log. Refused while a run of it goes (RUN_IN_PROGRESS); an unknown name is UNKNOWN_WORKER. The scheduler rescans after. The desktop deletes from the Jobs menu and the job’s view (DSK-65a), confirmed.

  • WK-02 The directory name is the job’s name: ^[a-z0-9][a-z0-9_-]{0,63}$; a frontmatter name must match it. Only valid names are looked up (they become file names).

  • WK-03 Frontmatter is decoded strictly (unknown keys are errors — a misspelling would silently change behaviour). A leading BOM and blank lines are tolerated; missing frontmatter delimiters are errors.

  • WK-03a 2026-11-05 (scan N26-engine-sub-2#6: WORKER.md’s front matter ended at the first line starting with ---, a ---- rule included). The front matter opens with a --- line and ends at the next line that is only --- (trailing spaces and a CR allowed), the rule SKILL.md, rules, notes and summaries follow too (spec_013 SK-02a; jobspec.Split keeps its own copy, as pkg/jobspec can’t import the engine).

  • WK-04 Invalid if: bad name, empty workflow body, unparseable schedule or time zone, bad permission, bad or non-positive limits.timeout, negative limits, unsupported overlap/catch_up/runs_on/on_request/merge (the last two listed 2026-11-05, scan N26-engine-sub-2 spec gaps: the code always refused them), hashing failure. An invalid job still loads with its problems listed.

  • WK-05 Content hash: SHA-256 over every regular file under the job directory (relative path, size, content; symlinks skipped; ≤ 64 MB), sha256:<hex>.

  • WK-05a 2026-11-05 (scan N26 desktop-4#19 follow-up: a workflow: job gets its workflow’s step permissions as the workflow is now, WF-20, but the workflow wasn’t in the hash, so editing it widened what an enabled job may do with no one enabling it again). A job that names a workflow is hashed with it: after its own files, the name, then each regular file in .agents/workflows that would load as that workflow (<name>.flow.yaml, the suffix in any case; name, size, content), or a mark that there’s none. Editing, creating or removing the workflow changes the hash, so an enabled job is changed until it’s enabled again, as after an edit to WORKER.md. workers.Load, ReadSpec, HashDir and Discover take the workflows folder, so the listing, GetWorkerSpec/UpdateWorker’s check, enabling, runs and the move to the service agree. A job without workflow: hashes as before, so the upgrade suspends none.

  • WK-05b 2026-11-05 (scan N26 engine-decisions: a run checked the job’s hash, then read the workflow again to run it and to add its steps’ permissions, so an edit in between gave that one run steps and permissions nobody reviewed; WORKER.md too was parsed from one read and hashed from another). The job’s files are read once per check: workers.Load hashes WORKER.md from the bytes it parsed and keeps the workflow’s file as hashed (Worker.FlowFile, the first file that loads as it). A run whose job isn’t enabled at that hash doesn’t start (it is changed); one that starts runs the workflow parsed from those bytes, and its steps’ grants (WF-20) come from them, never from the file again. A paused run of a job resumes the same way: the job is read once, a job that isn’t enabled as it is now (changed, disabled, invalid) refuses the resume with ErrWorkerNotEnabled and keeps the paused run until it is, and the workflow and its grants come from the bytes the job’s hash covers (which must still be the file the run paused on, as for any paused run). A job that’s gone resumes with everything refused, as before.

  • WK-75 Built 2026-11-15 (blitz-enterprise spec_015_evals EVS-10). A job may run evals instead of a prompt or workflow (evals: [name, …] in its WORKER.md; each a name an eval’s file can have): each eval’s every case, as Studio’s ▶ does; its run’s last message, so its output on an organization’s service, is the results as JSON (EvalsOutput: each eval’s run with its cases, each case’s prompt, expected and output cut to 4 KB). A case that fails is a result, not a failed run; an eval that isn’t there, or can’t run, fails it.

3. Schedules

  • WK-10 Accepted: five-field cron, descriptors (@hourly, @daily, @weekly, @monthly, @every 90m), or fixed plain-text phrases translated by rules, never guessed: hourly|daily|weekly|monthly, every [N|word] minute(s)|hour(s)|day(s) (non-divisors become @every), daily|weekdays|weekends|every <weekday> at <time> where time is 6, 6 am, 6:30 PM, 18:30, noon, midnight. Anything else is an error listing the accepted forms.
  • WK-10 2026-11-05 (scan N26-safety-enterprise#29: “every 10 days” became 0 0 */10 * *, a day-of-month step that runs on the 1st, 11th, 21st and 31st, then the 1st again). “every N days” is @every <24·N>h (“every day” stays @daily): no day-of-month step fits every month.
  • WK-11 Next(t) evaluates in the job’s time zone.

4. Permissions and policy

  • WK-20 A permission is <kind>:<pattern>: shell:<command or glob>, write:<path glob>, delete:<path glob>, web:<host or search provider>, mcp:<server>:<tool glob>. Write/delete paths are workspace-relative and may not be absolute or use ... Globs use path.Match (* doesn’t cross /); a pattern ending in / covers everything below.
  • WK-20a Since v0.6.3. A write or delete pattern written with a leading ./ (write:./daily-news/*) is read without it (daily-news/*), as the tools give paths; before, it matched nothing, and the job’s writes were refused.
  • WK-20b Since v0.8.4. In a write or delete pattern, a ** segment is any number of folders: write:reports/** covers everything under reports/ at any depth (reports/ai-news/10-23-2026.html), reports/**/*.html the HTML files there, **/notes.md a notes.md anywhere; reports itself isn’t covered. A single * still stays within one folder, and a pattern ending in / (write:reports/) still covers everything under it. Command, web and MCP patterns are unchanged.
  • WK-21 A request is allowed only if it has targets and every target is covered by a permission of its kind. File targets must be clean workspace-relative paths. A shell command containing any of ; & | \ $ ( ) < > \ \n \ris covered **only** by a permission that is exactly that command (sogo list *can't covergo list x; rm -rf ~`). Reading never needs permission.
  • WK-22 Host policy [workers.policy]: allow (permission kinds; default all five), default_max_turns 50, default_max_cost_usd 1, default_timeout 30m, max_turns 200, max_cost_usd 10, max_timeout 2h, max_concurrent 2. Disallowed permissions are dropped and caps applied, each with a note shown to the user.
  • WK-22a 2026-11-05 (scan N26-engine-sub-2#7: a hand-edited default_timeout = "30 minutes" gave every job without a timeout none at all, and a max_timeout that didn’t parse removed the cap, without a word). A default_timeout or max_timeout that isn’t a Go duration above zero (30m, 1h30m) is reported when the settings are checked (an error at [workers.policy]), when the workspace opens and by blitz doctor, and is never “no limit”: the shipped 30m applies in its place, as the default or as the cap, with a note on the run. An empty default_timeout is the shipped default too.
  • WK-22b 2026-11-05 (scan N26-engine-sub-2#10: a job’s max_turns: 0 or max_cost_usd: 0 silently got the defaults, while a guardrail’s limits.md reads 0 as no limit). In a job, a limit of 0 is the same as leaving it out: the policy’s default applies. There’s no “no limit” in a job; the guide says so beside the limits.

5. Enabling

  • WK-30 State per (workspace, name) in ~/.blitz/workers.json (the service is its only writer; atomic writes): new, enabled (at the current hash), disabled, changed (enabled at an older hash — doesn’t run), invalid.
  • WK-30a 2026-11-05 (scan N26-engine-sub-2#12: an enable whose write failed, disk full, still enabled the job in memory until the service restarted, and a disable could overwrite a concurrent enable). The store changes a copy and takes it only once it’s written; each change reads and writes under one lock.
  • WK-31 blitz jobs enable <name> shows the path, description, schedule (as written, as cron, time zone), effective permissions, limits, problems and content hash, asks [y/N] (or -y), then enables the hash shown; a change in between fails with HASH_MISMATCH. Invalid jobs can’t be enabled. When no login item keeps the service running, it says Workers run in the Blitz service: keep it running with 'blitz service install'. (Corrected 2026-10-14: it said blitz serve.)
  • WK-31a 2026-11-05 (scan N26-cli-2#15: the quote predates the jobs rename). The line says Jobs run in the Blitz service: keep it running with 'blitz service install'.
  • WK-31b 2026-11-05 (scan N26-cli-2#24: a limit of 0, none, showed as “0 model calls, $0.00, 0s” in the prompt that approves the job). The limits line says each one that is 0 as no limit: no limit on model calls, no cost limit, no time limit.
  • WK-32 disable, list (name, state, schedule, cron, next run, description, problems), runs <name> [-n 10], run <name> (runs now, prints events and the record; non-success exits 1). undo <run-id> [-f] puts back the files a run changed. Request errors (unknown, not enabled, running, disabled, hash mismatch) exit 2. These always go through the service, starting it when needed (CLI-14). (Corrected 2026-10-14: an in-process path no longer exists.)

6. Runs

  • WK-40 A run requires the job enabled at its current hash. The same job never runs twice at once: a second request is RUN_IN_PROGRESS, and a skipped scheduled run is recorded (skipped).
  • WK-41 Each run gets its own session titled ⏰ <name> <YYYY-MM-DD HH:MM> (openable with /resume) and recorded as the run’s agent, and a prompt prefixed with an unattended preamble (nobody can answer; only permitted actions work; end with a summary of what was and wasn’t done). The transcript records the workflow text.
  • WK-42 Unattended approvals (spec_005_approvals APR-10): permitted requests pass; everything else is refused and recorded as a refusal {tool, kind, detail, time}. ask_user_question is refused.
  • WK-43 Limits: max_turns (model calls), max_cost_usd (checked after each event; cancels the run), timeout — applied through the turn’s own limits (WS-29), so the run’s error is the limit’s message. Status: succeeded, failed, limited (turns, cost or time, with the cause as error), skipped; running while live.
  • WK-43a 2026-11-05 (scan N26-engine-top-2#2, N26-engine-top-1#2: a job whose body is a workflow got only its timeout, without the time-limit cause, ran its steps on the active agent and the workspace’s model, and kept none of their changes for blitz jobs undo). A workflow job’s run keeps the job’s limits across its steps: max_turns is one budget for all of them (each step’s turn still within the limits guardrail’s), max_cost_usd is checked after every event against the run’s spend, and the timeout cancels with ErrTimeLimit, so a run stopped at any of them ends limited with the limit as its error. Its agent steps run on the job’s agent and model (a step’s own agent wins) and are the run’s turns: their changes go into its checkpoint (files, WK-54) and blitz jobs undo <run> undoes them.
  • WK-43b 2026-11-05 (the owner: a limit with no hint sends people looking for a setting, spec_041 GT-32). A run stopped at a limit no guardrail set says what set it: “the job sets this in workers//WORKER.md; to allow more a run, raise max_turns under limits: there.”, for the jobs’ default “this is the jobs’ default; … set max_turns under limits: in workers//WORKER.md, or change the default in Settings › Library › Jobs.”, and for a host cap “this is the jobs’ cap; to allow more a run, raise it in Settings › Library › Jobs.” (Workspace.jobLimitHints).
  • WK-45 Agent and model: a run uses the job’s agent (else the workspace’s active agent) and model (else the workspace’s), for that run only (spec_016_engine ENG-16); the workspace’s active agent and model are unchanged. An undefined agent is listed as a problem and fails the run; a model that can’t be built fails the run with the (secret-masked) reason. workers enable shows both so they are part of what is approved.
  • WK-44 Run log: one JSONL file per job, ~/.blitz/worker-runs/<hex(sha256(workspace))[:16]>-<name>.jsonl (0600): id (YYYYMMDDTHHMMSS-<16 hex>), workspace, job, hash, status, manual, started, duration, cost, calls, session, refusals, error. Torn last lines are skipped. Listed newest first.
  • WK-44a 2026-11-05 (scan N26-engine-sub-2#8: the record after a torn last line was written onto it, so the next run after a crash was lost with the torn one). Appending to a run log, a session’s transcript, event log or sub-agent log (jsonl.Append) starts a new line first when the file’s last line was torn, so only the torn record is skipped.
  • WK-44b 2026-11-05 (scan N26-engine-sub-2#11: a run line over 4 MB stopped the reader, hiding every later run, and the scheduler’s look at the last run dropped a read error). A run log is read line by line however long a line is; a read error at the scheduler’s catch-up look is logged. The log isn’t trimmed yet: every run is kept.

7. Scheduler (service)

  • WK-50 Runs only in the service (blitzd) with [workers] enabled. It watches every workspace that has at least one enabled job, even when no client has it open, rescanning every minute to pick up new, edited and removed jobs; a changed hash, cron or time zone re-registers the entry.

  • WK-51 Concurrency: max_concurrent slots across workspaces. A manual run fails at once with TOO_MANY_RUNS when all are busy; a scheduled run waits, but a job already waiting isn’t queued again (a job that falls behind runs once, not once per missed tick).

  • WK-51a 2026-11-05 (scan N26-service#30, #31: TOO_MANY_RUNS didn’t say where the limit is set; one failed listing unscheduled a workspace’s jobs; a bad schedule was logged every minute). TOO_MANY_RUNS names workers.policy.max_concurrent (in its metadata too) and says a change applies once the service restarts. A rescan keeps the jobs of a workspace that can’t be opened or listed now, scheduled as they were, until it can; a schedule that doesn’t parse is said once per version of the job, not at every rescan.

  • WK-52 catch_up: once: when a job is first registered (the service starts, or it’s enabled) and a scheduled time passed since its last run, it runs once as soon as possible. A job that has never run has nothing to catch up. Ticks missed while the service runs (a machine asleep) collapse into at most one run when its timer fires; nothing more is promised.

  • WK-53 Live runs keep their events so WatchWorkerRun replays them, then streams live ones until the run finishes; events aren’t kept afterwards. Stopping the scheduler cancels all runs and waits for them.

  • WK-53a 2026-11-05 (scan N26-service#24: a live run kept every event, streamed text pieces included, for as long as it ran, growing the service’s memory). A live run keeps its latest 5,000 events, as a background run does (keptRunEvents); WatchWorkerRun replays those, in order, then streams live ones, skipping any dropped before it could send them. The run’s end is always kept.

  • WK-53a Since v0.6.3 (the owner’s request). A run going now can be stopped. Each run has its own context under the scheduler’s (liveRun.stop); StopWorkerRun(run_id) cancels it with api.ErrRunStopped as the cause and returns the record as it was (RUN_NOT_RUNNING when no such run is going). The turn winds down, and the run is recorded with status stopped (RUN_STATUS_STOPPED, error “stopped by the user”, RUN_STOPPED on its finished event); its changed files are kept and, like any run’s, undone with blitz jobs undo. ListRunningWorkerRuns lists the runs going now in every workspace, oldest first. blitz jobs stop <name|run-id> stops the workspace’s run of that job. Stopping the scheduler still cancels every run (recorded as failed, as before).

  • WK-53b Since v0.6.3 (the owner’s request). RewriteWorker(workspace, worker) has the suggestions model (else the reviewer’s, else the main one) rewrite a job’s instructions, as the form has them, for an unattended run (pkg/engine/workerrewrite.go): self-contained (no looking up its own definition or listing folders), named sources fetched once, bounded work, an exact output path and format, what to do when a step fails, a short finish, nothing invented. The model also lists the permissions they need, as narrowly as they allow, and up to five lines on what changed. It replies in JSON; permissions that don’t parse (ParsePermission) are dropped, a reply without instructions is a problem, and a model that fails gives problem (redacted) instead of an error. The instructions sent are redacted for secrets. Nothing is saved: the form takes the suggestion only when the user says so. NO_INSTRUCTIONS without instructions.

  • WK-54 A run’s file changes are its own checkpoint (BL-WK-01): its turn is a job turn (Checkpoints.BeginWorkerTurn, the run’s ID on it), which /checkpoints and /undo in interactive sessions leave out, and changes go to their own session’s turn even while an interactive turn runs (FS-60a). The run record lists the files it changed (files; blitz jobs runs shows them with the run’s ID).

  • WK-55 blitz jobs undo <run-id> [--force] (WorkerService.UndoWorkerRun, Workspace.UndoWorkerRun) restores those files as they were before the run, with /undo’s conflict rules (FS-63): a file changed since blocks it unless forced; NOTHING_TO_UNDO when nothing is left (undone already, or trimmed from the store). It’s audited (BL-WK-02).

  • WK-56 [workers] notify (BL-WK-10): a shell command run after each scheduled run (and each scheduled run skipped because the last still ran) whose status is in notify_on (default failed, limited), never after manual runs. It gets the run record as a line of JSON on stdin, BLITZ_WORKER and BLITZ_RUN_STATUS in its environment, runs in the workspace outside the sandbox with a 30 s limit, and a failure is a warning. Only the user’s settings may set it (never a project’s).

  • WK-57 Since v0.7.1 (the owner’s request); since v0.8.0 each workspace’s submenu, spec_038_electron EL-111, holds its jobs, and the runs going on are at the menu’s top. The tray’s Jobs submenu (tray.WorkerEntries until v0.8.0), so jobs, which run while the window is closed, can be seen and handled from the tray: first each run going on, Stop (running) (StopWorkerRun); then each job of every registered workspace (named <folder> › <worker> when there’s more than one workspace), with Run now (RunWorker), Enabled (a check item: DisableWorker, or EnableWorker at its hash for one disabled at the content it was enabled with; a new, changed or invalid job says Review it in Blitz to enable it, greyed, and doesn’t run from here) and Show in Blitz, which opens blitz://workers?dir=<workspace> (EL-22): the app opens the workspace on its jobs. Asked every 2 s with the tray’s status; redrawn only when it changes. The home workspace’s jobs are named Global › <worker> (WK-60); their Show in Blitz opens Settings › Library › Jobs.

  • WK-60 Since v0.7.1 (the owner’s request). Global jobs: work that belongs to no project. They’re defined in ~/.blitz/workers/<name>/WORKER.md (config.UserWorkersDir) and run in the home workspace, ~/.blitz/home (config.HomeWorkspace, made when missing): a workspace of its own, so they have the same states, review, policy, schedule, run log, sessions and RPCs as any workspace’s, with workspace set to the home workspace. The engine gives the home workspace ~/.blitz/workers as its only job folder (workerRoots), so CreateWorker there writes to it.

  • WK-61 Since v0.7.1 (the owner’s request). WorkerService.ListAllWorkers lists the home workspace first, then every workspace with a job on record in ~/.blitz/workers.json, enabled or disabled (Store.Known), by folder, each with its jobs. A workspace whose folder is gone is missing, with the jobs on record (name, enabled or disabled) and nothing opened; one that can’t be opened has its (redacted) problem. This is what keeps a job from running unseen: the service runs a workspace’s enabled jobs whether or not the app has the workspace open (WK-50).

  • WK-62 Since v0.7.1 (the owner’s request). A workspace whose folder is gone (moved, deleted, an unplugged drive) is skipped by the rescan and logged once, not every minute; its jobs run again if it comes back. WorkerService.ForgetWorkspaceWorkers(workspace) drops every job of the workspace from the store (Store.ForgetWorkspace): none is enabled any more, and the service stops looking for the folder. Files aren’t touched (a folder that comes back has its jobs as new). Refused while one of them runs (RUN_IN_PROGRESS); a relative path is INVALID_WORKSPACE.

  • WK-63 Since v0.7.1 (the owner’s request). The global limits on every job are a form at the top of Settings › Library › Jobs (WorkerLimits): the default and maximum model calls, cost and time (since v0.8.4 the maximums are optional caps, none by default: WK-73), how many runs go at once, and the permission kinds a job may be given (chips; all off is none, read only). Each field is saved as it’s left with SetConfigValue (workers.policy.*, typed: counts, US dollars, lengths of time like 30m, kinds; empty puts back the default) in the global settings, and ListAllWorkers returns them as they’re set (WorkerPolicySettings). Open workspaces reload the policy (ReloadWorkerPolicy) and apply it from their next listing or run; a run going keeps the limits it started with. max_concurrent applies when the service restarts: until then the form says how many the service runs at once (running_max_concurrent).

  • WK-63a 2026-11-05 (scan N26-desktop-2#1: the form asked for the policy every 10 s and put every field back, so a cap being typed was wiped before it was left and nothing was saved). When the policy comes again, a field changes only when its saved value did: a value being typed (or not yet saved) stays.

  • WK-70 v0.8.4 (the owner’s request). Jobs from the chat. The blitz agent has create_job and list_jobs (pkg/engine/tools/jobs.go, the engine’s Jobs calls: DraftWorker, PreviewSchedule, CreateWorker, ListWorkers). Asked for something on a schedule (“every day at 8 am fetch … and write a report to …”), it lists the jobs first, then calls create_job with the name, the schedule in plain text or cron, a prompt that says everything a run needs (it runs without the conversation), only the permissions that prompt needs, and optional agent, model, limits and catch-up. The tool drafts the job (DraftWorker: what CreateWorker would write, checked as the scheduler reads it, nothing written); an invalid one comes back with its problems for the agent to fix, unasked. A valid one is always asked about (MustAsk, so no mode or rule lets it through, and a job’s own run can’t make jobs), showing the WORKER.md as a diff and the next three runs. Approved, it’s created paused, as the New Job dialog’s are (decision 2026-10-23); the chat shows a card with the job’s schedule and permissions, Review (Studio › Jobs, its details) and Enable. list_jobs is allowed in plan mode.

  • WK-71 v0.8.4 (the owner’s request). May do without asking in the job editor is a rule builder (PermissionRules.tsx), not a free-form box: a row per rule, a kind (Run commands, Write files, Delete files, Fetch from the web, Use MCP tools) and its pattern, with that kind’s examples as the placeholder and a sentence saying what the row allows; Add a rule and remove. Each row’s help button (?) opens what that kind’s patterns cover, with examples and their meaning (ruleHelp); choosing one fills the pattern. Kinds Settings › Library › Jobs doesn’t allow are offered disabled, and a row of one says a run won’t get it; a line that isn’t kind:pattern is kept as Other, as written. The form still holds kind:pattern lines (parseRules, rulesText; the request tidies them and leaves out a row without its pattern yet), so WORKER.md is written as before.

  • WK-72 v0.8.4 (the owner’s request). A schedule picker instead of the schedule’s text field (SchedulePicker.tsx, scheduleForm.ts): Repeats every hour (at a minute), every day, every weekday, every week on chosen days, or every month on a day (1–28), at a time; or Custom, text or cron as before. The picker writes cron (0 8 * * 1,5), so the service reads exactly what it shows, and opens a job’s schedule in its own form when it’s one of them, else in Custom. The time zone is a dropdown of the browser’s zones grouped by region, each with its place and its offset now (Chicago (UTC−05:00)), the first choice the service machine’s; a job’s zone the browser doesn’t know is kept. The service’s reading of it, WorkerService.PreviewSchedule (the cron form, the time zone and the next runs, up to 20, or a problem rather than an error, since it’s asked as you type), is a card: the schedule in a sentence (Every Monday and Friday at 8:00 AM) with its cron as a chip, the next five runs as dated rows (the month and day as a tile, the weekday and time, and how far off: tomorrow, in 3 days), and a month stepped with arrows, run days filled and today ringed, in the job’s time zone. A new job starts at every day at 9:00.

  • WK-73 v0.8.4 (the owner’s request: the maximums were too often too low). The job limits are defaults, not caps: the shipped [workers.policy] has default_max_turns = 50, default_max_cost_usd = 1 and default_timeout = "30m", which fill in what a job leaves out, and no max_* (0 or empty: none), so a job may set more. A host that wants a cap still sets one: Settings › Library › Jobs’ second column is Cap (empty: no limit). Settings files that set max_* keep their caps. The job editor’s fields read Model calls a run, Cost a run (USD) and Time a run, with the defaults as placeholders (“Default: 50”) and a cap, when the host set one, under them.

  • WK-73a 2026-11-05 (scan N26-engine-top-2#6: nothing said that the workspace’s limits guardrail caps jobs too). A job’s limits apply under the workspace’s limits guardrail (spec_041 GT-31), which holds each turn to 200 model calls and $10 unless limits.md says otherwise: a job that sets more stops at the guardrail’s, and its error names the guardrail’s file (GT-32). The guide says so beside [workers.policy].

  • WK-73b 2026-11-05 (scan N26-desktop-2#20: the spec didn’t say what the job form does with a value over the host’s cap; it saved it without a word and runs were held to the cap). The form accepts it (the job file may go to another host with other caps), and marks the field: its note under it reads Over the cap: runs stop at {cap} in the error colour, as runs are held to the cap.

  • WK-74 v0.8.4 (the owner’s request, for continuity with Workflows). New job begins with Compose with AI, as New workflow does (spec_045_composer): describe the job, answer a few questions (when, in which time zone, where the results go, what it may reach), and the composer drafts the WORKER.md, checked as the scheduler reads it (checkJobDraft: the name, the frontmatter, the schedule, the agent), problems going back to it until it loads. The draft (ComposeDraft.worker, read with workers.ParseSpec) shows its schedule, permissions and prompt; Use this job fills the form, to review and Create.

8. Known gaps

  • service install is needed for jobs to keep schedules across logins; API keys must be in ~/.blitz/.env.toml.