Skip to Content
We are live but in Staging 🎉
DSL ReferenceSteps: Plan, Run, Agent, Ask

Steps: Plan, Run, Agent, Ask

Last validated: 2026-05-14

This page covers high-level orchestration primitives used for dynamic planning, delegated execution, autonomous loops, and human input.

plan

Generates an executable plan artifact (usually via LLM) from task/context inputs.

plan "Generate execution plan" with llm task = task tools = ["file_read", "grep", "shell_exec", "file_write"] context = codebase_summary.text model = "gpt-4o" max_steps = 10 validate = true -> mission

Syntax:

plan "Label" with llm field = expr field2 = expr -> binding

run

Executes a run target by identifier.

run mission -> execution_result

With optional additional inputs:

run mission mode = "safe" retries = 2 -> execution_result

Notes:

  • target is an identifier, not a quoted file path.
  • Typical pattern is plan ... -> mission then run mission.

agent

Runs an autonomous LLM agent loop with configurable inputs.

agent "Deep research agent" with llm system = "You are a thorough research analyst." task = "Research topic: {topic}." tools = ["web_search", "fetch_url"] max_iterations = 8 temperature = 0.4 -> research

Syntax mirrors do/plan input style and supports arbitrary key/value fields.

ask

Pauses for human (or external) response and resumes on submitted input.

ask "Review findings" prompt = "Review the research on {topic}. Approve or reject." options = ["approve", "revise", "reject"] timeout = "2h" max_retries = 2 -> review

Free-form ask:

ask "Enter API key" prompt = "Provide the API key for staging" type = "text" timeout = "1h" -> api_key

Numeric/boolean ask:

ask "Set threshold" prompt = "Enter confidence threshold (0-100)" type = "number" default = 80 -> threshold ask "Enable feature?" prompt = "Enable the experimental feature?" type = "boolean" default = true -> enabled

Access resumed value as binding.value in downstream expressions.

Human-In-The-Loop Pattern

agent "Draft report" with llm task = "Create report for {topic}" -> report ask "Approve report" prompt = "Approve this report?\n\n{report.text}" options = ["approve", "request_changes", "reject"] -> decision decide "Handle decision" with rules when decision.value == "approve" -> "Done" when decision.value == "request_changes" -> "Revise" otherwise -> "Rejected" "Revise": ask "Provide edits" prompt = "What should change?" type = "text" -> edits agent "Revise report" with llm task = "Revise report: {report.text}\nFeedback: {edits.value}" -> revised emit "Revised" result = revised.text "Done": emit "Approved" result = report.text "Rejected": emit "Rejected" result = "Rejected by reviewer"

Practical Guidance

  1. Keep plan outputs bounded (max_steps, validation flags) to avoid unbounded dynamic scripts.
  2. Feed run with validated plan outputs rather than ad-hoc identifiers.
  3. Constrain agent with tool allowlists and iteration caps.
  4. Pair ask with check or decide so every review response has explicit routing.