Operating system set to macOS
Documentation jurisdiction set to United States
Sign inConnect Claude
API/schemas
Schema

AgentRunStepDefinition

Agent-run step β€” runs the FULL agentic loop (``WorkstreamV4Executor``) as one node in the declarative WDL step-DAG ("Autopilot"). Distinct from ``archie_query`` (a single orchestrator query that bypasses the verifier): an ``agent_run`` step works MULTI-TURN with a tool allowlist + declared deliverables until it is done or a budget cap is hit. Runs ``RunMode.AUTO_RUN`` by default (no per-step approval); interruptible via the cycle's pause/resume/cancel signals BETWEEN steps + the budget caps WITHIN the step (the workflow cannot pause mid-activity). The DB ``step_kind`` enum already carries ``agent_run`` (migration 20260601_0220).

FieldTypeDescription
idrequiredstringβ€”
namerequiredstringβ€”
typestringβ€”
descriptionstring | nullβ€”
depends_onstring | object[]β€”
stagestring | nullβ€”
timeoutstring | nullβ€”
retry_policyRetryPolicy | nullβ€”
error_handlerStepErrorHandler | nullβ€”
emit_artifactEmitArtifactSpec | nullβ€”
optionalbooleanβ€”
continue_on_errorbooleanβ€”
halt_conditionsHaltCondition[]β€”
item shape
parametersStepParameter[]β€”
item shape
guardsStepGuard[]β€”
item shape
impact_level"low" | "medium" | "high" | "critical"Impact classification for steps.
lowmediumhighcritical
run_mode"propose" | "auto_run"Execution mode for steps.
proposeauto_run
requires_approvalbooleanβ€”
metadataobject | nullβ€”
examplesStepExample[] | nullAttached example files for this step. Each entry pairs a platform.file_uploads.file_id with a role + tags + notes so the runtime can shape its instruction. Bounded at 20 to keep a reasonable upper limit on the prompt preamble.
applies_whenstring | nullCEL predicate evaluated at MATERIALIZATION (not at step execution): the step is marked skipped when it evaluates False. Stored verbatim β€” the expression is parsed by celpy at launch, so any coercion here would change its meaning.
tagsstring[] | nullCategorical labels on the step itself (e.g. 'pdf-read', 'coutts', 'fy25'). Free-form; recommended tag set is documented per workstream surface.
firm_question_codesstring[] | nullBlocker codes this step may raise that are questions the run asks the firm later, not reasons to stop. A code listed here is carried past the blocker barrier (and recorded on the run's carried_blockers) unless the resolution form refuses it. Matched exactly against the blocker codes this step itself raises; a code not listed here still stops the run.
decidesanytreatment | classification | difference, when the step decides one
domain_questionany{domain, issue}: the domain question asked
no_domain_reasonany{reason, card_link}: no domain covers it
goalrequiredstringNatural-language objective for the agentic loop (Jinja2-templated).
domainstringAccounting/domain knowledge key carried into the agent executor.
client_idstring | nullClient identifier; may be a Jinja2 binding such as {{ inputs.client_id }}.
contextobjectTyped WorkPlan/client context, recursively Jinja2-rendered at execution.
show nested
Empty object.
model_rolestring | nullLogical runtime-model role (for example accounting_review), never a provider or concrete model id. Resolved by the central routing policy.
toolsstring[] | nullTool allowlist for the agent, passed to build_tool_router(allowed_tools=…). None = all cycle tools.
deliverablesobject[] | nullDeclared deliverables (name + type [+ description/schema]) the agent must produce.
max_turnsintegerTool-loop turn cap β€” the in-step interruptibility bound.
max_cost_usdnumberCost budget cap in USD.
max_duration_minutesintegerWall-clock cap in minutes.
source_tracingbooleanRequire the agent loop's outputs to retain source tracing.
human_checkpointsstring[]Named checkpoints enforced by the agent guardrail contract.
inputsobject | nullOptional Jinja2 input bindings ({{ inputs.* }} / {{ outputs.* }}).
expected_outputsobject[] | nullOutput schema hints for DAG threading (name + type per entry).