{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "ref": "Config",
  "type": "object",
  "properties": {
    "$schema": {
      "description": "URL of the schema this file is validated against. Set it to https://proxy.100xprompt.com/config.json to get completion and inline documentation in your editor.",
      "type": "string"
    },
    "theme": {
      "description": "Colour theme for the terminal UI. Accepts any built-in theme name or one defined in a themes/ directory. Omit to follow the terminal's own palette.",
      "type": "string"
    },
    "keybinds": {
      "description": "Remap keyboard shortcuts. Every action listed here has a default; only the ones you set are overridden. Use <leader> to build on the leader key, separate alternatives with commas to bind several chords to one action, and set \"none\" to leave an action unbound.",
      "ref": "KeybindsConfig",
      "type": "object",
      "properties": {
        "leader": {
          "description": "Prefix key that opens a two-key chord. Press it, then the second key within 2 seconds; every `<leader>…` binding below is built on it.\n\ndefault: `ctrl+x`",
          "default": "ctrl+x",
          "type": "string",
          "examples": [
            "ctrl+x"
          ]
        },
        "app_exit": {
          "description": "Quit 100xprompt. Press it twice: the first press on an empty prompt shows \"press again to exit\", and a second press within 1.5 seconds quits. While a turn is running, ctrl+c interrupts it instead. With text typed, ctrl+c hits `input_clear` first and just clears it. A leader chord (`<leader>q`) quits at once. Inside a dialog or a permission prompt this key cancels instead of quitting.\n\ndefault: `ctrl+c,ctrl+d,<leader>q`",
          "default": "ctrl+c,ctrl+d,<leader>q",
          "type": "string",
          "examples": [
            "ctrl+c,ctrl+d,<leader>q"
          ]
        },
        "app_redraw": {
          "description": "Redraw the whole screen, for when the display has been garbled by something else writing to the terminal.\n\ndefault: `ctrl+l`",
          "default": "ctrl+l",
          "type": "string",
          "examples": [
            "ctrl+l"
          ]
        },
        "editor_open": {
          "description": "Open the current prompt in $EDITOR. Whatever you save comes back into the prompt, and @file/@agent mentions are re-anchored to wherever their text ended up.\n\ndefault: `<leader>e`",
          "default": "<leader>e",
          "type": "string",
          "examples": [
            "<leader>e"
          ]
        },
        "theme_list": {
          "description": "Open the theme picker.\n\ndefault: `<leader>t`",
          "default": "<leader>t",
          "type": "string",
          "examples": [
            "<leader>t"
          ]
        },
        "scrollbar_toggle": {
          "description": "Show or hide the scrollbar alongside the session transcript.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "task_background": {
          "description": "Accepted for compatibility but currently inert — nothing in the TUI reads this binding. Background tasks are reached from the command palette (\"Background tasks\").\n\ndefault: `ctrl+b`",
          "default": "ctrl+b",
          "type": "string",
          "examples": [
            "ctrl+b"
          ]
        },
        "username_toggle": {
          "description": "Accepted for compatibility but currently inert — this build has no username display to toggle and nothing reads this binding.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "status_view": {
          "description": "Open the status panel: version, providers, connected MCP servers and the active directories.\n\ndefault: `<leader>s`",
          "default": "<leader>s",
          "type": "string",
          "examples": [
            "<leader>s"
          ]
        },
        "session_export": {
          "description": "Export the transcript as Markdown. Asks what to include, writes the file into the current directory and opens it in $EDITOR; edits you make there are saved back to the file.\n\ndefault: `<leader>x`",
          "default": "<leader>x",
          "type": "string",
          "examples": [
            "<leader>x"
          ]
        },
        "session_new": {
          "description": "Start a new session, carrying anything already typed in the prompt across to it.\n\ndefault: `<leader>n`",
          "default": "<leader>n",
          "type": "string",
          "examples": [
            "<leader>n"
          ]
        },
        "session_list": {
          "description": "Open the session switcher.\n\ndefault: `<leader>l`",
          "default": "<leader>l",
          "type": "string",
          "examples": [
            "<leader>l"
          ]
        },
        "session_timeline": {
          "description": "Open the message timeline and jump to any earlier point in the session.\n\ndefault: `<leader>g`",
          "default": "<leader>g",
          "type": "string",
          "examples": [
            "<leader>g"
          ]
        },
        "session_fork": {
          "description": "Pick an earlier message and branch a new session from it, leaving this one intact.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "session_rename": {
          "description": "Rename the current session.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "session_share": {
          "description": "Publish a share link for this session and copy it to the clipboard. Hidden when `share` is set to \"disabled\".\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "session_unshare": {
          "description": "Revoke this session's share link.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "session_interrupt": {
          "description": "Abort the turn in flight. Only active while the session is busy; in shell (!) mode it leaves shell mode instead.\n\ndefault: `escape`",
          "default": "escape",
          "type": "string",
          "examples": [
            "escape"
          ]
        },
        "session_compact": {
          "description": "Summarize the session so far and carry on from the summary, reclaiming context. Needs a provider connected.\n\ndefault: `<leader>c`",
          "default": "<leader>c",
          "type": "string",
          "examples": [
            "<leader>c"
          ]
        },
        "messages_page_up": {
          "description": "Scroll the transcript up by half a viewport. (The name is inherited; the step really is half a screen, and `messages_half_page_up` is a quarter.)\n\ndefault: `pageup`",
          "default": "pageup",
          "type": "string",
          "examples": [
            "pageup"
          ]
        },
        "messages_page_down": {
          "description": "Scroll the transcript down by half a viewport. (The name is inherited; the step really is half a screen, and `messages_half_page_down` is a quarter.)\n\ndefault: `pagedown`",
          "default": "pagedown",
          "type": "string",
          "examples": [
            "pagedown"
          ]
        },
        "messages_half_page_up": {
          "description": "Scroll the transcript up by a quarter of a viewport — half the step `messages_page_up` takes.\n\ndefault: `ctrl+alt+u`",
          "default": "ctrl+alt+u",
          "type": "string",
          "examples": [
            "ctrl+alt+u"
          ]
        },
        "messages_half_page_down": {
          "description": "Scroll the transcript down by a quarter of a viewport — half the step `messages_page_down` takes.\n\ndefault: `ctrl+alt+d`",
          "default": "ctrl+alt+d",
          "type": "string",
          "examples": [
            "ctrl+alt+d"
          ]
        },
        "messages_first": {
          "description": "Jump to the top of the transcript.\n\ndefault: `ctrl+g,home`",
          "default": "ctrl+g,home",
          "type": "string",
          "examples": [
            "ctrl+g,home"
          ]
        },
        "messages_last": {
          "description": "Jump to the bottom of the transcript.\n\ndefault: `ctrl+alt+g,end`",
          "default": "ctrl+alt+g,end",
          "type": "string",
          "examples": [
            "ctrl+alt+g,end"
          ]
        },
        "messages_next": {
          "description": "Scroll to the next message boundary.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "messages_previous": {
          "description": "Scroll to the previous message boundary.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "messages_last_user": {
          "description": "Jump to the most recent message you actually typed, skipping synthetic and hidden text.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "messages_copy": {
          "description": "Copy the last assistant message to the clipboard, also emitting OSC 52 so it works over SSH and inside tmux.\n\ndefault: `<leader>y`",
          "default": "<leader>y",
          "type": "string",
          "examples": [
            "<leader>y"
          ]
        },
        "messages_undo": {
          "description": "Roll the session back to before your previous message and restore that message's text and attachments into the prompt. Aborts the turn in flight first.\n\ndefault: `<leader>u`",
          "default": "<leader>u",
          "type": "string",
          "examples": [
            "<leader>u"
          ]
        },
        "messages_redo": {
          "description": "Step forward again after an undo, restoring the next message. Only available while a message is reverted.\n\ndefault: `<leader>r`",
          "default": "<leader>r",
          "type": "string",
          "examples": [
            "<leader>r"
          ]
        },
        "messages_toggle_conceal": {
          "description": "Collapse or expand fenced code blocks in the transcript. Shares its default with `tips_toggle`, which is only live on the home screen, so the two never collide.\n\ndefault: `<leader>h`",
          "default": "<leader>h",
          "type": "string",
          "examples": [
            "<leader>h"
          ]
        },
        "feedback_up": {
          "description": "Rate the last Auto-routed response as good (👍). Does nothing if the last response was not Auto-routed.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "feedback_down": {
          "description": "Rate the last Auto-routed response as bad (👎). Does nothing if the last response was not Auto-routed.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "tool_details": {
          "description": "Show or hide the expanded output underneath each tool call.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "model_list": {
          "description": "Open the model picker.\n\ndefault: `<leader>m`",
          "default": "<leader>m",
          "type": "string",
          "examples": [
            "<leader>m"
          ]
        },
        "model_cycle_recent": {
          "description": "Switch to the next model in your recently-used list without opening the picker.\n\ndefault: `f2`",
          "default": "f2",
          "type": "string",
          "examples": [
            "f2"
          ]
        },
        "model_cycle_recent_reverse": {
          "description": "Switch to the previous model in your recently-used list without opening the picker.\n\ndefault: `shift+f2`",
          "default": "shift+f2",
          "type": "string",
          "examples": [
            "shift+f2"
          ]
        },
        "model_cycle_favorite": {
          "description": "Switch to the next favourited model. Warns if you have not starred any.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "model_cycle_favorite_reverse": {
          "description": "Switch to the previous favourited model. Warns if you have not starred any.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "command_list": {
          "description": "Open the command palette — every action in one searchable list.\n\ndefault: `ctrl+p`",
          "default": "ctrl+p",
          "type": "string",
          "examples": [
            "ctrl+p"
          ]
        },
        "agent_list": {
          "description": "Open the agent picker.\n\ndefault: `<leader>a`",
          "default": "<leader>a",
          "type": "string",
          "examples": [
            "<leader>a"
          ]
        },
        "agent_cycle": {
          "description": "Switch to the next agent.\n\ndefault: `tab`",
          "default": "tab",
          "type": "string",
          "examples": [
            "tab"
          ]
        },
        "agent_cycle_reverse": {
          "description": "Switch to the previous agent.\n\ndefault: `shift+tab`",
          "default": "shift+tab",
          "type": "string",
          "examples": [
            "shift+tab"
          ]
        },
        "permission_mode_cycle": {
          "description": "Cycle the session's permission mode: default → acceptEdits → auto → plan → back to default.\n\ndefault: `<leader>p`",
          "default": "<leader>p",
          "type": "string",
          "examples": [
            "<leader>p"
          ]
        },
        "variant_cycle": {
          "description": "Cycle the model's thinking / reasoning-effort level: model default → each level the model offers → back to default. Does nothing on models with no levels.\n\ndefault: `ctrl+t`",
          "default": "ctrl+t",
          "type": "string",
          "examples": [
            "ctrl+t"
          ]
        },
        "input_clear": {
          "description": "Clear the prompt. Only fires while there is text; on an empty prompt the same default falls through to `app_exit`.\n\ndefault: `ctrl+c`",
          "default": "ctrl+c",
          "type": "string",
          "examples": [
            "ctrl+c"
          ]
        },
        "input_paste": {
          "description": "Paste the system clipboard into the prompt. An image on the clipboard is attached as a file part instead of pasted as text.\n\ndefault: `ctrl+v`",
          "default": "ctrl+v",
          "type": "string",
          "examples": [
            "ctrl+v"
          ]
        },
        "input_submit": {
          "description": "Send the prompt.\n\ndefault: `return`",
          "default": "return",
          "type": "string",
          "examples": [
            "return"
          ]
        },
        "input_newline": {
          "description": "Insert a line break without sending.\n\ndefault: `shift+return,ctrl+return,alt+return,ctrl+j`",
          "default": "shift+return,ctrl+return,alt+return,ctrl+j",
          "type": "string",
          "examples": [
            "shift+return,ctrl+return,alt+return,ctrl+j"
          ]
        },
        "input_move_left": {
          "description": "Move the cursor one character left.\n\ndefault: `left,ctrl+b`",
          "default": "left,ctrl+b",
          "type": "string",
          "examples": [
            "left,ctrl+b"
          ]
        },
        "input_move_right": {
          "description": "Move the cursor one character right.\n\ndefault: `right,ctrl+f`",
          "default": "right,ctrl+f",
          "type": "string",
          "examples": [
            "right,ctrl+f"
          ]
        },
        "input_move_up": {
          "description": "Move the cursor up one wrapped row.\n\ndefault: `up`",
          "default": "up",
          "type": "string",
          "examples": [
            "up"
          ]
        },
        "input_move_down": {
          "description": "Move the cursor down one wrapped row.\n\ndefault: `down`",
          "default": "down",
          "type": "string",
          "examples": [
            "down"
          ]
        },
        "input_select_left": {
          "description": "Inert. The prompt editor has no selection model, and unlike the other `input_select_*` keys this one is not wired to a cursor move either.\n\ndefault: `shift+left`",
          "default": "shift+left",
          "type": "string",
          "examples": [
            "shift+left"
          ]
        },
        "input_select_right": {
          "description": "Inert. The prompt editor has no selection model, and unlike the other `input_select_*` keys this one is not wired to a cursor move either.\n\ndefault: `shift+right`",
          "default": "shift+right",
          "type": "string",
          "examples": [
            "shift+right"
          ]
        },
        "input_select_up": {
          "description": "Moves the cursor up one wrapped row. The prompt editor has no selection model, so nothing is highlighted.\n\ndefault: `shift+up`",
          "default": "shift+up",
          "type": "string",
          "examples": [
            "shift+up"
          ]
        },
        "input_select_down": {
          "description": "Moves the cursor down one wrapped row. The prompt editor has no selection model, so nothing is highlighted.\n\ndefault: `shift+down`",
          "default": "shift+down",
          "type": "string",
          "examples": [
            "shift+down"
          ]
        },
        "input_line_home": {
          "description": "Move the cursor to the start of the current line.\n\ndefault: `ctrl+a`",
          "default": "ctrl+a",
          "type": "string",
          "examples": [
            "ctrl+a"
          ]
        },
        "input_line_end": {
          "description": "Move the cursor to the end of the current line.\n\ndefault: `ctrl+e`",
          "default": "ctrl+e",
          "type": "string",
          "examples": [
            "ctrl+e"
          ]
        },
        "input_select_line_home": {
          "description": "Moves the cursor to the start of the line — identical to `input_line_home`. The prompt editor has no selection model.\n\ndefault: `ctrl+shift+a`",
          "default": "ctrl+shift+a",
          "type": "string",
          "examples": [
            "ctrl+shift+a"
          ]
        },
        "input_select_line_end": {
          "description": "Moves the cursor to the end of the line — identical to `input_line_end`. The prompt editor has no selection model.\n\ndefault: `ctrl+shift+e`",
          "default": "ctrl+shift+e",
          "type": "string",
          "examples": [
            "ctrl+shift+e"
          ]
        },
        "input_visual_line_home": {
          "description": "Move the cursor to the start of the current line. Identical to `input_line_home` today: this movement works on real lines, not wrapped rows.\n\ndefault: `alt+a`",
          "default": "alt+a",
          "type": "string",
          "examples": [
            "alt+a"
          ]
        },
        "input_visual_line_end": {
          "description": "Move the cursor to the end of the current line. Identical to `input_line_end` today: this movement works on real lines, not wrapped rows.\n\ndefault: `alt+e`",
          "default": "alt+e",
          "type": "string",
          "examples": [
            "alt+e"
          ]
        },
        "input_select_visual_line_home": {
          "description": "Moves the cursor to the start of the line — identical to `input_line_home`. No selection model, and no wrapped-row behaviour either.\n\ndefault: `alt+shift+a`",
          "default": "alt+shift+a",
          "type": "string",
          "examples": [
            "alt+shift+a"
          ]
        },
        "input_select_visual_line_end": {
          "description": "Moves the cursor to the end of the line — identical to `input_line_end`. No selection model, and no wrapped-row behaviour either.\n\ndefault: `alt+shift+e`",
          "default": "alt+shift+e",
          "type": "string",
          "examples": [
            "alt+shift+e"
          ]
        },
        "input_buffer_home": {
          "description": "Move the cursor to the very start of the prompt.\n\ndefault: `home`",
          "default": "home",
          "type": "string",
          "examples": [
            "home"
          ]
        },
        "input_buffer_end": {
          "description": "Move the cursor to the very end of the prompt.\n\ndefault: `end`",
          "default": "end",
          "type": "string",
          "examples": [
            "end"
          ]
        },
        "input_select_buffer_home": {
          "description": "Moves the cursor to the very start of the prompt — identical to `input_buffer_home`. The prompt editor has no selection model.\n\ndefault: `shift+home`",
          "default": "shift+home",
          "type": "string",
          "examples": [
            "shift+home"
          ]
        },
        "input_select_buffer_end": {
          "description": "Moves the cursor to the very end of the prompt — identical to `input_buffer_end`. The prompt editor has no selection model.\n\ndefault: `shift+end`",
          "default": "shift+end",
          "type": "string",
          "examples": [
            "shift+end"
          ]
        },
        "input_delete_line": {
          "description": "Delete from the cursor to the end of the line — the same edit as `input_delete_to_line_end`, despite the name. The whole line is not removed.\n\ndefault: `ctrl+shift+d`",
          "default": "ctrl+shift+d",
          "type": "string",
          "examples": [
            "ctrl+shift+d"
          ]
        },
        "input_delete_to_line_end": {
          "description": "Delete from the cursor to the end of the line.\n\ndefault: `ctrl+k`",
          "default": "ctrl+k",
          "type": "string",
          "examples": [
            "ctrl+k"
          ]
        },
        "input_delete_to_line_start": {
          "description": "Delete from the start of the line up to the cursor.\n\ndefault: `ctrl+u`",
          "default": "ctrl+u",
          "type": "string",
          "examples": [
            "ctrl+u"
          ]
        },
        "input_backspace": {
          "description": "Delete the character before the cursor.\n\ndefault: `backspace,shift+backspace`",
          "default": "backspace,shift+backspace",
          "type": "string",
          "examples": [
            "backspace,shift+backspace"
          ]
        },
        "input_delete": {
          "description": "Delete the character after the cursor.\n\ndefault: `ctrl+d,delete,shift+delete`",
          "default": "ctrl+d,delete,shift+delete",
          "type": "string",
          "examples": [
            "ctrl+d,delete,shift+delete"
          ]
        },
        "input_undo": {
          "description": "Undo the last edit to the prompt text. This is the prompt's own edit history — to undo a sent message use `messages_undo`. On Windows the default also includes ctrl+z.\n\ndefault: `ctrl+-,super+z`",
          "default": "ctrl+-,super+z",
          "type": "string",
          "examples": [
            "ctrl+-,super+z"
          ]
        },
        "input_redo": {
          "description": "Redo an edit to the prompt text undone by `input_undo`.\n\ndefault: `ctrl+.,super+shift+z`",
          "default": "ctrl+.,super+shift+z",
          "type": "string",
          "examples": [
            "ctrl+.,super+shift+z"
          ]
        },
        "input_word_forward": {
          "description": "Move the cursor one word right.\n\ndefault: `alt+f,alt+right,ctrl+right`",
          "default": "alt+f,alt+right,ctrl+right",
          "type": "string",
          "examples": [
            "alt+f,alt+right,ctrl+right"
          ]
        },
        "input_word_backward": {
          "description": "Move the cursor one word left.\n\ndefault: `alt+b,alt+left,ctrl+left`",
          "default": "alt+b,alt+left,ctrl+left",
          "type": "string",
          "examples": [
            "alt+b,alt+left,ctrl+left"
          ]
        },
        "input_select_word_forward": {
          "description": "Moves the cursor one word right — identical to `input_word_forward`. The prompt editor has no selection model.\n\ndefault: `alt+shift+f,alt+shift+right`",
          "default": "alt+shift+f,alt+shift+right",
          "type": "string",
          "examples": [
            "alt+shift+f,alt+shift+right"
          ]
        },
        "input_select_word_backward": {
          "description": "Moves the cursor one word left — identical to `input_word_backward`. The prompt editor has no selection model.\n\ndefault: `alt+shift+b,alt+shift+left`",
          "default": "alt+shift+b,alt+shift+left",
          "type": "string",
          "examples": [
            "alt+shift+b,alt+shift+left"
          ]
        },
        "input_delete_word_forward": {
          "description": "Delete from the cursor forward to the end of the word.\n\ndefault: `alt+d,alt+delete,ctrl+delete`",
          "default": "alt+d,alt+delete,ctrl+delete",
          "type": "string",
          "examples": [
            "alt+d,alt+delete,ctrl+delete"
          ]
        },
        "input_delete_word_backward": {
          "description": "Delete from the cursor back to the start of the word.\n\ndefault: `ctrl+w,ctrl+backspace,alt+backspace`",
          "default": "ctrl+w,ctrl+backspace,alt+backspace",
          "type": "string",
          "examples": [
            "ctrl+w,ctrl+backspace,alt+backspace"
          ]
        },
        "history_previous": {
          "description": "Recall the previous prompt you submitted. Only fires when the cursor is already at the very start of the prompt, so it never fights with cursor movement.\n\ndefault: `up`",
          "default": "up",
          "type": "string",
          "examples": [
            "up"
          ]
        },
        "history_next": {
          "description": "Recall the next prompt in history. Only fires when the cursor is already at the very end of the prompt, so it never fights with cursor movement.\n\ndefault: `down`",
          "default": "down",
          "type": "string",
          "examples": [
            "down"
          ]
        },
        "session_child_cycle": {
          "description": "Move to the next sub-session spawned by this one.\n\ndefault: `<leader>right`",
          "default": "<leader>right",
          "type": "string",
          "examples": [
            "<leader>right"
          ]
        },
        "session_child_cycle_reverse": {
          "description": "Move to the previous sub-session spawned by this one.\n\ndefault: `<leader>left`",
          "default": "<leader>left",
          "type": "string",
          "examples": [
            "<leader>left"
          ]
        },
        "session_parent": {
          "description": "Go back up to the session that spawned this one.\n\ndefault: `<leader>up`",
          "default": "<leader>up",
          "type": "string",
          "examples": [
            "<leader>up"
          ]
        },
        "terminal_suspend": {
          "description": "Suspend to the shell (SIGTSTP). Bring it back with `fg` and the UI redraws. Not available on Windows, which has no SIGTSTP: there the default is unbound and ctrl+z is undo (`input_undo`).\n\ndefault: `ctrl+z`",
          "default": "ctrl+z",
          "type": "string",
          "examples": [
            "ctrl+z"
          ]
        },
        "terminal_title_toggle": {
          "description": "Turn terminal window-title updates on or off. The choice is remembered between runs.\n\ndefault: `none`",
          "default": "none",
          "type": "string",
          "examples": [
            "none"
          ]
        },
        "tips_toggle": {
          "description": "Show or hide the tips block on the home screen. Only bound on the home screen — inside a session the same default runs `messages_toggle_conceal`.\n\ndefault: `<leader>h`",
          "default": "<leader>h",
          "type": "string",
          "examples": [
            "<leader>h"
          ]
        },
        "sprites_toggle": {
          "description": "Show or hide the companion sprite in the session view. The choice is remembered between runs.\n\ndefault: `<leader>b`",
          "default": "<leader>b",
          "type": "string",
          "examples": [
            "<leader>b"
          ]
        },
        "transcript_search": {
          "description": "Search the whole session — replies, prompts, thinking and tool output — and jump to what matches.\n\ndefault: `<leader>f`",
          "default": "<leader>f",
          "type": "string",
          "examples": [
            "<leader>f"
          ]
        },
        "history_search": {
          "description": "Search earlier prompts (in this project) by any words in them, and put the one picked back in the prompt.\n\ndefault: `ctrl+r`",
          "default": "ctrl+r",
          "type": "string",
          "examples": [
            "ctrl+r"
          ]
        },
        "transcript_full": {
          "description": "Show the full transcript: every tool panel open and every output unabridged. Press again to go back.\n\ndefault: `ctrl+o`",
          "default": "ctrl+o",
          "type": "string",
          "examples": [
            "ctrl+o"
          ]
        },
        "file_quick_open": {
          "description": "Open the file finder and add the picked file to the prompt as an @-mention.\n\ndefault: `<leader>o`",
          "default": "<leader>o",
          "type": "string",
          "examples": [
            "<leader>o"
          ]
        },
        "agents_stop_all": {
          "description": "Stop everything running in the background: shells, subagents and sessions sent to the background.\n\ndefault: `<leader>k`",
          "default": "<leader>k",
          "type": "string",
          "examples": [
            "<leader>k"
          ]
        }
      },
      "additionalProperties": false
    },
    "logLevel": {
      "description": "Lowest severity written to the log file. DEBUG is the most detailed and ERROR the least.\n\n@deprecated Renamed to `log_level`. This spelling is still honoured.",
      "ref": "LogLevel",
      "type": "string",
      "enum": [
        "DEBUG",
        "INFO",
        "WARN",
        "ERROR"
      ],
      "deprecated": true
    },
    "sandbox": {
      "description": "Enable the OS command sandbox (seatbelt on macOS, bwrap on Linux). Default: OFF on macOS, ON elsewhere. Set true to opt in on macOS, false to opt out anywhere.",
      "type": "boolean"
    },
    "sandboxAutoApprove": {
      "description": "Skip the bash permission prompt for commands the sandbox actually contains, since the kernel is already enforcing the boundary. Default: ON wherever the sandbox is active. Commands that can exfiltrate data (curl, ssh, rsync…), dangerous commands, and denied/plan-mode commands always still prompt. Set false to always prompt.\n\n@deprecated Renamed to `sandbox_auto_approve`. This spelling is still honoured.",
      "type": "boolean",
      "deprecated": true
    },
    "sandboxBackend": {
      "description": "Which sandbox backend confines untrusted bash commands. Default: seatbelt on macOS, landlock on Linux (unset = platform default, unchanged behavior). \"microvm\" runs each command in a VM-isolated environment with its own kernel — detected via HUNDREDXPROMPT_MICROVM_RUNNER or a `msb` (microsandbox), `docker`, `podman`, or apple `container` CLI on PATH (image: HUNDREDXPROMPT_MICROVM_IMAGE, default alpine). If no runner is present it degrades gracefully to the platform sandbox. \"seatbelt\"/\"landlock\" pin that backend (honored only on the matching OS); \"none\" disables the sandbox like sandbox: false.",
      "type": "string",
      "enum": [
        "microvm",
        "seatbelt",
        "landlock",
        "none"
      ]
    },
    "tui": {
      "description": "Behaviour of the terminal UI itself — scrolling feel and how diffs are laid out.",
      "type": "object",
      "properties": {
        "scroll_speed": {
          "description": "Rows moved per mouse-wheel notch in the transcript. Default 3. Ignored when `scroll_acceleration.enabled` is true, which replaces the fixed step entirely.",
          "type": "number",
          "minimum": 0.001
        },
        "scroll_acceleration": {
          "description": "Momentum scrolling for the transcript, in place of a fixed rows-per-notch step. Overrides `scroll_speed` when enabled.",
          "type": "object",
          "properties": {
            "enabled": {
              "description": "Turn on the acceleration curve. Flick the wheel and the transcript keeps travelling; a slow scroll stays precise.",
              "type": "boolean"
            }
          },
          "required": [
            "enabled"
          ],
          "additionalProperties": false
        },
        "diff_style": {
          "description": "How file diffs are laid out. \"auto\" (the default) shows them side by side once the terminal is wider than 120 columns and stacks them below that; \"stacked\" always keeps the single-column unified view.",
          "type": "string",
          "enum": [
            "auto",
            "stacked"
          ]
        }
      },
      "additionalProperties": false
    },
    "server": {
      "description": "Where the HTTP server binds and who may talk to it. Applies to `100xprompt serve` and anything else that starts the server.",
      "ref": "ServerConfig",
      "type": "object",
      "properties": {
        "port": {
          "description": "Port the HTTP server binds to. Leave unset to try 4096 first and fall back to any free port. `--port` on the command line wins over this.",
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        "hostname": {
          "description": "Address the HTTP server binds to. Defaults to 127.0.0.1, or 0.0.0.0 when `mdns` is on and no hostname is set here. `--hostname` on the command line wins over this.",
          "type": "string"
        },
        "mdns": {
          "description": "Advertise the server over mDNS/Bonjour so other machines on the LAN can find it. Skipped with a warning if the server is bound to loopback, since nothing off-box could reach it anyway.",
          "type": "boolean"
        },
        "cors": {
          "description": "Extra origins allowed to call the HTTP server, matched exactly. localhost, 127.0.0.1, tauri://localhost and *.100xprompt.com/.ai are already allowed. Any `--cors` values are added to this list rather than replacing it.",
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "additionalProperties": false
    },
    "command": {
      "description": "Custom slash commands, keyed by the name you type after '/'. See https://100xprompt.com/docs/commands",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "object",
        "properties": {
          "template": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "agent": {
            "type": "string"
          },
          "model": {
            "type": "string"
          },
          "subtask": {
            "type": "boolean"
          },
          "plugin": {
            "type": "string"
          },
          "allowed-tools": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          },
          "argument-hint": {
            "type": "string"
          },
          "aliases": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "template"
        ],
        "additionalProperties": false
      }
    },
    "watcher": {
      "description": "Which paths the file watcher pays attention to while a session is open.",
      "type": "object",
      "properties": {
        "ignore": {
          "description": "Extra glob patterns to ignore, on top of .gitignore and the built-in exclusions.",
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "additionalProperties": false
    },
    "plugin": {
      "description": "Plugins to load, each either an npm package (optionally @version, defaulting to latest) or a file:// path to a local module. Loaded in addition to the built-in plugins.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "hooks": {
      "description": "Lifecycle hooks (command, prompt, agent, http) keyed by event: PreToolUse, PostToolUse, PostToolUseFailure, UserPromptSubmit, PermissionRequest, SessionStart, SessionEnd, Stop, PreCompact, PostCompact, and more",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "matcher": {
              "description": "Regex matched against the tool name (PreToolUse/PostToolUse only)",
              "type": "string"
            },
            "hooks": {
              "type": "array",
              "items": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "description": "Shell hook (default type)",
                        "type": "string",
                        "const": "command"
                      },
                      "command": {
                        "description": "Shell command. Receives the event JSON on stdin",
                        "type": "string"
                      },
                      "timeout": {
                        "description": "Timeout in seconds (default 60)",
                        "type": "number"
                      }
                    },
                    "required": [
                      "command"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "description": "Single non-streaming LLM validation call",
                        "type": "string",
                        "const": "prompt"
                      },
                      "prompt": {
                        "description": "Validation instructions for the model",
                        "type": "string"
                      },
                      "model": {
                        "description": "Model as provider/model (defaults to the small model)",
                        "type": "string"
                      },
                      "timeout": {
                        "description": "Timeout in seconds (default 60)",
                        "type": "number"
                      }
                    },
                    "required": [
                      "type"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "description": "Read-only verifier subagent",
                        "type": "string",
                        "const": "agent"
                      },
                      "prompt": {
                        "description": "Verification instructions for the subagent",
                        "type": "string"
                      },
                      "agent": {
                        "description": "Agent definition to run (default: general)",
                        "type": "string"
                      },
                      "model": {
                        "description": "Model as provider/model",
                        "type": "string"
                      },
                      "maxTurns": {
                        "description": "Max tool turns (capped at 50)\n\n@deprecated Renamed to `max_turns`. This spelling is still honoured.",
                        "type": "number",
                        "deprecated": true
                      },
                      "timeout": {
                        "description": "Timeout in seconds (default 300)",
                        "type": "number"
                      },
                      "max_turns": {
                        "description": "Max tool turns (capped at 50)",
                        "type": "number"
                      }
                    },
                    "required": [
                      "type"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "description": "Webhook (SSRF-guarded; private addresses refused)",
                        "type": "string",
                        "const": "http"
                      },
                      "url": {
                        "description": "Webhook URL (http/https)",
                        "type": "string"
                      },
                      "method": {
                        "description": "HTTP method (default POST)",
                        "type": "string",
                        "enum": [
                          "POST",
                          "PUT"
                        ]
                      },
                      "headers": {
                        "description": "Extra headers; ${ENV_VAR} is interpolated",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string"
                        }
                      },
                      "timeout": {
                        "description": "Timeout in seconds (default 30)",
                        "type": "number"
                      }
                    },
                    "required": [
                      "type",
                      "url"
                    ],
                    "additionalProperties": false
                  }
                ]
              }
            }
          },
          "required": [
            "hooks"
          ],
          "additionalProperties": false
        }
      }
    },
    "verification": {
      "description": "Adversarial verification gate — require a read-only verifier subagent verdict before completion reporting on significant changes",
      "type": "object",
      "properties": {
        "enabled": {
          "description": "Enable the adversarial verification gate: significant turns (threshold+ files modified) cannot mark the final todo completed until a verification subagent has issued VERDICT: PASS/FAIL/PARTIAL. Default false",
          "type": "boolean"
        },
        "threshold": {
          "description": "Distinct files modified in a turn before verification is required. Default 3",
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        "agent": {
          "description": "Subagent spawned to verify the work (default: verifier)",
          "type": "string"
        }
      },
      "additionalProperties": false
    },
    "kairos": {
      "description": "Kairos mode — Claude Code-style background pacing (tick loop + model-controlled sleep) with terminal-focus-aware autonomy",
      "type": "object",
      "properties": {
        "enabled": {
          "description": "Enable the /kairos TUI command: a background tick loop where the model paces itself with the sleep tool and calibrates autonomy to terminal focus. Default true; set false to disable",
          "type": "boolean"
        },
        "default_sleep": {
          "description": "Seconds to wait before the next tick when the model didn't call sleep. Default 60",
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        }
      },
      "additionalProperties": false
    },
    "vim": {
      "description": "Enable Vim keybindings in the TUI prompt input",
      "type": "boolean"
    },
    "recap": {
      "description": "Show an end-of-turn recap (Crunched for … + a one-line summary of what changed). Default on.",
      "type": "boolean"
    },
    "output_style": {
      "description": "Active output style (built-in: explanatory, learning, concise; or a custom output-styles/*.md name)",
      "type": "string"
    },
    "tool_search": {
      "description": "Defer MCP tool schemas behind a `tool_search` tool to save context. Deferred by default when more than 8 MCP tools are available; set false to disable, true to always defer, or a number to use a custom threshold",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "number"
        }
      ]
    },
    "snapshot": {
      "description": "Whether to record a restorable snapshot of the working tree before edits, which is what makes reverting a turn possible. On by default; set false to skip it entirely.",
      "type": "boolean"
    },
    "share": {
      "description": "Who can be given a link to a session. 'manual' (the default) shares only when you ask for it; 'auto' publishes every new session as it starts; 'disabled' refuses to share at all and hides the share command.",
      "type": "string",
      "enum": [
        "manual",
        "auto",
        "disabled"
      ]
    },
    "autoshare": {
      "description": "Superseded by `share`. Setting this to true is rewritten to `share: \"auto\"` when the config loads, and only when `share` is not set — so if you set both, `share` wins. Nothing else reads this key.\n\n@deprecated Renamed to `auto_share`. This spelling is still honoured.",
      "type": "boolean",
      "deprecated": true
    },
    "autoupdate": {
      "description": "What to do when a newer release exists: true installs it in the background, 'notify' only mentions it and leaves the upgrade to you, false stops checking altogether.\n\n@deprecated Renamed to `auto_update`. This spelling is still honoured.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "const": "notify"
        }
      ],
      "deprecated": true
    },
    "usageReport": {
      "description": "Whether to show usage on your own API keys (OpenRouter, Anthropic, any provider you configure) on your 100xprompt dashboard alongside gateway usage. When you are signed in, each finished step on your own key sends only numbers and names: token counts, cost, provider, model and the upstream that served it, never prompts, replies, tool data, file paths, keys or config. Usage through the 100xprompt gateway is never reported this way, and own-key usage never counts toward your plan. On by default; set false, or export HUNDREDXPROMPT_DISABLE_USAGE_REPORT=1, to stop it.",
      "type": "boolean"
    },
    "disabled_providers": {
      "description": "Provider ids to leave out even though credentials for them were found. Use this to stop a provider you have keys for from being offered.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "enabled_providers": {
      "description": "Provider ids to allow, as an exclusive list: once this is set, every provider not named here is ignored regardless of available credentials.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "model": {
      "description": "The model each new session starts on, written as provider/model — for example anthropic/claude-sonnet-4-5 or 100xprompt/pro. Leave unset to use the best model your credentials allow.",
      "type": "string"
    },
    "fallback_model": {
      "description": "Model to retry with, as provider/model, when the primary one is rate-limited, overloaded, or otherwise refusing work. Pick something on a different provider so a single outage cannot take out both.",
      "type": "string"
    },
    "small_model": {
      "description": "Cheaper model, as provider/model, for the small side-jobs that run alongside a conversation: session titles, summaries and similar. Never used for your actual turns.",
      "type": "string"
    },
    "advisor_model": {
      "description": "Stronger model consulted by the /second-opinion command, in the format of provider/model. Defaults to the strongest available model",
      "type": "string"
    },
    "plan_model": {
      "description": "Stronger model to use when the session is in plan mode (e.g. 'anthropic/claude-opus-4-5'). When set and the session permission mode is 'plan', requests use this model instead of the session's normal model. Supports provider/model format or a short alias (e.g. 'opus').",
      "type": "string"
    },
    "memory": {
      "description": "Long-term memory system configuration",
      "type": "object",
      "properties": {
        "enabled": {
          "description": "Master switch for the memory system: extraction, consolidation, recall, and context injection. Default true",
          "type": "boolean"
        },
        "extraction": {
          "description": "Turn-end automatic memory extraction via the side-model. Default true",
          "type": "boolean"
        },
        "consolidation": {
          "description": "Periodic automatic memory consolidation (auto-dream) job. Default true",
          "type": "boolean"
        },
        "recall": {
          "description": "Per-message query-relevant memory recall via the side-model. Default true",
          "type": "boolean"
        },
        "model": {
          "description": "Override the side-model used for memory extraction/consolidation/recall, in the format of provider/model",
          "type": "string"
        },
        "team": {
          "description": "Shared / team memory backend (Firestore). When a workspace id and GCP credentials are configured, memory is shared across the team with per-record access control; otherwise memory stays local-only.",
          "type": "object",
          "properties": {
            "workspace": {
              "description": "Team/workspace id. When set (together with GCP credentials) team memory is enabled: memories can be shared with the workspace and are stored in Firestore under this namespace. Off by default.",
              "type": "string"
            },
            "user": {
              "description": "Stable id for the current user within the workspace, used as the memory owner and to filter private memories. Defaults to the OS username when omitted.",
              "type": "string"
            },
            "project_id": {
              "description": "GCP project id for Firestore. Falls back to the GCP_PROJECT_ID / GOOGLE_CLOUD_PROJECT environment variables when omitted.",
              "type": "string"
            },
            "credentials": {
              "description": "Path to a GCP service-account JSON key file for Firestore, or the JSON itself. Falls back to Application Default Credentials (GOOGLE_APPLICATION_CREDENTIALS) when omitted.",
              "type": "string"
            },
            "collection": {
              "description": "Root Firestore collection for team memories (default 'team-memories').",
              "type": "string"
            },
            "default_visibility": {
              "description": "Visibility applied to new memories written while team mode is on (default 'private'). Reads always merge the user's private memories with team-visible ones.",
              "type": "string",
              "enum": [
                "private",
                "team"
              ]
            }
          },
          "additionalProperties": false
        }
      },
      "additionalProperties": false
    },
    "default_agent": {
      "description": "Default agent to use when none is specified. Must be a primary agent. Falls back to 'build' if not set or if the specified agent is invalid.",
      "type": "string"
    },
    "username": {
      "description": "Name shown against your messages in the transcript. Defaults to your operating-system username.",
      "type": "string"
    },
    "mode": {
      "description": "Superseded by `agent`. Each entry here is merged into `agent` as a primary agent when the config loads, so existing files keep working — but new configuration belongs under `agent`, which is the only place subagents can be defined.",
      "type": "object",
      "properties": {
        "build": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "plan": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        }
      },
      "additionalProperties": {
        "ref": "AgentConfig",
        "type": "object",
        "properties": {
          "model": {
            "type": "string"
          },
          "temperature": {
            "type": "number"
          },
          "top_p": {
            "type": "number"
          },
          "prompt": {
            "type": "string"
          },
          "tools": {
            "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {
              "type": "boolean"
            }
          },
          "disable": {
            "type": "boolean"
          },
          "description": {
            "description": "Description of when to use the agent",
            "type": "string"
          },
          "mode": {
            "type": "string",
            "enum": [
              "subagent",
              "primary",
              "all"
            ]
          },
          "hidden": {
            "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
            "type": "boolean"
          },
          "slim": {
            "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
            "type": "boolean"
          },
          "options": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          },
          "color": {
            "description": "Hex color code for the agent (e.g., #FF5733)",
            "type": "string",
            "pattern": "^#[0-9a-fA-F]{6}$"
          },
          "steps": {
            "description": "Maximum number of agentic iterations before forcing text-only response",
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "maxSteps": {
            "description": "@deprecated Use 'steps' field instead.\n\n@deprecated Renamed to `max_steps`. This spelling is still honoured.",
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "deprecated": true
          },
          "permission": {
            "ref": "PermissionConfig",
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "__originalKeys": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "read": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "edit": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "glob": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "grep": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "list": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "bash": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "task": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "external_directory": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "todowrite": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "todoread": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "question": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "webfetch": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "websearch": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "codesearch": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "lsp": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "doom_loop": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "additionalDirectories": {
                    "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.\n\n@deprecated Renamed to `additional_directories`. This spelling is still honoured.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "deprecated": true
                  },
                  "workspaceRoot": {
                    "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.\n\n@deprecated Renamed to `workspace_root`. This spelling is still honoured.",
                    "type": "string",
                    "deprecated": true
                  },
                  "additional_directories": {
                    "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "workspace_root": {
                    "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                    "type": "string"
                  }
                },
                "additionalProperties": {
                  "ref": "PermissionRuleConfig",
                  "anyOf": [
                    {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    {
                      "ref": "PermissionObjectConfig",
                      "type": "object",
                      "propertyNames": {
                        "type": "string"
                      },
                      "additionalProperties": {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      }
                    }
                  ]
                }
              },
              {
                "ref": "PermissionActionConfig",
                "type": "string",
                "enum": [
                  "ask",
                  "allow",
                  "deny"
                ]
              }
            ]
          },
          "max_steps": {
            "description": "@deprecated Use 'steps' field instead.",
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "additionalProperties": {}
      }
    },
    "agent": {
      "description": "Define or adjust agents, keyed by agent name. The built-ins (build, plan, general, explore and the specialised title/summary/compaction ones) can be reconfigured here, and any other name creates a new agent. See https://100xprompt.com/docs/agent",
      "type": "object",
      "properties": {
        "plan": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "build": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "general": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "explore": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "title": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "summary": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        },
        "compaction": {
          "ref": "AgentConfig",
          "type": "object",
          "properties": {
            "model": {
              "type": "string"
            },
            "temperature": {
              "type": "number"
            },
            "top_p": {
              "type": "number"
            },
            "prompt": {
              "type": "string"
            },
            "tools": {
              "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "disable": {
              "type": "boolean"
            },
            "description": {
              "description": "Description of when to use the agent",
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "subagent",
                "primary",
                "all"
              ]
            },
            "hidden": {
              "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
              "type": "boolean"
            },
            "slim": {
              "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
              "type": "boolean"
            },
            "options": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {}
            },
            "color": {
              "description": "Hex color code for the agent (e.g., #FF5733)",
              "type": "string",
              "pattern": "^#[0-9a-fA-F]{6}$"
            },
            "steps": {
              "description": "Maximum number of agentic iterations before forcing text-only response",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxSteps": {
              "description": "@deprecated Use 'steps' field instead.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "permission": {
              "ref": "PermissionConfig",
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "__originalKeys": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "read": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "edit": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "glob": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "grep": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "list": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "bash": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "task": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "external_directory": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "todowrite": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "todoread": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "question": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "webfetch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "websearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "codesearch": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "lsp": {
                      "ref": "PermissionRuleConfig",
                      "anyOf": [
                        {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        },
                        {
                          "ref": "PermissionObjectConfig",
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "ref": "PermissionActionConfig",
                            "type": "string",
                            "enum": [
                              "ask",
                              "allow",
                              "deny"
                            ]
                          }
                        }
                      ]
                    },
                    "doom_loop": {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    "additionalDirectories": {
                      "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "workspaceRoot": {
                      "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                      "type": "string"
                    }
                  },
                  "additionalProperties": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  }
                },
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              ]
            }
          },
          "additionalProperties": {}
        }
      },
      "additionalProperties": {
        "ref": "AgentConfig",
        "type": "object",
        "properties": {
          "model": {
            "type": "string"
          },
          "temperature": {
            "type": "number"
          },
          "top_p": {
            "type": "number"
          },
          "prompt": {
            "type": "string"
          },
          "tools": {
            "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {
              "type": "boolean"
            }
          },
          "disable": {
            "type": "boolean"
          },
          "description": {
            "description": "Description of when to use the agent",
            "type": "string"
          },
          "mode": {
            "type": "string",
            "enum": [
              "subagent",
              "primary",
              "all"
            ]
          },
          "hidden": {
            "description": "Hide this subagent from the @ autocomplete menu (default: false, only applies to mode: subagent)",
            "type": "boolean"
          },
          "slim": {
            "description": "Use a slim system prompt when this agent runs as a spawned subagent: skips memory, mode prompts, and the full environment block (default: true for task-spawned subagents; set false to opt out)",
            "type": "boolean"
          },
          "options": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          },
          "color": {
            "description": "Hex color code for the agent (e.g., #FF5733)",
            "type": "string",
            "pattern": "^#[0-9a-fA-F]{6}$"
          },
          "steps": {
            "description": "Maximum number of agentic iterations before forcing text-only response",
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "maxSteps": {
            "description": "@deprecated Use 'steps' field instead.\n\n@deprecated Renamed to `max_steps`. This spelling is still honoured.",
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "deprecated": true
          },
          "permission": {
            "ref": "PermissionConfig",
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "__originalKeys": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "read": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "edit": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "glob": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "grep": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "list": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "bash": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "task": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "external_directory": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "todowrite": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "todoread": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "question": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "webfetch": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "websearch": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "codesearch": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "lsp": {
                    "ref": "PermissionRuleConfig",
                    "anyOf": [
                      {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      },
                      {
                        "ref": "PermissionObjectConfig",
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "ref": "PermissionActionConfig",
                          "type": "string",
                          "enum": [
                            "ask",
                            "allow",
                            "deny"
                          ]
                        }
                      }
                    ]
                  },
                  "doom_loop": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  },
                  "additionalDirectories": {
                    "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.\n\n@deprecated Renamed to `additional_directories`. This spelling is still honoured.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "deprecated": true
                  },
                  "workspaceRoot": {
                    "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.\n\n@deprecated Renamed to `workspace_root`. This spelling is still honoured.",
                    "type": "string",
                    "deprecated": true
                  },
                  "additional_directories": {
                    "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "workspace_root": {
                    "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
                    "type": "string"
                  }
                },
                "additionalProperties": {
                  "ref": "PermissionRuleConfig",
                  "anyOf": [
                    {
                      "ref": "PermissionActionConfig",
                      "type": "string",
                      "enum": [
                        "ask",
                        "allow",
                        "deny"
                      ]
                    },
                    {
                      "ref": "PermissionObjectConfig",
                      "type": "object",
                      "propertyNames": {
                        "type": "string"
                      },
                      "additionalProperties": {
                        "ref": "PermissionActionConfig",
                        "type": "string",
                        "enum": [
                          "ask",
                          "allow",
                          "deny"
                        ]
                      }
                    }
                  ]
                }
              },
              {
                "ref": "PermissionActionConfig",
                "type": "string",
                "enum": [
                  "ask",
                  "allow",
                  "deny"
                ]
              }
            ]
          },
          "max_steps": {
            "description": "@deprecated Use 'steps' field instead.",
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "additionalProperties": {}
      }
    },
    "provider": {
      "description": "Add providers or change ones already known, keyed by provider id. Use it to point at a self-hosted or OpenAI-compatible endpoint, supply base URLs and headers, or correct the cost and context limits of an individual model.",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "ref": "ProviderConfig",
        "type": "object",
        "properties": {
          "api": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "env": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "id": {
            "type": "string"
          },
          "npm": {
            "type": "string"
          },
          "models": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "family": {
                  "type": "string"
                },
                "release_date": {
                  "type": "string"
                },
                "attachment": {
                  "type": "boolean"
                },
                "reasoning": {
                  "type": "boolean"
                },
                "temperature": {
                  "type": "boolean"
                },
                "tool_call": {
                  "type": "boolean"
                },
                "interleaved": {
                  "anyOf": [
                    {
                      "type": "boolean",
                      "const": true
                    },
                    {
                      "type": "object",
                      "properties": {
                        "field": {
                          "type": "string",
                          "enum": [
                            "reasoning_content",
                            "reasoning_details"
                          ]
                        }
                      },
                      "required": [
                        "field"
                      ],
                      "additionalProperties": false
                    }
                  ]
                },
                "cost": {
                  "type": "object",
                  "properties": {
                    "input": {
                      "type": "number"
                    },
                    "output": {
                      "type": "number"
                    },
                    "cache_read": {
                      "type": "number"
                    },
                    "cache_write": {
                      "type": "number"
                    },
                    "context_over_200k": {
                      "type": "object",
                      "properties": {
                        "input": {
                          "type": "number"
                        },
                        "output": {
                          "type": "number"
                        },
                        "cache_read": {
                          "type": "number"
                        },
                        "cache_write": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "input",
                        "output"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "input",
                    "output"
                  ],
                  "additionalProperties": false
                },
                "limit": {
                  "type": "object",
                  "properties": {
                    "context": {
                      "type": "number"
                    },
                    "output": {
                      "type": "number"
                    }
                  },
                  "required": [
                    "context",
                    "output"
                  ],
                  "additionalProperties": false
                },
                "modalities": {
                  "type": "object",
                  "properties": {
                    "input": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "text",
                          "audio",
                          "image",
                          "video",
                          "pdf"
                        ]
                      }
                    },
                    "output": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "text",
                          "audio",
                          "image",
                          "video",
                          "pdf"
                        ]
                      }
                    }
                  },
                  "required": [
                    "input",
                    "output"
                  ],
                  "additionalProperties": false
                },
                "experimental": {
                  "type": "boolean"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "alpha",
                    "beta",
                    "deprecated"
                  ]
                },
                "options": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {}
                },
                "headers": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "type": "string"
                  }
                },
                "provider": {
                  "type": "object",
                  "properties": {
                    "npm": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "npm"
                  ],
                  "additionalProperties": false
                },
                "variants": {
                  "description": "Variant-specific configuration",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "type": "object",
                    "properties": {
                      "disabled": {
                        "description": "Disable this variant for the model",
                        "type": "boolean"
                      }
                    },
                    "additionalProperties": {}
                  }
                }
              },
              "additionalProperties": false
            }
          },
          "whitelist": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "blacklist": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "options": {
            "type": "object",
            "properties": {
              "apiKey": {
                "type": "string"
              },
              "baseURL": {
                "type": "string"
              },
              "enterpriseUrl": {
                "description": "GitHub Enterprise URL for copilot authentication",
                "type": "string"
              },
              "setCacheKey": {
                "description": "Enable promptCacheKey for this provider (default false)",
                "type": "boolean"
              },
              "timeout": {
                "description": "Timeout in milliseconds for requests to this provider. Default is 300000 (5 minutes). Set to false to disable timeout.",
                "anyOf": [
                  {
                    "description": "Timeout in milliseconds for requests to this provider. Default is 300000 (5 minutes). Set to false to disable timeout.",
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  {
                    "description": "Disable timeout for this provider entirely.",
                    "type": "boolean",
                    "const": false
                  }
                ]
              }
            },
            "additionalProperties": {}
          }
        },
        "additionalProperties": false
      }
    },
    "mcp": {
      "description": "MCP servers to connect to, keyed by the name their tools are prefixed with. An entry is either a full server definition (a local command to spawn, or a remote URL) or just `{ \"enabled\": false }` to switch off one declared elsewhere.",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "anyOf": [
          {
            "anyOf": [
              {
                "ref": "McpLocalConfig",
                "type": "object",
                "properties": {
                  "type": {
                    "description": "Type of MCP server connection",
                    "type": "string",
                    "const": "local"
                  },
                  "command": {
                    "description": "Command and arguments to run the MCP server",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "environment": {
                    "description": "Environment variables to set when running the MCP server",
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "enabled": {
                    "description": "Enable or disable the MCP server on startup",
                    "type": "boolean"
                  },
                  "timeout": {
                    "description": "Timeout in ms for fetching tools from the MCP server. Defaults to 5000 (5 seconds) if not specified.",
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "type",
                  "command"
                ],
                "additionalProperties": false
              },
              {
                "ref": "McpRemoteConfig",
                "type": "object",
                "properties": {
                  "type": {
                    "description": "Type of MCP server connection",
                    "type": "string",
                    "const": "remote"
                  },
                  "url": {
                    "description": "URL of the remote MCP server",
                    "type": "string"
                  },
                  "enabled": {
                    "description": "Enable or disable the MCP server on startup",
                    "type": "boolean"
                  },
                  "headers": {
                    "description": "Headers to send with the request",
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "oauth": {
                    "description": "OAuth authentication configuration for the MCP server. Set to false to disable OAuth auto-detection.",
                    "anyOf": [
                      {
                        "ref": "McpOAuthConfig",
                        "type": "object",
                        "properties": {
                          "clientId": {
                            "description": "OAuth client ID. If not provided, dynamic client registration (RFC 7591) will be attempted.\n\n@deprecated Renamed to `client_id`. This spelling is still honoured.",
                            "type": "string",
                            "deprecated": true
                          },
                          "clientSecret": {
                            "description": "OAuth client secret (if required by the authorization server)\n\n@deprecated Renamed to `client_secret`. This spelling is still honoured.",
                            "type": "string",
                            "deprecated": true
                          },
                          "scope": {
                            "description": "OAuth scopes to request during authorization",
                            "type": "string"
                          },
                          "client_id": {
                            "description": "OAuth client ID. If not provided, dynamic client registration (RFC 7591) will be attempted.",
                            "type": "string"
                          },
                          "client_secret": {
                            "description": "OAuth client secret (if required by the authorization server)",
                            "type": "string"
                          }
                        },
                        "additionalProperties": false
                      },
                      {
                        "type": "boolean",
                        "const": false
                      }
                    ]
                  },
                  "timeout": {
                    "description": "Timeout in ms for fetching tools from the MCP server. Defaults to 5000 (5 seconds) if not specified.",
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "type",
                  "url"
                ],
                "additionalProperties": false
              }
            ]
          },
          {
            "type": "object",
            "properties": {
              "enabled": {
                "type": "boolean"
              }
            },
            "required": [
              "enabled"
            ],
            "additionalProperties": false
          }
        ]
      }
    },
    "enableAllProjectMcpServers": {
      "description": "Automatically approve every MCP server declared in the project's committed .mcp.json. Security: leave off so untrusted repo servers require explicit opt-in.\n\n@deprecated Renamed to `enable_all_project_mcp_servers`. This spelling is still honoured.",
      "type": "boolean",
      "deprecated": true
    },
    "enabledMcpjsonServers": {
      "description": "Names of project .mcp.json MCP servers approved to connect (Claude Code parity)\n\n@deprecated Renamed to `enabled_mcpjson_servers`. This spelling is still honoured.",
      "type": "array",
      "items": {
        "type": "string"
      },
      "deprecated": true
    },
    "disabledMcpjsonServers": {
      "description": "Names of project .mcp.json MCP servers rejected — they never connect (Claude Code parity)\n\n@deprecated Renamed to `disabled_mcpjson_servers`. This spelling is still honoured.",
      "type": "array",
      "items": {
        "type": "string"
      },
      "deprecated": true
    },
    "formatter": {
      "description": "Code formatters run after a file is edited, keyed by formatter name. Override the command or file extensions of a built-in, add your own, disable one with `disabled: true`, or set this whole field to false to format nothing.",
      "anyOf": [
        {
          "type": "boolean",
          "const": false
        },
        {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "object",
            "properties": {
              "disabled": {
                "type": "boolean"
              },
              "command": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "environment": {
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {
                  "type": "string"
                }
              },
              "extensions": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "additionalProperties": false
          }
        }
      ]
    },
    "lsp": {
      "description": "Language servers used for diagnostics and symbol lookup, keyed by server id. Override a built-in's command, add a server of your own (`extensions` is required for those), disable one with `disabled: true`, or set this whole field to false to run no language servers.",
      "anyOf": [
        {
          "type": "boolean",
          "const": false
        },
        {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "disabled": {
                    "type": "boolean",
                    "const": true
                  }
                },
                "required": [
                  "disabled"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "command": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "extensions": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "disabled": {
                    "type": "boolean"
                  },
                  "env": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "initialization": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {}
                  }
                },
                "required": [
                  "command"
                ],
                "additionalProperties": false
              }
            ]
          }
        }
      ]
    },
    "instructions": {
      "description": "Extra files whose contents are prepended to the system prompt, as paths or glob patterns relative to the project root. These are read in addition to the AGENTS.md files found automatically, not instead of them.",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "layout": {
      "description": "No longer has any effect. The terminal UI sizes itself to the window and has no alternative layouts; the key is still accepted so older config files keep validating.",
      "deprecated": true,
      "ref": "LayoutConfig",
      "type": "string",
      "enum": [
        "auto",
        "stretch"
      ]
    },
    "permission": {
      "description": "What may run without asking. Each tool maps to allow (run silently), ask (prompt first) or deny (refuse outright); bash and edit can also take per-pattern rules so, say, `git status` is allowed while `git push` still prompts.",
      "ref": "PermissionConfig",
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "__originalKeys": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "read": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "edit": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "glob": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "grep": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "list": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "bash": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "task": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "external_directory": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "todowrite": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "todoread": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "question": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "webfetch": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "websearch": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "codesearch": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "lsp": {
              "ref": "PermissionRuleConfig",
              "anyOf": [
                {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                },
                {
                  "ref": "PermissionObjectConfig",
                  "type": "object",
                  "propertyNames": {
                    "type": "string"
                  },
                  "additionalProperties": {
                    "ref": "PermissionActionConfig",
                    "type": "string",
                    "enum": [
                      "ask",
                      "allow",
                      "deny"
                    ]
                  }
                }
              ]
            },
            "doom_loop": {
              "ref": "PermissionActionConfig",
              "type": "string",
              "enum": [
                "ask",
                "allow",
                "deny"
              ]
            },
            "additionalDirectories": {
              "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.\n\n@deprecated Renamed to `additional_directories`. This spelling is still honoured.",
              "type": "array",
              "items": {
                "type": "string"
              },
              "deprecated": true
            },
            "workspaceRoot": {
              "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.\n\n@deprecated Renamed to `workspace_root`. This spelling is still honoured.",
              "type": "string",
              "deprecated": true
            },
            "additional_directories": {
              "description": "Extra directories agents may operate in beyond the workspace root. Org policy can pin these as an immutable directory boundary.",
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "workspace_root": {
              "description": "Policy-pinned workspace root. Highest-precedence directory boundary; overrides the env var.",
              "type": "string"
            }
          },
          "additionalProperties": {
            "ref": "PermissionRuleConfig",
            "anyOf": [
              {
                "ref": "PermissionActionConfig",
                "type": "string",
                "enum": [
                  "ask",
                  "allow",
                  "deny"
                ]
              },
              {
                "ref": "PermissionObjectConfig",
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {
                  "ref": "PermissionActionConfig",
                  "type": "string",
                  "enum": [
                    "ask",
                    "allow",
                    "deny"
                  ]
                }
              }
            ]
          }
        },
        {
          "ref": "PermissionActionConfig",
          "type": "string",
          "enum": [
            "ask",
            "allow",
            "deny"
          ]
        }
      ]
    },
    "permissions": {
      "description": "Claude Code-style structured permissions: allow/deny/ask rule strings plus defaultMode and disableBypassPermissionsMode. Merged with `permission` (structured rules take precedence). See https://100xprompt.com/docs/permissions",
      "ref": "PermissionsConfig",
      "type": "object",
      "properties": {
        "allow": {
          "description": "CC-style allow rules, e.g. \"Bash(git status:*)\", \"Edit\"",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "deny": {
          "description": "CC-style deny rules — deny always wins over allow for a tool",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "ask": {
          "description": "CC-style ask rules — force a prompt even when another rule allows",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "defaultMode": {
          "description": "Permission mode new sessions start in. --permission-mode and mid-session toggles still override it.",
          "ref": "PermissionModeConfig",
          "type": "string",
          "enum": [
            "default",
            "acceptEdits",
            "plan",
            "auto",
            "bypassPermissions"
          ]
        },
        "disableBypassPermissionsMode": {
          "description": "When \"disable\", removes bypassPermissions from the settable modes for this project.",
          "type": "string",
          "const": "disable"
        }
      },
      "additionalProperties": false
    },
    "tools": {
      "description": "Superseded by `permission`. Kept working by translation: true becomes an allow rule and false a deny rule for that tool name, with write/edit/patch/multiedit all collapsing onto the single `edit` permission. Anything set in `permission` overrides the result, so prefer that.",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "boolean"
      }
    },
    "enterprise": {
      "description": "Settings for an organisation-hosted deployment.",
      "type": "object",
      "properties": {
        "url": {
          "description": "Base URL of your organisation's 100xprompt deployment, used to fetch managed configuration.",
          "type": "string"
        }
      },
      "additionalProperties": false
    },
    "compaction": {
      "default": {
        "auto": {
          "enabled": true,
          "compactionThresholdPct": 82,
          "tailPreserveTurns": 4,
          "summaryMaxTokens": 4000,
          "rehydrateFileCount": 5
        },
        "micro": {
          "enabled": true,
          "maxToolResultTokens": 10000,
          "hotTailCount": 5,
          "coldStorageBudgetTokens": 20000,
          "pruneEligibleMinTokens": 500,
          "coldPreviewTokens": 1000
        }
      },
      "type": "object",
      "properties": {
        "auto": {
          "default": {
            "enabled": true,
            "compactionThresholdPct": 95,
            "tailPreserveTurns": 4,
            "summaryMaxTokens": 4000,
            "rehydrateFileCount": 5
          },
          "type": "object",
          "properties": {
            "enabled": {
              "default": true,
              "type": "boolean"
            },
            "compactionThresholdPct": {
              "default": 95,
              "type": "number",
              "minimum": 0,
              "maximum": 100,
              "deprecated": true,
              "description": "@deprecated Renamed to `compaction_threshold_pct`. This spelling is still honoured."
            },
            "compactionThreshold": {
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `compaction_threshold`. This spelling is still honoured."
            },
            "tailPreserveTurns": {
              "default": 4,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `tail_preserve_turns`. This spelling is still honoured."
            },
            "summaryMaxTokens": {
              "default": 4000,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `summary_max_tokens`. This spelling is still honoured."
            },
            "rehydrateFileCount": {
              "default": 5,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `rehydrate_file_count`. This spelling is still honoured."
            },
            "compaction_threshold": {
              "type": "number"
            },
            "compaction_threshold_pct": {
              "default": 95,
              "type": "number",
              "minimum": 0,
              "maximum": 100
            },
            "tail_preserve_turns": {
              "default": 4,
              "type": "number"
            },
            "summary_max_tokens": {
              "default": 4000,
              "type": "number"
            },
            "rehydrate_file_count": {
              "default": 5,
              "type": "number"
            }
          },
          "additionalProperties": false
        },
        "micro": {
          "default": {
            "enabled": true,
            "maxToolResultTokens": 10000,
            "hotTailCount": 5,
            "coldStorageBudgetTokens": 20000,
            "pruneEligibleMinTokens": 500,
            "coldPreviewTokens": 1000
          },
          "type": "object",
          "properties": {
            "enabled": {
              "default": true,
              "type": "boolean"
            },
            "maxToolResultTokens": {
              "default": 10000,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `max_tool_result_tokens`. This spelling is still honoured."
            },
            "hotTailCount": {
              "default": 5,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `hot_tail_count`. This spelling is still honoured."
            },
            "coldStorageBudgetTokens": {
              "default": 20000,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `cold_storage_budget_tokens`. This spelling is still honoured."
            },
            "pruneEligibleMinTokens": {
              "default": 500,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `prune_eligible_min_tokens`. This spelling is still honoured."
            },
            "coldPreviewTokens": {
              "default": 1000,
              "type": "number",
              "deprecated": true,
              "description": "@deprecated Renamed to `cold_preview_tokens`. This spelling is still honoured."
            },
            "max_tool_result_tokens": {
              "default": 10000,
              "type": "number"
            },
            "hot_tail_count": {
              "default": 5,
              "type": "number"
            },
            "cold_storage_budget_tokens": {
              "default": 20000,
              "type": "number"
            },
            "prune_eligible_min_tokens": {
              "default": 500,
              "type": "number"
            },
            "cold_preview_tokens": {
              "default": 1000,
              "type": "number"
            }
          },
          "additionalProperties": false
        }
      },
      "additionalProperties": false
    },
    "cache": {
      "description": "Prompt-cache tuning for Anthropic-family models",
      "default": {
        "ttl": "1h"
      },
      "type": "object",
      "properties": {
        "ttl": {
          "description": "Prompt-cache lifetime for Anthropic-family models. \"1h\" (default) keeps the cached prefix alive across long pauses — writes cost 2x base but the prefix is reused instead of re-written every turn, a net win for long interactive/agentic sessions. \"5m\" writes cheapest (1.25x base input). No effect on non-Anthropic providers.\n\ndefault: `1h`",
          "default": "1h",
          "type": "string",
          "enum": [
            "5m",
            "1h"
          ],
          "examples": [
            "1h"
          ]
        }
      },
      "additionalProperties": false
    },
    "experimental": {
      "type": "object",
      "properties": {
        "channel": {
          "description": "Out-of-band permission approval. Requires HUNDREDXPROMPT_CHANNEL_RELAY=1 and the HMAC key in HUNDREDXPROMPT_CHANNEL_SECRET. There is deliberately no `secret` field here: this file is project-committed, and a committed approval key is a backdoor.",
          "type": "object",
          "properties": {
            "allow": {
              "description": "Responder identities (chat/user ids) permitted to approve or deny a relayed permission prompt. Empty authorizes nobody.",
              "default": [],
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "telegram": {
              "type": "object",
              "properties": {
                "token": {
                  "type": "string"
                },
                "chatID": {
                  "type": "string",
                  "deprecated": true,
                  "description": "@deprecated Renamed to `chat_id`. This spelling is still honoured."
                },
                "chat_id": {
                  "type": "string"
                }
              },
              "required": [
                "token",
                "chatID"
              ],
              "additionalProperties": false
            },
            "timeoutMs": {
              "description": "Approval deadline in ms; on expiry the relay denies. Default 600000.\n\n@deprecated Renamed to `timeout_ms`. This spelling is still honoured.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991,
              "deprecated": true
            },
            "unreachable": {
              "description": "'deny' (default) fails closed when no channel accepted the prompt; 'degrade' falls back to the local dialog. Neither can produce an allow.",
              "type": "string",
              "enum": [
                "deny",
                "degrade"
              ]
            },
            "timeout_ms": {
              "description": "Approval deadline in ms; on expiry the relay denies. Default 600000.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            }
          },
          "additionalProperties": false
        },
        "hook": {
          "type": "object",
          "properties": {
            "file_edited": {
              "type": "object",
              "propertyNames": {
                "type": "string"
              },
              "additionalProperties": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "command": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "environment": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string"
                      },
                      "additionalProperties": {
                        "type": "string"
                      }
                    }
                  },
                  "required": [
                    "command"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "session_completed": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "command": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "environment": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  }
                },
                "required": [
                  "command"
                ],
                "additionalProperties": false
              }
            }
          },
          "additionalProperties": false
        },
        "chatMaxRetries": {
          "description": "Number of retries for chat completions on failure\n\n@deprecated Renamed to `chat_max_retries`. This spelling is still honoured.",
          "type": "number",
          "deprecated": true
        },
        "disable_paste_summary": {
          "type": "boolean"
        },
        "skillEvolve": {
          "description": "Self-evolving skills (offline, validation-gated). Disabled by default.",
          "type": "object",
          "properties": {
            "enabled": {
              "description": "Automatically run validation-gated skill evolution on a daily throttle. Default FALSE (manual only — run `100xprompt skills evolve <name>` yourself). Set true to let 100xprompt self-improve your skills in the background, always behind the validation gate (a skill is only changed if it measurably improves on your recent sessions).",
              "default": false,
              "type": "boolean"
            },
            "skills": {
              "description": "Restrict auto-evolution to these skill names. Empty/omitted evolves every discovered skill. Manual `skills evolve <name>` is unaffected by this list.",
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "optimizerModel": {
              "description": "Model (provider/model) that proposes skill edits. Defaults to a strong cheap teacher.",
              "type": "string"
            },
            "gateMetric": {
              "description": "Gate comparison metric. 'hard' (default) = binary failure-mode coverage; 'soft' = partial-credit (sensitive to incremental edits); 'mixed' = weighted blend of both (see mixedWeight).",
              "type": "string",
              "enum": [
                "hard",
                "soft",
                "mixed"
              ]
            },
            "mixedWeight": {
              "description": "For gateMetric 'mixed': weight given to soft coverage in [0,1]. Default 0.5.",
              "type": "number",
              "minimum": 0,
              "maximum": 1
            },
            "autonomousLr": {
              "description": "Autonomous learning-rate: scale the per-pass edit budget up/down from recent gate outcomes instead of a fixed budget. Default false (fixed budget).",
              "type": "boolean"
            },
            "slowUpdate": {
              "description": "Epoch-level slow update: maintain a protected long-horizon guidance section in the skill that step edits can't touch. Default false.",
              "type": "boolean"
            },
            "dream": {
              "description": "Dream rollouts + associative recall (synthetic augmentation for sparse data). Default off.",
              "type": "object",
              "properties": {
                "rollouts": {
                  "description": "Synthesize this many contrastive variations per real replay item when held-out data is thin. >1 enables dream augmentation.",
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 9007199254740991
                },
                "recallK": {
                  "description": "Associative recall: pull the K most task-similar past items into tonight's replay set. >0 enables recall.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "additionalProperties": false
            }
          },
          "additionalProperties": false
        },
        "promptSuggestion": {
          "description": "Suggested next prompt after each turn (experimental, side-model). Disabled by default.",
          "type": "object",
          "properties": {
            "enabled": {
              "description": "After each turn ends, a cheap side-model reads the recent conversation and proposes a suggested next prompt in the TUI input footer (accept to fill the input, ignore to dismiss). Default FALSE — fully inert when off: no model call, no render. Interactive CLI only; never fires for SDK/headless/subagent sessions.",
              "default": false,
              "type": "boolean"
            },
            "variant": {
              "description": "Suggestion prompt variant. 'user_intent' (default) predicts what the user would naturally type next; 'stated_intent' currently shares the same prompt.",
              "type": "string",
              "enum": [
                "user_intent",
                "stated_intent"
              ]
            }
          },
          "additionalProperties": false
        },
        "batch_tool": {
          "description": "Enable the batch tool",
          "type": "boolean"
        },
        "pluginIsolation": {
          "description": "Run the plugin host in a supervised child process (the VS Code extension-host model): plugins execute out-of-process over JSON-RPC stdio, so a crashing plugin cannot take the agent down and a hung plugin hook is killed and the child restarted (bounded by a restart budget; on exhaustion plugins degrade to unavailable while the agent keeps running). Default FALSE — the in-process plugin host is used. Plugin-provided tools and auth are not served in isolated mode.",
          "type": "boolean"
        },
        "persistentRetry": {
          "description": "Persistent (unattended) transport retry. Disabled by default — strictly additive, interactive behavior unchanged when off.",
          "type": "object",
          "properties": {
            "enabled": {
              "description": "Unattended/long-running agentic tasks: keep retrying retryable provider failures (429/529/5xx/network) past the interactive ceiling, with capped backoff + heartbeat waits, until maxWaitMs elapses. Default FALSE — interactive sessions stay bounded (fast-fail to the session retry countdown). Background calls still bail on 529; aborts still cancel instantly.",
              "default": false,
              "type": "boolean"
            },
            "maxWaitMs": {
              "description": "Hard cap on TOTAL time spent in persistent transport retries for one request. Default 7200000 (2h). The request always fails once this elapses — persistent retry never loops forever.",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            },
            "maxDelayMs": {
              "description": "Per-attempt backoff ceiling in persistent mode. Default 60000 (60s). Server-directed Retry-After waits are honored in full (clamped to the remaining maxWaitMs budget).",
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            }
          },
          "additionalProperties": false
        },
        "openTelemetry": {
          "description": "Enable OpenTelemetry spans for AI SDK calls (using the 'experimental_telemetry' flag)\n\n@deprecated Renamed to `open_telemetry`. This spelling is still honoured.",
          "type": "boolean",
          "deprecated": true
        },
        "telemetry": {
          "description": "Opt in to the privacy-first audit/telemetry sink. Disabled by default; can be force-disabled via DO_NOT_TRACK or HUNDREDXPROMPT_TELEMETRY_DISABLE.",
          "type": "boolean"
        },
        "telemetryEndpoint": {
          "description": "Destination URL for telemetry batches. No default — self-hosted / privacy-sensitive by design.\n\n@deprecated Renamed to `telemetry_endpoint`. This spelling is still honoured.",
          "type": "string",
          "deprecated": true
        },
        "telemetryHeaders": {
          "description": "Optional headers (e.g. auth) sent with every telemetry batch.\n\n@deprecated Renamed to `telemetry_headers`. This spelling is still honoured.",
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string"
          },
          "deprecated": true
        },
        "telemetryMode": {
          "description": "Telemetry wire format: generic JSON batch ('json') or OTLP-compatible logs ('otlp').\n\n@deprecated Renamed to `telemetry_mode`. This spelling is still honoured.",
          "type": "string",
          "enum": [
            "json",
            "otlp"
          ],
          "deprecated": true
        },
        "telemetrySampleRate": {
          "description": "Global telemetry sampling rate (0..1, default 1 = keep all). Multiplies each sink's own sampleRate to form its effective keep-probability.\n\n@deprecated Renamed to `telemetry_sample_rate`. This spelling is still honoured.",
          "type": "number",
          "minimum": 0,
          "maximum": 1,
          "deprecated": true
        },
        "telemetrySinks": {
          "description": "Multi-sink telemetry routing. When set (non-empty), fully replaces the single telemetryEndpoint field; each sink samples, segments (general/privileged) and retries through its own disk queue independently. Config-driven only — remote/fetched killswitches are out of scope.\n\n@deprecated Renamed to `telemetry_sinks`. This spelling is still honoured.",
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "endpoint": {
                "description": "Destination URL for this sink's batches. No default — self-hosted / privacy-sensitive.",
                "type": "string"
              },
              "headers": {
                "description": "Optional headers (e.g. auth) sent with every batch for this sink.",
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {
                  "type": "string"
                }
              },
              "mode": {
                "description": "Wire format for this sink: generic JSON batch ('json') or OTLP-compatible logs ('otlp').",
                "type": "string",
                "enum": [
                  "json",
                  "otlp"
                ]
              },
              "access": {
                "description": "'general' (default) receives the sanitized payload with PII-tagged _PROTO_* fields stripped; 'privileged' receives the full payload including _PROTO_* — point only at a trusted first-party store.",
                "type": "string",
                "enum": [
                  "general",
                  "privileged"
                ]
              },
              "enabled": {
                "description": "Per-sink killswitch. Default true; set false to skip this sink entirely (no payload built).",
                "type": "boolean"
              },
              "sampleRate": {
                "description": "Per-sink sampling rate (0..1, default 1 = keep all).\n\n@deprecated Renamed to `sample_rate`. This spelling is still honoured.",
                "type": "number",
                "minimum": 0,
                "maximum": 1,
                "deprecated": true
              },
              "sample_rate": {
                "description": "Per-sink sampling rate (0..1, default 1 = keep all).",
                "type": "number",
                "minimum": 0,
                "maximum": 1
              }
            },
            "required": [
              "endpoint"
            ],
            "additionalProperties": false
          },
          "deprecated": true
        },
        "primary_tools": {
          "description": "Tools that should only be available to primary agents.",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "continue_loop_on_deny": {
          "description": "Continue the agent loop when a tool call is denied",
          "type": "boolean"
        },
        "verificationGate": {
          "description": "Verification-gated stopping: the agent loop cannot end a turn (stop) until a verifier emits a pass verdict (e.g. `bun run typecheck`). Default false — the loop stops as before.",
          "type": "boolean"
        },
        "mcp_timeout": {
          "description": "Timeout in milliseconds for model context protocol (MCP) requests",
          "type": "integer",
          "exclusiveMinimum": 0,
          "maximum": 9007199254740991
        },
        "chat_max_retries": {
          "description": "Number of retries for chat completions on failure",
          "type": "number"
        },
        "open_telemetry": {
          "description": "Enable OpenTelemetry spans for AI SDK calls (using the 'experimental_telemetry' flag)",
          "type": "boolean"
        },
        "telemetry_endpoint": {
          "description": "Destination URL for telemetry batches. No default — self-hosted / privacy-sensitive by design.",
          "type": "string"
        },
        "telemetry_headers": {
          "description": "Optional headers (e.g. auth) sent with every telemetry batch.",
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string"
          }
        },
        "telemetry_mode": {
          "description": "Telemetry wire format: generic JSON batch ('json') or OTLP-compatible logs ('otlp').",
          "type": "string",
          "enum": [
            "json",
            "otlp"
          ]
        },
        "telemetry_sample_rate": {
          "description": "Global telemetry sampling rate (0..1, default 1 = keep all). Multiplies each sink's own sampleRate to form its effective keep-probability.",
          "type": "number",
          "minimum": 0,
          "maximum": 1
        },
        "telemetry_sinks": {
          "description": "Multi-sink telemetry routing. When set (non-empty), fully replaces the single telemetryEndpoint field; each sink samples, segments (general/privileged) and retries through its own disk queue independently. Config-driven only — remote/fetched killswitches are out of scope.",
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "endpoint": {
                "description": "Destination URL for this sink's batches. No default — self-hosted / privacy-sensitive.",
                "type": "string"
              },
              "headers": {
                "description": "Optional headers (e.g. auth) sent with every batch for this sink.",
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {
                  "type": "string"
                }
              },
              "mode": {
                "description": "Wire format for this sink: generic JSON batch ('json') or OTLP-compatible logs ('otlp').",
                "type": "string",
                "enum": [
                  "json",
                  "otlp"
                ]
              },
              "access": {
                "description": "'general' (default) receives the sanitized payload with PII-tagged _PROTO_* fields stripped; 'privileged' receives the full payload including _PROTO_* — point only at a trusted first-party store.",
                "type": "string",
                "enum": [
                  "general",
                  "privileged"
                ]
              },
              "enabled": {
                "description": "Per-sink killswitch. Default true; set false to skip this sink entirely (no payload built).",
                "type": "boolean"
              },
              "sampleRate": {
                "description": "Per-sink sampling rate (0..1, default 1 = keep all).\n\n@deprecated Renamed to `sample_rate`. This spelling is still honoured.",
                "type": "number",
                "minimum": 0,
                "maximum": 1,
                "deprecated": true
              },
              "sample_rate": {
                "description": "Per-sink sampling rate (0..1, default 1 = keep all).",
                "type": "number",
                "minimum": 0,
                "maximum": 1
              }
            },
            "required": [
              "endpoint"
            ],
            "additionalProperties": false
          }
        }
      },
      "additionalProperties": false
    },
    "env": {
      "description": "Environment variables injected into the agent's tool environment (e.g. Bash, hooks). Keys and values are plain strings; tools that spawn subprocesses should merge these into their environment.",
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "string"
      }
    },
    "includeCoAuthoredBy": {
      "description": "Whether to append a Co-Authored-By trailer to git commits. Defaults to true. Set to false to suppress the trailer (e.g. for repositories that enforce clean commit footers).\n\n@deprecated Renamed to `include_co_authored_by`. This spelling is still honoured.",
      "type": "boolean",
      "deprecated": true
    },
    "statusline": {
      "description": "Shell command to execute for custom footer status text. Receives session context as JSON on stdin and its stdout is rendered as trailing text in the TUI footer.",
      "type": "string"
    },
    "worktree": {
      "description": "Ergonomics for git worktrees created by the enter_worktree tool",
      "type": "object",
      "properties": {
        "sparsePaths": {
          "description": "Cone-mode sparse-checkout paths. When non-empty, new worktrees check out only these paths instead of the full tree — cheap to branch from a huge repo. Leave unset for a normal full checkout.\n\n@deprecated Renamed to `sparse_paths`. This spelling is still honoured.",
          "type": "array",
          "items": {
            "type": "string"
          },
          "deprecated": true
        },
        "symlinkDirectories": {
          "description": "Directories (e.g. ['node_modules', '.venv']) to symlink from a new worktree back to the main repo, avoiding a costly reinstall. Skipped when the source is missing or the target already exists.\n\n@deprecated Renamed to `symlink_directories`. This spelling is still honoured.",
          "type": "array",
          "items": {
            "type": "string"
          },
          "deprecated": true
        },
        "sparse_paths": {
          "description": "Cone-mode sparse-checkout paths. When non-empty, new worktrees check out only these paths instead of the full tree — cheap to branch from a huge repo. Leave unset for a normal full checkout.",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "symlink_directories": {
          "description": "Directories (e.g. ['node_modules', '.venv']) to symlink from a new worktree back to the main repo, avoiding a costly reinstall. Skipped when the source is missing or the target already exists.",
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "additionalProperties": false
    },
    "log_level": {
      "description": "Lowest severity written to the log file. DEBUG is the most detailed and ERROR the least.",
      "ref": "LogLevel",
      "type": "string",
      "enum": [
        "DEBUG",
        "INFO",
        "WARN",
        "ERROR"
      ]
    },
    "sandbox_auto_approve": {
      "description": "Skip the bash permission prompt for commands the sandbox actually contains, since the kernel is already enforcing the boundary. Default: ON wherever the sandbox is active. Commands that can exfiltrate data (curl, ssh, rsync…), dangerous commands, and denied/plan-mode commands always still prompt. Set false to always prompt.",
      "type": "boolean"
    },
    "enable_all_project_mcp_servers": {
      "description": "Automatically approve every MCP server declared in the project's committed .mcp.json. Security: leave off so untrusted repo servers require explicit opt-in.",
      "type": "boolean"
    },
    "enabled_mcpjson_servers": {
      "description": "Names of project .mcp.json MCP servers approved to connect (Claude Code parity)",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "disabled_mcpjson_servers": {
      "description": "Names of project .mcp.json MCP servers rejected — they never connect (Claude Code parity)",
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "include_co_authored_by": {
      "description": "Whether to append a Co-Authored-By trailer to git commits. Defaults to true. Set to false to suppress the trailer (e.g. for repositories that enforce clean commit footers).",
      "type": "boolean"
    },
    "auto_update": {
      "description": "What to do when a newer release exists: true installs it in the background, 'notify' only mentions it and leaves the upgrade to you, false stops checking altogether.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "const": "notify"
        }
      ]
    },
    "auto_share": {
      "description": "Superseded by `share`. Setting this to true is rewritten to `share: \"auto\"` when the config loads, and only when `share` is not set — so if you set both, `share` wins. Nothing else reads this key.",
      "type": "boolean"
    }
  },
  "additionalProperties": false,
  "allowComments": true,
  "allowTrailingCommas": true
}