From d82153c058718bcec0fbc1958d25596e3ac746ec Mon Sep 17 00:00:00 2001 From: Ed_ Date: Wed, 10 Jun 2026 19:43:58 -0400 Subject: [PATCH] docs(models): sync WorkspaceProfile dataclass to 4-field model Match the actual src/models.py WorkspaceProfile: - name: str - ini_content: str - show_windows: Dict[str, bool] - panel_states: Dict[str, Any] Remove fictional fields (scope, auto_switch_triggers, description). Remove non-existent LayoutPreset class (was a 2026-06-05 casualty). --- docs/guide_models.md | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/docs/guide_models.md b/docs/guide_models.md index 9c8551fd..3ab9e618 100644 --- a/docs/guide_models.md +++ b/docs/guide_models.md @@ -315,26 +315,18 @@ class HookResponse: data: dict[str, Any] = field(default_factory=dict) ``` -### `WorkspaceProfile`, `LayoutPreset` — Layouts +### `WorkspaceProfile` — Layouts ```python -@dataclass class WorkspaceProfile: name: str - scope: Literal["global", "project"] - docking_layout: str # ImGui ini-string - window_visibility: dict[str, bool] = field(default_factory=dict) - panel_state: dict[str, dict] = field(default_factory=dict) - auto_switch_triggers: list[str] = field(default_factory=list) - description: str = "" - -@dataclass -class LayoutPreset: - name: str - multi_viewport_state: dict[str, Any] = field(default_factory=dict) - description: str = "" + ini_content: str # ImGui ini settings string (from SaveIniSettingsToMemory) + show_windows: Dict[str, bool] = field(default_factory=dict) + panel_states: Dict[str, Any] = field(default_factory=dict) ``` +> **Note:** The 2026-06-05 refactor (per `live_gui_fragility_fixes_20260605`) collapsed the previous design (which had `docking_layout: bytes` with base64, plus `theme`, `theme_fx_enabled`, `captured_at`, `description` as additional fields) into a 4-field model. `ini_content` is a plain `str` (not base64) because `ImGui.SaveIniSettingsToMemory()` returns a string and `tomli_w` rejects `bytes`. `LayoutPreset` is no longer a separate class; multi-viewport state lives in `panel_states`. See [guide_workspace_profiles.md](guide_workspace_profiles.md) for the full data model and TOML example. + ### `RAGConfig`, `RAGChunk`, `RAGResult` — RAG ```python