{
  "openapi": "3.1.0",
  "info": {
    "title": "VoiceStudio Local API",
    "version": "0.5.0",
    "description": "The open-source desktop application's local API. Filesystem, model installation, settings, diagnostics, and administration operations run only on the customer's machine."
  },
  "paths": {
    "/health": {
      "get": {
        "summary": "Health",
        "operationId": "health_health_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/model/status": {
      "get": {
        "summary": "Model Status",
        "description": "Report model loading state for frontend warm-up indicators.",
        "operationId": "model_status_model_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ModelStatusResponse"
                }
              }
            }
          }
        }
      }
    },
    "/model/loaded": {
      "get": {
        "summary": "Loaded Models",
        "description": "List all currently loaded models for the flush dropdown (MM2-04).\nThin delegation to the model_lifecycle facade — shape unchanged:\n``{models, count}``.",
        "operationId": "loaded_models_model_loaded_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/model/unload/{model_id}": {
      "post": {
        "summary": "Unload Model",
        "description": "Unload a specific model by id (MM2-04). Delegates to model_lifecycle;\nan unknown id maps to HTTP 400. ``tts`` | ``diarization`` |\n``sidecar:<id>`` | ``sidecars``.",
        "operationId": "unload_model_model_unload__model_id__post",
        "parameters": [
          {
            "name": "model_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Model Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/info": {
      "get": {
        "summary": "System Info",
        "description": "Settings page system info — model, tokens, data dir, timeout.\n\nThis endpoint MUST never throw — it's called on every Settings page load\nand a 500 here blocks the entire UI from rendering system details.",
        "operationId": "system_info_system_info_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SystemInfoResponse"
                }
              }
            }
          }
        }
      }
    },
    "/system/logs": {
      "get": {
        "summary": "System Logs",
        "description": "Tail the rolling runtime log — everything Python logged since last rotation.\n\nBack-stop: if the rolling log doesn't exist yet (fresh install, disk error),\nfall back to the crash log so the UI always has something to show.",
        "operationId": "system_logs_system_logs_get",
        "parameters": [
          {
            "name": "tail",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 200,
              "title": "Tail"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/logs/tauri": {
      "get": {
        "summary": "System Logs Tauri",
        "description": "Tail the Tauri plugin log (or backend stdout redirect, whichever exists).",
        "operationId": "system_logs_tauri_system_logs_tauri_get",
        "parameters": [
          {
            "name": "tail",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 200,
              "title": "Tail"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/logs/stream": {
      "get": {
        "summary": "Stream Logs",
        "description": "Server-Sent Events stream of new log lines.\n\nThe client opens an EventSource connection and receives new lines as they\nare appended to the log file.  This replaces the polling pattern used by\nthe LogsFooter component.\n\nUsage (frontend)::\n\n    const es = new EventSource('/system/logs/stream?source=backend');\n    es.onmessage = (e) => { const lines = JSON.parse(e.data); ... };",
        "operationId": "stream_logs_system_logs_stream_get",
        "parameters": [
          {
            "name": "source",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "'backend' or 'tauri'",
              "default": "backend",
              "title": "Source"
            },
            "description": "'backend' or 'tauri'"
          },
          {
            "name": "interval",
            "in": "query",
            "required": false,
            "schema": {
              "type": "number",
              "maximum": 10,
              "minimum": 0.3,
              "description": "Poll interval in seconds",
              "default": 1,
              "title": "Interval"
            },
            "description": "Poll interval in seconds"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/logs/clear": {
      "post": {
        "summary": "Clear System Logs",
        "description": "Truncate the rolling runtime log and the crash log (what the Backend tab reads).",
        "operationId": "clear_system_logs_system_logs_clear_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/logs/tauri/clear": {
      "post": {
        "summary": "Clear Tauri Logs",
        "description": "Truncate whichever Tauri-side log files we know about. OS-level rotation may recreate them.",
        "operationId": "clear_tauri_logs_system_logs_tauri_clear_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/sysinfo": {
      "get": {
        "summary": "Get Sys Info",
        "operationId": "get_sys_info_sysinfo_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SysinfoResponse"
                }
              }
            }
          }
        }
      }
    },
    "/system/flush-memory": {
      "post": {
        "summary": "Flush Memory",
        "description": "Aggressively release RAM/VRAM by clearing caches and running GC.\n\nWhen unload_model=true, the TTS model is fully unloaded and will be\nre-loaded lazily on the next generation request.",
        "operationId": "flush_memory_system_flush_memory_post",
        "parameters": [
          {
            "name": "unload_model",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Unload Model"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/notifications": {
      "get": {
        "summary": "System Notifications",
        "description": "Return actionable notifications for the UI notification panel.\n\nEach notification has:\n  - id: unique key (for dismiss tracking)\n  - level: \"info\" | \"warn\" | \"error\"\n  - title: short heading\n  - message: longer description\n  - action: optional {\"label\": str, \"type\": \"navigate|link|api\", \"target\": str}",
        "operationId": "system_notifications_system_notifications_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/last-run-crash": {
      "get": {
        "summary": "Get Last Run Crash",
        "description": "Newest unclean-shutdown record from the previous backend run (#1164)\n— the deployment-agnostic twin of the desktop shell's crash marker\n(`get_last_backend_crash`), for browser/dev/Docker frontends that have no\nshell to ask. Version-gated like the shell's markers: records from a\ndifferent release than the running build are ignored (kept on disk).",
        "operationId": "get_last_run_crash_system_last_run_crash_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/last-run-crash/ack": {
      "post": {
        "summary": "Ack Last Run Crash",
        "description": "Mark the newest unclean-shutdown record as seen. Watermark semantics\n(like the shell's ack): the record itself is retained so bug reports can\nstill attach the evidence; a NEWER death re-arms the notice.",
        "operationId": "ack_last_run_crash_system_last_run_crash_ack_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/crash/ack": {
      "post": {
        "summary": "Ack Crash",
        "description": "Mark the current crash log as seen — dismisses the\n'crash-last-session' notification until the log changes again.",
        "operationId": "ack_crash_system_crash_ack_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/set-env": {
      "post": {
        "summary": "Set Env Var",
        "description": "Set an environment variable at runtime, persisted across restarts.\n\nPersistent keys (proxy, FFMPEG_PATH, translation provider keys, …) are\nsaved to ``prefs.json`` so they survive backend restarts (restored at\nstartup in ``main.py``). HF_TOKEN is persisted via\n``huggingface_hub.login()`` (and cleared via ``logout()``). Other keys\nare set on ``os.environ`` for the running process.\n\nThe loopback-origin gate that previously lived inline here is now applied\nat the router level via `dependencies=[Depends(require_admin)]` on\n`router` — see the top of this file. Every route on this router is\ngated, including this one. The 403 body and behavior are unchanged.",
        "operationId": "set_env_var_system_set_env_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "type": "object",
                "title": "Body"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/clean-audio": {
      "post": {
        "summary": "Clean Audio",
        "description": "Accept a raw mic recording, run demucs vocal isolation, return clean WAV.",
        "operationId": "clean_audio_clean_audio_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_clean_audio_clean_audio_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/asr-backends": {
      "get": {
        "summary": "Asr Backends",
        "description": "List all registered ASR backends and their availability.",
        "operationId": "asr_backends_system_asr_backends_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/hf-token/state": {
      "get": {
        "summary": "Hf Token State",
        "description": "Return the 3-source HF token cascade state for the Settings UI\n(Wave 2 React panel consumes this). Never returns the raw token —\nonly a masked preview, whoami username, and per-source validity.",
        "operationId": "hf_token_state_system_hf_token_state_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/errors/recent": {
      "get": {
        "summary": "Recent Errors",
        "description": "Recent unhandled backend errors, newest first — structured, deduped\n(count per fingerprint), classified (error_class), pre-scrubbed. The\nbug-report pipeline reads this to auto-attach the most recent backend\nfailure; Settings → Logs can render it as a triage view.",
        "operationId": "recent_errors_system_errors_recent_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 50,
              "minimum": 1,
              "default": 20,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/diagnostic-bundle": {
      "post": {
        "summary": "Diagnostic Bundle",
        "description": "Build the drag-onto-a-GitHub-issue zip (core.diagnostic_bundle):\nself-check report, recent error journal, scrubbed log tails. Returns the\nlocal path so the UI can reveal it in the file manager. The path itself\nis NOT scrubbed — this response never leaves the machine; the zip's\n*contents* are scrubbed because the zip does.",
        "operationId": "diagnostic_bundle_system_diagnostic_bundle_post",
        "parameters": [
          {
            "name": "network",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Include the hub reachability probe",
              "default": false,
              "title": "Network"
            },
            "description": "Include the hub reachability probe"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/diagnose": {
      "get": {
        "summary": "System Diagnose",
        "description": "Run the self-check suite (core.diagnose) and return the structured report.\n\nThe hub probe can block up to ~5s (and ``deep=true`` far longer), so the\nwhole run goes through a threadpool; pass ``network=false`` for an\ninstant offline report. Output is pre-scrubbed (core.scrub) — safe to\npaste into a GitHub issue.",
        "operationId": "system_diagnose_system_diagnose_get",
        "parameters": [
          {
            "name": "network",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Include the HuggingFace hub reachability probe",
              "default": true,
              "title": "Network"
            },
            "description": "Include the HuggingFace hub reachability probe"
          },
          {
            "name": "deep",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Also load the active engine and synthesize a short utterance (may cold-load the model — minutes on first run)",
              "default": false,
              "title": "Deep"
            },
            "description": "Also load the active engine and synthesize a short utterance (may cold-load the model — minutes on first run)"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/system/quarantine-status": {
      "get": {
        "summary": "Quarantine Status",
        "description": "Report whether the running .app bundle has the macOS quarantine xattr.\n\nOn non-macOS platforms or dev runs (not inside a .app bundle), always\nreturns ``{\"quarantined\": false, \"error_class\": null}``. The React\nErrorBoundary polls this endpoint on first load and renders the docs\ndeeplink when ``error_class`` is set (Plan 01-02 wired the deeplink).",
        "operationId": "quarantine_status_system_quarantine_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/network/state": {
      "get": {
        "summary": "Network State",
        "operationId": "network_state_system_network_state_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/network/enable": {
      "post": {
        "summary": "Network Enable",
        "operationId": "network_enable_system_network_enable_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/network/disable": {
      "post": {
        "summary": "Network Disable",
        "operationId": "network_disable_system_network_disable_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/tailscale/status": {
      "get": {
        "summary": "Tailscale Status",
        "operationId": "tailscale_status_system_tailscale_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/tailscale/enable": {
      "post": {
        "summary": "Tailscale Enable",
        "operationId": "tailscale_enable_system_tailscale_enable_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/system/tailscale/disable": {
      "post": {
        "summary": "Tailscale Disable",
        "operationId": "tailscale_disable_system_tailscale_disable_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/stats/usage": {
      "get": {
        "summary": "Stats Usage",
        "operationId": "stats_usage_stats_usage_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/personalities": {
      "get": {
        "summary": "List Personalities",
        "description": "Return built-in voice personality presets.",
        "operationId": "list_personalities_personalities_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/profiles": {
      "get": {
        "summary": "List Profiles",
        "operationId": "list_profiles_profiles_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "post": {
        "summary": "Create Profile",
        "description": "Create a voice profile (spec: docs/specs/voice-studio-unification.md §5).\n\nkind='clone'  — requires `ref_audio` (the user's reference recording).\nkind='design' — requires `vd_states` (JSON of category picks); the server\n                renders a deterministic sample WAV (seed 42, same path as\n                archetype materialization) and stores it as the profile's\n                reference so the voice identity is stable across runs.",
        "operationId": "create_profile_profiles_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_create_profile_profiles_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}": {
      "get": {
        "summary": "Get Profile",
        "description": "Full profile record for the voice profile page.",
        "operationId": "get_profile_profiles__profile_id__get",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "put": {
        "summary": "Update Profile",
        "description": "Partial update — only fields set on the payload are changed.",
        "operationId": "update_profile_profiles__profile_id__put",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProfileUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Delete Profile",
        "operationId": "delete_profile_profiles__profile_id__delete",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}/hosted-sync": {
      "post": {
        "summary": "Sync Profile To Hosted",
        "description": "Explicitly copy a consent-verified local clone to the hosted library.\n\nThis is deliberately not part of local profile creation: merely creating a\nprofile must never upload biometric source audio. The hosted service records\nthe existing spoken-consent evidence as its versioned attestation; it does\nnot receive the consent recording itself.",
        "operationId": "sync_profile_to_hosted_profiles__profile_id__hosted_sync_post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}/usage": {
      "get": {
        "summary": "Get Profile Usage",
        "description": "Where has this voice been used? Synth-history + segment counts per project.",
        "operationId": "get_profile_usage_profiles__profile_id__usage_get",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}/audio": {
      "get": {
        "summary": "Get Profile Audio",
        "operationId": "get_profile_audio_profiles__profile_id__audio_get",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}/lock": {
      "post": {
        "summary": "Lock Profile",
        "operationId": "lock_profile_profiles__profile_id__lock_post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "$ref": "#/components/schemas/Body_lock_profile_profiles__profile_id__lock_post"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}/unlock": {
      "post": {
        "summary": "Unlock Profile",
        "operationId": "unlock_profile_profiles__profile_id__unlock_post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/profiles/{profile_id}/consent": {
      "post": {
        "summary": "Record Consent",
        "operationId": "record_consent_profiles__profile_id__consent_post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_record_consent_profiles__profile_id__consent_post"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Revoke Consent",
        "operationId": "revoke_consent_profiles__profile_id__consent_delete",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/export": {
      "post": {
        "summary": "Export File",
        "operationId": "export_file_export_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ExportRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/export/record": {
      "post": {
        "summary": "Record Export",
        "operationId": "record_export_export_record_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ExportRecordRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/export/history": {
      "get": {
        "summary": "Get Export History",
        "operationId": "get_export_history_export_history_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/export/reveal": {
      "post": {
        "summary": "Reveal In Folder",
        "operationId": "reveal_in_folder_export_reveal_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RevealRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/generate": {
      "post": {
        "summary": "Generate Speech",
        "operationId": "generate_speech_generate_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_generate_speech_generate_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/history": {
      "get": {
        "summary": "List History",
        "description": "The newest 50 generations plus every starred take, newest first, kept to\nrows whose audio still exists on disk.\n\nStarred takes ride along past the 50-row window so a keeper can never age\noff the rail. Rows whose WAV was deleted out-of-band (cleared outputs dir,\nmanual cleanup) used to come back anyway and render dead players that 404\non every fetch; prune them here so the UI never sees them again.",
        "operationId": "list_history_history_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Clear History",
        "operationId": "clear_history_history_delete",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/history/{history_id}/starred": {
      "put": {
        "summary": "Set History Starred",
        "description": "Star/unstar a take. Starred takes survive the retention cap and always\nappear in GET /history regardless of the recency window.",
        "operationId": "set_history_starred_history__history_id__starred_put",
        "parameters": [
          {
            "name": "history_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "History Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_StarBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/history/{history_id}": {
      "delete": {
        "summary": "Delete Single History",
        "operationId": "delete_single_history_history__history_id__delete",
        "parameters": [
          {
            "name": "history_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "History Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/parse-subtitle-text": {
      "post": {
        "summary": "Dub Parse Subtitle Text",
        "description": "Parse pasted subtitle text into timed cues. Stateless — no job, no I/O.\n\nA thin wrapper over `services.srt_parser.parse_srt` so the client's\n\"paste a translation\" flow reuses the exact lenient parser the .srt\nimport path uses (BOM / CRLF / `.`-vs-`,` ms / missing indices, plus\nde-overlapping). Unlike `/dub/import-srt/{job_id}` this mutates\nnothing: the caller maps these cues onto the segments it already has,\nkeeping the existing timings and `text_original`.",
        "operationId": "dub_parse_subtitle_text_dub_parse_subtitle_text_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ParseSubtitleTextRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/import-srt/{job_id}": {
      "post": {
        "summary": "Dub Import Srt",
        "description": "Replace `job[\"segments\"]` with timestamps + text parsed from an SRT\nfile. Used as a fallback when Whisper mis-transcribes — the user can\npoint at their own pre-synced subtitles and skip ASR entirely.\n\nReturns the new segment list plus counts of any cues we had to skip or\nre-time (overlap shifts). The caller surfaces these so the user knows\nif the import wasn't lossless.",
        "operationId": "dub_import_srt_dub_import_srt__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_dub_import_srt_dub_import_srt__job_id__post"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/cleanup-segments/{job_id}": {
      "post": {
        "summary": "Dub Cleanup Segments",
        "description": "Re-run merge/stitch passes on a job's existing segments to drop fragments.",
        "operationId": "dub_cleanup_segments_dub_cleanup_segments__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/abort/{job_id}": {
      "post": {
        "summary": "Dub Abort",
        "description": "Cancel in-flight upload/transcribe subprocesses for a job.",
        "operationId": "dub_abort_dub_abort__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/history": {
      "get": {
        "summary": "List Dub History",
        "operationId": "list_dub_history_dub_history_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Clear Dub History",
        "description": "Delete persisted dub rows and their on-disk dirs (scoped to known IDs).",
        "operationId": "clear_dub_history_dub_history_delete",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/dub/history/{history_id}": {
      "delete": {
        "summary": "Delete Single Dub History",
        "operationId": "delete_single_dub_history_dub_history__history_id__delete",
        "parameters": [
          {
            "name": "history_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "History Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/preview/upload": {
      "post": {
        "summary": "Preview Upload",
        "operationId": "preview_upload_preview_upload_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_preview_upload_preview_upload_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/preview/{filename}": {
      "get": {
        "summary": "Preview Serve",
        "operationId": "preview_serve_preview__filename__get",
        "parameters": [
          {
            "name": "filename",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Filename"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/upload": {
      "post": {
        "summary": "Dub Upload",
        "description": "Accept a media upload, write to disk, queue background prep task.\n\n`input_type` is \"video\" (default) or \"audio\". Audio-only jobs (#119) skip\nscene detection, thumbnailing, and the final video mux — the transcribe →\ntranslate → TTS core is identical.\n\nReturns 202 with {job_id, task_id, filename}. Client should open SSE on\n/tasks/stream/{task_id} to monitor extract/demucs stages and wait for the\n'ready' event before starting transcription.",
        "operationId": "dub_upload_dub_upload_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_dub_upload_dub_upload_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/ingest-url": {
      "post": {
        "summary": "Dub Ingest Url",
        "description": "Ingest a remote video URL via yt-dlp. Queues background prep task.\n\nReturns 202 immediately with {job_id, task_id}. All work (download,\naudio extract, Demucs, scene detect, thumbnail) happens in the background\ntask and progress is streamed via /tasks/stream/{task_id}.",
        "operationId": "dub_ingest_url_dub_ingest_url_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DubIngestUrlRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/transcribe-stream/{job_id}": {
      "get": {
        "summary": "Dub Transcribe Stream",
        "description": "Stream per-chunk segments via SSE, then emit diarized final pass.\n\nPre-flight checks (missing job, missing audio, ASR not loaded) are emitted\nas in-stream `error` events rather than HTTP errors, because EventSource\non the client can't read non-2xx response bodies — a 503 there surfaces\nas an opaque \"network error\" instead of the actionable message we want.\n\n`num_speakers` is an optional hint passed straight to pyannote. Left unset,\npyannote auto-detects the count — but its auto-detect can collapse a\nmulti-speaker clip to a single speaker (issue #274). When the user knows\nthe exact count, supplying it forces pyannote to return that many speakers.\nOn paths that can't honor the hint exactly (inline ASR turns, the\nsilence-gap heuristic) it is never silently dropped: the heuristic cycles\nthe requested count and a `warning` SSE event tells the user how far the\nlabels can be trusted.",
        "operationId": "dub_transcribe_stream_dub_transcribe_stream__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "num_speakers",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Num Speakers"
            }
          },
          {
            "name": "per_segment_refs",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Per Segment Refs"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/transcribe/{job_id}": {
      "post": {
        "summary": "Dub Transcribe",
        "description": "Legacy synchronous transcribe (kept for the headless CLI).\n\n`num_speakers` mirrors the SSE endpoint's query param (same 1–20 clamp):\nan exact speaker count forwarded to pyannote, or cycled by the silence-gap\nheuristic when pyannote is unavailable. None → auto-detect.",
        "operationId": "dub_transcribe_dub_transcribe__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "num_speakers",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Num Speakers"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/generate/{job_id}": {
      "post": {
        "summary": "Dub Generate",
        "description": "Adds a dub generation job to the async batch task pool.",
        "operationId": "dub_generate_dub_generate__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/schemas__requests__DubRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/preview-segment/{job_id}": {
      "post": {
        "summary": "Preview Segment",
        "description": "Generate TTS for a single segment and return WAV bytes.\n\nThis is the fast path for interactive editing — 8 diffusion steps,\nno disk write, no mix. The preview IS synthetic audio leaving the app,\nso it carries the same invisible provenance mark as every other\nproducer (#1169 — \"no watermark\" here used to be an exemption).",
        "operationId": "preview_segment_dub_preview_segment__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SegmentPreviewRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tasks/stream/{task_id}": {
      "get": {
        "summary": "Stream Task",
        "description": "Universal Server-Sent Event stream for background tasks.\n\n`?after_seq=N` enables resumption: on reconnect, the client replays\npersisted events with seq > N, then (if the job is still live) attaches\nto the in-memory listener for live updates. After a server restart the\nin-memory task is gone but the persisted tail + final `jobs.status` are\nstill readable, so a mid-stream reload still sees the final state.",
        "operationId": "stream_task_tasks_stream__task_id__get",
        "parameters": [
          {
            "name": "task_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Task Id"
            }
          },
          {
            "name": "after_seq",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 0,
              "title": "After Seq"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/jobs": {
      "get": {
        "summary": "List Jobs",
        "description": "List persisted jobs, newest first.\n\n`status=active` → running + pending (what the batch-queue UI wants).\n`status=failed|done|cancelled|pending|running` → exact match.\n`project_id=...` → scope to one project.",
        "operationId": "list_jobs_jobs_get",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Status"
            }
          },
          {
            "name": "project_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Project Id"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 100,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/jobs/{job_id}": {
      "get": {
        "summary": "Get Job",
        "operationId": "get_job_jobs__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/jobs/{job_id}/events": {
      "get": {
        "summary": "List Job Events",
        "description": "Persisted SSE tail. Strict ascending seq so the client can stitch\nit onto a live feed (which starts above the last returned seq).",
        "operationId": "list_job_events_jobs__job_id__events_get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "after_seq",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 0,
              "title": "After Seq"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 500,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tasks/cancel/{task_id}": {
      "post": {
        "summary": "Cancel Task",
        "description": "Cancel a running background task (e.g. dub generation).",
        "operationId": "cancel_task_tasks_cancel__task_id__post",
        "parameters": [
          {
            "name": "task_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Task Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/tracks/{job_id}": {
      "get": {
        "summary": "Dub List Tracks",
        "operationId": "dub_list_tracks_dub_tracks__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/segments-text/{job_id}": {
      "get": {
        "summary": "Dub Segments Text",
        "description": "Per-segment texts for one generated track: ``{\"texts\": {segKey: text}}``.\n\nBacking store is ``job[\"segments_i18n\"]`` (P1.2) — the authoritative\nper-language map every generate rebuilds. The Export preview tabs use it\nto hydrate segments whose in-browser ``translations[lang]`` entry is\nmissing (tracks generated before per-language persistence, partial\nregens), so switching the preview language can't leave a mixed-language\ntranscript. Empty map when the job predates segments_i18n or the track\nwas never generated — the client keeps whatever it has.",
        "operationId": "dub_segments_text_dub_segments_text__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/download/{job_id}/{filename}": {
      "get": {
        "summary": "Dub Download",
        "operationId": "dub_download_dub_download__job_id___filename__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Mix background noise into dubbed tracks",
              "default": true,
              "title": "Preserve Bg"
            },
            "description": "Mix background noise into dubbed tracks"
          },
          {
            "name": "default_track",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "original",
              "title": "Default Track"
            }
          },
          {
            "name": "include_tracks",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Comma-separated list of tracks to include (e.g. 'original,de,es'). Empty = include all.",
              "default": "",
              "title": "Include Tracks"
            },
            "description": "Comma-separated list of tracks to include (e.g. 'original,de,es'). Empty = include all."
          },
          {
            "name": "burn_subs",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Burn subtitles into the video stream (forces re-encode). Uses dual-subtitle layout when dual=1.",
              "default": false,
              "title": "Burn Subs"
            },
            "description": "Burn subtitles into the video stream (forces re-encode). Uses dual-subtitle layout when dual=1."
          },
          {
            "name": "dual",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "When burn_subs=1, render translated on top of italicised original.",
              "default": false,
              "title": "Dual"
            },
            "description": "When burn_subs=1, render translated on top of italicised original."
          },
          {
            "name": "out_format",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Audio-only jobs (#119): output container — wav, m4a, mp3, or flac. Ignored for video jobs.",
              "default": "m4a",
              "title": "Out Format"
            },
            "description": "Audio-only jobs (#119): output container — wav, m4a, mp3, or flac. Ignored for video jobs."
          },
          {
            "name": "X-VoiceStudio-Path-Authorization",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "X-Voicestudio-Path-Authorization"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/download/{job_id}": {
      "get": {
        "summary": "Dub Download",
        "operationId": "dub_download_dub_download__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Mix background noise into dubbed tracks",
              "default": true,
              "title": "Preserve Bg"
            },
            "description": "Mix background noise into dubbed tracks"
          },
          {
            "name": "default_track",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "original",
              "title": "Default Track"
            }
          },
          {
            "name": "include_tracks",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Comma-separated list of tracks to include (e.g. 'original,de,es'). Empty = include all.",
              "default": "",
              "title": "Include Tracks"
            },
            "description": "Comma-separated list of tracks to include (e.g. 'original,de,es'). Empty = include all."
          },
          {
            "name": "burn_subs",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Burn subtitles into the video stream (forces re-encode). Uses dual-subtitle layout when dual=1.",
              "default": false,
              "title": "Burn Subs"
            },
            "description": "Burn subtitles into the video stream (forces re-encode). Uses dual-subtitle layout when dual=1."
          },
          {
            "name": "dual",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "When burn_subs=1, render translated on top of italicised original.",
              "default": false,
              "title": "Dual"
            },
            "description": "When burn_subs=1, render translated on top of italicised original."
          },
          {
            "name": "out_format",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Audio-only jobs (#119): output container — wav, m4a, mp3, or flac. Ignored for video jobs.",
              "default": "m4a",
              "title": "Out Format"
            },
            "description": "Audio-only jobs (#119): output container — wav, m4a, mp3, or flac. Ignored for video jobs."
          },
          {
            "name": "X-VoiceStudio-Path-Authorization",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "X-Voicestudio-Path-Authorization"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/media/{job_id}": {
      "get": {
        "summary": "Dub Get Media",
        "operationId": "dub_get_media_dub_media__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/preview-video/{job_id}": {
      "get": {
        "summary": "Dub Preview Video",
        "description": "Return an inline-playable MP4 with the chosen dubbed track as sole audio.\n\nCaches per lang+preserve_bg combination under exports/preview_{lang}_{bg}.mp4.\nCache is invalidated when the underlying dubbed track mtime is newer than the cache.",
        "operationId": "dub_preview_video_dub_preview_video__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "description": "Language code of the dubbed track to mux in",
              "title": "Lang"
            },
            "description": "Language code of the dubbed track to mux in"
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Preserve Bg"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/onsets/{job_id}": {
      "get": {
        "summary": "Dub Get Onsets",
        "description": "Speech-onset times for the timeline editor's snap-to-onset ticks (#280).\n\nPrefers the Demucs-isolated vocals track (clean speech energy); falls\nback to the mixed audio. Computed once per job and cached as\n``onsets.json`` in the job directory; recomputed if the source audio is\nnewer than the cache (e.g. re-ingest into the same job dir).",
        "operationId": "dub_get_onsets_dub_onsets__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/thumb/{job_id}": {
      "get": {
        "summary": "Dub Get Thumb",
        "description": "Serve the extracted dub video thumbnail (jpg). 404 if not generated.",
        "operationId": "dub_get_thumb_dub_thumb__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/audio/{job_id}": {
      "get": {
        "summary": "Dub Get Audio",
        "operationId": "dub_get_audio_dub_audio__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/preview/{job_id}/{segment_index}": {
      "get": {
        "summary": "Dub Preview Segment",
        "operationId": "dub_preview_segment_dub_preview__job_id___segment_index__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "segment_index",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "title": "Segment Index"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/qc/{job_id}": {
      "post": {
        "summary": "Dub Qc Pass",
        "description": "Re-recognize the dubbed audio and flag lines whose recognized text\ndrifts from the target text. Opt-in, never fatal: the dub is untouched —\nthis only annotates segments with a per-line drift score and a measured\nstart/end, surfaced as \"verify this line\" markers feeding incremental\nre-dub. The generated text stays authoritative (design delta from\npyvideotrans, which overwrites subtitles).",
        "operationId": "dub_qc_pass_dub_qc__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          },
          {
            "name": "drift_threshold",
            "in": "query",
            "required": false,
            "schema": {
              "type": "number",
              "default": 0.5,
              "title": "Drift Threshold"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/download-audio/{job_id}/{filename}": {
      "get": {
        "summary": "Dub Download Audio",
        "operationId": "dub_download_audio_dub_download_audio__job_id___filename__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Preserve Bg"
            }
          },
          {
            "name": "X-VoiceStudio-Path-Authorization",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "X-Voicestudio-Path-Authorization"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/download-audio/{job_id}": {
      "get": {
        "summary": "Dub Download Audio",
        "operationId": "dub_download_audio_dub_download_audio__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Preserve Bg"
            }
          },
          {
            "name": "X-VoiceStudio-Path-Authorization",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "X-Voicestudio-Path-Authorization"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/srt/{job_id}/{filename}": {
      "get": {
        "summary": "Dub Export Srt",
        "operationId": "dub_export_srt_dub_srt__job_id___filename__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "dual",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Dual"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline.",
              "title": "Lang"
            },
            "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline."
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/srt/{job_id}": {
      "get": {
        "summary": "Dub Export Srt",
        "operationId": "dub_export_srt_dub_srt__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "dual",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Dual"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline.",
              "title": "Lang"
            },
            "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline."
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/vtt/{job_id}/{filename}": {
      "get": {
        "summary": "Dub Export Vtt",
        "operationId": "dub_export_vtt_dub_vtt__job_id___filename__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "dual",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Dual"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline.",
              "title": "Lang"
            },
            "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline."
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/vtt/{job_id}": {
      "get": {
        "summary": "Dub Export Vtt",
        "operationId": "dub_export_vtt_dub_vtt__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "dual",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Dual"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline.",
              "title": "Lang"
            },
            "description": "Track language code. Emits that track's text (segments_i18n) when the job carries it; when that track was generated under Smart Fit or stretch_video, cue times come from the fitted timeline."
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/export-segments/{job_id}": {
      "get": {
        "summary": "Dub Export Segments Zip",
        "operationId": "dub_export_segments_zip_dub_export_segments__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/download-mp3/{job_id}/{filename}": {
      "get": {
        "summary": "Dub Download Mp3",
        "operationId": "dub_download_mp3_dub_download_mp3__job_id___filename__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Preserve Bg"
            }
          },
          {
            "name": "bitrate",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "192k",
              "title": "Bitrate"
            }
          },
          {
            "name": "X-VoiceStudio-Path-Authorization",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "X-Voicestudio-Path-Authorization"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/download-mp3/{job_id}": {
      "get": {
        "summary": "Dub Download Mp3",
        "operationId": "dub_download_mp3_dub_download_mp3__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          },
          {
            "name": "preserve_bg",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Preserve Bg"
            }
          },
          {
            "name": "bitrate",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "192k",
              "title": "Bitrate"
            }
          },
          {
            "name": "X-VoiceStudio-Path-Authorization",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "X-Voicestudio-Path-Authorization"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/export-stems/{job_id}": {
      "get": {
        "summary": "Dub Export Stems",
        "operationId": "dub_export_stems_dub_export_stems__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dub/translate": {
      "post": {
        "summary": "Dub Translate",
        "operationId": "dub_translate_dub_translate_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TranslateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/projects": {
      "get": {
        "summary": "List Projects",
        "operationId": "list_projects_projects_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "post": {
        "summary": "Create Project",
        "operationId": "create_project_projects_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProjectSaveRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/projects/{project_id}": {
      "get": {
        "summary": "Get Project",
        "operationId": "get_project_projects__project_id__get",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "put": {
        "summary": "Update Project",
        "operationId": "update_project_projects__project_id__put",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProjectSaveRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "summary": "Rename Project",
        "description": "Lightweight rename — updates only the project name (and updated_at),\nwithout re-serialising the whole state blob like PUT does.",
        "operationId": "rename_project_projects__project_id__patch",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProjectRenameRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Delete Project",
        "operationId": "delete_project_projects__project_id__delete",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/glossary/{project_id}": {
      "get": {
        "summary": "List Terms",
        "operationId": "list_terms_glossary__project_id__get",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "post": {
        "summary": "Add Term",
        "operationId": "add_term_glossary__project_id__post",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GlossaryTerm"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Clear Terms",
        "description": "Clear every term. `only_auto=true` keeps user-added entries.",
        "operationId": "clear_terms_glossary__project_id__delete",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          },
          {
            "name": "only_auto",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Only Auto"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/glossary/{project_id}/{term_id}": {
      "put": {
        "summary": "Update Term",
        "operationId": "update_term_glossary__project_id___term_id__put",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          },
          {
            "name": "term_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Term Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GlossaryTermUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Delete Term",
        "operationId": "delete_term_glossary__project_id___term_id__delete",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          },
          {
            "name": "term_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Term Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/glossary/{project_id}/auto-extract": {
      "post": {
        "summary": "Auto Extract",
        "description": "Ask the LLM to propose glossary entries from the project's source segments.\n\nWrites them as `auto=1` rows. Existing terms with the same (source,target)\nare NOT duplicated. Returns the full current glossary after the pass.",
        "operationId": "auto_extract_glossary__project_id__auto_extract_post",
        "parameters": [
          {
            "name": "project_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Project Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AutoExtractRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines": {
      "get": {
        "summary": "List All Engines",
        "operationId": "list_all_engines_engines_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/tts": {
      "get": {
        "summary": "List Tts Backends",
        "operationId": "list_tts_backends_engines_tts_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/asr": {
      "get": {
        "summary": "List Asr Backends",
        "operationId": "list_asr_backends_engines_asr_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/llm": {
      "get": {
        "summary": "List Llm Backends",
        "operationId": "list_llm_backends_engines_llm_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/effects/presets": {
      "get": {
        "summary": "List Effects Presets",
        "description": "Return available DSP effect presets for the dub pipeline.\n\nEach preset is a named chain of audio effects (EQ, compressor, reverb, etc.)\nthat can be applied to generated TTS audio on a per-segment basis.",
        "operationId": "list_effects_presets_engines_effects_presets_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EffectPresetsResponse"
                }
              }
            }
          }
        }
      }
    },
    "/engines/translation": {
      "get": {
        "summary": "List Translation Engines",
        "description": "Translation engines with per-engine pip-package availability.\n\nSeparate from the tts/asr/llm \"family\" endpoints because these are\npip-installable on demand rather than select-from-what's-available.\nThe UI uses this to show a one-click Install chip when the user picks\nan engine whose Python dependency isn't importable yet.",
        "operationId": "list_translation_engines_engines_translation_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/translation/{engine_id}/install": {
      "post": {
        "summary": "Install Translation Engine",
        "operationId": "install_translation_engine_engines_translation__engine_id__install_post",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/translation/{engine_id}": {
      "delete": {
        "summary": "Uninstall Translation Engine",
        "operationId": "uninstall_translation_engine_engines_translation__engine_id__delete",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/sidecar/{engine_id}/install": {
      "post": {
        "summary": "Install Sidecar Engine",
        "description": "Start (or report) the one-click install for a sidecar engine.\n\nReturns ``{status: \"started\"|\"already_running\"|\"already_installed\"}``.\n404 for engines that have no sidecar installer — the response names the\ntranslation-engine route so a mis-aimed client can self-correct.",
        "operationId": "install_sidecar_engine_engines_sidecar__engine_id__install_post",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Uninstall Sidecar Engine",
        "description": "Remove an app-managed sidecar install (checkout + venv + weights) and\nclear the persisted path. Refuses user-managed installs (a clone the user\nmade themselves) and installs with a job still running.",
        "operationId": "uninstall_sidecar_engine_engines_sidecar__engine_id__install_delete",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/sidecar/{engine_id}/install/status": {
      "get": {
        "summary": "Sidecar Install Status",
        "description": "Step-by-step status of the sidecar install job (poll while running).\n\nShape: ``{engine_id, installed, managed, install_dir, job}`` where job is\nnull before the first run, else ``{state, steps[], log[], error,\nremediation, weights_progress, started_at, finished_at}``.",
        "operationId": "sidecar_install_status_engines_sidecar__engine_id__install_status_get",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/{engine_id}/health": {
      "get": {
        "summary": "Engine Health",
        "description": "Spawn-and-ping a SubprocessBackend; ``is_available()`` for the rest.\n\nReturns:\n    { id, ok, message, latency_ms }\n\n    Never raises through to a 500: backend diagnostics stay in the local\n    log and the response carries a fixed failure message, so the UI can\n    render a per-row failure without exposing private data. Unknown engine\n    ids return 404.",
        "operationId": "engine_health_engines__engine_id__health_get",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/{engine_id}/selftest": {
      "post": {
        "summary": "Engine Selftest",
        "description": "Run a bounded, real synthesis on an available in-process TTS engine.\n\n404 for an unknown TTS id; 400 when the engine is subprocess-isolated or\nnot currently available (a real synth on either is meaningless). Never\nraises through to a 500 on a synth failure — the exception is captured into\n``ok=False`` / ``message`` so the panel renders a per-row failure.",
        "operationId": "engine_selftest_engines__engine_id__selftest_post",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SelfTestResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/select": {
      "post": {
        "summary": "Select Engine",
        "description": "Persist a family's engine pick to prefs.json. Refuses unknown backends,\nbackends whose deps aren't installed, AND backends that cannot run on THIS\nhost's hardware (routing_status == \"unavailable\") — so the UI can't silently\nbrick a pipeline by picking an engine that needs a GPU this machine lacks.\nA `cpu_fallback` pick is allowed (it runs, just slower) — only a hard\n`unavailable` is blocked. LLM is never routing-gated (its status is \"n/a\").",
        "operationId": "select_engine_engines_select_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SelectEngineRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SelectEngineResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tools/probe": {
      "post": {
        "summary": "Probe",
        "operationId": "probe_tools_probe_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProbeReq"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tools/incremental": {
      "post": {
        "summary": "Plan Incremental",
        "operationId": "plan_incremental_tools_incremental_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/IncrementalReq"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tools/direction": {
      "post": {
        "summary": "Parse Direction",
        "operationId": "parse_direction_tools_direction_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DirectionReq"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tools/rate-fit": {
      "post": {
        "summary": "Rate Fit",
        "operationId": "rate_fit_tools_rate_fit_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RateFitReq"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/tools/effects": {
      "get": {
        "summary": "List Effects",
        "description": "Return available audio effect presets (Broadcast, Cinematic, etc.).",
        "operationId": "list_effects_tools_effects_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/tools/plugins": {
      "get": {
        "summary": "List Tts Plugins",
        "description": "Return all registered TTS engine plugins and their availability.",
        "operationId": "list_tts_plugins_tools_plugins_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/tools/video-context/{job_id}": {
      "post": {
        "summary": "Analyse Video Context",
        "description": "Analyse the source video's visual context for dubbing decisions.\n\nReturns per-segment mood, brightness, and complexity cues that\ncan be used as TTS instruct hints.",
        "operationId": "analyse_video_context_tools_video_context__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/stories/encode": {
      "post": {
        "summary": "Stories Encode",
        "description": "Transcode an uploaded WAV to MP3/M4B/OGG and return the encoded bytes.\n\nProvenance note (#1169): this endpoint is a pure TRANSCODER, not a\nsynthesis producer — it never calls a TTS engine, so it must not call\nmark_synthetic (the upload may be arbitrary user audio, and marking human\nspeech as synthetic would be wrong). Audio the Stories Editor stitched\nfrom VoiceStudio generations is already marked at its producing route, and\nthe AudioSeal mark survives the lossy encode here.",
        "operationId": "stories_encode_stories_encode_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_stories_encode_stories_encode_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/models": {
      "get": {
        "summary": "List Models",
        "description": "Catalogue every known model + its on-disk install state.\n\nUses a 10 s response cache to avoid repeated ``scan_cache_dir()`` disk\nwalks when the frontend polls.",
        "operationId": "list_models_models_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/setup/recommendations": {
      "get": {
        "summary": "Recommendations",
        "description": "Return a curated model preset for the caller's device + architecture.\n\nData-driven from the ``curated_on`` field in models.yaml — adding or\nretargeting a curated pick is a catalog edit, not a code change. Only the\nTTS model is required; the ASR picks here are the optional \"best for your\nsystem\" set the wizard and Settings surface for on-demand install.",
        "operationId": "recommendations_setup_recommendations_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/setup/status": {
      "get": {
        "summary": "Setup Status",
        "description": "Snapshot the setup state so the client can pick its boot screen.",
        "operationId": "setup_status_setup_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SetupStatusResponse"
                }
              }
            }
          }
        }
      }
    },
    "/setup/preflight": {
      "get": {
        "summary": "Preflight",
        "description": "One-shot system health check for the wizard.",
        "operationId": "preflight_setup_preflight_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PreflightResponse"
                }
              }
            }
          }
        }
      }
    },
    "/setup/warmup": {
      "post": {
        "summary": "Setup Warmup",
        "description": "Trigger a model load in the background so the first dub doesn't pay\nthe cold-start tax.",
        "operationId": "setup_warmup_setup_warmup_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/setup/download-stream": {
      "get": {
        "summary": "Setup Download Stream",
        "description": "SSE: forward every HuggingFace download tqdm update as a JSON event.",
        "operationId": "setup_download_stream_setup_download_stream_get",
        "parameters": [
          {
            "name": "target",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Target"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/models/install": {
      "post": {
        "summary": "Install Model",
        "description": "Download one HF repo snapshot; progress goes through the shared\n``/setup/download-stream`` SSE feed.",
        "operationId": "install_model_models_install_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/InstallModelRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/models/install/cancel": {
      "post": {
        "summary": "Cancel Install",
        "description": "Request cancellation of an in-flight install (FDL-11).\n\nBest-effort: stops further retry attempts and marks the row cancelled. A\nsingle in-flight snapshot_download/Xet fetch isn't interruptible mid-file\nin hf_hub 1.7.2, so an already-streaming file finishes; the cancel takes\neffect at the next retry boundary. Clears the cooldown so the user can\nimmediately restart.",
        "operationId": "cancel_install_models_install_cancel_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/InstallModelRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/models/{repo_id}": {
      "delete": {
        "summary": "Delete Model",
        "description": "Remove every cached revision of a repo from the HF cache.",
        "operationId": "delete_model_models__repo_id__delete",
        "parameters": [
          {
            "name": "repo_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Repo Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/categories": {
      "get": {
        "summary": "List Categories",
        "description": "List all voice gallery categories.",
        "operationId": "list_categories_gallery_categories_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/gallery/voices": {
      "get": {
        "summary": "List Voices",
        "description": "List voices in the gallery, optionally filtered by category or search.",
        "operationId": "list_voices_gallery_voices_get",
        "parameters": [
          {
            "name": "category",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "description": "Filter by category",
              "title": "Category"
            },
            "description": "Filter by category"
          },
          {
            "name": "search",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "description": "Search by name or character",
              "title": "Search"
            },
            "description": "Search by name or character"
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 200,
              "minimum": 1,
              "default": 50,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/voices/{voice_id}": {
      "get": {
        "summary": "Get Voice",
        "description": "Get a specific voice from the gallery.",
        "operationId": "get_voice_gallery_voices__voice_id__get",
        "parameters": [
          {
            "name": "voice_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Voice Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Delete Voice",
        "description": "Delete a voice from the gallery.",
        "operationId": "delete_voice_gallery_voices__voice_id__delete",
        "parameters": [
          {
            "name": "voice_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Voice Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "summary": "Update Voice",
        "description": "Update voice metadata — name, tags, is_favorite.",
        "operationId": "update_voice_gallery_voices__voice_id__patch",
        "parameters": [
          {
            "name": "voice_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Voice Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": true,
                "title": "Body"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/search/youtube": {
      "post": {
        "summary": "Search Youtube",
        "description": "Search a source site (via yt-dlp) for clips matching the user's query.\n\nThe query is user-supplied; the project ships no celebrity/character seed\nlist. Users are responsible for the licensing of whatever they import.",
        "operationId": "search_youtube_gallery_search_youtube_post",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "description": "User-supplied search terms or video title",
              "title": "Query"
            },
            "description": "User-supplied search terms or video title"
          },
          {
            "name": "category",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Free-form tag stored with results",
              "default": "import",
              "title": "Category"
            },
            "description": "Free-form tag stored with results"
          },
          {
            "name": "max_results",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 20,
              "minimum": 1,
              "default": 5,
              "title": "Max Results"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/download": {
      "post": {
        "summary": "Download Youtube Clip",
        "description": "Download a clip from YouTube for voice cloning.",
        "operationId": "download_youtube_clip_gallery_download_post",
        "parameters": [
          {
            "name": "video_url",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "description": "YouTube video URL",
              "title": "Video Url"
            },
            "description": "YouTube video URL"
          },
          {
            "name": "start_time",
            "in": "query",
            "required": false,
            "schema": {
              "type": "number",
              "minimum": 0,
              "description": "Start time in seconds",
              "default": 0,
              "title": "Start Time"
            },
            "description": "Start time in seconds"
          },
          {
            "name": "duration",
            "in": "query",
            "required": false,
            "schema": {
              "type": "number",
              "maximum": 30,
              "minimum": 1,
              "description": "Clip duration in seconds",
              "default": 10,
              "title": "Duration"
            },
            "description": "Clip duration in seconds"
          },
          {
            "name": "character_name",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "description": "Name to label this clip",
              "title": "Character Name"
            },
            "description": "Name to label this clip"
          },
          {
            "name": "category",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Free-form tag stored with the clip",
              "default": "import",
              "title": "Category"
            },
            "description": "Free-form tag stored with the clip"
          },
          {
            "name": "description",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Optional description",
              "default": "",
              "title": "Description"
            },
            "description": "Optional description"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/upload": {
      "post": {
        "summary": "Upload Voice Clip",
        "description": "Upload a voice clip directly to the gallery.",
        "operationId": "upload_voice_clip_gallery_upload_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_upload_voice_clip_gallery_upload_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/voices/{voice_id}/save-as-profile": {
      "post": {
        "summary": "Save Voice As Profile",
        "description": "Save a gallery voice as a voice profile for cloning.",
        "operationId": "save_voice_as_profile_gallery_voices__voice_id__save_as_profile_post",
        "parameters": [
          {
            "name": "voice_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Voice Id"
            }
          },
          {
            "name": "profile_name",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "description": "Name for the voice profile",
              "title": "Profile Name"
            },
            "description": "Name for the voice profile"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/voices/{voice_id}/preview": {
      "get": {
        "summary": "Preview Voice",
        "description": "Get a voice clip for preview playback.",
        "operationId": "preview_voice_gallery_voices__voice_id__preview_get",
        "parameters": [
          {
            "name": "voice_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Voice Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/voices/batch-delete": {
      "post": {
        "summary": "Batch Delete Voices",
        "description": "Delete multiple voices by ID list.",
        "operationId": "batch_delete_voices_gallery_voices_batch_delete_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "type": "object",
                "title": "Body"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/gallery/voices/{voice_id}/to-profile": {
      "post": {
        "summary": "Voice To Profile",
        "description": "Create a voice profile from a gallery clip.",
        "operationId": "voice_to_profile_gallery_voices__voice_id__to_profile_post",
        "parameters": [
          {
            "name": "voice_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Voice Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/archetypes/categories": {
      "get": {
        "summary": "List Categories",
        "description": "The seven use-case categories the gallery is organized by.",
        "operationId": "list_categories_archetypes_categories_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/archetypes/previews/status": {
      "get": {
        "summary": "Preview Gallery Status",
        "description": "Consent state, coverage and freshness for the Settings line.",
        "operationId": "preview_gallery_status_archetypes_previews_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/archetypes/previews": {
      "put": {
        "summary": "Set Preview Gallery",
        "description": "Turn pre-rendered previews on or off.\n\nTurning it ON is the user's explicit yes to an outbound call, and is the\nonly thing that ever starts one — there is no on-install background fetch.\nThe featured set is pulled right here so the yes has a visible effect;\nfailures are silent by design (``fetch_featured`` swallows them) and leave\npreviews rendering locally.",
        "operationId": "set_preview_gallery_archetypes_previews_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Body_set_preview_gallery_archetypes_previews_put"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/archetypes/previews/check": {
      "post": {
        "summary": "Check Preview Gallery",
        "description": "Manual \"check now\" — bypasses the 24 h throttle, never the signature.",
        "operationId": "check_preview_gallery_archetypes_previews_check_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/archetypes": {
      "get": {
        "summary": "List Archetypes Endpoint",
        "description": "Filtered, paginated view over the archetype catalog.\n\n``q`` is a free-text substring match over the archetype name/instruct so a\nvoice picker can search the *entire* several-hundred-voice catalog by typing\n(the facet filters alone can't reach a specific voice by name). Content-free\nand local — it just narrows the in-memory catalog.",
        "operationId": "list_archetypes_endpoint_archetypes_get",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Q"
            }
          },
          {
            "name": "use_case",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Use Case"
            }
          },
          {
            "name": "gender",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Gender"
            }
          },
          {
            "name": "age",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Age"
            }
          },
          {
            "name": "pitch",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Pitch"
            }
          },
          {
            "name": "accent",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Accent"
            }
          },
          {
            "name": "whisper",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Whisper"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Lang"
            }
          },
          {
            "name": "featured",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Featured"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 500,
              "minimum": 1,
              "default": 60,
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/archetypes/{archetype_id}": {
      "get": {
        "summary": "Get Archetype Endpoint",
        "operationId": "get_archetype_endpoint_archetypes__archetype_id__get",
        "parameters": [
          {
            "name": "archetype_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Archetype Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/archetypes/{archetype_id}/preview/state": {
      "get": {
        "summary": "Preview Archetype State",
        "description": "Where the next ``/preview`` for this archetype would come from.\n\nTouches neither the model nor the network, so a picker can label a voice\n(\"may take a moment\", \"download a model first\") *before* it commits to a\nrequest that may take 40 seconds or fail.",
        "operationId": "preview_archetype_state_archetypes__archetype_id__preview_state_get",
        "parameters": [
          {
            "name": "archetype_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Archetype Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/archetypes/{archetype_id}/preview": {
      "get": {
        "summary": "Preview Archetype",
        "description": "Serve a short preview clip — from the gallery, the cache, or the engine.",
        "operationId": "preview_archetype_archetypes__archetype_id__preview_get",
        "parameters": [
          {
            "name": "archetype_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Archetype Id"
            }
          },
          {
            "name": "local",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Bypass gallery audio after a client decode failure",
              "default": false,
              "title": "Local"
            },
            "description": "Bypass gallery audio after a client decode failure"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/archetypes/{archetype_id}/use": {
      "post": {
        "summary": "Use Archetype",
        "description": "Materialize an archetype into a reusable voice profile.\n\nRenders a reference sample (so the voice has a concrete identity and a\npreview) and inserts a ``voice_profiles`` row carrying the archetype's\ninstruct + language. The profile then shows up everywhere voices are\npicked (Dub / Generate / Clone).\n\nNever sourced from the voice gallery, no matter how cheap that would be:\nthis WAV lands in ``VOICES_DIR`` as the profile's reference audio, so a\ndownloaded, lossily-encoded MP3 would silently become the sample every\nfuture clone of this voice is built from. It renders locally or it fails.",
        "operationId": "use_archetype_archetypes__archetype_id__use_post",
        "parameters": [
          {
            "name": "archetype_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Archetype Id"
            }
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Name"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/design/describe": {
      "post": {
        "summary": "Describe Voice",
        "description": "Parse a free-text description into design attrs + a validator-safe instruct.\n\nResponse shape::\n\n    {\n      \"attrs\":     {\"Gender\": \"female\", \"Age\": \"elderly\", ... or \"Auto\"},\n      \"instruct\":  \"female, elderly, low pitch, british accent\",\n      \"matched\":   [{\"category\": \"Age\", \"token\": \"elderly\", \"phrase\": \"elderly\"}, ...],\n      \"unmatched\": [\"slightly raspy\"]\n    }",
        "operationId": "describe_voice_design_describe_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DescribeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Describe Voice Design Describe Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/community/sources": {
      "get": {
        "summary": "Community Sources",
        "description": "The content repos the gallery loads from (default: omnivoice-gallery).",
        "operationId": "community_sources_community_sources_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/community/manifest": {
      "get": {
        "summary": "Community Manifest",
        "operationId": "community_manifest_community_manifest_get",
        "parameters": [
          {
            "name": "refresh",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Refresh"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/community/items": {
      "get": {
        "summary": "Community Items",
        "operationId": "community_items_community_items_get",
        "parameters": [
          {
            "name": "use_case",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Use Case"
            }
          },
          {
            "name": "gender",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Gender"
            }
          },
          {
            "name": "type",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Type"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Lang"
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Q"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 500,
              "minimum": 1,
              "default": 60,
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          },
          {
            "name": "refresh",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Refresh"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/community/submit-url": {
      "get": {
        "summary": "Community Submit Url",
        "description": "Build the prefilled GitHub submission URL (server-free, local-first).",
        "operationId": "community_submit_url_community_submit_url_get",
        "parameters": [
          {
            "name": "type",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "preset",
              "title": "Type"
            }
          },
          {
            "name": "source",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Source"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/community/items/{item_id}/preview": {
      "get": {
        "summary": "Community Preview",
        "description": "Serve every community preview through the authenticated same-origin API.",
        "operationId": "community_preview_community_items__item_id__preview_get",
        "parameters": [
          {
            "name": "item_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Item Id"
            }
          },
          {
            "name": "local",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Bypass canonical gallery audio after decode failure",
              "default": false,
              "title": "Local"
            },
            "description": "Bypass canonical gallery audio after decode failure"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/community/items/{item_id}/use": {
      "post": {
        "summary": "Community Use",
        "description": "Materialize a community item into a reusable voice profile.\n\nPreset → render through the archetype engine. Voice → download the\n(host-allow-listed, SHA-256-verified) reference clip. Both create a\n``voice_profiles`` row usable everywhere voices are picked.",
        "operationId": "community_use_community_items__item_id__use_post",
        "parameters": [
          {
            "name": "item_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Item Id"
            }
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Name"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/batch/enqueue": {
      "post": {
        "summary": "Enqueue Batch Job",
        "description": "Enqueue a video for batch dubbing.\n\nThe video is saved to disk and a job is added to the queue.\nReturns the job ID for status polling.",
        "operationId": "enqueue_batch_job_batch_enqueue_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_enqueue_batch_job_batch_enqueue_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/batch/jobs": {
      "get": {
        "summary": "List Batch Jobs",
        "description": "List batch jobs, optionally filtered by status.",
        "operationId": "list_batch_jobs_batch_jobs_get",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Status"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 50,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/batch/jobs/{job_id}": {
      "get": {
        "summary": "Get Batch Job",
        "description": "Get the status of a specific batch job.",
        "operationId": "get_batch_job_batch_jobs__job_id__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Delete Batch Job",
        "description": "Delete a batch job record and its video file.",
        "operationId": "delete_batch_job_batch_jobs__job_id__delete",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/batch/jobs/{job_id}/cancel": {
      "post": {
        "summary": "Cancel Batch Job",
        "description": "Cancel a queued or running batch job.",
        "operationId": "cancel_batch_job_batch_jobs__job_id__cancel_post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/batch/download/{job_id}/{lang}": {
      "get": {
        "summary": "Download Batch Output",
        "description": "Download a completed batch job's output video for a given language.",
        "operationId": "download_batch_output_batch_download__job_id___lang__get",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          },
          {
            "name": "lang",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/watermark/detect": {
      "post": {
        "summary": "Detect Audio Watermark",
        "description": "Upload an audio file and check whether it contains a VoiceStudio watermark.\n\nReturns confidence score, decoded message, and source attribution.",
        "operationId": "detect_audio_watermark_watermark_detect_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_detect_audio_watermark_watermark_detect_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/watermark/status": {
      "get": {
        "summary": "Watermark Status",
        "description": "Return current watermark configuration.",
        "operationId": "watermark_status_watermark_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/watermark/settings": {
      "post": {
        "summary": "Update Watermark Settings",
        "description": "Update watermark preferences.",
        "operationId": "update_watermark_settings_watermark_settings_post",
        "parameters": [
          {
            "name": "invisible",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Invisible"
            }
          },
          {
            "name": "visible_audio",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Visible Audio"
            }
          },
          {
            "name": "visible_video",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Visible Video"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/transcribe": {
      "post": {
        "summary": "Transcribe Audio",
        "description": "Transcribe an audio file to text.\n\nArgs:\n    audio: The audio file to transcribe.\n    language: Optional language hint (not currently used; auto-detected).\n    model: Whisper model size (legacy; ignored in dual-mode architecture).\n    mode: 'fast' (default) uses MLX Turbo for speed; 'accurate' uses\n          WhisperX with forced alignment for word-level timing.\n    refine: Opt-in local-LLM cleanup of the final text (disfluencies,\n          self-corrections, punctuation) — same pipeline the live\n          dictation socket uses. Off by default so MCP/CLI callers don't\n          pay LLM latency unless they ask; honours the user's\n          Settings → Dictation-refinement config and silently passes\n          through when no LLM backend is configured. The raw ``text``\n          is always returned; ``refined_text`` is added only when the\n          LLM actually changed something.\n\nReturns:\n    {\n        \"text\": \"full transcription\",\n        \"refined_text\": \"cleaned text\",   # only when refine=true changed it\n        \"segments\": [ {\"start\": 0.0, \"end\": 1.5, \"text\": \"...\"}, ... ],\n        \"language\": \"en\",\n        \"duration_s\": 4.2,\n        \"transcription_time_s\": 0.8,\n        \"engine\": \"mlx-whisper\"\n    }",
        "operationId": "transcribe_audio_transcribe_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_transcribe_audio_transcribe_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/dictation/models": {
      "get": {
        "summary": "List Dictation Models",
        "description": "The seven sherpa-onnx dictation models + install state.\n\nEach entry: id, repo_id, label, tag (\"offline\"|\"streaming\"), recommended,\nsize_gb, languages, kind, and install state (installed/installing). The\n``installed`` flag is computed from the same HF cache the model store reads,\nso it matches the model-store row state.",
        "operationId": "list_dictation_models_dictation_models_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/dictation/prefs": {
      "get": {
        "summary": "Get Dictation Prefs",
        "operationId": "get_dictation_prefs_dictation_prefs_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "post": {
        "summary": "Set Dictation Prefs",
        "description": "Persist any subset of the dictation prefs. Validates ``mode`` and\n``model_id`` so a bad value can't wedge the capture engine.",
        "operationId": "set_dictation_prefs_dictation_prefs_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DictationPrefsUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/audio/speech": {
      "post": {
        "tags": [
          "OpenAI-Compatible Audio API"
        ],
        "summary": "Create Speech",
        "description": "Generate audio from text. Compatible with OpenAI's POST /v1/audio/speech.",
        "operationId": "create_speech_v1_audio_speech_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SpeechRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/audio/transcriptions": {
      "post": {
        "tags": [
          "OpenAI-Compatible Audio API"
        ],
        "summary": "Create Transcription",
        "description": "Transcribe audio to text. Compatible with OpenAI's POST /v1/audio/transcriptions.",
        "operationId": "create_transcription_v1_audio_transcriptions_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_create_transcription_v1_audio_transcriptions_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/audio/voices": {
      "get": {
        "tags": [
          "OpenAI-Compatible Audio API"
        ],
        "summary": "List Voices",
        "description": "List available voices. VoiceStudio extension to the OpenAI API.",
        "operationId": "list_voices_v1_audio_voices_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/marketplace/export/{profile_id}": {
      "post": {
        "tags": [
          "Voice Marketplace"
        ],
        "summary": "Export Profile",
        "description": "Export a voice profile as a downloadable .omnivoice bundle (ZIP).",
        "operationId": "export_profile_marketplace_export__profile_id__post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/marketplace/import": {
      "post": {
        "tags": [
          "Voice Marketplace"
        ],
        "summary": "Import Profile",
        "description": "Import a voice profile from a .omnivoice bundle.",
        "operationId": "import_profile_marketplace_import_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_import_profile_marketplace_import_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/marketplace/publish/{profile_id}": {
      "post": {
        "tags": [
          "Voice Marketplace"
        ],
        "summary": "Publish To Marketplace",
        "description": "Publish a voice profile to the local marketplace directory.\n\nThis saves a .omnivoice bundle to the marketplace folder so other\nVoiceStudio instances on the same machine (or shared network drive)\ncan discover and import it.",
        "operationId": "publish_to_marketplace_marketplace_publish__profile_id__post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          },
          {
            "name": "tags",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Comma-separated tags",
              "default": "",
              "title": "Tags"
            },
            "description": "Comma-separated tags"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/marketplace/browse": {
      "get": {
        "tags": [
          "Voice Marketplace"
        ],
        "summary": "Browse Marketplace",
        "description": "List available .omnivoice bundles in the local marketplace directory.",
        "operationId": "browse_marketplace_marketplace_browse_get",
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "description": "Search by name or tags",
              "title": "Search"
            },
            "description": "Search by name or tags"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/marketplace/install/{filename}": {
      "post": {
        "tags": [
          "Voice Marketplace"
        ],
        "summary": "Install From Marketplace",
        "description": "Import a voice profile from a bundle in the local marketplace directory.",
        "operationId": "install_from_marketplace_marketplace_install__filename__post",
        "parameters": [
          {
            "name": "filename",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Filename"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/marketplace/{filename}": {
      "delete": {
        "tags": [
          "Voice Marketplace"
        ],
        "summary": "Remove From Marketplace",
        "description": "Remove a bundle from the local marketplace directory.",
        "operationId": "remove_from_marketplace_marketplace__filename__delete",
        "parameters": [
          {
            "name": "filename",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Filename"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/personas/export/{profile_id}": {
      "post": {
        "summary": "Export Persona",
        "description": "Build + stream a `.ovsvoice` bundle for a profile.",
        "operationId": "export_persona_personas_export__profile_id__post",
        "parameters": [
          {
            "name": "profile_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Profile Id"
            }
          },
          {
            "name": "license_spdx",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "LicenseRef-VoiceStudio-Personal",
              "title": "License Spdx"
            }
          },
          {
            "name": "tags",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "Tags"
            }
          },
          {
            "name": "include_reference",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": true,
              "title": "Include Reference"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/personas/import": {
      "post": {
        "summary": "Import Persona",
        "description": "Create a new voice profile from a `.ovsvoice` (or legacy `.omnivoice`) bundle.",
        "operationId": "import_persona_personas_import_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_import_persona_personas_import_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/personas/inspect": {
      "post": {
        "summary": "Inspect Persona",
        "description": "Read a bundle's manifest + consent summary WITHOUT writing any file or row.",
        "operationId": "inspect_persona_personas_inspect_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_inspect_persona_personas_inspect_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/engines/sonitranslate/status": {
      "get": {
        "tags": [
          "SoniTranslate"
        ],
        "summary": "Sonitranslate Status",
        "description": "Check SoniTranslate availability.",
        "operationId": "sonitranslate_status_engines_sonitranslate_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/sonitranslate/install": {
      "post": {
        "tags": [
          "SoniTranslate"
        ],
        "summary": "Sonitranslate Install",
        "description": "Clone and set up SoniTranslate (heavy — ~15GB with models).",
        "operationId": "sonitranslate_install_engines_sonitranslate_install_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/sonitranslate/start": {
      "post": {
        "tags": [
          "SoniTranslate"
        ],
        "summary": "Sonitranslate Start",
        "description": "Start the SoniTranslate Gradio server.",
        "operationId": "sonitranslate_start_engines_sonitranslate_start_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/sonitranslate/stop": {
      "post": {
        "tags": [
          "SoniTranslate"
        ],
        "summary": "Sonitranslate Stop",
        "description": "Stop the SoniTranslate Gradio server.",
        "operationId": "sonitranslate_stop_engines_sonitranslate_stop_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/engines/sonitranslate/dub": {
      "post": {
        "tags": [
          "SoniTranslate"
        ],
        "summary": "Sonitranslate Dub",
        "description": "Run full dubbing pipeline via SoniTranslate.\n\nTranscribes, translates, generates TTS, and mixes audio.\nReturns the path to the dubbed output video.\n\nKNOWN PROVENANCE GAP (#1169, documented — not silently ignored): the\ndubbed audio is synthesized and muxed entirely inside the external\nSoniTranslate sidecar (its own venv + gradio pipeline, Edge-TTS voices),\nwhich hands back a finished video file. VoiceStudio's tensor-stage\nmark_synthetic chokepoint never sees that audio; marking it would require\na demux → embed → re-mux post-pass on the sidecar's output, which is a\nlossy re-encode of a pipeline we don't control. This opt-in engine\n(explicit install + start) is therefore NOT covered by the invisible\nAudioSeal provenance mark that every built-in synthesis path carries.",
        "operationId": "sonitranslate_dub_engines_sonitranslate_dub_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/api__routers__sonitranslate__DubRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook/plan": {
      "post": {
        "summary": "Audiobook Plan",
        "description": "Parse a script into a chapter/span plan (pure preview, no synthesis).",
        "operationId": "audiobook_plan_audiobook_plan_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AudiobookPlanRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Audiobook Plan Audiobook Plan Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook/import": {
      "post": {
        "summary": "Audiobook Import",
        "description": "Import a ``.txt``/``.md``/``.epub``/``.pdf`` into a chapter-delimited script.\n\nEPUB is parsed in spine order (stdlib only, local); PDF text is extracted\nwith pypdf (pure-Python) then chapterized; plain text gets ``# `` headings\ninserted ahead of obvious chapter-title lines. Returns the script text (for\nthe editor) + the resulting chapter count.",
        "operationId": "audiobook_import_audiobook_import_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_audiobook_import_audiobook_import_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Audiobook Import Audiobook Import Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook/cover": {
      "post": {
        "summary": "Audiobook Cover",
        "description": "Upload a cover image; returns a server-side ``path`` to pass back as\n``cover_path`` in the synth request. Validated here (jpg/png + size cap) and\nagain at render time.",
        "operationId": "audiobook_cover_audiobook_cover_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_audiobook_cover_audiobook_cover_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Audiobook Cover Audiobook Cover Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook/preview": {
      "post": {
        "summary": "Audiobook Preview",
        "description": "Render a single chapter so the user can audition it before the full run.\n\nReuses the same content-addressed cache as the job, so a preview warms the\ncache (the later full render reuses it) and a re-preview is instant.",
        "operationId": "audiobook_preview_audiobook_preview_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AudiobookPreviewRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Audiobook Preview Audiobook Preview Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook": {
      "post": {
        "summary": "Audiobook Synthesize",
        "description": "Synthesize a chapterized audiobook from a script, streaming SSE progress.",
        "operationId": "audiobook_synthesize_audiobook_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AudiobookRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/longform/render": {
      "post": {
        "summary": "Longform Render",
        "description": "Render a pre-built chapter/span plan (the Stories Editor's compiled\ncast+lines) through the shared chapterized renderer — same resume, loudness,\ncover, metadata, and output formats as the Audiobook job.",
        "operationId": "longform_render_longform_render_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LongformRenderRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook/jobs": {
      "get": {
        "summary": "List Resumable Jobs",
        "description": "List interrupted longform renders that can be resumed — a work dir that\nstill holds a resume manifest (a job left mid-render by a crash/quit). The\nids come from scanning the filesystem, so the UI can offer one-click resume.",
        "operationId": "list_resumable_jobs_audiobook_jobs_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response List Resumable Jobs Audiobook Jobs Get"
                }
              }
            }
          }
        }
      }
    },
    "/audiobook/resume/{job_id}": {
      "post": {
        "summary": "Resume Longform",
        "description": "Resume an interrupted longform render from its persisted manifest. The\nalready-rendered chapters are content-addressed in the shared cache, so they\nreturn instantly — only the unrendered chapters synthesize again. Streams the\nsame SSE event shape as the original render, under the original job_id.",
        "operationId": "resume_longform_audiobook_resume__job_id__post",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Job Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/longform/jobs": {
      "get": {
        "summary": "Longform Jobs",
        "description": "Finished Audiobook + Story renders, newest-first, ready to re-download.\n\nEach item's ``output`` is served at ``/audio/<output>``. Never 500s — on any\nbackend hiccup it returns an empty list rather than an error.\n\n``job_store`` is bound at module import (top of file), NOT re-imported\nhere at call time. A call-time ``from core import job_store`` re-resolves\nthrough ``sys.modules`` on every request — and several test suites purge\nand re-import the whole ``core``/``services`` namespace under a\ntemporary OMNIVOICE_DATA_DIR (the ``isolated_db`` pattern,\ntests/smoke/test_boot_smoke.py, …) without restoring the old module\ntree. After one of those ran, the call-time import resolved a stale\nmodule world whose DB_PATH pointed at a different SQLite file than the\none the test seeded through its collection-time bindings, so the library\ncame back without the seeded jobs (the order-dependent\ntest_route_handler_returns_jobs_envelope full-suite flake). The\nmodule-level binding keeps this route in the same world as whoever\nimported this module. Regression:\ntests/test_longform_jobs.py::test_route_survives_leaked_module_world_purge.",
        "operationId": "longform_jobs_longform_jobs_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 500,
              "minimum": 1,
              "default": 50,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Longform Jobs Longform Jobs Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/pronunciation": {
      "get": {
        "summary": "List Entries",
        "operationId": "list_entries_pronunciation_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "post": {
        "summary": "Create Entry",
        "operationId": "create_entry_pronunciation_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PronEntry"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/pronunciation/{entry_id}": {
      "put": {
        "summary": "Update Entry",
        "operationId": "update_entry_pronunciation__entry_id__put",
        "parameters": [
          {
            "name": "entry_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Entry Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PronEntryUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "summary": "Delete Entry",
        "operationId": "delete_entry_pronunciation__entry_id__delete",
        "parameters": [
          {
            "name": "entry_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Entry Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/pronunciation/test": {
      "post": {
        "summary": "Test Substitution",
        "description": "Show the post-substitution text for ``req.text`` — no model call.\n\nApplies the same dictionary + inline ``[[…]]`` resolution the synth path\nruns, so the user sees exactly what the engine will be handed.",
        "operationId": "test_substitution_pronunciation_test_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PronTestRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/pronunciation/export": {
      "get": {
        "summary": "Export Entries",
        "description": "Every entry as a JSON-serializable list (round-trips ``/import``).",
        "operationId": "export_entries_pronunciation_export_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/pronunciation/import": {
      "post": {
        "summary": "Import Entries",
        "description": "Bulk-add entries. ``replace=true`` clears the table first.\n\nEach entry is validated like ``POST /pronunciation``; one bad row fails the\nwhole import (400) so the table is never left half-applied.",
        "operationId": "import_entries_pronunciation_import_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PronImportRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/hf-token": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Save Hf Token",
        "description": "Persist a new HF token to the encrypted settings store + the HF\ncanonical file (via huggingface_hub.login). Returns the updated\ncascade state.",
        "operationId": "save_hf_token_api_settings_hf_token_post",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_HFTokenBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "settings"
        ],
        "summary": "Clear Hf Token",
        "description": "Clear the App-source token. Optionally also call huggingface_hub.logout\nto clear the canonical HF file. Returns the updated cascade state.",
        "operationId": "clear_hf_token_api_settings_hf_token_delete",
        "parameters": [
          {
            "name": "also_clear_hf_cli",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Also Clear Hf Cli"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/hf-token/state": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Hf Token State",
        "description": "3-source HF token cascade state for the Settings UI.\n\n``fresh=1`` drops the resolver's whoami validation cache first so the\nresponse re-runs whoami for every source — this is what the panel's\n\"Test now\" button sends. Plain GETs (panel mounts) keep the 300s cache\nso repeat Settings visits don't hammer the HF API.",
        "operationId": "get_hf_token_state_api_settings_hf_token_state_get",
        "parameters": [
          {
            "name": "fresh",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Fresh"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/perf/torch-compile-disabled": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Torch Compile Disabled",
        "description": "Return the current torch.compile-disabled toggle + the runtime platform.\nUI uses the platform to render the toggle disabled (with an explainer)\non non-Windows hosts, since the OOM is Windows-specific (issue #65).",
        "operationId": "get_torch_compile_disabled_api_settings_perf_torch_compile_disabled_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Torch Compile Disabled",
        "description": "Persist the toggle. Honoured by `services.engine_env.build_engine_env()`\nwhich injects TORCH_COMPILE_DISABLE=1 on Windows when enabled.",
        "operationId": "set_torch_compile_disabled_api_settings_perf_torch_compile_disabled_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_TorchCompileBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/compute-device": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Compute Device",
        "description": "Current compute-device override state (Settings → Performance).",
        "operationId": "get_compute_device_api_settings_compute_device_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Compute Device",
        "description": "Persist the compute-device pick. Applied by the capability probe at\nthe next backend start (host caps are immutable per process — same\nrestart contract as the rest of the Performance tab). ``OMNIVOICE_DEVICE``\nalways wins over this pick; the UI shows the pin instead of pretending.",
        "operationId": "set_compute_device_api_settings_compute_device_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_ComputeDeviceBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/history-retention": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get History Retention",
        "description": "Current generation-history retention cap (Settings → Storage).",
        "operationId": "get_history_retention_api_settings_history_retention_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set History Retention",
        "description": "Persist the retention cap. Enforced after every generation: the oldest\nunstarred takes over the cap are pruned (rows + their audio files);\nstarred takes are never pruned. 0 disables pruning entirely.",
        "operationId": "set_history_retention_api_settings_history_retention_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_HistoryRetentionBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/dictation-refinement": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Dictation Refinement",
        "description": "Current refinement config + whether an LLM backend is configured.",
        "operationId": "get_dictation_refinement_api_settings_dictation_refinement_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Dictation Refinement",
        "operationId": "set_dictation_refinement_api_settings_dictation_refinement_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_RefinementBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-endpoint": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Llm Endpoint",
        "description": "Current OpenAI-compatible LLM endpoint config + live availability.",
        "operationId": "get_llm_endpoint_api_settings_llm_endpoint_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Llm Endpoint",
        "description": "Persist base URL / model / API key for the OpenAI-compatible endpoint.\n\nReuses the env-var persistence path (prefs.json, restored at startup):\nbase_url -> TRANSLATE_BASE_URL, model -> TRANSLATE_MODEL,\napi_key -> TRANSLATE_API_KEY. A None field is left unchanged; an empty\nstring clears it. Ollama ignores the key; vLLM / LM Studio require it.",
        "operationId": "set_llm_endpoint_api_settings_llm_endpoint_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_LLMEndpointBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-providers": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "List Llm Providers",
        "description": "All providers with resolved base_url/model + whether a key is configured.\n\nNever returns key material — only `has_key`/`key_from_env` booleans.",
        "operationId": "list_llm_providers_api_settings_llm_providers_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-providers/{provider_id}": {
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Save Llm Provider",
        "description": "Save a provider's key (encrypted) + optional base_url/model/account.\n\nA None field is left unchanged; an empty api_key clears the stored key.",
        "operationId": "save_llm_provider_api_settings_llm_providers__provider_id__put",
        "parameters": [
          {
            "name": "provider_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Provider Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_LLMProviderBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-providers/active": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Set Active Llm Provider",
        "operationId": "set_active_llm_provider_api_settings_llm_providers_active_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_LLMActiveBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-providers/{provider_id}/test": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Test Llm Provider",
        "description": "One cheap round-trip against a provider to prove the key/URL work.\n\nTemporarily activates the provider for the probe by resolving its config\ndirectly (does not change the persisted active selection). Returns\nlatency_ms plus, on failure, a classified ``kind`` (config / auth /\nnot_found / rate_limit / network / error) so the UI shows an actionable,\nlocalizable message instead of a raw exception string.",
        "operationId": "test_llm_provider_api_settings_llm_providers__provider_id__test_post",
        "parameters": [
          {
            "name": "provider_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Provider Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-providers/{provider_id}/models": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "List Llm Provider Models",
        "description": "List model ids the provider's key can access (OpenAI-compat /models).\n\nPowers the model-picker datalist in Settings → LLM Providers so users\ndon't have to guess model names. Read-only; failures return the same\nclassified shape as /test; capped so a huge catalog can't bloat the UI.",
        "operationId": "list_llm_provider_models_api_settings_llm_providers__provider_id__models_get",
        "parameters": [
          {
            "name": "provider_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Provider Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-skills": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "List Llm Skills",
        "description": "Every LLM skill with its toggle, routing, and resolved ready status.",
        "operationId": "list_llm_skills_api_settings_llm_skills_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/api/settings/llm-skills/{skill_id}": {
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Llm Skill",
        "description": "Toggle a skill and/or set its provider routing.\n\nField semantics match the providers PUT: an omitted field is left\nunchanged; ``provider_override: \"\"``/``null`` clears the override.\n404 for an unknown skill or an unknown provider id.",
        "operationId": "set_llm_skill_api_settings_llm_skills__skill_id__put",
        "parameters": [
          {
            "name": "skill_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Skill Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_LLMSkillBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/license": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Post License Acceptance",
        "description": "Persist a per-engine license-acceptance boolean.\n\nReturns ``{\"ok\": True, \"engine_id\": ..., \"accepted\": ...}`` so the\ncaller can update its UI without a second round-trip. Validation:\n``engine_id`` must be in the in-tree allow-list ‑‑ refuses arbitrary\nkeys so the settings table can't be polluted via this route.",
        "operationId": "post_license_acceptance_api_settings_license_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_LicenseAcceptBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Post License Acceptance Api Settings License Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/license/{engine_id}": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get License Acceptance",
        "description": "Return ``{\"engine_id\": ..., \"accepted\": bool}``.\n\nSame allow-list as the POST handler so an unknown engine id is a\n400 rather than a silent ``accepted=false`` for a non-existent\nengine.",
        "operationId": "get_license_acceptance_api_settings_license__engine_id__get",
        "parameters": [
          {
            "name": "engine_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Engine Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Get License Acceptance Api Settings License  Engine Id  Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/storage/models-dir": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Models Dir",
        "description": "Current models directory: the persisted choice (from the durable env\nfile — the same value main.py reads at startup), what's effective in this\nprocess, and the platform default.",
        "operationId": "get_models_dir_api_settings_storage_models_dir_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Models Dir",
        "description": "Set (or clear, with an empty path) the models download directory.\n\nValidates the directory is writable, then writes OMNIVOICE_CACHE_DIR to the\ndurable per-user env file so main.py applies it on the next launch. The env\nfile is the only persisted store, so GET can never diverge from what was\nsaved. Returns restart_required=True.",
        "operationId": "set_models_dir_api_settings_storage_models_dir_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_ModelsDirBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/storage": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Storage Report",
        "description": "Disk + per-category storage usage for the Settings → Storage panel.\n\n`refresh=1` bypasses the 5-minute cache and rescans. `min_free_gb`\nreuses the setup wizard's constant so both surfaces warn at the same\nthreshold.",
        "operationId": "get_storage_report_api_settings_storage_get",
        "parameters": [
          {
            "name": "refresh",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Refresh"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/storage/temp/clear": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Clear Temp Files",
        "description": "Delete VoiceStudio-owned temp files (Settings → Storage → Temporary files).\n\nRemoves only the ``omnivoice*`` entries in the OS temp dir — the exact\npopulation the storage report's \"temp\" category counts — and invalidates\nthe cached report so the next scan reflects the reclaimed space. Partial\nfailures (files held open by a running job) are returned per entry.",
        "operationId": "clear_temp_files_api_settings_storage_temp_clear_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/api/settings/hf-mirror": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Hf Mirror",
        "operationId": "get_hf_mirror_api_settings_hf_mirror_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Hf Mirror",
        "operationId": "set_hf_mirror_api_settings_hf_mirror_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_HFMirrorBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/hf-mirror/test": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Test Hf Mirror",
        "description": "Re-run the endpoint race now (the Auto panel's \"Test again\").\n\nForces fresh probes and re-caches the decision. In manual mode this is a\nno-op (an explicit endpoint is never auto-switched) — the response simply\nreflects the current state.",
        "operationId": "test_hf_mirror_api_settings_hf_mirror_test_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/api/settings/asr-openai-compat": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Asr Openai Compat",
        "operationId": "get_asr_openai_compat_api_settings_asr_openai_compat_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Asr Openai Compat",
        "operationId": "set_asr_openai_compat_api_settings_asr_openai_compat_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_ASROpenAICompatBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/asr-openai-compat/test": {
      "post": {
        "tags": [
          "settings"
        ],
        "summary": "Test Asr Openai Compat",
        "description": "Cheap connectivity probe for the \"Test connection\" button.\n\nGET {base_url}/models against the PERSISTED config — the panel saves\nfirst, then tests, same stale-config contract as\n/llm-providers/{id}/test. No audio leaves the machine, nothing is\ntranscribed. Loopback-only via the router-level guard. Always 200 with a\nstructured verdict ({ok, status, latency_ms, ...} — see\nservices.asr_backend.probe_openai_compat_server) so the UI renders\nsuccess/latency or the exact failure without a raw 500. The key is never\nlogged or echoed back.",
        "operationId": "test_asr_openai_compat_api_settings_asr_openai_compat_test_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/api/settings/changelog": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Changelog",
        "description": "Structured release notes from the shipped CHANGELOG.md (newest first).\n\nBullets are raw markdown-lite (bold leads, `code`, (#NNN) refs) — the\nfrontend renders them safely without HTML. `available: false` when this\ninstall has no changelog (never an error: the viewer just hides).",
        "operationId": "get_changelog_api_settings_changelog_get",
        "parameters": [
          {
            "name": "limit_versions",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 50,
              "minimum": 1,
              "default": 5,
              "title": "Limit Versions"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/settings/db-backup": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Db Backup State",
        "description": "Newest pre-migration database backup (or none yet). Feeds the\n\"your data is backed up before every update\" line in Settings → Updates.",
        "operationId": "get_db_backup_state_api_settings_db_backup_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/api/settings/analytics": {
      "get": {
        "tags": [
          "settings"
        ],
        "summary": "Get Analytics",
        "operationId": "get_analytics_api_settings_analytics_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "settings"
        ],
        "summary": "Set Analytics",
        "operationId": "set_analytics_api_settings_analytics_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_AnalyticsBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/media-tools/status": {
      "get": {
        "summary": "Media Tools Status",
        "description": "Per-tool {ok, path, version, origin} + background-op states.",
        "operationId": "media_tools_status_media_tools_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/media-tools/acquire": {
      "post": {
        "summary": "Media Tools Acquire",
        "description": "(Re-)fetch the pinned, checksummed static ffmpeg/ffprobe build in the\nbackground. Idempotent; poll /media-tools/status for progress.",
        "operationId": "media_tools_acquire_media_tools_acquire_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/media-tools/ytdlp/update": {
      "post": {
        "summary": "Media Tools Ytdlp Update",
        "description": "Fetch the newest yt-dlp wheel (sha256-verified against PyPI metadata)\ninto the update-surviving overlay. Applies on next backend start.",
        "operationId": "media_tools_ytdlp_update_media_tools_ytdlp_update_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/media-tools/ytdlp/restore": {
      "post": {
        "summary": "Media Tools Ytdlp Restore",
        "description": "Drop the overlay — the app-tested, locked yt-dlp takes over on next\nstart. Always safe (the locked install is never modified).",
        "operationId": "media_tools_ytdlp_restore_media_tools_ytdlp_restore_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/media-tools/{tool}/custom-path": {
      "post": {
        "summary": "Media Tools Custom Path",
        "operationId": "media_tools_custom_path_media_tools__tool__custom_path_post",
        "parameters": [
          {
            "name": "tool",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Tool"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CustomPathRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/media-tools/{tool}/use-system": {
      "post": {
        "summary": "Media Tools Use System",
        "operationId": "media_tools_use_system_media_tools__tool__use_system_post",
        "parameters": [
          {
            "name": "tool",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Tool"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/media-tools/{tool}/restore": {
      "post": {
        "summary": "Media Tools Restore",
        "operationId": "media_tools_restore_media_tools__tool__restore_post",
        "parameters": [
          {
            "name": "tool",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Tool"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/auth/session": {
      "post": {
        "tags": [
          "auth"
        ],
        "summary": "Create Session",
        "operationId": "create_session_api_auth_session_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SessionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "auth"
        ],
        "summary": "Delete Session",
        "operationId": "delete_session_api_auth_session_delete",
        "responses": {
          "204": {
            "description": "Successful Response"
          }
        }
      }
    },
    "/api/auth/ws-ticket": {
      "post": {
        "tags": [
          "auth"
        ],
        "summary": "Create Ws Ticket",
        "operationId": "create_ws_ticket_api_auth_ws_ticket_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebSocketTicketRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/mcp/bindings": {
      "get": {
        "tags": [
          "mcp"
        ],
        "summary": "List Bindings",
        "description": "All per-agent voice bindings, most-recently-seen first.",
        "operationId": "list_bindings_api_mcp_bindings_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "mcp"
        ],
        "summary": "Upsert Binding",
        "description": "Create or update the binding for an MCP client id.",
        "operationId": "upsert_binding_api_mcp_bindings_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/_BindingBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/api/mcp/bindings/{client_id}": {
      "delete": {
        "tags": [
          "mcp"
        ],
        "summary": "Delete Binding",
        "operationId": "delete_binding_api_mcp_bindings__client_id__delete",
        "parameters": [
          {
            "name": "client_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Client Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers": {
      "get": {
        "tags": [
          "workers"
        ],
        "summary": "List Workers",
        "description": "Everything the workers panel renders, in one call.",
        "operationId": "list_workers_workers_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response List Workers Workers Get"
                }
              }
            }
          }
        }
      }
    },
    "/workers/target": {
      "get": {
        "tags": [
          "workers"
        ],
        "summary": "Get Target",
        "description": "What the GPU picker shows: the choice, the resolved answer, the options.\n\n`active` is the same answer the generation path uses, so the badge cannot\nclaim work goes somewhere the router will not send it. Pass `op` for the\nsurface being rendered — omitting it answers for the target as a whole,\nwhich is what the picker's own menu asks.",
        "operationId": "get_target_workers_target_get",
        "parameters": [
          {
            "name": "op",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "Op"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Get Target Workers Target Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Set Target",
        "description": "Choose where work runs. Exactly one target is active at a time.",
        "operationId": "set_target_workers_target_post",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TargetRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Set Target Workers Target Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/enabled": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Set Enabled",
        "description": "Turn the feature on or off.\n\nOff means off: the control plane stops, the listening socket closes, and\nthe app is exactly what it was before the toggle existed.",
        "operationId": "set_enabled_workers_enabled_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EnableRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Set Enabled Workers Enabled Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/agent": {
      "get": {
        "tags": [
          "workers"
        ],
        "summary": "Agent Status",
        "description": "The other side of the same feature: is THIS machine lending its GPU?\n\nSeparate from `GET /workers`, which answers for the control plane. A\nmachine can legitimately be both — a desktop that borrows a laptop's GPU\nand lends its own to a colleague — so neither status can stand in for the\nother.",
        "operationId": "agent_status_workers_agent_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Agent Status Workers Agent Get"
                }
              }
            }
          }
        }
      }
    },
    "/workers/agent/join": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Join Control Plane",
        "description": "Redeem a join code and start working for that control plane.\n\nThis is the endpoint that makes the feature reachable. Joining used to mean\nsetting OMNIVOICE_WORKER_MODE and OMNIVOICE_WORKER_TOKEN in the environment\nand relaunching the app — a step most users will never take, on the machine\nthat is usually the least convenient to configure by hand.\n\nThe code is single-use and short-lived, so a failure here is nearly always\n\"expired\" or \"wrong address\"; it is returned verbatim rather than as a bare\n409, because the user's next action depends on which one it was.",
        "operationId": "join_control_plane_workers_agent_join_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/JoinRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Join Control Plane Workers Agent Join Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/agent/enabled": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Set Agent Enabled",
        "description": "Start or stop lending this machine, without forgetting the enrollment.\n\nOff stops the agent and clears the setting, so nothing dials out; the\npinned certificate stays, which is what lets \"on\" resume without asking for\nanother code.",
        "operationId": "set_agent_enabled_workers_agent_enabled_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EnableRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Set Agent Enabled Workers Agent Enabled Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/enrollments": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Create Enrollment",
        "description": "Mint a single-use join token.\n\nThe plaintext is returned once and never stored — the response is the only\ntime it exists outside the worker that redeems it.",
        "operationId": "create_enrollment_workers_enrollments_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EnrollRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Create Enrollment Workers Enrollments Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/{worker_id}": {
      "patch": {
        "tags": [
          "workers"
        ],
        "summary": "Update Worker",
        "operationId": "update_worker_workers__worker_id__patch",
        "parameters": [
          {
            "name": "worker_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Worker Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WorkerUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Update Worker Workers  Worker Id  Patch"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "workers"
        ],
        "summary": "Revoke Worker",
        "description": "Remove a worker — which means revoke its key, not hide the row.\n\nIts in-flight work is released so it can be retried elsewhere rather than\nwaiting out a lease on a machine that will never answer again.",
        "operationId": "revoke_worker_workers__worker_id__delete",
        "parameters": [
          {
            "name": "worker_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Worker Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Revoke Worker Workers  Worker Id  Delete"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/{worker_id}/consent": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Grant Consent",
        "description": "Record the user's explicit yes to sending their audio to this machine.",
        "operationId": "grant_consent_workers__worker_id__consent_post",
        "parameters": [
          {
            "name": "worker_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Worker Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Grant Consent Workers  Worker Id  Consent Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/{worker_id}/resume": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Clear Breaker",
        "description": "Clear a paused worker's circuit breakers.\n\nThe user fixed the machine and knows it — a breaker with no manual clear is\nthe quarantine trap the reputation system had.",
        "operationId": "clear_breaker_workers__worker_id__resume_post",
        "parameters": [
          {
            "name": "worker_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Worker Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Clear Breaker Workers  Worker Id  Resume Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/tasks": {
      "get": {
        "tags": [
          "workers"
        ],
        "summary": "List Tasks",
        "description": "Recent remote tasks, for the queue view.",
        "operationId": "list_tasks_workers_tasks_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 50,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response List Tasks Workers Tasks Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Submit Task",
        "description": "Run one task on a remote worker and wait for it. **DEV ONLY.**\n\nThis is the producer the remote pipeline never had: until it existed the\nscheduler had no caller outside the test suite, so picking a remote GPU\nchanged the badge and nothing else — every job still ran locally. It is\nthe smallest thing that makes remote execution observable end to end, not\nthe shipping surface: the GPU gateway takes over routing real generation\nand this endpoint goes with it.\n\nLoopback-only and behind the same opt-in as the rest of the feature, so a\nuser who never enabled remote workers cannot reach it at all.",
        "operationId": "submit_task_workers_tasks_post",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SubmitTaskRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Submit Task Workers Tasks Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/tasks/{task_id}/cancel": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Cancel Task",
        "operationId": "cancel_task_workers_tasks__task_id__cancel_post",
        "parameters": [
          {
            "name": "task_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Task Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Cancel Task Workers Tasks  Task Id  Cancel Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound": {
      "get": {
        "tags": [
          "workers"
        ],
        "summary": "Inbound Status",
        "operationId": "inbound_status_workers_inbound_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Inbound Status Workers Inbound Get"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound/enabled": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Set Inbound Enabled",
        "operationId": "set_inbound_enabled_workers_inbound_enabled_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/InboundEnableRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Set Inbound Enabled Workers Inbound Enabled Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound/keys": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Issue Inbound Key",
        "description": "Mint one panel's key and return the string it pastes.\n\nThe secret is in this response and nowhere else afterwards — only its hash\nis stored, so it cannot be shown again, only replaced.",
        "operationId": "issue_inbound_key_workers_inbound_keys_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/IssueKeyRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Issue Inbound Key Workers Inbound Keys Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound/keys/{key_id}": {
      "delete": {
        "tags": [
          "workers"
        ],
        "summary": "Revoke Inbound Key",
        "description": "Revoke one panel. Everyone else stays connected — the whole reason keys\nare per panel rather than one shared node key.",
        "operationId": "revoke_inbound_key_workers_inbound_keys__key_id__delete",
        "parameters": [
          {
            "name": "key_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Key Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Revoke Inbound Key Workers Inbound Keys  Key Id  Delete"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound/sessions/{session_id}/disconnect": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Disconnect Inbound Session",
        "operationId": "disconnect_inbound_session_workers_inbound_sessions__session_id__disconnect_post",
        "parameters": [
          {
            "name": "session_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Session Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Disconnect Inbound Session Workers Inbound Sessions  Session Id  Disconnect Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound/connections": {
      "post": {
        "tags": [
          "workers"
        ],
        "summary": "Add Inbound Connection",
        "description": "Paste a connection string from a GPU machine and dial it.",
        "operationId": "add_inbound_connection_workers_inbound_connections_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConnectRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": true,
                  "type": "object",
                  "title": "Response Add Inbound Connection Workers Inbound Connections Post"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/workers/inbound/connections/{endpoint}": {
      "delete": {
        "tags": [
          "workers"
        ],
        "summary": "Remove Inbound Connection",
        "operationId": "remove_inbound_connection_workers_inbound_connections__endpoint__delete",
        "parameters": [
          {
            "name": "endpoint",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Endpoint"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true,
                  "title": "Response Remove Inbound Connection Workers Inbound Connections  Endpoint  Delete"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "AudiobookPlanRequest": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          },
          "default_voice": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Voice"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "AudiobookPlanRequest"
      },
      "AudiobookPreviewRequest": {
        "properties": {
          "num_step": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 512,
                "minimum": 1
              },
              {
                "type": "null"
              }
            ],
            "title": "Num Step"
          },
          "guidance_scale": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 20,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Guidance Scale"
          },
          "position_temperature": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Position Temperature"
          },
          "class_temperature": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Class Temperature"
          },
          "postprocess_output": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Postprocess Output"
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 4294967295,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed"
          },
          "emo_vector": {
            "anyOf": [
              {
                "items": {
                  "type": "number"
                },
                "type": "array",
                "maxItems": 8,
                "minItems": 8
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Vector"
          },
          "emo_text": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 500
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Text"
          },
          "emo_alpha": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 1,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Alpha"
          },
          "vary_repeats": {
            "type": "boolean",
            "title": "Vary Repeats",
            "default": false
          },
          "text": {
            "type": "string",
            "title": "Text"
          },
          "chapter_index": {
            "type": "integer",
            "title": "Chapter Index",
            "default": 0
          },
          "default_voice": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Voice"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "lexicon": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Lexicon"
          },
          "voice_map": {
            "anyOf": [
              {
                "additionalProperties": {
                  "type": "string"
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Map"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "AudiobookPreviewRequest"
      },
      "AudiobookRequest": {
        "properties": {
          "num_step": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 512,
                "minimum": 1
              },
              {
                "type": "null"
              }
            ],
            "title": "Num Step"
          },
          "guidance_scale": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 20,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Guidance Scale"
          },
          "position_temperature": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Position Temperature"
          },
          "class_temperature": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Class Temperature"
          },
          "postprocess_output": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Postprocess Output"
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 4294967295,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed"
          },
          "emo_vector": {
            "anyOf": [
              {
                "items": {
                  "type": "number"
                },
                "type": "array",
                "maxItems": 8,
                "minItems": 8
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Vector"
          },
          "emo_text": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 500
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Text"
          },
          "emo_alpha": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 1,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Alpha"
          },
          "vary_repeats": {
            "type": "boolean",
            "title": "Vary Repeats",
            "default": false
          },
          "text": {
            "type": "string",
            "title": "Text"
          },
          "default_voice": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Voice"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "bitrate": {
            "type": "string",
            "title": "Bitrate",
            "default": "128k"
          },
          "format": {
            "type": "string",
            "title": "Format",
            "default": "m4b"
          },
          "loudness": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Loudness"
          },
          "cover_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cover Path"
          },
          "metadata": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Metadata"
          },
          "lexicon": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Lexicon"
          },
          "voice_map": {
            "anyOf": [
              {
                "additionalProperties": {
                  "type": "string"
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Map"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "AudiobookRequest"
      },
      "AutoExtractRequest": {
        "properties": {
          "source_lang": {
            "type": "string",
            "title": "Source Lang",
            "default": "en"
          },
          "target_lang": {
            "type": "string",
            "title": "Target Lang"
          },
          "segments": {
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array",
            "title": "Segments",
            "description": "[{text: '...'}] — only text is read; other fields ignored."
          },
          "max_terms": {
            "type": "integer",
            "title": "Max Terms",
            "default": 40
          }
        },
        "type": "object",
        "required": [
          "target_lang"
        ],
        "title": "AutoExtractRequest"
      },
      "Body_audiobook_cover_audiobook_cover_post": {
        "properties": {
          "cover": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Cover"
          }
        },
        "type": "object",
        "required": [
          "cover"
        ],
        "title": "Body_audiobook_cover_audiobook_cover_post"
      },
      "Body_audiobook_import_audiobook_import_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_audiobook_import_audiobook_import_post"
      },
      "Body_clean_audio_clean_audio_post": {
        "properties": {
          "audio": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Audio"
          }
        },
        "type": "object",
        "required": [
          "audio"
        ],
        "title": "Body_clean_audio_clean_audio_post"
      },
      "Body_create_profile_profiles_post": {
        "properties": {
          "name": {
            "type": "string",
            "title": "Name"
          },
          "ref_audio": {
            "anyOf": [
              {
                "type": "string",
                "contentMediaType": "application/octet-stream"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ref Audio"
          },
          "ref_text": {
            "type": "string",
            "title": "Ref Text",
            "default": ""
          },
          "instruct": {
            "type": "string",
            "title": "Instruct",
            "default": ""
          },
          "language": {
            "type": "string",
            "title": "Language",
            "default": "Auto"
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed"
          },
          "personality": {
            "type": "string",
            "title": "Personality",
            "default": ""
          },
          "kind": {
            "type": "string",
            "title": "Kind",
            "default": "clone"
          },
          "vd_states": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vd States"
          }
        },
        "type": "object",
        "required": [
          "name"
        ],
        "title": "Body_create_profile_profiles_post"
      },
      "Body_create_transcription_v1_audio_transcriptions_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File",
            "description": "Audio file to transcribe"
          },
          "model": {
            "type": "string",
            "title": "Model",
            "description": "ASR model. Accepts 'whisper-1' (maps to active engine), or an VoiceStudio engine ID: whisperx, faster-whisper, mlx-whisper, pytorch-whisper.",
            "default": "whisper-1"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language",
            "description": "Language of the input audio (ISO 639-1). Optional."
          },
          "prompt": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Prompt",
            "description": "Optional text to guide the model's style or continue a previous segment."
          },
          "response_format": {
            "type": "string",
            "title": "Response Format",
            "description": "Output format: json, text, verbose_json, srt, vtt.",
            "default": "json"
          },
          "temperature": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Temperature",
            "description": "Sampling temperature (0–1). Not used by all backends."
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_create_transcription_v1_audio_transcriptions_post"
      },
      "Body_detect_audio_watermark_watermark_detect_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_detect_audio_watermark_watermark_detect_post"
      },
      "Body_dub_import_srt_dub_import_srt__job_id__post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_dub_import_srt_dub_import_srt__job_id__post"
      },
      "Body_dub_upload_dub_upload_post": {
        "properties": {
          "video": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Video"
          },
          "job_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Job Id"
          },
          "input_type": {
            "type": "string",
            "title": "Input Type",
            "default": "video"
          }
        },
        "type": "object",
        "required": [
          "video"
        ],
        "title": "Body_dub_upload_dub_upload_post"
      },
      "Body_enqueue_batch_job_batch_enqueue_post": {
        "properties": {
          "video": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Video"
          },
          "langs": {
            "type": "string",
            "title": "Langs",
            "default": "es"
          },
          "voice_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Id"
          },
          "preserve_bg": {
            "type": "boolean",
            "title": "Preserve Bg",
            "default": true
          }
        },
        "type": "object",
        "required": [
          "video"
        ],
        "title": "Body_enqueue_batch_job_batch_enqueue_post"
      },
      "Body_generate_speech_generate_post": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "ref_audio": {
            "anyOf": [
              {
                "type": "string",
                "contentMediaType": "application/octet-stream"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ref Audio"
          },
          "ref_text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ref Text"
          },
          "instruct": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Instruct"
          },
          "duration": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Duration"
          },
          "num_step": {
            "type": "integer",
            "title": "Num Step",
            "default": 16
          },
          "guidance_scale": {
            "type": "number",
            "title": "Guidance Scale",
            "default": 2
          },
          "speed": {
            "type": "number",
            "title": "Speed",
            "default": 1
          },
          "t_shift": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "T Shift"
          },
          "denoise": {
            "type": "boolean",
            "title": "Denoise",
            "default": true
          },
          "postprocess_output": {
            "type": "boolean",
            "title": "Postprocess Output",
            "default": true
          },
          "layer_penalty_factor": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Layer Penalty Factor"
          },
          "position_temperature": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Position Temperature"
          },
          "class_temperature": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Class Temperature"
          },
          "profile_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Profile Id"
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed"
          },
          "effect_preset": {
            "type": "string",
            "title": "Effect Preset",
            "default": "broadcast"
          },
          "engine": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Engine"
          },
          "max_chunk_chars": {
            "type": "integer",
            "minimum": 0,
            "title": "Max Chunk Chars",
            "default": 800
          },
          "crossfade_ms": {
            "type": "integer",
            "maximum": 1000,
            "minimum": 0,
            "title": "Crossfade Ms",
            "default": 50
          },
          "pronounce": {
            "type": "boolean",
            "title": "Pronounce",
            "default": true
          },
          "stream": {
            "type": "boolean",
            "title": "Stream",
            "default": false
          },
          "hosted": {
            "type": "boolean",
            "title": "Hosted",
            "default": false
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "Body_generate_speech_generate_post"
      },
      "Body_import_persona_personas_import_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_import_persona_personas_import_post"
      },
      "Body_import_profile_marketplace_import_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File",
            "description": "A .omnivoice bundle file"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_import_profile_marketplace_import_post"
      },
      "Body_inspect_persona_personas_inspect_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_inspect_persona_personas_inspect_post"
      },
      "Body_lock_profile_profiles__profile_id__lock_post": {
        "properties": {
          "history_id": {
            "type": "string",
            "title": "History Id"
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed"
          }
        },
        "type": "object",
        "required": [
          "history_id"
        ],
        "title": "Body_lock_profile_profiles__profile_id__lock_post"
      },
      "Body_preview_upload_preview_upload_post": {
        "properties": {
          "video": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Video"
          }
        },
        "type": "object",
        "required": [
          "video"
        ],
        "title": "Body_preview_upload_preview_upload_post"
      },
      "Body_record_consent_profiles__profile_id__consent_post": {
        "properties": {
          "consent_audio": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Consent Audio"
          },
          "consent_text": {
            "type": "string",
            "title": "Consent Text"
          }
        },
        "type": "object",
        "required": [
          "consent_audio",
          "consent_text"
        ],
        "title": "Body_record_consent_profiles__profile_id__consent_post"
      },
      "Body_set_preview_gallery_archetypes_previews_put": {
        "properties": {
          "enabled": {
            "type": "boolean",
            "title": "Enabled"
          }
        },
        "type": "object",
        "required": [
          "enabled"
        ],
        "title": "Body_set_preview_gallery_archetypes_previews_put"
      },
      "Body_stories_encode_stories_encode_post": {
        "properties": {
          "file": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "File"
          },
          "format": {
            "type": "string",
            "title": "Format",
            "default": "mp3"
          },
          "bitrate": {
            "type": "string",
            "title": "Bitrate",
            "default": "192k"
          }
        },
        "type": "object",
        "required": [
          "file"
        ],
        "title": "Body_stories_encode_stories_encode_post"
      },
      "Body_transcribe_audio_transcribe_post": {
        "properties": {
          "audio": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Audio"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model"
          },
          "mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Mode"
          },
          "refine": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Refine"
          }
        },
        "type": "object",
        "required": [
          "audio"
        ],
        "title": "Body_transcribe_audio_transcribe_post"
      },
      "Body_upload_voice_clip_gallery_upload_post": {
        "properties": {
          "name": {
            "type": "string",
            "title": "Name"
          },
          "character": {
            "type": "string",
            "title": "Character",
            "default": ""
          },
          "category": {
            "type": "string",
            "title": "Category",
            "default": "import"
          },
          "description": {
            "type": "string",
            "title": "Description",
            "default": ""
          },
          "audio": {
            "type": "string",
            "contentMediaType": "application/octet-stream",
            "title": "Audio"
          }
        },
        "type": "object",
        "required": [
          "name",
          "audio"
        ],
        "title": "Body_upload_voice_clip_gallery_upload_post"
      },
      "ConnectRequest": {
        "properties": {
          "connection_string": {
            "type": "string",
            "maxLength": 512,
            "minLength": 1,
            "title": "Connection String"
          }
        },
        "type": "object",
        "required": [
          "connection_string"
        ],
        "title": "ConnectRequest"
      },
      "CustomPathRequest": {
        "properties": {
          "authorization": {
            "type": "string",
            "title": "Authorization"
          }
        },
        "type": "object",
        "required": [
          "authorization"
        ],
        "title": "CustomPathRequest"
      },
      "DescribeRequest": {
        "properties": {
          "description": {
            "type": "string",
            "maxLength": 2000,
            "title": "Description",
            "default": ""
          }
        },
        "type": "object",
        "title": "DescribeRequest"
      },
      "DeviceInfo": {
        "properties": {
          "os": {
            "type": "string",
            "title": "Os"
          },
          "arch": {
            "type": "string",
            "title": "Arch"
          },
          "gpu_vendor": {
            "type": "string",
            "title": "Gpu Vendor",
            "default": "none"
          },
          "gpu_backend": {
            "type": "string",
            "title": "Gpu Backend",
            "default": "cpu"
          },
          "gpu_available": {
            "type": "boolean",
            "title": "Gpu Available",
            "default": false
          },
          "gpu_driver": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Gpu Driver"
          },
          "gpu_device_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Gpu Device Name"
          },
          "gpu_family": {
            "type": "string",
            "title": "Gpu Family",
            "default": "cpu"
          },
          "vram_gb": {
            "type": "number",
            "title": "Vram Gb",
            "default": 0
          },
          "ram_gb": {
            "type": "number",
            "title": "Ram Gb",
            "default": 0
          },
          "disk_free_gb": {
            "type": "number",
            "title": "Disk Free Gb",
            "default": 0
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "os",
          "arch"
        ],
        "title": "DeviceInfo",
        "description": "GPU/system device info from preflight."
      },
      "DictationPrefsUpdate": {
        "properties": {
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Mode"
          },
          "model_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model Id"
          }
        },
        "type": "object",
        "title": "DictationPrefsUpdate"
      },
      "DirectionReq": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text",
            "description": "Natural-language direction, e.g. 'urgent and surprised'"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "DirectionReq"
      },
      "DubIngestUrlRequest": {
        "properties": {
          "url": {
            "type": "string",
            "title": "Url"
          },
          "job_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Job Id"
          },
          "fetch_subs": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Fetch Subs",
            "default": false
          },
          "sub_langs": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Sub Langs"
          },
          "cookie_file": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cookie File"
          }
        },
        "type": "object",
        "required": [
          "url"
        ],
        "title": "DubIngestUrlRequest"
      },
      "DubSegment": {
        "properties": {
          "start": {
            "type": "number",
            "title": "Start"
          },
          "end": {
            "type": "number",
            "title": "End"
          },
          "text": {
            "type": "string",
            "title": "Text"
          },
          "instruct": {
            "type": "string",
            "title": "Instruct",
            "default": ""
          },
          "profile_id": {
            "type": "string",
            "title": "Profile Id",
            "default": ""
          },
          "speed": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speed"
          },
          "gain": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Gain"
          },
          "target_lang": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target Lang"
          },
          "direction": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Direction"
          },
          "effect_preset": {
            "type": "string",
            "title": "Effect Preset",
            "default": "broadcast"
          }
        },
        "type": "object",
        "required": [
          "start",
          "end",
          "text"
        ],
        "title": "DubSegment"
      },
      "EffectPresetEntry": {
        "properties": {
          "id": {
            "type": "string",
            "title": "Id"
          },
          "label": {
            "type": "string",
            "title": "Label"
          },
          "icon": {
            "type": "string",
            "title": "Icon"
          },
          "description": {
            "type": "string",
            "title": "Description"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "id",
          "label",
          "icon",
          "description"
        ],
        "title": "EffectPresetEntry",
        "description": "One DSP effect preset."
      },
      "EffectPresetsResponse": {
        "properties": {
          "presets": {
            "items": {
              "$ref": "#/components/schemas/EffectPresetEntry"
            },
            "type": "array",
            "title": "Presets"
          }
        },
        "type": "object",
        "title": "EffectPresetsResponse",
        "description": "GET /engines/effects/presets"
      },
      "EnableRequest": {
        "properties": {
          "enabled": {
            "type": "boolean",
            "title": "Enabled"
          }
        },
        "type": "object",
        "required": [
          "enabled"
        ],
        "title": "EnableRequest"
      },
      "EnrollRequest": {
        "properties": {
          "label": {
            "type": "string",
            "maxLength": 120,
            "title": "Label",
            "default": ""
          },
          "endpoint": {
            "type": "string",
            "maxLength": 256,
            "title": "Endpoint",
            "default": ""
          },
          "ttl_seconds": {
            "type": "integer",
            "maximum": 86400,
            "minimum": 60,
            "title": "Ttl Seconds",
            "default": 900
          }
        },
        "type": "object",
        "title": "EnrollRequest"
      },
      "ExportRecordRequest": {
        "properties": {
          "filename": {
            "type": "string",
            "title": "Filename"
          },
          "destination_path": {
            "type": "string",
            "title": "Destination Path",
            "default": "~/Downloads"
          },
          "mode": {
            "type": "string",
            "title": "Mode",
            "default": "file"
          }
        },
        "type": "object",
        "required": [
          "filename"
        ],
        "title": "ExportRecordRequest"
      },
      "ExportRequest": {
        "properties": {
          "source_filename": {
            "type": "string",
            "title": "Source Filename"
          },
          "authorization": {
            "type": "string",
            "title": "Authorization"
          },
          "mode": {
            "type": "string",
            "title": "Mode",
            "default": "history"
          }
        },
        "type": "object",
        "required": [
          "source_filename",
          "authorization"
        ],
        "title": "ExportRequest"
      },
      "FitOptions": {
        "properties": {
          "max_audio_only_rate": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Audio Only Rate"
          },
          "audio_rate_cap": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Audio Rate Cap"
          },
          "video_slow_cap": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Video Slow Cap"
          },
          "gap_guard_s": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Gap Guard S"
          },
          "allow_video_retime": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Allow Video Retime"
          }
        },
        "type": "object",
        "title": "FitOptions",
        "description": "Optional knob overrides for the `smart_fit` timing strategy.\n\nAll fields default to None — the server fills in the canonical\ndefaults (services.fit_planner.FitParams) so old clients and sparse\npayloads behave identically to a fully-populated default payload."
      },
      "GlossaryTerm": {
        "properties": {
          "source": {
            "type": "string",
            "title": "Source"
          },
          "target": {
            "type": "string",
            "title": "Target"
          },
          "note": {
            "type": "string",
            "title": "Note",
            "default": ""
          }
        },
        "type": "object",
        "required": [
          "source",
          "target"
        ],
        "title": "GlossaryTerm"
      },
      "GlossaryTermUpdate": {
        "properties": {
          "source": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Source"
          },
          "target": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target"
          },
          "note": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Note"
          }
        },
        "type": "object",
        "title": "GlossaryTermUpdate"
      },
      "GpuRouting": {
        "properties": {
          "engine": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Engine"
          },
          "effective_device": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Effective Device"
          },
          "routing_status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Routing Status"
          },
          "routing_reason": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Routing Reason"
          },
          "host_family": {
            "type": "string",
            "title": "Host Family",
            "default": "cpu"
          },
          "vram_gb": {
            "type": "number",
            "title": "Vram Gb",
            "default": 0
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "GpuRouting",
        "description": "Routing verdict for the active TTS engine on THIS host (#21).\n\nDistinct from the per-engine `routing_*` keys in `/engines`: this is the\nsingle verdict for the *currently-selected* engine, surfaced in preflight +\ndiagnose so the user hears about a CPU fallback / unavailable GPU before a\nslow or failed synth — no silent CPU fallback."
      },
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "type": "array",
            "title": "Detail"
          }
        },
        "type": "object",
        "title": "HTTPValidationError"
      },
      "InboundEnableRequest": {
        "properties": {
          "enabled": {
            "type": "boolean",
            "title": "Enabled"
          },
          "bind": {
            "type": "string",
            "title": "Bind",
            "default": ""
          },
          "port": {
            "type": "integer",
            "title": "Port",
            "default": 0
          }
        },
        "type": "object",
        "required": [
          "enabled"
        ],
        "title": "InboundEnableRequest"
      },
      "IncrementalReq": {
        "properties": {
          "segments": {
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array",
            "title": "Segments"
          },
          "stored_hashes": {
            "anyOf": [
              {
                "additionalProperties": {
                  "type": "string"
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Stored Hashes"
          },
          "lang": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Lang"
          },
          "voice_match": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Match"
          }
        },
        "type": "object",
        "required": [
          "segments"
        ],
        "title": "IncrementalReq"
      },
      "InstallModelRequest": {
        "properties": {
          "repo_id": {
            "type": "string",
            "title": "Repo Id"
          },
          "target": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target"
          }
        },
        "type": "object",
        "required": [
          "repo_id"
        ],
        "title": "InstallModelRequest"
      },
      "IssueKeyRequest": {
        "properties": {
          "label": {
            "type": "string",
            "maxLength": 64,
            "title": "Label",
            "default": ""
          }
        },
        "type": "object",
        "title": "IssueKeyRequest"
      },
      "JoinRequest": {
        "properties": {
          "token": {
            "type": "string",
            "maxLength": 4096,
            "title": "Token"
          }
        },
        "type": "object",
        "required": [
          "token"
        ],
        "title": "JoinRequest",
        "description": "A join code, as pasted (or scanned) from the control plane."
      },
      "LongformChapter": {
        "properties": {
          "title": {
            "type": "string",
            "title": "Title",
            "default": ""
          },
          "spans": {
            "items": {
              "$ref": "#/components/schemas/LongformSpan"
            },
            "type": "array",
            "title": "Spans",
            "default": []
          }
        },
        "type": "object",
        "title": "LongformChapter"
      },
      "LongformRenderRequest": {
        "properties": {
          "num_step": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 512,
                "minimum": 1
              },
              {
                "type": "null"
              }
            ],
            "title": "Num Step"
          },
          "guidance_scale": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 20,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Guidance Scale"
          },
          "position_temperature": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Position Temperature"
          },
          "class_temperature": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Class Temperature"
          },
          "postprocess_output": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Postprocess Output"
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 4294967295,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed"
          },
          "emo_vector": {
            "anyOf": [
              {
                "items": {
                  "type": "number"
                },
                "type": "array",
                "maxItems": 8,
                "minItems": 8
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Vector"
          },
          "emo_text": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 500
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Text"
          },
          "emo_alpha": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 1,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Emo Alpha"
          },
          "vary_repeats": {
            "type": "boolean",
            "title": "Vary Repeats",
            "default": false
          },
          "chapters": {
            "items": {
              "$ref": "#/components/schemas/LongformChapter"
            },
            "type": "array",
            "title": "Chapters",
            "default": []
          },
          "default_voice": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Voice"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "bitrate": {
            "type": "string",
            "title": "Bitrate",
            "default": "128k"
          },
          "format": {
            "type": "string",
            "title": "Format",
            "default": "m4b"
          },
          "loudness": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Loudness"
          },
          "cover_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cover Path"
          },
          "metadata": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Metadata"
          },
          "lexicon": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Lexicon"
          },
          "voice_map": {
            "anyOf": [
              {
                "additionalProperties": {
                  "type": "string"
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Map"
          }
        },
        "type": "object",
        "title": "LongformRenderRequest"
      },
      "LongformSpan": {
        "properties": {
          "voice_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Id"
          },
          "text": {
            "type": "string",
            "title": "Text"
          },
          "pause_ms_after": {
            "type": "integer",
            "title": "Pause Ms After",
            "default": 0
          },
          "speed": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speed"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "LongformSpan"
      },
      "MissingModel": {
        "properties": {
          "repo_id": {
            "type": "string",
            "title": "Repo Id"
          },
          "label": {
            "type": "string",
            "title": "Label"
          }
        },
        "type": "object",
        "required": [
          "repo_id",
          "label"
        ],
        "title": "MissingModel"
      },
      "ModelStatusResponse": {
        "properties": {
          "status": {
            "type": "string",
            "title": "Status",
            "description": "idle | loading | ready"
          },
          "checkpoint": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Checkpoint"
          },
          "loaded_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Loaded At"
          },
          "sub_stage": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Sub Stage",
            "description": "Current loading sub-stage: importing | loading_weights | loading_asr | compiling | ready | error"
          },
          "detail": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detail",
            "description": "Human-readable detail of current loading phase"
          },
          "error": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Error",
            "description": "Error message if loading failed"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "status"
        ],
        "title": "ModelStatusResponse",
        "description": "GET /model/status"
      },
      "ParseSubtitleTextRequest": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "ParseSubtitleTextRequest",
        "description": "Raw pasted subtitle text (SRT/VTT-ish) to be parsed into timed cues.\n\nUsed by the \"paste translation from an external source\" flow: the user\npastes what ChatGPT/DeepL/a human gave them and the client needs the\nSAME lenient cue parsing the .srt import path uses — parsing it here\nkeeps `services.srt_parser` the single source of truth instead of\ngrowing a second, subtly-different implementation in JavaScript."
      },
      "PreflightCheck": {
        "properties": {
          "id": {
            "type": "string",
            "title": "Id"
          },
          "label": {
            "type": "string",
            "title": "Label"
          },
          "status": {
            "type": "string",
            "title": "Status",
            "description": "pass | warn | fail"
          },
          "detail": {
            "type": "string",
            "title": "Detail",
            "default": ""
          },
          "fix": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Fix"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "id",
          "label",
          "status"
        ],
        "title": "PreflightCheck",
        "description": "One check in the preflight report."
      },
      "PreflightResponse": {
        "properties": {
          "ok": {
            "type": "boolean",
            "title": "Ok"
          },
          "has_warnings": {
            "type": "boolean",
            "title": "Has Warnings",
            "default": false
          },
          "checks": {
            "items": {
              "$ref": "#/components/schemas/PreflightCheck"
            },
            "type": "array",
            "title": "Checks"
          },
          "device": {
            "$ref": "#/components/schemas/DeviceInfo"
          },
          "gpu_routing": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/GpuRouting"
              },
              {
                "type": "null"
              }
            ]
          },
          "media_tools": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Tools"
          }
        },
        "type": "object",
        "required": [
          "ok",
          "device"
        ],
        "title": "PreflightResponse",
        "description": "GET /setup/preflight"
      },
      "ProbeReq": {
        "properties": {
          "path": {
            "type": "string",
            "title": "Path"
          }
        },
        "type": "object",
        "required": [
          "path"
        ],
        "title": "ProbeReq"
      },
      "ProfileUpdate": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "ref_text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ref Text"
          },
          "instruct": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Instruct"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "personality": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Personality"
          }
        },
        "type": "object",
        "title": "ProfileUpdate"
      },
      "ProjectRenameRequest": {
        "properties": {
          "name": {
            "type": "string",
            "title": "Name"
          }
        },
        "type": "object",
        "required": [
          "name"
        ],
        "title": "ProjectRenameRequest"
      },
      "ProjectSaveRequest": {
        "properties": {
          "name": {
            "type": "string",
            "title": "Name"
          },
          "video_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Video Path"
          },
          "audio_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Audio Path"
          },
          "duration": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Duration"
          },
          "state": {
            "additionalProperties": true,
            "type": "object",
            "title": "State"
          }
        },
        "type": "object",
        "required": [
          "name",
          "state"
        ],
        "title": "ProjectSaveRequest"
      },
      "PronEntry": {
        "properties": {
          "term": {
            "type": "string",
            "title": "Term"
          },
          "replacement": {
            "type": "string",
            "title": "Replacement",
            "default": ""
          },
          "type": {
            "type": "string",
            "title": "Type",
            "default": "respelling"
          },
          "language": {
            "type": "string",
            "title": "Language",
            "default": "*"
          },
          "enabled": {
            "type": "boolean",
            "title": "Enabled",
            "default": true
          }
        },
        "type": "object",
        "required": [
          "term"
        ],
        "title": "PronEntry"
      },
      "PronEntryUpdate": {
        "properties": {
          "term": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Term"
          },
          "replacement": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Replacement"
          },
          "type": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Type"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          }
        },
        "type": "object",
        "title": "PronEntryUpdate"
      },
      "PronImportRequest": {
        "properties": {
          "entries": {
            "items": {
              "$ref": "#/components/schemas/PronEntry"
            },
            "type": "array",
            "title": "Entries"
          },
          "replace": {
            "type": "boolean",
            "title": "Replace",
            "default": false
          }
        },
        "type": "object",
        "required": [
          "entries"
        ],
        "title": "PronImportRequest"
      },
      "PronTestRequest": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "PronTestRequest"
      },
      "RateFitReq": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          },
          "slot_seconds": {
            "type": "number",
            "title": "Slot Seconds"
          },
          "target_lang": {
            "type": "string",
            "title": "Target Lang"
          },
          "source_text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Source Text"
          }
        },
        "type": "object",
        "required": [
          "text",
          "slot_seconds",
          "target_lang"
        ],
        "title": "RateFitReq"
      },
      "RevealRequest": {
        "properties": {
          "path": {
            "type": "string",
            "title": "Path"
          }
        },
        "type": "object",
        "required": [
          "path"
        ],
        "title": "RevealRequest"
      },
      "SegmentPreviewRequest": {
        "properties": {
          "segment_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segment Id"
          },
          "text": {
            "type": "string",
            "title": "Text"
          },
          "language": {
            "type": "string",
            "title": "Language",
            "default": "Auto"
          },
          "instruct": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Instruct"
          },
          "profile_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Profile Id"
          },
          "speed": {
            "type": "number",
            "title": "Speed",
            "default": 1
          },
          "duration": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Duration"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "SegmentPreviewRequest"
      },
      "SelectEngineRequest": {
        "properties": {
          "family": {
            "type": "string",
            "title": "Family"
          },
          "backend_id": {
            "type": "string",
            "title": "Backend Id"
          },
          "model_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model Id"
          }
        },
        "type": "object",
        "required": [
          "family",
          "backend_id"
        ],
        "title": "SelectEngineRequest"
      },
      "SelectEngineResponse": {
        "properties": {
          "family": {
            "type": "string",
            "title": "Family"
          },
          "active": {
            "type": "string",
            "title": "Active"
          },
          "env_override": {
            "type": "boolean",
            "title": "Env Override"
          },
          "routing_status": {
            "type": "string",
            "title": "Routing Status",
            "default": "cpu_only"
          },
          "effective_device": {
            "type": "string",
            "title": "Effective Device",
            "default": "cpu"
          },
          "routing_reason": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Routing Reason"
          }
        },
        "type": "object",
        "required": [
          "family",
          "active",
          "env_override"
        ],
        "title": "SelectEngineResponse"
      },
      "SelfTestResponse": {
        "properties": {
          "id": {
            "type": "string",
            "title": "Id"
          },
          "ok": {
            "type": "boolean",
            "title": "Ok"
          },
          "message": {
            "type": "string",
            "title": "Message"
          },
          "duration_ms": {
            "type": "number",
            "title": "Duration Ms"
          },
          "sample_rate": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Sample Rate"
          },
          "num_samples": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Num Samples"
          },
          "audio_seconds": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Audio Seconds"
          },
          "timed_out": {
            "type": "boolean",
            "title": "Timed Out",
            "default": false
          }
        },
        "type": "object",
        "required": [
          "id",
          "ok",
          "message",
          "duration_ms"
        ],
        "title": "SelfTestResponse"
      },
      "SessionRequest": {
        "properties": {
          "transport": {
            "type": "string",
            "enum": [
              "cookie",
              "bearer"
            ],
            "title": "Transport"
          }
        },
        "type": "object",
        "required": [
          "transport"
        ],
        "title": "SessionRequest"
      },
      "SetupStatusResponse": {
        "properties": {
          "models_ready": {
            "type": "boolean",
            "title": "Models Ready"
          },
          "missing": {
            "items": {
              "$ref": "#/components/schemas/MissingModel"
            },
            "type": "array",
            "title": "Missing"
          },
          "hf_cache_dir": {
            "type": "string",
            "title": "Hf Cache Dir"
          },
          "disk_free_gb": {
            "type": "number",
            "title": "Disk Free Gb"
          },
          "min_free_gb": {
            "type": "integer",
            "title": "Min Free Gb",
            "default": 10
          },
          "enough_disk": {
            "type": "boolean",
            "title": "Enough Disk",
            "default": true
          }
        },
        "type": "object",
        "required": [
          "models_ready",
          "hf_cache_dir",
          "disk_free_gb"
        ],
        "title": "SetupStatusResponse",
        "description": "GET /setup/status"
      },
      "SpeechRequest": {
        "properties": {
          "model": {
            "type": "string",
            "title": "Model",
            "description": "TTS model to use. Maps to VoiceStudio engine IDs: 'omnivoice', 'voxcpm2', 'cosyvoice', 'mlx-audio', 'kittentts', 'moss-tts-nano'. Also accepts 'tts-1' and 'tts-1-hd' as aliases for the active engine.",
            "default": "omnivoice"
          },
          "input": {
            "type": "string",
            "maxLength": 4096,
            "title": "Input",
            "description": "The text to synthesize. Max 4096 characters."
          },
          "voice": {
            "type": "string",
            "title": "Voice",
            "description": "Voice to use. For VoiceStudio: pass a voice profile ID, 'default', or a KittenTTS preset name. OpenAI voice names (alloy, echo, fable, onyx, nova, shimmer) are accepted but mapped to defaults.",
            "default": "default"
          },
          "response_format": {
            "type": "string",
            "enum": [
              "mp3",
              "opus",
              "aac",
              "flac",
              "wav",
              "pcm"
            ],
            "title": "Response Format",
            "description": "Audio output format.",
            "default": "mp3"
          },
          "speed": {
            "type": "number",
            "maximum": 4,
            "minimum": 0.25,
            "title": "Speed",
            "description": "Speed of the generated audio (0.25 to 4.0).",
            "default": 1
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language",
            "description": "Language code (ISO 639-1)"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description",
            "description": "Voice description for voice design (VoxCPM2 only). E.g. 'young female, warm tone, slight British accent'."
          },
          "instruct": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Instruct",
            "description": "Style instruction for the TTS engine."
          },
          "duration": {
            "anyOf": [
              {
                "type": "number",
                "exclusiveMinimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Duration",
            "description": "VoiceStudio extension: target output duration in seconds."
          },
          "seed": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Seed",
            "description": "VoiceStudio extension: deterministic sampling seed."
          },
          "denoise": {
            "type": "boolean",
            "title": "Denoise",
            "description": "VoiceStudio extension: prepend denoise control when supported.",
            "default": true
          },
          "preprocess_prompt": {
            "type": "boolean",
            "title": "Preprocess Prompt",
            "description": "VoiceStudio extension: trim/preprocess reference prompt when supported.",
            "default": true
          },
          "chunk_duration": {
            "anyOf": [
              {
                "type": "number",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Chunk Duration",
            "description": "OmniVoice GGUF extension: long-form internal chunk duration."
          },
          "chunk_threshold": {
            "anyOf": [
              {
                "type": "number",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Chunk Threshold",
            "description": "OmniVoice GGUF extension: long-form internal chunk threshold."
          },
          "num_step": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 128,
                "minimum": 1
              },
              {
                "type": "null"
              }
            ],
            "title": "Num Step",
            "description": "VoiceStudio extension: iterative unmasking steps (app default 16; 32 = the model's documented quality preset)."
          },
          "guidance_scale": {
            "anyOf": [
              {
                "type": "number",
                "maximum": 20,
                "exclusiveMinimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Guidance Scale",
            "description": "VoiceStudio extension: classifier-free guidance scale (app default 2.0)."
          }
        },
        "type": "object",
        "required": [
          "input"
        ],
        "title": "SpeechRequest",
        "description": "POST /v1/audio/speech — mirrors OpenAI's CreateSpeechRequest."
      },
      "SubmitTaskRequest": {
        "properties": {
          "engine": {
            "type": "string",
            "maxLength": 64,
            "title": "Engine"
          },
          "operation": {
            "type": "string",
            "maxLength": 32,
            "title": "Operation",
            "default": "tts"
          },
          "model_id": {
            "type": "string",
            "maxLength": 128,
            "title": "Model Id",
            "default": ""
          },
          "params": {
            "additionalProperties": true,
            "type": "object",
            "title": "Params"
          },
          "deadline_seconds": {
            "type": "number",
            "maximum": 21600,
            "exclusiveMinimum": 0,
            "title": "Deadline Seconds"
          },
          "idempotency_key": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 128
              },
              {
                "type": "null"
              }
            ],
            "title": "Idempotency Key"
          }
        },
        "type": "object",
        "required": [
          "engine",
          "deadline_seconds"
        ],
        "title": "SubmitTaskRequest",
        "description": "One unit of work for a remote worker. **Dev only** — see `submit_task`."
      },
      "SysinfoResponse": {
        "properties": {
          "cpu": {
            "type": "number",
            "title": "Cpu",
            "description": "CPU usage percentage (0–100)"
          },
          "ram": {
            "type": "number",
            "title": "Ram",
            "description": "Used RAM in GiB"
          },
          "total_ram": {
            "type": "number",
            "title": "Total Ram",
            "description": "Total RAM in GiB"
          },
          "vram": {
            "type": "number",
            "title": "Vram",
            "description": "Used VRAM in GiB",
            "default": 0
          },
          "gpu_active": {
            "type": "boolean",
            "title": "Gpu Active",
            "description": "Whether a GPU is actively used",
            "default": false
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "cpu",
          "ram",
          "total_ram"
        ],
        "title": "SysinfoResponse",
        "description": "GET /sysinfo"
      },
      "SystemInfoResponse": {
        "properties": {
          "app_version": {
            "type": "string",
            "title": "App Version",
            "default": ""
          },
          "data_dir": {
            "type": "string",
            "title": "Data Dir"
          },
          "outputs_dir": {
            "type": "string",
            "title": "Outputs Dir"
          },
          "crash_log_path": {
            "type": "string",
            "title": "Crash Log Path"
          },
          "idle_timeout_seconds": {
            "type": "integer",
            "title": "Idle Timeout Seconds"
          },
          "model_checkpoint": {
            "type": "string",
            "title": "Model Checkpoint",
            "default": "unknown"
          },
          "asr_model": {
            "type": "string",
            "title": "Asr Model",
            "default": "unknown"
          },
          "translate_provider": {
            "type": "string",
            "title": "Translate Provider",
            "default": "unknown"
          },
          "has_hf_token": {
            "type": "boolean",
            "title": "Has Hf Token",
            "default": false
          },
          "fast_download": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Fast Download"
          },
          "device": {
            "type": "string",
            "title": "Device",
            "default": "cpu"
          },
          "python": {
            "type": "string",
            "title": "Python",
            "default": ""
          },
          "platform": {
            "type": "string",
            "title": "Platform",
            "default": ""
          },
          "arch": {
            "type": "string",
            "title": "Arch",
            "default": ""
          },
          "os_version": {
            "type": "string",
            "title": "Os Version",
            "default": ""
          },
          "cpu_model": {
            "type": "string",
            "title": "Cpu Model",
            "default": ""
          },
          "cpu_count": {
            "type": "integer",
            "title": "Cpu Count",
            "default": 0
          },
          "ram_total_gb": {
            "type": "number",
            "title": "Ram Total Gb",
            "default": 0
          },
          "gpu_name": {
            "type": "string",
            "title": "Gpu Name",
            "default": ""
          },
          "vram_total_gb": {
            "type": "number",
            "title": "Vram Total Gb",
            "default": 0
          },
          "disk_free_gb": {
            "type": "number",
            "title": "Disk Free Gb",
            "default": 0
          },
          "error": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Error"
          },
          "ffmpeg_ok": {
            "type": "boolean",
            "title": "Ffmpeg Ok",
            "default": false
          },
          "ffmpeg_path": {
            "type": "string",
            "title": "Ffmpeg Path",
            "default": ""
          },
          "proxy_url": {
            "type": "string",
            "title": "Proxy Url",
            "default": ""
          },
          "share_enabled": {
            "type": "boolean",
            "title": "Share Enabled",
            "default": false
          },
          "share_port": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Share Port"
          },
          "lan_addresses": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Lan Addresses",
            "default": []
          },
          "pin_required": {
            "type": "boolean",
            "title": "Pin Required",
            "default": false
          },
          "backend_port": {
            "type": "integer",
            "title": "Backend Port",
            "default": 3900
          },
          "share_port_base": {
            "type": "integer",
            "title": "Share Port Base",
            "default": 3901
          },
          "ui_port": {
            "type": "integer",
            "title": "Ui Port",
            "default": 3901
          }
        },
        "additionalProperties": true,
        "type": "object",
        "required": [
          "data_dir",
          "outputs_dir",
          "crash_log_path",
          "idle_timeout_seconds"
        ],
        "title": "SystemInfoResponse",
        "description": "GET /system/info"
      },
      "TargetRequest": {
        "properties": {
          "target": {
            "type": "string",
            "maxLength": 64,
            "title": "Target"
          }
        },
        "type": "object",
        "required": [
          "target"
        ],
        "title": "TargetRequest",
        "description": "`local`, or the id of an enrolled worker."
      },
      "TranslateRequest": {
        "properties": {
          "segments": {
            "items": {
              "$ref": "#/components/schemas/TranslateSegment"
            },
            "type": "array",
            "title": "Segments"
          },
          "target_lang": {
            "type": "string",
            "title": "Target Lang"
          },
          "provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Provider"
          },
          "source_lang": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Source Lang"
          },
          "job_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Job Id"
          },
          "quality": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Quality",
            "default": "fast"
          },
          "glossary": {
            "anyOf": [
              {
                "items": {
                  "additionalProperties": true,
                  "type": "object"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Glossary"
          },
          "dialect": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Dialect"
          },
          "auto_glossary": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Auto Glossary"
          },
          "reflect": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reflect"
          },
          "condense": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Condense",
            "default": false
          }
        },
        "type": "object",
        "required": [
          "segments",
          "target_lang"
        ],
        "title": "TranslateRequest"
      },
      "TranslateSegment": {
        "properties": {
          "id": {
            "type": "string",
            "title": "Id"
          },
          "text": {
            "type": "string",
            "title": "Text"
          },
          "target_lang": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target Lang"
          },
          "direction": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Direction"
          },
          "slot_seconds": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Slot Seconds"
          },
          "start": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Start"
          },
          "end": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "End"
          }
        },
        "type": "object",
        "required": [
          "id",
          "text"
        ],
        "title": "TranslateSegment"
      },
      "ValidationError": {
        "properties": {
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          },
          "input": {
            "title": "Input"
          },
          "ctx": {
            "type": "object",
            "title": "Context"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      },
      "WebSocketTicketRequest": {
        "properties": {
          "path": {
            "type": "string",
            "title": "Path"
          }
        },
        "type": "object",
        "required": [
          "path"
        ],
        "title": "WebSocketTicketRequest"
      },
      "WorkerUpdate": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 120
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "priority": {
            "anyOf": [
              {
                "type": "integer",
                "maximum": 100,
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "title": "Priority"
          }
        },
        "type": "object",
        "title": "WorkerUpdate"
      },
      "_ASROpenAICompatBody": {
        "properties": {
          "base_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Base Url"
          },
          "model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model"
          },
          "api_key": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Api Key",
            "description": "'' clears it, None leaves unchanged"
          }
        },
        "type": "object",
        "title": "_ASROpenAICompatBody"
      },
      "_AnalyticsBody": {
        "properties": {
          "enabled": {
            "type": "boolean",
            "title": "Enabled",
            "description": "User's explicit choice. Default is OFF."
          }
        },
        "type": "object",
        "required": [
          "enabled"
        ],
        "title": "_AnalyticsBody"
      },
      "_BindingBody": {
        "properties": {
          "client_id": {
            "type": "string",
            "maxLength": 128,
            "minLength": 1,
            "title": "Client Id"
          },
          "label": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Label"
          },
          "profile_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Profile Id"
          },
          "default_engine": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default Engine"
          }
        },
        "type": "object",
        "required": [
          "client_id"
        ],
        "title": "_BindingBody"
      },
      "_ComputeDeviceBody": {
        "properties": {
          "value": {
            "type": "string",
            "title": "Value",
            "description": "auto | cuda | rocm | xpu | mps | cpu"
          }
        },
        "type": "object",
        "required": [
          "value"
        ],
        "title": "_ComputeDeviceBody"
      },
      "_HFMirrorBody": {
        "properties": {
          "url": {
            "type": "string",
            "title": "Url",
            "description": "HF_ENDPOINT URL; empty string clears it (official endpoint)",
            "default": ""
          },
          "mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Mode",
            "description": "'auto' switches to automatic endpoint selection (clears any explicit endpoint); 'manual' (or omitted — back-compat with older clients) pins the given url as an explicit choice."
          }
        },
        "type": "object",
        "title": "_HFMirrorBody"
      },
      "_HFTokenBody": {
        "properties": {
          "token": {
            "type": "string",
            "minLength": 1,
            "title": "Token",
            "description": "HuggingFace access token"
          }
        },
        "type": "object",
        "required": [
          "token"
        ],
        "title": "_HFTokenBody"
      },
      "_HistoryRetentionBody": {
        "properties": {
          "cap": {
            "type": "integer",
            "maximum": 100000,
            "minimum": 0,
            "title": "Cap",
            "description": "Max takes kept before the oldest UNstarred ones (rows + WAVs) are pruned; 0 = unlimited"
          }
        },
        "type": "object",
        "required": [
          "cap"
        ],
        "title": "_HistoryRetentionBody"
      },
      "_LLMActiveBody": {
        "properties": {
          "provider": {
            "type": "string",
            "title": "Provider",
            "description": "provider id to activate"
          }
        },
        "type": "object",
        "required": [
          "provider"
        ],
        "title": "_LLMActiveBody"
      },
      "_LLMEndpointBody": {
        "properties": {
          "base_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Base Url"
          },
          "model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model"
          },
          "api_key": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Api Key"
          }
        },
        "type": "object",
        "title": "_LLMEndpointBody"
      },
      "_LLMProviderBody": {
        "properties": {
          "api_key": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Api Key",
            "description": "API key; '' clears it, None leaves unchanged"
          },
          "base_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Base Url"
          },
          "model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model"
          },
          "account_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Account Id",
            "description": "Cloudflare account id"
          },
          "make_active": {
            "type": "boolean",
            "title": "Make Active",
            "default": false
          }
        },
        "type": "object",
        "title": "_LLMProviderBody"
      },
      "_LLMSkillBody": {
        "properties": {
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled",
            "description": "None leaves the toggle unchanged"
          },
          "provider_override": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Provider Override",
            "description": "provider id to route this skill to; '' or null clears it (skill follows the active provider). Omit to leave unchanged."
          }
        },
        "type": "object",
        "title": "_LLMSkillBody"
      },
      "_LicenseAcceptBody": {
        "properties": {
          "engine_id": {
            "type": "string",
            "maxLength": 64,
            "minLength": 1,
            "title": "Engine Id"
          },
          "accepted": {
            "type": "boolean",
            "title": "Accepted",
            "description": "True to accept the license terms"
          }
        },
        "type": "object",
        "required": [
          "engine_id",
          "accepted"
        ],
        "title": "_LicenseAcceptBody"
      },
      "_ModelsDirBody": {
        "properties": {
          "authorization": {
            "type": "string",
            "title": "Authorization",
            "description": "One-shot native desktop authorization"
          }
        },
        "type": "object",
        "required": [
          "authorization"
        ],
        "title": "_ModelsDirBody"
      },
      "_RefinementBody": {
        "properties": {
          "auto": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Auto"
          },
          "smart_cleanup": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Smart Cleanup"
          },
          "self_correction": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Self Correction"
          },
          "preserve_technical": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Preserve Technical"
          }
        },
        "type": "object",
        "title": "_RefinementBody"
      },
      "_StarBody": {
        "properties": {
          "starred": {
            "type": "boolean",
            "title": "Starred"
          }
        },
        "type": "object",
        "required": [
          "starred"
        ],
        "title": "_StarBody"
      },
      "_TorchCompileBody": {
        "properties": {
          "enabled": {
            "type": "boolean",
            "title": "Enabled",
            "description": "True to set TORCH_COMPILE_DISABLE=1 on engine subprocesses"
          }
        },
        "type": "object",
        "required": [
          "enabled"
        ],
        "title": "_TorchCompileBody"
      },
      "api__routers__sonitranslate__DubRequest": {
        "properties": {
          "video_authorization": {
            "type": "string",
            "title": "Video Authorization"
          },
          "target_language": {
            "type": "string",
            "title": "Target Language",
            "default": "Spanish (es)"
          },
          "source_language": {
            "type": "string",
            "title": "Source Language",
            "default": "Automatic detection"
          },
          "tts_voice": {
            "type": "string",
            "title": "Tts Voice",
            "default": "es-ES-AlvaroNeural-Male"
          },
          "max_speakers": {
            "type": "integer",
            "title": "Max Speakers",
            "default": 1
          },
          "output_authorization": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Output Authorization"
          }
        },
        "type": "object",
        "required": [
          "video_authorization"
        ],
        "title": "DubRequest"
      },
      "schemas__requests__DubRequest": {
        "properties": {
          "segments": {
            "items": {
              "$ref": "#/components/schemas/DubSegment"
            },
            "type": "array",
            "title": "Segments"
          },
          "language": {
            "type": "string",
            "title": "Language",
            "default": "Auto"
          },
          "language_code": {
            "type": "string",
            "title": "Language Code",
            "default": "und"
          },
          "instruct": {
            "type": "string",
            "title": "Instruct",
            "default": ""
          },
          "num_step": {
            "type": "integer",
            "title": "Num Step",
            "default": 16
          },
          "guidance_scale": {
            "type": "number",
            "title": "Guidance Scale",
            "default": 2
          },
          "speed": {
            "type": "number",
            "title": "Speed",
            "default": 1
          },
          "segment_ids": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segment Ids"
          },
          "regen_only": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Regen Only"
          },
          "preview": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Preview",
            "default": false
          },
          "slot_fit": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Slot Fit",
            "default": "time_stretch"
          },
          "timing_strategy": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "concise",
                  "stretch_video",
                  "strict_slot",
                  "smart_fit"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Timing Strategy",
            "default": "concise"
          },
          "overflow_budget_s": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Overflow Budget S",
            "default": 0
          },
          "fit_options": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/FitOptions"
              },
              {
                "type": "null"
              }
            ]
          },
          "voice_match": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "per_line",
                  "consistent"
                ]
              },
              {
                "type": "null"
              }
            ],
            "title": "Voice Match",
            "default": "per_line"
          }
        },
        "type": "object",
        "required": [
          "segments"
        ],
        "title": "DubRequest"
      }
    }
  },
  "servers": [
    {
      "url": "http://localhost:3900",
      "description": "Open source — this machine"
    }
  ],
  "x-voicestudio-contract": {
    "product": "local",
    "audience": "local-application",
    "availability": "available-with-desktop-app",
    "source_repository": "debpalash/VoiceStudio",
    "source_commit": "e6f4c766f595a9fe47de1642f2237bc2c565a8a8",
    "source_sha256": "a1ad4f1ef928b3d9e4482ffc1ac7ce813603a41db2410c45e4bddbac965f5599",
    "generated_contract_version": "0.5.0"
  }
}
