{
 "schema_version": "1.0",
 "nodes": [
  {
   "id": "person",
   "type": "input/image",
   "label": "Person",
   "parameters": {
    "image": "__MODEL__",
    "required": true
   }
  },
  {
   "id": "scenes",
   "type": "input/json_value",
   "label": "Scenes",
   "parameters": {
    "value": [
     {
      "brief": "An autumn coat campaign: the woman of the reference photo sits at a café terrace with a friend, in a camel wool coat, holding a cup; late afternoon.",
      "role": "the woman in the camel wool coat holding a cup"
     },
     {
      "brief": "An autumn coat campaign: the woman of the reference photo walks across a city square at dusk among other people, in a camel wool coat, the lights coming on.",
      "role": "the woman in the camel wool coat walking in the foreground"
     },
     {
      "brief": "An autumn coat campaign: the woman of the reference photo looks at a large painting in an art gallery among other visitors, in a camel wool coat, three-quarter view.",
      "role": "the woman in the camel wool coat looking at the painting"
     }
    ],
    "required": true
   }
  },
  {
   "id": "each",
   "type": "enumerate/json",
   "label": "Each scene",
   "parameters": {
    "jsonConfig": {
     "arrayPath": "(root)",
     "properties": [
      {
       "sourcePath": "brief",
       "outputPort": "brief",
       "outputType": "text",
       "selected": true,
       "label": "Brief"
      },
      {
       "sourcePath": "role",
       "outputPort": "role",
       "outputType": "text",
       "selected": true,
       "label": "Role"
      }
     ]
    },
    "emptyBehavior": "fail"
   }
  },
  {
   "id": "rep",
   "type": "workflow/repeat",
   "label": "Until it is her",
   "parameters": {
    "max_attempts": 3,
    "on_exhausted": "best",
    "workflow": "__BODY__"
   }
  },
  {
   "id": "o_img",
   "type": "output/image",
   "label": "pictures",
   "parameters": {
    "output_name": "pictures"
   }
  },
  {
   "id": "o_disp",
   "type": "output/text",
   "label": "dispositions",
   "parameters": {
    "output_name": "dispositions"
   }
  },
  {
   "id": "o_rep",
   "type": "output/json",
   "label": "reports",
   "parameters": {
    "output_name": "reports"
   }
  }
 ],
 "connections": [
  {
   "from_node": "scenes",
   "from_output": "json",
   "to_node": "each",
   "to_input": "json"
  },
  {
   "from_node": "each",
   "from_output": "brief",
   "to_node": "rep",
   "to_input": "brief"
  },
  {
   "from_node": "each",
   "from_output": "role",
   "to_node": "rep",
   "to_input": "role"
  },
  {
   "from_node": "person",
   "from_output": "image",
   "to_node": "rep",
   "to_input": "person"
  },
  {
   "from_node": "rep",
   "from_output": "candidate",
   "to_node": "o_img",
   "to_input": "image"
  },
  {
   "from_node": "rep",
   "from_output": "disposition",
   "to_node": "o_disp",
   "to_input": "text"
  },
  {
   "from_node": "rep",
   "from_output": "report",
   "to_node": "o_rep",
   "to_input": "json"
  }
 ],
 "layout": {
  "nodes": {
   "person": {
    "x": 80,
    "y": 80
   },
   "scenes": {
    "x": 80,
    "y": 280
   },
   "each": {
    "x": 420,
    "y": 80
   },
   "rep": {
    "x": 760,
    "y": 80
   },
   "o_img": {
    "x": 1100,
    "y": 80
   },
   "o_disp": {
    "x": 1100,
    "y": 280
   },
   "o_rep": {
    "x": 1100,
    "y": 480
   }
  }
 }
}
