{
  "kind": "original-bounded-choice-workflow",
  "version": 1,
  "scope": "Classify the response projection returned from a shown server action.",
  "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
  "choices": [
    "Projection",
    "Whole",
    "Noresult",
    "Unclear"
  ],
  "actions": {
    "Projection": {
      "action": "preview_jev_server_return_field_scope",
      "payload": {
        "decision": "Projection"
      },
      "pending": true
    },
    "Whole": {
      "action": "preview_jev_server_return_field_scope",
      "payload": {
        "decision": "Whole"
      },
      "pending": true
    },
    "Noresult": {
      "action": "preview_jev_server_return_field_scope",
      "payload": {
        "decision": "Noresult"
      },
      "pending": true
    },
    "Unclear": {
      "action": "preview_jev_server_return_field_scope",
      "payload": {
        "decision": "Unclear"
      },
      "pending": true
    }
  },
  "samples": [
    {
      "id": "case-1",
      "label": "Small response",
      "expected": "Projection",
      "request": {
        "context": "{\n  \"task\": \"Classify the response projection returned from a shown server action.\",\n  \"evidence\": {\n    \"code\": \"\\\"use server\\\"; const user=await db.user.update({where:{id},data}); return {id:user.id,name:user.name};\"\n  }\n}",
        "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
        "choices": [
          "Projection",
          "Whole",
          "Noresult",
          "Unclear"
        ]
      }
    },
    {
      "id": "case-2",
      "label": "Entire updated row",
      "expected": "Whole",
      "request": {
        "context": "{\n  \"task\": \"Classify the response projection returned from a shown server action.\",\n  \"evidence\": {\n    \"code\": \"\\\"use server\\\"; return await db.user.update({where:{id},data});\",\n    \"context\": \"ORM update returns the full user record\"\n  }\n}",
        "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
        "choices": [
          "Projection",
          "Whole",
          "Noresult",
          "Unclear"
        ]
      }
    },
    {
      "id": "case-3",
      "label": "Database selection",
      "expected": "Projection",
      "request": {
        "context": "{\n  \"task\": \"Classify the response projection returned from a shown server action.\",\n  \"evidence\": {\n    \"code\": \"\\\"use server\\\"; return db.user.findUnique({where:{id},select:{id:true,name:true}});\"\n  }\n}",
        "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
        "choices": [
          "Projection",
          "Whole",
          "Noresult",
          "Unclear"
        ]
      }
    },
    {
      "id": "case-4",
      "label": "No payload",
      "expected": "Noresult",
      "request": {
        "context": "{\n  \"task\": \"Classify the response projection returned from a shown server action.\",\n  \"evidence\": {\n    \"code\": \"\\\"use server\\\"; await saveChange(); return;\"\n  }\n}",
        "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
        "choices": [
          "Projection",
          "Whole",
          "Noresult",
          "Unclear"
        ]
      }
    },
    {
      "id": "case-5",
      "label": "Unknown mapper",
      "expected": "Unclear",
      "request": {
        "context": "{\n  \"task\": \"Classify the response projection returned from a shown server action.\",\n  \"evidence\": {\n    \"code\": \"\\\"use server\\\"; return toClient(user);\",\n    \"helper\": \"toClient implementation unavailable\"\n  }\n}",
        "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
        "choices": [
          "Projection",
          "Whole",
          "Noresult",
          "Unclear"
        ]
      }
    },
    {
      "id": "case-6",
      "label": "Whole public row",
      "expected": "Whole",
      "request": {
        "context": "{\n  \"task\": \"Classify the response projection returned from a shown server action.\",\n  \"evidence\": {\n    \"code\": \"\\\"use server\\\"; return db.color.findUnique({where:{id}});\",\n    \"context\": \"Color row has only id and public displayName; no secret field is claimed\"\n  }\n}",
        "question": "Classify the client return: Projection for explicitly selected fields or a supplied response-mapping contract; Whole for an entire database record with no projection; Noresult when nothing is returned; Unclear when the mapper or record shape is unavailable. Whole identifies a broad boundary, not proof of secret exposure. Inspect the actual returned value rather than a helper name.",
        "choices": [
          "Projection",
          "Whole",
          "Noresult",
          "Unclear"
        ]
      }
    }
  ],
  "consumer": "preview_choice_workflow.py"
}
