Skip to content
ttorta docs

API Reference

The workflow schema

The workflow block in torta.json, key by key, with the shipped defaults.


The workflow block in torta.json is the contract the linters, the board, the engine and the generators all read.

Anything you do not state is taken from the defaults. Run torta sync after editing to regenerate the walls and the briefs.

The shape

{
  "workflow": {
    "types": [],
    "filename": {},
    "frontmatterRequired": [],
    "budgets": {},
    "sections": {},
    "maxLines": 300,
    "statuses": [],
    "dispatch": {},
    "sessionBudgets": {},
    "style": {},
    "presets": {}
  }
}

types

The ticket types. Default:

["feature", "fix", "chore", "refactor", "adhoc", "epic", "hotfix"]

filename

{
  "pattern": "^([a-z]+)\\.([a-z0-9]+(?:-[a-z0-9]+){2})\\.([A-Z_]+)\\.md$",
  "shape": "<type>.<three-word-name>.<STATUS>.md"
}

The complaint, verbatim:

filename must be <type>.<three-word-name>.<STATUS>.md, all lowercase except the status — the assignee belongs in frontmatter, not here

frontmatterRequired

Every field a ticket has to carry. Default:

["status", "project", "type", "title", "assignee", "author", "date", "repo"]

budgets

Section name to maximum lines, counted from the heading to the line before the next heading. The shipped budgets:

Section Lines Section Lines
User story 3 Report 20
Defect 6 History 40
What and why 3 Review 12
Behaviour that must not change 5 Backend validation 12
Acceptance criteria 10 Frontend validation 12
Motivation 5 Growth validation 12
Proposed change 25 Product alignment 12
Impact and risks 8 QA alignment 12
Verification 15 Blocked 12
Sprint scope 15 QA 12
Out of scope 5 Measurement 12
Notes 10 Deploy 12
Spec 12 Code drop 12

sections

The required authoring sections per type, in order.

Type Sections
feature User story, Acceptance criteria, Motivation, Proposed change, Impact and risks, Verification
fix and hotfix Defect, Acceptance criteria, Proposed change, Impact and risks, Verification
chore, refactor, adhoc What and why, Behaviour that must not change, Proposed change, Impact and risks, Verification
epic What and why, Sprint scope

maxLines

300, with ## History excluded from the count.

statuses

Each entry carries status, name, assignee, note, next, stage and placed_by. next is a list of { status, when }, where when is the condition the board shows.

assignee is a role reference: $gate, $assignee, $author, $sprint_home, $front_door, $acceptance or $walls. Which agent fills each role comes from the preset.

Two optional keys turn a transition into a question for the user: userFacing: true, and prompt, the exact sentence the needs-you lane shows.

The 22 shipped statuses:

Status Means Holder May become Asks you
SPEC Cut from an approved plan, awaiting the gate $gate APPROVED, RE_SPEC yes
RE_SPEC Spec sent back for more detail $sprint_home SPEC
REVIEW Awaiting the gate’s verdict $gate APPROVED, REDO yes
APPROVED Cleared to build $assignee WIP
REDO Proposal sent back $author REVIEW
WIP Implementation in progress $assignee CODE_REVIEW, BLOCKED, DONE
BLOCKED Hard constraint hit mid-build $gate NOT_FEASIBLE, APPROVED yes
NOT_FEASIBLE Constraint confirmed $front_door REVIEW, DONE yes
CODE_REVIEW PR open, awaiting review $gate FOR_QA, FOR_DEPLOY, CODE_DROP_FAIL, REQUEST_CHANGE, DONE
REQUEST_CHANGE Changes requested on the PR $assignee CODE_REVIEW
FOR_QA Merged into the sprint branch, awaiting acceptance test $acceptance STG, REOPEN
REOPEN Failed acceptance on the sprint branch $assignee WIP
STG In staging, accepted, waiting for the drop $walls DEPLOYED
CODE_DROP Code drop called, staging to production $walls CODE_REVIEW
CODE_DROP_FAIL The repo-wide suite failed on the drop PR $acceptance CODE_REVIEW, REQUEST_CHANGE
FOR_DEPLOY Drop PR approved, cleared to ship $walls DEPLOYED yes
DEPLOYED Shipped and verified live $gate FOR_MEASURE
DONE Finished with nothing to deploy
FOR_MEASURE Live, waiting on data $front_door MEASURED
MEASURED Bet settled, validated or invalidated $front_door
OPEN Sprint open $sprint_home CLOSED
CLOSED Sprint closed

RE_SPEC and REDO both increment redo_count. The third one halts the ticket and notifies the user.

dispatch

{
  "maxConcurrent": 3,
  "staleLockMs": 120000,
  "cooldownMs": 60000,
  "sweepMs": 15000,
  "killPollMs": 1000,
  "priorityTypes": ["hotfix"]
}

See how agents are dispatched.

sessionBudgets

{
  "wallClockMs": 1800000,
  "tokens": 200000,
  "toolCalls": 200,
  "continuations": 8
}

See budgets and leases.

presets

Preset Agents Roles
solo archi, product, frontend, backend, growth gate: archi, front door: product, walls: archi, digest: archi
full-team archi, product, qa, frontend, backend, growth, infra, pm gate: archi, front door: product, sprint home: pm, walls: infra, acceptance: qa, digest: archi

A part no agent fills takes its statuses with it.

style

The house rules the prose and commit linters read, on a page of their own.