Request a demo
How it works

Schedules and headless runs: InsightWorker without anyone at the keyboard

The three ways InsightWorker runs unattended: one-shot prompts for scripts, headless app runs with streamed events for pipelines, and a scheduler that fires prompts and workflows on an interval or a cron expression.

November 11, 2026 · 7 min read · All articles

Most of the value of an AI worker shows up when nobody has to ask: the overnight check that is already written up at 9 a.m., the pipeline step that drafts the release note, the hourly sweep of a queue. InsightWorker has three ways to run without anyone at the keyboard, and they suit different jobs.

One-shot prompts

insightworker -c "list all Airflow DAGs" runs a single prompt through the agent with your configured provider and tools, prints the result and exits. It is the quickest way to put the worker in a cron line or a CI step, and the least structured: the output is prose.

Headless app runs

When a pipeline needs structure, run an app instead of a prompt:

insightworker app run dag-failure-triage \
  --input dag_id=etl_orders_daily \
  --input run_id=scheduled__2026-11-18T02:00:00 \
  --input env=prod

The worker reads the bundle's widget.json and workflow.yaml (from ./apps/<slug>/, or --bundle-dir), builds the inputs from --input pairs or an --inputs JSON file, resolves file inputs to absolute paths, runs the steps, prints each step's events as they stream and returns an exit code. Other systems use exactly this: the InsightTestBench QA bench, for one, runs its test-generation and analysis apps through insightworker app run and reads the event stream.

The scheduler

Schedules live in .insightworker/schedules.yaml in the workspace. Each has a name, a cadence and what to run:

schedules:
  - name: nightly-dag-check
    cron: "15 6 * * 1-5"          # 06:15 on weekdays, local time
    prompt: >
      List the DAGs whose last run failed since yesterday 18:00,
      diagnose each with the dag-run-diagnose skill, and write
      a summary to reports/dag-check.md.
    enabled: true
  - name: hourly-backlog
    every: 1h
    workflow: claims-backlog-report
    enabled: false
  • Cadence is either every: (45s, 30m, 2h30m, 1d, or @hourly, @daily, @weekly) or cron: (a standard cron expression in the machine's local time zone, or TZ if set). Not both.
  • What to run is either a prompt: or a workflow: (a workflow folder in the workspace, whose tasks the agent is asked to run).
  • enabled switches a schedule off without deleting it.

insightworker --daemon starts the scheduler. insightworker schedule list shows what is configured, and insightworker schedule run <name> fires one schedule now, which is the way to test it. Each schedule writes a log to .insightworker/logs/<name>.log with its start, every tool call, errors and the end.

Dry runs

insightworker schedule run --dry-run <name> sets a flag that side-effecting tools check. That covers email: instead of sending, the message opens as a preview in a browser. Other tools run normally in a dry run, so a dry run is not a sandbox.

Unattended means auto-approved. A scheduled run has no one to answer permission prompts, so its tool calls are approved automatically. Decide what a schedule may do by what you put in its prompt or workflow, by the credentials the worker runs with, and by testing it with schedule run before you enable it.

Choosing between them

You needUse
A quick answer inside a script, read by a personOne-shot -c
Typed inputs, step outputs and an exit code for a pipelineHeadless app run
The same check or digest every hour, night or weekdayA schedule, ideally running an app or a tightly scoped prompt

A checklist before enabling a schedule

  1. Write the prompt as an instruction with a defined output (a file, a report path), not a question.
  2. Run it once with schedule run and read the log.
  3. If it sends anything, run it again with --dry-run.
  4. Give the worker's account only the access the schedule needs.
  5. Set enabled: true and start the daemon somewhere that stays up.

Example: a data engineering team's morning DAG check.

Build one app for your team

Bring one repetitive task your team does every week. We will build it with you as an InsightWorker app, on your model provider, and run it from the CLI, a browser or a schedule.

Request a demo