{
  "title": "Director Action Update Context",
  "id": "9f6a86d4-4a5c-45aa-b6b9-e4e16c2c2a7d",
  "properties": {
    "name": "update_context",
    "description": "Instruct another agent to make changes to the story context:\n\n- World entries (add, update, remove)\n- Historical entries (add, update. remove)\n- Existing characters (attributes, details, description, acting instructions, example dialogue, scene entry / exit)\n- Create new characters\n- Story Configuration (Title, Description, Introduction, Content Classification, Story Intention, Scene Intention, Scene Type)\n- Contextual Pins (add, update, remove pins of world entries)\n\nIMPORTANT: \n- Changes to existing context: you MUST ALWAYS provide the specific Context ID of the entry you wish to affect. If you do not have the context ID, retrieve it first by querying for the information. Context IDs must be fenced in backticks (`)  E.g., `context_type:path.id`\n- Creating new context: You cannot decide its Context ID, it will be automatically created as part of the process.\n- New characters: Specify whether they need to immediately participate in the scene (e.g., be activated) or not. If yes also provide instructions on how they enter the scene.\n- Activating or deactivating an existing character's scene participation: if the character's exit or entry has not yet been narrated, also provide instructions on how to narrate their exit or entry.\n- Historical entries are special static context items that have a specific time period attached. When create new static history you must always explicitly state how long ago the event took place.",
    "instructions": "Instruct another agent to make changes to the World, Characters, History or Story configuration. Changes can mean updates, creations or removals.",
    "example_json": "[\n  {\n    \"instructions\": \"Create Thornwick the Wise, an ancient dragon who has been sleeping in the Crystal Caverns for centuries. He has emerald scales, golden eyes, and vast knowledge of forgotten magic. He's cautious but curious about the modern world. He should not be active in the scene at this point.\"\n  },\n  {\n    \"instructions\": \"Update the story intention to be more specific about the expected story's mature content.\"\n  },\n  {\n    \"instructions\": \"Add a new world entry for the Crystal Caverns. Describe the caverns as a magical place with ancient magic and hidden treasures.\"\n  }\n]"
  },
  "x": 0,
  "y": 0,
  "width": 200,
  "height": 100,
  "collapsed": false,
  "inherited": false,
  "registry": "agents/director/chat/directorActionUpdateContext",
  "nodes": {
    "72e91871-5a49-4611-b902-d2e0c3cb0c46": {
      "title": "Validate Value Is Set",
      "id": "72e91871-5a49-4611-b902-d2e0c3cb0c46",
      "properties": {
        "error_message": "`instructions` is required",
        "blank_string_is_unset": true
      },
      "x": 347,
      "y": 76,
      "width": 275,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "validation/ValidateValueIsSet",
      "base_type": "core/Node"
    },
    "817effe3-19d2-44f8-b65b-a20dcb69cf4d": {
      "title": "SET local.instructions",
      "id": "817effe3-19d2-44f8-b65b-a20dcb69cf4d",
      "properties": {
        "name": "instructions",
        "scope": "local"
      },
      "x": 657,
      "y": 76,
      "width": 210,
      "height": 122,
      "collapsed": false,
      "inherited": false,
      "registry": "state/SetState",
      "base_type": "core/Node"
    },
    "75b77137-3f1d-4578-978c-1560efb7a5cf": {
      "title": "Stage 0",
      "id": "75b77137-3f1d-4578-978c-1560efb7a5cf",
      "properties": {
        "stage": 0
      },
      "x": 887,
      "y": 76,
      "width": 210,
      "height": 118,
      "collapsed": false,
      "inherited": false,
      "registry": "core/Stage",
      "base_type": "core/Node"
    },
    "b1546ad2-2f69-45ff-8ad2-444a14d7f160": {
      "title": "summarizer",
      "id": "b1546ad2-2f69-45ff-8ad2-444a14d7f160",
      "properties": {
        "agent_name": "summarizer"
      },
      "x": 804,
      "y": 436,
      "width": 210,
      "height": 58,
      "collapsed": true,
      "inherited": false,
      "registry": "agents/GetAgent",
      "base_type": "core/Node"
    },
    "00fc7caa-7893-4a8a-b05a-3b552ac4a205": {
      "title": "instructions",
      "id": "00fc7caa-7893-4a8a-b05a-3b552ac4a205",
      "properties": {
        "name": "instructions",
        "typ": "str",
        "instructions": "Concrete, actionable and concise instructions to the agent on what character changes need to be done."
      },
      "x": -1993,
      "y": 323,
      "width": 210,
      "height": 106,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Argument",
      "base_type": "core/Node"
    },
    "f02f1a29-e2c0-4222-ac45-0afae1805cdf": {
      "title": "instructions",
      "id": "f02f1a29-e2c0-4222-ac45-0afae1805cdf",
      "properties": {
        "name": "instructions",
        "typ": "str",
        "instructions": "Concrete, actionable and concise instructions to the agent on what world information changes need to be done."
      },
      "x": -1677,
      "y": 564,
      "width": 210,
      "height": 106,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Argument",
      "base_type": "core/Node"
    },
    "c461d53e-a776-472b-9e66-44b687fd32ad": {
      "title": "Return",
      "id": "c461d53e-a776-472b-9e66-44b687fd32ad",
      "properties": {},
      "x": -798,
      "y": 588,
      "width": 140,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/Return",
      "base_type": "core/Node"
    },
    "a5a15864-d09e-4d15-b1ca-9adc75d3c4be": {
      "title": "DEF world_changes",
      "id": "a5a15864-d09e-4d15-b1ca-9adc75d3c4be",
      "properties": {
        "name": "world_changes"
      },
      "x": -228,
      "y": 598,
      "width": 210,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/DefineFunction",
      "base_type": "core/Node"
    },
    "317254b6-33c8-445f-8431-a072c3b33f00": {
      "title": "FN character_changes",
      "id": "317254b6-33c8-445f-8431-a072c3b33f00",
      "properties": {
        "name": "character_changes"
      },
      "x": 643,
      "y": 1535,
      "width": 211,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/GetFunction",
      "base_type": "core/Node"
    },
    "cfaec2dd-2c88-4087-8678-43cadd6c3226": {
      "title": "AI Function Callback",
      "id": "cfaec2dd-2c88-4087-8678-43cadd6c3226",
      "properties": {
        "name": "my_function",
        "allow_multiple_calls": true
      },
      "x": 909,
      "y": 1535,
      "width": 214,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Callback",
      "base_type": "core/Node"
    },
    "b90a792b-638e-45c3-9e33-c4951efbd76e": {
      "title": "AI Function Callback",
      "id": "b90a792b-638e-45c3-9e33-c4951efbd76e",
      "properties": {
        "name": "my_function",
        "allow_multiple_calls": true
      },
      "x": 913,
      "y": 1705,
      "width": 214,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Callback",
      "base_type": "core/Node"
    },
    "551a7a88-45ed-42d7-96c0-903fd79b2f79": {
      "title": "FN world_changes",
      "id": "551a7a88-45ed-42d7-96c0-903fd79b2f79",
      "properties": {
        "name": "world_changes"
      },
      "x": 643,
      "y": 1705,
      "width": 211,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/GetFunction",
      "base_type": "core/Node"
    },
    "d4ae9150-4cfc-4c98-a530-d903d8468afc": {
      "title": "FN character_changes",
      "id": "d4ae9150-4cfc-4c98-a530-d903d8468afc",
      "properties": {
        "name": "story_config_changes"
      },
      "x": 636,
      "y": 1878,
      "width": 211,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/GetFunction",
      "base_type": "core/Node"
    },
    "90f46116-2451-4769-994b-cf60488b1880": {
      "title": "Stage 1",
      "id": "90f46116-2451-4769-994b-cf60488b1880",
      "properties": {
        "stage": 1
      },
      "x": 2269,
      "y": 1376,
      "width": 210,
      "height": 118,
      "collapsed": false,
      "inherited": false,
      "registry": "core/Stage",
      "base_type": "core/Node"
    },
    "190656df-de95-4129-8076-2ff3e8eedd5b": {
      "title": "GET local.focal_calls",
      "id": "190656df-de95-4129-8076-2ff3e8eedd5b",
      "properties": {
        "name": "focal_calls",
        "scope": "local"
      },
      "x": 1151,
      "y": 1,
      "width": 210,
      "height": 122,
      "collapsed": false,
      "inherited": false,
      "registry": "state/GetState",
      "base_type": "core/Node"
    },
    "f5e3af1d-3da3-4813-b89d-a719384c79ae": {
      "title": "AI Function Calling",
      "id": "f5e3af1d-3da3-4813-b89d-a719384c79ae",
      "properties": {
        "template": null,
        "max_calls": 8,
        "retries": 0,
        "response_length": 4096
      },
      "x": 1579,
      "y": 1276,
      "width": 210,
      "height": 250,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Focal",
      "base_type": "core/Node"
    },
    "2553322b-eef6-4438-8d5b-f2fda099055c": {
      "title": "DEF character_changes",
      "id": "2553322b-eef6-4438-8d5b-f2fda099055c",
      "properties": {
        "name": "character_changes"
      },
      "x": -237,
      "y": 369,
      "width": 210,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/DefineFunction",
      "base_type": "core/Node"
    },
    "70e39dcd-7c5b-4e27-acd2-7cd305247484": {
      "title": "Validate Value Is Set",
      "id": "70e39dcd-7c5b-4e27-acd2-7cd305247484",
      "properties": {
        "error_message": "`instructions` is required",
        "blank_string_is_unset": true
      },
      "x": -1743,
      "y": 323,
      "width": 275,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "validation/ValidateValueIsSet",
      "base_type": "core/Node"
    },
    "a8581ffe-c27f-4767-a993-19d4d0b3d373": {
      "title": "true",
      "id": "a8581ffe-c27f-4767-a993-19d4d0b3d373",
      "properties": {
        "value": true
      },
      "x": -1437,
      "y": 309,
      "width": 210,
      "height": 58,
      "collapsed": true,
      "inherited": false,
      "registry": "core/MakeBool",
      "base_type": "core/Node"
    },
    "27afad53-fa02-46ea-99d4-41460f3ca4f7": {
      "title": "Instruct Character Changes",
      "id": "27afad53-fa02-46ea-99d4-41460f3ca4f7",
      "properties": {},
      "x": -1247,
      "y": 359,
      "width": 218,
      "height": 66,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/instructCharacterChanges",
      "base_type": "core/Graph"
    },
    "aa235b82-365d-4ed0-89ad-c45fbe100a13": {
      "title": "Return",
      "id": "aa235b82-365d-4ed0-89ad-c45fbe100a13",
      "properties": {},
      "x": -917,
      "y": 379,
      "width": 140,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/Return",
      "base_type": "core/Node"
    },
    "03837765-6b28-4919-8b0e-02899afe1a74": {
      "title": "Return",
      "id": "03837765-6b28-4919-8b0e-02899afe1a74",
      "properties": {},
      "x": -829,
      "y": 913,
      "width": 140,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/Return",
      "base_type": "core/Node"
    },
    "e0e1c161-eafd-4162-8ec8-57f205bb5c59": {
      "title": "Validate Value Is Set",
      "id": "e0e1c161-eafd-4162-8ec8-57f205bb5c59",
      "properties": {
        "error_message": "`instructions` is required",
        "blank_string_is_unset": true
      },
      "x": -1497,
      "y": 868,
      "width": 275,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "validation/ValidateValueIsSet",
      "base_type": "core/Node"
    },
    "fdecbd55-ee35-4d79-bad7-b7d9521714c0": {
      "title": "Instruct Story Config Updates",
      "id": "fdecbd55-ee35-4d79-bad7-b7d9521714c0",
      "properties": {},
      "x": -1146,
      "y": 897,
      "width": 244,
      "height": 46,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/instructStoryConfigUpdates",
      "base_type": "core/Graph"
    },
    "9a5c222d-7b60-4d7c-88a1-303d43b4b851": {
      "title": "DEF story_config_changes",
      "id": "9a5c222d-7b60-4d7c-88a1-303d43b4b851",
      "properties": {
        "name": "story_config_changes"
      },
      "x": -236,
      "y": 917,
      "width": 210,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/DefineFunction",
      "base_type": "core/Node"
    },
    "ecbb3078-18ae-44ca-9302-c2957dd4302e": {
      "title": "Validate Value Is Set",
      "id": "ecbb3078-18ae-44ca-9302-c2957dd4302e",
      "properties": {
        "error_message": "`instructions` is required",
        "blank_string_is_unset": true
      },
      "x": -1427,
      "y": 564,
      "width": 275,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "validation/ValidateValueIsSet",
      "base_type": "core/Node"
    },
    "b0f49779-a569-4704-9b07-d48ad5e2bab4": {
      "title": "instructions",
      "id": "b0f49779-a569-4704-9b07-d48ad5e2bab4",
      "properties": {
        "name": "instructions",
        "typ": "str",
        "instructions": "Concrete, actionable and concise instructions to the agent on what story configuration changes need to be done."
      },
      "x": -1747,
      "y": 868,
      "width": 210,
      "height": 106,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Argument",
      "base_type": "core/Node"
    },
    "6d97ea03-8c1d-40ca-ad3c-50f84d47c504": {
      "title": "AI Function Callback Metadata",
      "id": "6d97ea03-8c1d-40ca-ad3c-50f84d47c504",
      "properties": {
        "instructions": "Changes to story configuration must go to the `story_config_changes` function.\n\n- Story introductory text changes\n- Story intention changes\n- Current scene intention and type changes\n- Scene type creation / deletion / updates\n- Activate or deactivate permanent context pins (via Context ID)",
        "examples": [
          {
            "instructions": "Modify the current scene intention to transition from tense negotiation to action sequence as the bomb timer reaches its final minutes."
          },
          {
            "instructions": "Activate a pin for `world_entry.manual:c578f00dd1a9` as its currently very relevant to the scene."
          }
        ]
      },
      "x": -640,
      "y": 910,
      "width": 314,
      "height": 82,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Metadata",
      "base_type": "core/Node"
    },
    "0d840e2b-0edc-46a7-b587-120c32c51bc1": {
      "title": "SET local.focal_calls",
      "id": "0d840e2b-0edc-46a7-b587-120c32c51bc1",
      "properties": {
        "name": "focal_calls",
        "scope": "local"
      },
      "x": 1913,
      "y": 1346,
      "width": 210,
      "height": 122,
      "collapsed": false,
      "inherited": false,
      "registry": "state/SetState",
      "base_type": "core/Node"
    },
    "1eb0f232-2ddd-4cc6-9315-887222d4e01d": {
      "title": "true",
      "id": "1eb0f232-2ddd-4cc6-9315-887222d4e01d",
      "properties": {
        "value": true
      },
      "x": 894,
      "y": 386,
      "width": 210,
      "height": 58,
      "collapsed": true,
      "inherited": false,
      "registry": "core/MakeBool",
      "base_type": "core/Node"
    },
    "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b": {
      "title": "Build Prompt",
      "id": "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b",
      "properties": {
        "template_file": "base",
        "scope": "common",
        "instructions": "",
        "reserved_tokens": 312,
        "limit_max_tokens": 0,
        "include_scene_intent": true,
        "include_extra_context": false,
        "include_memory_context": false,
        "include_scene_context": false,
        "include_character_context": false,
        "include_gamestate_context": false,
        "memory_prompt": "",
        "prefill_prompt": "ANALYSIS:",
        "return_prefill_prompt": false,
        "dedupe_enabled": true,
        "response_length": 0,
        "technical": true
      },
      "x": 1035,
      "y": 576,
      "width": 304,
      "height": 542,
      "collapsed": false,
      "inherited": false,
      "registry": "prompt/BuildPrompt",
      "base_type": "core/Node"
    },
    "d1f38cd6-653e-4dd5-a377-eb68e6ae98bd": {
      "title": "List Collector",
      "id": "d1f38cd6-653e-4dd5-a377-eb68e6ae98bd",
      "properties": {},
      "x": 700,
      "y": 740,
      "width": 140,
      "height": 81,
      "collapsed": false,
      "inherited": false,
      "registry": "data/ListCollector",
      "dynamic_inputs": [
        {
          "name": "item0",
          "type": "*"
        }
      ],
      "base_type": "core/DynamicSocketNodeBase"
    },
    "1d5c1854-9c40-40bb-9521-16b944baaef5": {
      "title": "GET local.instructions",
      "id": "1d5c1854-9c40-40bb-9521-16b944baaef5",
      "properties": {
        "name": "instructions",
        "scope": "local"
      },
      "x": 30,
      "y": 312,
      "width": 210,
      "height": 122,
      "collapsed": false,
      "inherited": false,
      "registry": "state/GetState",
      "base_type": "core/Node"
    },
    "8de5c510-bafa-44f7-975c-085cfa06b476": {
      "title": "Scan Context IDs",
      "id": "8de5c510-bafa-44f7-975c-085cfa06b476",
      "properties": {
        "header": "Relevant Context",
        "display_mode": "compact"
      },
      "x": 390,
      "y": 710,
      "width": 210,
      "height": 142,
      "collapsed": false,
      "inherited": false,
      "registry": "context_id/ScanContextIDs",
      "base_type": "core/Node"
    },
    "121604ad-680e-4304-97ce-30139b001370": {
      "title": "AI Function Callback Metadata",
      "id": "121604ad-680e-4304-97ce-30139b001370",
      "properties": {
        "instructions": "Any character specific changes go to this function.\n\n- Character Creation\n- Character attribute changes\n- Character description changes\n- Character detail changes\n- Character name changes\n- Character UX color changes\n- Character voice assignment changes\n- Deactivation / Activation of a character\n- Dialogue examples for a character\n- Acting instructions for a character",
        "examples": [
          {
            "instructions": "Create a new character named Lyra Moonwhisper, a 150-year-old elven mage with silver hair and ancient knowledge of forbidden spells. Make her active in the current scene."
          },
          {
            "instructions": "Update Commander Zara's personality attribute to show that her experiences with the alien parasites have made her more paranoid and suspicious of her crew."
          },
          {
            "instructions": "Change Dr. Chen's character voice assignment from the current narrator to 'Sarah (Neural)' to give her a more clinical and professional speaking style."
          },
          {
            "instructions": "Deactivate Detective Morgan from the current scene. Have him excuse himself to take an important phone call from the chief, leaving through the office door."
          }
        ]
      },
      "x": -667,
      "y": 369,
      "width": 314,
      "height": 82,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Metadata",
      "base_type": "core/Node"
    },
    "0f0ac6d7-4518-4b06-9b37-8f275ed84b97": {
      "title": "Return",
      "id": "0f0ac6d7-4518-4b06-9b37-8f275ed84b97",
      "properties": {},
      "x": -805,
      "y": 1122,
      "width": 140,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/Return",
      "base_type": "core/Node"
    },
    "ac358170-8123-407e-aa2e-1e95eb9356cf": {
      "title": "Validate Value Is Set",
      "id": "ac358170-8123-407e-aa2e-1e95eb9356cf",
      "properties": {
        "error_message": "`instructions` is required",
        "blank_string_is_unset": true
      },
      "x": -1434,
      "y": 1098,
      "width": 275,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "validation/ValidateValueIsSet",
      "base_type": "core/Node"
    },
    "ef0ddd3b-23af-4170-a532-f6561750f073": {
      "title": "Instruct History Updates",
      "id": "ef0ddd3b-23af-4170-a532-f6561750f073",
      "properties": {},
      "x": -1087,
      "y": 1118,
      "width": 212,
      "height": 66,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/instructHistoryUpdates",
      "base_type": "core/Graph"
    },
    "96bd24d6-40e0-4d5a-af5f-ceff530a83ac": {
      "title": "Instruct World Updates",
      "id": "96bd24d6-40e0-4d5a-af5f-ceff530a83ac",
      "properties": {},
      "x": -1070,
      "y": 600,
      "width": 212,
      "height": 66,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/instructWorldUpdates",
      "base_type": "core/Graph"
    },
    "5f46d8d6-18e0-4f88-8f3d-84861e76a8a5": {
      "title": "AI Function Callback Metadata",
      "id": "5f46d8d6-18e0-4f88-8f3d-84861e76a8a5",
      "properties": {
        "instructions": "Changes to world entries must go to the `world_changes` function.\n\n- World entry creation / deletion / updates\n\nIMPORTANT: This cannot be used for static history entries, which are a special kind of context.",
        "examples": [
          {
            "instructions": "Create a new world entry called 'The Crystal Caverns of Eldereth' describing the magical underground chambers where ancient dragons once hoarded their treasures."
          },
          {
            "instructions": "Update the existing world entry 'Mars Colony Beta-7' to include information about the recent discovery of underground water deposits and the new mining operations."
          },
          {
            "instructions": "Add a new history entry showing that two years ago, Emma and her mother had a big fight about Emma's decision to drop out of college."
          },
          {
            "instructions": "Delete the world entry 'Haunted Mansion on Hill Street' as the supernatural elements are being removed from the story."
          }
        ]
      },
      "x": -598,
      "y": 598,
      "width": 314,
      "height": 82,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Metadata",
      "base_type": "core/Node"
    },
    "0f7404fb-d63c-409b-bec6-a0a291303a28": {
      "title": "instructions",
      "id": "0f7404fb-d63c-409b-bec6-a0a291303a28",
      "properties": {
        "name": "instructions",
        "typ": "str",
        "instructions": "Concrete, actionable and concise instructions to the agent on what static history information changes need to be done."
      },
      "x": -1684,
      "y": 1098,
      "width": 210,
      "height": 106,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Argument",
      "base_type": "core/Node"
    },
    "9c4ba59c-e6d9-4679-93ac-bf0e6ea03611": {
      "title": "AI Function Callback Metadata",
      "id": "9c4ba59c-e6d9-4679-93ac-bf0e6ea03611",
      "properties": {
        "instructions": "Changes to static history entries must go to the history_changes function.",
        "examples": [
          {
            "instructions": "Create a new static history entry for 1 week ago that describes how Jenna and Rob met at the birthday party"
          },
          {
            "instructions": "Remove the static history entry that states Richard fought a dragon and one. Context ID: `history_entry.static:3d4a2dfc`"
          },
          {
            "instructions": "Change the static history entry `history_entry.static:3d4a2dfc` - keep it as is but add that they went to the game afterwards."
          }
        ]
      },
      "x": -607,
      "y": 1118,
      "width": 314,
      "height": 82,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Metadata",
      "base_type": "core/Node"
    },
    "8af4646a-93a6-4ae0-ab5a-6dde4b44d7d1": {
      "title": "DEF history_changes",
      "id": "8af4646a-93a6-4ae0-ab5a-6dde4b44d7d1",
      "properties": {
        "name": "history_changes"
      },
      "x": -237,
      "y": 1118,
      "width": 210,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/DefineFunction",
      "base_type": "core/Node"
    },
    "08501b57-40ad-4060-aa1e-e4b511f4bdef": {
      "title": "Director Action Summary",
      "id": "08501b57-40ad-4060-aa1e-e4b511f4bdef",
      "properties": {},
      "x": 1441,
      "y": 51,
      "width": 193,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/directorActionSummary",
      "base_type": "core/Graph"
    },
    "859a4fe6-4693-4e6d-a841-7e9b378615fe": {
      "title": "Emit World Editor Sync",
      "id": "859a4fe6-4693-4e6d-a841-7e9b378615fe",
      "properties": {},
      "x": 1670,
      "y": 53,
      "width": 185,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "event/EmitWorldEditorSync",
      "base_type": "core/Node"
    },
    "6548308d-cf77-4322-9494-93b0ebb99551": {
      "title": "Return",
      "id": "6548308d-cf77-4322-9494-93b0ebb99551",
      "properties": {},
      "x": 1910,
      "y": 53,
      "width": 140,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/Return",
      "base_type": "core/Node"
    },
    "f76f3f64-af89-4c8c-80ae-6ff95ead4dc6": {
      "title": "Stage 999",
      "id": "f76f3f64-af89-4c8c-80ae-6ff95ead4dc6",
      "properties": {
        "stage": 999
      },
      "x": 2100,
      "y": 83,
      "width": 210,
      "height": 118,
      "collapsed": true,
      "inherited": false,
      "registry": "core/Stage",
      "base_type": "core/Node"
    },
    "ee07c367-b4da-46fd-b8a2-f12df134c52f": {
      "title": "Context ID Meta Entries",
      "id": "ee07c367-b4da-46fd-b8a2-f12df134c52f",
      "properties": {
        "filter_creative": true
      },
      "x": 390,
      "y": 580,
      "width": 210,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "context_id/ContextIDMetaEntries",
      "base_type": "core/Node"
    },
    "078e4097-1e13-400f-9dbf-02a447a2b353": {
      "title": "Make List",
      "id": "078e4097-1e13-400f-9dbf-02a447a2b353",
      "properties": {
        "item_type": "any",
        "items": [
          "story_configuration:title",
          "story_configuration:description",
          "story_configuration:content_classification"
        ]
      },
      "x": 130,
      "y": 960,
      "width": 210,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "data/MakeList",
      "base_type": "core/Node"
    },
    "0aa0a2ff-2395-4a04-a01e-10cc7a73dfaa": {
      "title": "Make Key-Value Pair",
      "id": "0aa0a2ff-2395-4a04-a01e-10cc7a73dfaa",
      "properties": {
        "key": "allowed_for_direct_update",
        "value": ""
      },
      "x": 390,
      "y": 940,
      "width": 210,
      "height": 122,
      "collapsed": false,
      "inherited": false,
      "registry": "data/MakeKeyValuePair",
      "base_type": "core/Node"
    },
    "b62ffa05-640b-4de1-a71f-fa8b265a80e3": {
      "title": "Jinja2 Format",
      "id": "b62ffa05-640b-4de1-a71f-fa8b265a80e3",
      "properties": {
        "template": "Analyze the instruction and route it to the appropriate function(s).\n\nYour only task is to route these instructions to the appropriate handler(s). \n\nYou MUST NOT embelish the instructions with new information.\n\n{% if context_id_items %}\n{% set target=context_id_items[0] %}\nYou have been given a specific context ID to update: `{{ target.context_id }}`.\nYou MUST pass along this context ID in your instructions.\n{% if target.context_id.context_type in context_id_types and target.context_id.__str__() not in allowed_for_direct_update -%}\nYOU MUST NOT USE THE `direct_context_update` FUNCTION HERE.\n{%- endif %}\n{% endif %}\n\nINSTRUCTIONS:\n```\n{{ instructions }}\n```"
      },
      "x": 670,
      "y": 490,
      "width": 210,
      "height": 193,
      "collapsed": false,
      "inherited": false,
      "registry": "prompt/Jinja2Format",
      "dynamic_inputs": [
        {
          "name": "item0",
          "type": "*"
        },
        {
          "name": "item1",
          "type": "*"
        },
        {
          "name": "item2",
          "type": "*"
        },
        {
          "name": "item3",
          "type": "*"
        }
      ],
      "base_type": "core/DynamicSocketNodeBase"
    },
    "3133d7af-2321-4deb-85c9-8a2a40f9020c": {
      "title": "instructions",
      "id": "3133d7af-2321-4deb-85c9-8a2a40f9020c",
      "properties": {
        "name": "instructions",
        "typ": "str",
        "instructions": "Concrete, actionable and concise instructions to the agent on what needs to be done."
      },
      "x": 20,
      "y": 70,
      "width": 292,
      "height": 106,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/ActionArgument",
      "base_type": "core/Node"
    },
    "eab07add-6f4a-46c4-9738-a2d57d0283d2": {
      "title": "Direct Context Update",
      "id": "eab07add-6f4a-46c4-9738-a2d57d0283d2",
      "properties": {},
      "x": 654,
      "y": 2059,
      "width": 176,
      "height": 26,
      "collapsed": false,
      "inherited": false,
      "registry": "agents/director/chat/directContextUpdate",
      "base_type": "core/functions/Function"
    },
    "5e8fb08e-30c4-4c6a-97e0-8b4844598f4c": {
      "title": "AI Function Callback",
      "id": "5e8fb08e-30c4-4c6a-97e0-8b4844598f4c",
      "properties": {
        "name": "direct_context_change",
        "allow_multiple_calls": true
      },
      "x": 904,
      "y": 2059,
      "width": 214,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Callback",
      "base_type": "core/Node"
    },
    "798c16ae-d13c-41ad-b302-2fc1ea606902": {
      "title": "FN history_changes",
      "id": "798c16ae-d13c-41ad-b302-2fc1ea606902",
      "properties": {
        "name": "history_changes"
      },
      "x": 634,
      "y": 2239,
      "width": 210,
      "height": 78,
      "collapsed": false,
      "inherited": false,
      "registry": "core/functions/GetFunction",
      "base_type": "core/Node"
    },
    "323899a1-ffba-4d63-af97-4a25f11bf00f": {
      "title": "AI Function Callback",
      "id": "323899a1-ffba-4d63-af97-4a25f11bf00f",
      "properties": {
        "name": "my_function",
        "allow_multiple_calls": true
      },
      "x": 894,
      "y": 2239,
      "width": 214,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Callback",
      "base_type": "core/Node"
    },
    "80265d56-f041-4b26-9468-2a0b38f886a2": {
      "title": "AI Function Callback",
      "id": "80265d56-f041-4b26-9468-2a0b38f886a2",
      "properties": {
        "name": "my_function",
        "allow_multiple_calls": true
      },
      "x": 910,
      "y": 1880,
      "width": 214,
      "height": 102,
      "collapsed": false,
      "inherited": false,
      "registry": "focal/Callback",
      "base_type": "core/Node"
    },
    "e9460323-7f9c-484b-a993-e351e8fd2762": {
      "title": "Callbacks",
      "id": "e9460323-7f9c-484b-a993-e351e8fd2762",
      "properties": {},
      "x": 1310,
      "y": 1820,
      "width": 140,
      "height": 161,
      "collapsed": false,
      "inherited": false,
      "registry": "data/ListCollector",
      "dynamic_inputs": [
        {
          "name": "item0",
          "type": "*"
        },
        {
          "name": "item1",
          "type": "*"
        },
        {
          "name": "item2",
          "type": "*"
        },
        {
          "name": "item3",
          "type": "*"
        },
        {
          "name": "item4",
          "type": "*"
        }
      ],
      "base_type": "core/DynamicSocketNodeBase"
    }
  },
  "edges": {
    "72e91871-5a49-4611-b902-d2e0c3cb0c46.value": [
      "817effe3-19d2-44f8-b65b-a20dcb69cf4d.value"
    ],
    "817effe3-19d2-44f8-b65b-a20dcb69cf4d.value": [
      "75b77137-3f1d-4578-978c-1560efb7a5cf.state"
    ],
    "b1546ad2-2f69-45ff-8ad2-444a14d7f160.agent": [
      "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.agent"
    ],
    "00fc7caa-7893-4a8a-b05a-3b552ac4a205.value": [
      "70e39dcd-7c5b-4e27-acd2-7cd305247484.value"
    ],
    "f02f1a29-e2c0-4222-ac45-0afae1805cdf.value": [
      "ecbb3078-18ae-44ca-9302-c2957dd4302e.value"
    ],
    "c461d53e-a776-472b-9e66-44b687fd32ad.value": [
      "5f46d8d6-18e0-4f88-8f3d-84861e76a8a5.state"
    ],
    "317254b6-33c8-445f-8431-a072c3b33f00.fn": [
      "cfaec2dd-2c88-4087-8678-43cadd6c3226.fn"
    ],
    "317254b6-33c8-445f-8431-a072c3b33f00.name": [
      "cfaec2dd-2c88-4087-8678-43cadd6c3226.name"
    ],
    "cfaec2dd-2c88-4087-8678-43cadd6c3226.callback": [
      "e9460323-7f9c-484b-a993-e351e8fd2762.item0"
    ],
    "b90a792b-638e-45c3-9e33-c4951efbd76e.callback": [
      "e9460323-7f9c-484b-a993-e351e8fd2762.item1"
    ],
    "551a7a88-45ed-42d7-96c0-903fd79b2f79.fn": [
      "b90a792b-638e-45c3-9e33-c4951efbd76e.fn"
    ],
    "551a7a88-45ed-42d7-96c0-903fd79b2f79.name": [
      "b90a792b-638e-45c3-9e33-c4951efbd76e.name"
    ],
    "d4ae9150-4cfc-4c98-a530-d903d8468afc.fn": [
      "80265d56-f041-4b26-9468-2a0b38f886a2.fn"
    ],
    "d4ae9150-4cfc-4c98-a530-d903d8468afc.name": [
      "80265d56-f041-4b26-9468-2a0b38f886a2.name"
    ],
    "190656df-de95-4129-8076-2ff3e8eedd5b.value": [
      "08501b57-40ad-4060-aa1e-e4b511f4bdef.calls"
    ],
    "f5e3af1d-3da3-4813-b89d-a719384c79ae.calls": [
      "0d840e2b-0edc-46a7-b587-120c32c51bc1.value"
    ],
    "70e39dcd-7c5b-4e27-acd2-7cd305247484.value": [
      "27afad53-fa02-46ea-99d4-41460f3ca4f7.instructions"
    ],
    "a8581ffe-c27f-4767-a993-19d4d0b3d373.value": [
      "27afad53-fa02-46ea-99d4-41460f3ca4f7.state"
    ],
    "27afad53-fa02-46ea-99d4-41460f3ca4f7.summary": [
      "aa235b82-365d-4ed0-89ad-c45fbe100a13.value"
    ],
    "aa235b82-365d-4ed0-89ad-c45fbe100a13.value": [
      "121604ad-680e-4304-97ce-30139b001370.state"
    ],
    "03837765-6b28-4919-8b0e-02899afe1a74.value": [
      "6d97ea03-8c1d-40ca-ad3c-50f84d47c504.state"
    ],
    "e0e1c161-eafd-4162-8ec8-57f205bb5c59.value": [
      "fdecbd55-ee35-4d79-bad7-b7d9521714c0.state",
      "fdecbd55-ee35-4d79-bad7-b7d9521714c0.instructions"
    ],
    "fdecbd55-ee35-4d79-bad7-b7d9521714c0.summary": [
      "03837765-6b28-4919-8b0e-02899afe1a74.value"
    ],
    "ecbb3078-18ae-44ca-9302-c2957dd4302e.value": [
      "96bd24d6-40e0-4d5a-af5f-ceff530a83ac.state",
      "96bd24d6-40e0-4d5a-af5f-ceff530a83ac.instructions"
    ],
    "b0f49779-a569-4704-9b07-d48ad5e2bab4.value": [
      "e0e1c161-eafd-4162-8ec8-57f205bb5c59.value"
    ],
    "6d97ea03-8c1d-40ca-ad3c-50f84d47c504.state": [
      "9a5c222d-7b60-4d7c-88a1-303d43b4b851.nodes"
    ],
    "0d840e2b-0edc-46a7-b587-120c32c51bc1.value": [
      "90f46116-2451-4769-994b-cf60488b1880.state"
    ],
    "1eb0f232-2ddd-4cc6-9315-887222d4e01d.value": [
      "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.state"
    ],
    "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.state": [
      "f5e3af1d-3da3-4813-b89d-a719384c79ae.state"
    ],
    "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.agent": [
      "f5e3af1d-3da3-4813-b89d-a719384c79ae.agent"
    ],
    "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.prompt": [
      "f5e3af1d-3da3-4813-b89d-a719384c79ae.prompt"
    ],
    "d1f38cd6-653e-4dd5-a377-eb68e6ae98bd.list": [
      "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.dynamic_context"
    ],
    "1d5c1854-9c40-40bb-9521-16b944baaef5.value": [
      "8de5c510-bafa-44f7-975c-085cfa06b476.text",
      "b62ffa05-640b-4de1-a71f-fa8b265a80e3.item0"
    ],
    "8de5c510-bafa-44f7-975c-085cfa06b476.dynamic_instruction": [
      "d1f38cd6-653e-4dd5-a377-eb68e6ae98bd.item0"
    ],
    "8de5c510-bafa-44f7-975c-085cfa06b476.context_id_items": [
      "b62ffa05-640b-4de1-a71f-fa8b265a80e3.item1"
    ],
    "121604ad-680e-4304-97ce-30139b001370.state": [
      "2553322b-eef6-4438-8d5b-f2fda099055c.nodes"
    ],
    "0f0ac6d7-4518-4b06-9b37-8f275ed84b97.value": [
      "9c4ba59c-e6d9-4679-93ac-bf0e6ea03611.state"
    ],
    "ac358170-8123-407e-aa2e-1e95eb9356cf.value": [
      "ef0ddd3b-23af-4170-a532-f6561750f073.state",
      "ef0ddd3b-23af-4170-a532-f6561750f073.instructions"
    ],
    "ef0ddd3b-23af-4170-a532-f6561750f073.summary": [
      "0f0ac6d7-4518-4b06-9b37-8f275ed84b97.value"
    ],
    "96bd24d6-40e0-4d5a-af5f-ceff530a83ac.summary": [
      "c461d53e-a776-472b-9e66-44b687fd32ad.value"
    ],
    "5f46d8d6-18e0-4f88-8f3d-84861e76a8a5.state": [
      "a5a15864-d09e-4d15-b1ca-9adc75d3c4be.nodes"
    ],
    "0f7404fb-d63c-409b-bec6-a0a291303a28.value": [
      "ac358170-8123-407e-aa2e-1e95eb9356cf.value"
    ],
    "9c4ba59c-e6d9-4679-93ac-bf0e6ea03611.state": [
      "8af4646a-93a6-4ae0-ab5a-6dde4b44d7d1.nodes"
    ],
    "08501b57-40ad-4060-aa1e-e4b511f4bdef.summary": [
      "859a4fe6-4693-4e6d-a841-7e9b378615fe.state"
    ],
    "859a4fe6-4693-4e6d-a841-7e9b378615fe.state": [
      "6548308d-cf77-4322-9494-93b0ebb99551.value"
    ],
    "6548308d-cf77-4322-9494-93b0ebb99551.value": [
      "f76f3f64-af89-4c8c-80ae-6ff95ead4dc6.state"
    ],
    "ee07c367-b4da-46fd-b8a2-f12df134c52f.context_id_types": [
      "b62ffa05-640b-4de1-a71f-fa8b265a80e3.item2"
    ],
    "078e4097-1e13-400f-9dbf-02a447a2b353.list": [
      "0aa0a2ff-2395-4a04-a01e-10cc7a73dfaa.value"
    ],
    "0aa0a2ff-2395-4a04-a01e-10cc7a73dfaa.kv": [
      "b62ffa05-640b-4de1-a71f-fa8b265a80e3.item3"
    ],
    "b62ffa05-640b-4de1-a71f-fa8b265a80e3.result": [
      "f5ba1cf8-4ff8-4b60-b6f8-bdf714aaf89b.instructions"
    ],
    "3133d7af-2321-4deb-85c9-8a2a40f9020c.value": [
      "72e91871-5a49-4611-b902-d2e0c3cb0c46.value"
    ],
    "eab07add-6f4a-46c4-9738-a2d57d0283d2.fn": [
      "5e8fb08e-30c4-4c6a-97e0-8b4844598f4c.fn"
    ],
    "5e8fb08e-30c4-4c6a-97e0-8b4844598f4c.callback": [
      "e9460323-7f9c-484b-a993-e351e8fd2762.item3"
    ],
    "798c16ae-d13c-41ad-b302-2fc1ea606902.fn": [
      "323899a1-ffba-4d63-af97-4a25f11bf00f.fn"
    ],
    "798c16ae-d13c-41ad-b302-2fc1ea606902.name": [
      "323899a1-ffba-4d63-af97-4a25f11bf00f.name"
    ],
    "323899a1-ffba-4d63-af97-4a25f11bf00f.callback": [
      "e9460323-7f9c-484b-a993-e351e8fd2762.item4"
    ],
    "80265d56-f041-4b26-9468-2a0b38f886a2.callback": [
      "e9460323-7f9c-484b-a993-e351e8fd2762.item2"
    ],
    "e9460323-7f9c-484b-a993-e351e8fd2762.list": [
      "f5e3af1d-3da3-4813-b89d-a719384c79ae.callbacks"
    ]
  },
  "groups": [
    {
      "title": "Input Validation",
      "x": 2,
      "y": 1,
      "width": 1119,
      "height": 225,
      "color": "#b58b2a",
      "font_size": 24,
      "inherited": false
    },
    {
      "title": "Route",
      "x": 5,
      "y": 232,
      "width": 2510,
      "height": 2384,
      "color": "#3f789e",
      "font_size": 24,
      "inherited": false
    },
    {
      "title": "FN - character_changes",
      "x": -2018,
      "y": 229,
      "width": 2016,
      "height": 247,
      "color": "#b06634",
      "font_size": 24,
      "inherited": false
    },
    {
      "title": "FN - world_changes",
      "x": -1708,
      "y": 478,
      "width": 1707,
      "height": 307,
      "color": "#b06634",
      "font_size": 24,
      "inherited": false
    },
    {
      "title": "FN - story_config_changes",
      "x": -1772,
      "y": 788,
      "width": 1770,
      "height": 231,
      "color": "#b06634",
      "font_size": 24,
      "inherited": false
    },
    {
      "title": "Return",
      "x": 1126,
      "y": -79,
      "width": 1209,
      "height": 305,
      "color": "#8A8",
      "font_size": 24,
      "inherited": false
    },
    {
      "title": "Function - history_changes",
      "x": -1709,
      "y": 1022,
      "width": 1707,
      "height": 206,
      "color": "#b06634",
      "font_size": 24,
      "inherited": false
    }
  ],
  "comments": [],
  "extends": null,
  "base_type": "agents/director/DirectorChatAction",
  "inputs": [],
  "outputs": [
    {
      "id": "b347a487-6837-447d-8064-d7b0caf3cf05",
      "name": "fn",
      "optional": false,
      "group": null,
      "socket_type": "function"
    }
  ],
  "module_properties": {},
  "style": {
    "title_color": "#573a2e",
    "node_color": "#392f2c",
    "icon": "F0295",
    "auto_title": null,
    "counterpart": null
  }
}