{
  "schemaVersion": "1.0",
  "kind": "build",
  "id": "BUILD-001",
  "revision": 1,
  "intent": "Demonstrate a small, testable repair-note use case with complete traceability.",
  "scope": [
    "Add and retrieve a repair note in an in-memory domain prototype.",
    "Reject empty notes without changing existing records."
  ],
  "nonGoals": [
    "Persistence, authentication, UI, deployment and commercial launch."
  ],
  "components": [
    "domain"
  ],
  "constraints": [
    "No external services or personal data."
  ],
  "opportunity": {
    "id": "OP-001",
    "revision": 1,
    "sha256": "7dbf3b4501f5294e1dfd89b32ab758ed1d776b7217b1d9cb8e87deddc55e0d07"
  },
  "decisions": [
    {
      "id": "D-001",
      "text": "Build the scoped in-memory prototype, including rejection of empty notes.",
      "authority": "owner",
      "record": "Fictional example approval; not authorization for a real product."
    }
  ],
  "approvalDecisionId": "D-001",
  "assumptions": [],
  "unknowns": [
    {
      "id": "Q-001",
      "question": "Will a real workshop pay for this?",
      "blocking": false,
      "resolution": null
    }
  ],
  "requirements": [
    {
      "id": "FR-001",
      "statement": "Adding a non-empty repair note returns an ID and preserves its trimmed text for retrieval.",
      "priority": "must",
      "component": "domain",
      "origin": {
        "kind": "evidence",
        "id": "E-001"
      },
      "acceptance": [
        {
          "id": "AC-001",
          "given": "An empty repair log",
          "when": "A note containing surrounding spaces is added",
          "then": "Its returned ID retrieves the trimmed note."
        }
      ],
      "verification": [
        {
          "id": "V-001",
          "acceptanceIds": [
            "AC-001"
          ],
          "layer": "unit",
          "method": "Run repair-log.test.mjs; test adds and retrieves a trimmed note."
        }
      ]
    },
    {
      "id": "FR-002",
      "statement": "An empty or whitespace-only note is rejected without changing the log.",
      "priority": "must",
      "component": "domain",
      "origin": {
        "kind": "decision",
        "id": "D-001"
      },
      "acceptance": [
        {
          "id": "AC-002",
          "given": "A repair log containing one note",
          "when": "An empty or whitespace-only note is added",
          "then": "An error is returned and the existing note remains the only record."
        }
      ],
      "verification": [
        {
          "id": "V-002",
          "acceptanceIds": [
            "AC-002"
          ],
          "layer": "unit",
          "method": "Run repair-log.test.mjs; test rejection and unchanged state."
        }
      ]
    }
  ]
}
