from typing import Literal from pydantic import Field from app.domain.timeline import Strict, WorkflowSpec class DraftCreate(Strict): folder_id: str | None = None name: str = Field(default="多镜头工作流", min_length=1, max_length=255) kind: Literal["three_shot", "multi_shot"] = "multi_shot" spec: WorkflowSpec class DraftPatch(Strict): folder_id: str | None = None name: str | None = Field(default=None, min_length=1, max_length=255) spec: WorkflowSpec | None = None class RunCreate(Strict): output_folder_id: str | None = None draft_revision: int = Field(ge=1) expected_version: int = Field(ge=1) execution_mode: Literal["interactive", "batch"] = "interactive" reuse_run_id: str | None = None class Control(Strict): expected_version: int | None = Field(default=None, ge=1) class Retry(Strict): expected_run_version: int = Field(ge=1) target_job_id: str