Skip to content

Transaction Example: From Utterance to Execution

Reading map

This Quick Add example uses the original illustrative date, 2026-06-22.

Example: full lifecycle

User says:

Coffee yesterday

Initial draft:

{
  "status": "needs_clarification",
  "transaction": {
    "type": "expense",
    "amount": null,
    "date": "2026-06-22",
    "category": "coffee",
    "note": "coffee"
  },
  "missing_fields": ["amount"],
  "next_action": {
    "type": "ask_user",
    "question": "How much was the coffee?"
  }
}

User says:

4.50

Updated draft:

{
  "status": "enriching",
  "transaction": {
    "type": "expense",
    "amount": 4.50,
    "date": "2026-06-22",
    "category": "coffee",
    "account_id": null
  }
}

Tool fills default account:

{
  "account_id": "default_cash",
  "source": "user_default"
}

Duplicate checker finds similar transaction:

{
  "warnings": [
    {
      "type": "possible_duplicate",
      "similar_transaction_id": "txn_789"
    }
  ]
}

Policy decides:

{
  "status": "ready_for_confirmation",
  "next_action": "show_confirmation",
  "requires_confirmation": true
}

User taps Save.

Executor receives:

{
  "action": "create_transaction",
  "transaction": {
    "type": "expense",
    "amount": 4.50,
    "currency": "USD",
    "date": "2026-06-22",
    "category_id": "coffee",
    "account_id": "default_cash",
    "note": "coffee"
  }
}

Backend writes.


Related: Draft refinement loop ยท Action policy, readiness, and execution gates.

Original text: 02-pipeline.md.