{
  "initial": "regex_apply_user_input",
  "states": {
    "regex_apply_user_input": {
      "tool": "regex_apply_user_input",
      "next": "load_character"
    },
    "load_character": {
      "tool": "load_character",
      "next": "activate_worldbook"
    },
    "activate_worldbook": {
      "tool": "activate_worldbook",
      "next": "load_chat_history"
    },
    "load_chat_history": {
      "tool": "load_chat_history",
      "next": "build_prompt_messages"
    },
    "build_prompt_messages": {
      "tool": "build_prompt_messages",
      "next": "llm_main_reply"
    },
    "llm_main_reply": {
      "tool": "llm_main_reply",
      "next": "regex_apply_ai_output"
    },
    "regex_apply_ai_output": {
      "tool": "regex_apply_ai_output",
      "next": "record_token_usage"
    },
    "record_token_usage": {
      "tool": "record_token_usage",
      "next": "enqueue_parallel_tasks"
    },
    "enqueue_parallel_tasks": {
      "tool": "enqueue_parallel_tasks",
      "next": "end"
    }
  }
}
