AI turns documents or topics into real, native PowerPoint decks—with native shapes, transitions and animations, data-backed charts and tables on demand, audio narration from speaker notes, and support for your own .pptx templates. · by Hugo He
refactor(prompts): tighten routing, failure recovery, artifact ownership, resume, refine
hugohe3e1203d8c1ad1
diff --git a/skills/ppt-master/references/artifact-ownership.md b/skills/ppt-master/references/artifact-ownership.mdindex 16d7d52d..a4402858 100644--- a/skills/ppt-master/references/artifact-ownership.md+++ b/skills/ppt-master/references/artifact-ownership.md@@ -1,22 +1,10 @@# Artifact Ownership Specification-Global artifact ownership rules for PPT Master projects. A selected route or-profile may explicitly omit an artifact without erasing its facts.+Global artifact ownership rules for PPT Master projects. A selected route or profile may explicitly omit an artifact without erasing its facts.-**Hard rule**: Read each fact from its owning artifact. Do not merge multiple channels into a second source of truth.+**Hard rule**: read each fact from its owning artifact; never merge several channels into a second source of truth.-**Quick Generate projection**: Quick omits confirmation, Design Spec, and lock.-Its current main agent reads source/analysis facts, keeps routine decisions in-active context, and prepares the selected images/icons plus required-operational manifests before SVG authoring. It realizes native formulas directly-from exact mathematical content under [`native-formula.md`](./native-formula.md),-and may also realize charts, tables, native shapes, and other ordinary authoring-capabilities directly from that context. Exact template workspace roots supplied for the run are validated and-installed directly; Quick reads only that project-local state and creates no-Confirm UI selection artifacts. Those artifacts retain their factual/provenance-roles. Quick writes the same final SVG quality provenance and package postflight-as the default profile, but it does not create `svg_final/`, a detailed design-history, or resumable planning state. Context loss restarts the Quick run.+**Quick Generate projection**: Quick omits confirmation, Design Spec, and lock. Its main agent reads source/analysis facts, keeps routine decisions in active context, prepares selected images/icons plus required operational manifests before SVG authoring, and realizes formulas, charts, tables, native shapes, and other ordinary capabilities directly from that context. Exact workspace roots supplied for the run are validated and installed directly; Quick reads only project-local state and creates no Confirm UI artifacts. It writes the same final SVG quality provenance and package postflight as Default but no `svg_final/`, design history, or resumable planning state; context loss restarts the run.---@@ -24,47 +12,46 @@ history, or resumable planning state. Context loss restarts the Quick run.| Artifact | Owner | Role | Read/write contract ||---|---|---|---|-| `sources/` content-type files | Content contract | Main pipeline factual/text origin for tables, chart data values, SmartArt node wording, and presentation content | Default Strategist reads content-type files (`.md` / `.markdown` / `.txt` / `.csv` / `.tsv` / `.json` / `.jsonl` / `.yaml` / `.yml`), judges by content, and resolves approved semantics plus preferred on-slide wording into §IX; Quick's current agent resolves them in active context. Default Executor opens source passages only for explicit verification/resolution. Never replace values with PPTX geometry JSON. |-| `sources/*.facts.json` | Fact provenance contract | Stable external `fact_id` → claim/source mapping created by topic research | Default Strategist cites IDs in §IX and Executor resolves them for attribution; Quick's current agent carries the same IDs into visible attribution. Scenario data never enters this file. |-| `sources/` converted-source originals | Source archive | Imported source files that have a converted content contract (`.pdf` / `.pptx` / `.docx` / `.xlsx` / `.html` / `.epub` / `.tex` / `.rst` / `.ipynb` / `.typ`, etc.) and source-adjacent extracted assets | Read via the converted `<stem>.md` in the main pipeline; direct-PPTX workflows read the `.pptx` by route |-| `sources/*.conversion_profile.json`, `sources/*_files/image_manifest.json` | Pipeline sidecar | Conversion audit record / asset index | NOT read as slide content; open only to audit a conversion or resolve assets |-| `sources/` Image to PPTX source containers | Visible-surface source contract | One or more immutable raster inputs that may each contain one page or several visibly bounded page frames | The Codex-supported Quick profile normalizes them into the ordered canonical frame roster without overwriting originals; frame count, not input-file count, owns slide count. |-| `analysis/source_profile.json` | Machine fact index | Compact PPTX intake digest | Default Strategist or Quick's current agent reads it as factual context and recommendation candidates |-| `analysis/<stem>.identity.json` | Native deck identity facts | Canvas, theme palette/fonts, observed usage | Read selectively when detailed identity facts are needed |-| `analysis/<stem>.slide_library.json` | Native PPTX structure facts | Text slots, geometry, native tables, native chart caches, SmartArt nodes/connections | Direct PPTX workflows use as native fill/structure contract |-| `analysis/beautify_inventory.json` | Beautify frozen validation ledger | Complete self-contained per-slide ledger of frozen content/data and validation exceptions, deterministically inlined from the source extracts | Keep the complete file as the sole Beautify ledger. Models normally consume derived read-only stdout projections from `beautify_inventory.py --summary` or `--page`; add `--with-geometry` only when raw source geometry is required. Never persist a projection or treat it as a second authority. |-| `analysis/image_analysis.csv` | Regenerated image fact view | Measured facts about the current `images/` folder | Re-run `analyze_images.py` before reading image facts after changes |-| `analysis/reconstruction_inventory.json` | Image to PPTX source-evidence ledger | Source-container/frame mapping, hashes, page order/canvas, visible-region bboxes, observed text/graphic/image family, transcription confidence, overlap/z-order observations, and unresolved evidence | The active Codex Quick agent writes it before layer decisions. It contains no final realization, prompts, output filenames, or SVG bindings; those belong to Quick active context plus required operational image evidence. |-| `design_spec.md` | Strategist design authority | Human-readable design intent, page brief, rationale, resources, and production mechanics | Consume final confirmation once, write/audit here, and apply enabled refinement to this same artifact. §I records effective Speaker Notes, Custom Animations, and Narration Audio outcomes plus provenance; a newer explicit user instruction updates only its owning outcome without reopening Confirm UI. After Gate 1 plus conditional approval, later roles read this file instead of `result.json`; §IX owns Executor page content, while its layout/composition/capability/motif recommendations remain References unless an explicit user/template/resource constraint promotes the named property. |-| `spec_lock.md` | Execution anchor and routing contract | Machine-readable stable color/type roles, icons, images, page rhythm, charts, `template_reuse_scope`, and the route's PowerPoint structure mode; mirror/layout template routes additionally own input prototypes, the Master roster, and the complete page-to-Master/Layout mapping | Strategist authors the route-specific anchors from the audited Design Spec plus current project/page/template context. Executor retains the complete lock once per valid execution context; local uncertainty consults that retained copy before the owning Design Spec fragment. Sparse page-local color/font garnish needs no lock row; a recurring semantic role or new adaptive Layout identity requires Strategist repair before reuse. |-| `project_manager.py page-context` stdout | Derived on-demand page context | Read-only model-facing anchor set + current-page delta + fingerprints for large references | Use only for explicit diagnostics/telemetry or an unresolved page/template/chart path-SHA projection. Never edit or persist it as a replacement source of truth, and never run it as a routine pre-page gate. `global` is a bounded anchor set, not a whitelist. `reference_set` carries path/SHA/load policy but never appends reference payloads. |-| `analysis/page-context/P<NN>.usage.json` | Derived optional context telemetry | Measured on-demand page-context size plus hashes of owning inputs/references | `page-context --record-usage` deterministically replaces only the invoked page's snapshot; `page-context-report` summarizes existing snapshots. Telemetry may be partial. Use token data to evaluate context cost, never as content or an execution contract. |-| `images/` | Runtime image pool | User, extracted, AI, web, slice, and EMF/WMF assets | Default Step 5 or Quick Generate resource preparation writes here; `analysis/image_analysis.csv` derives from current contents |-| `images/image_prompts.json`, `image_queries.json`, `image_sources.json` | Conditional resource contracts | AI/web execution status and provenance | Create only for a triggered path, including Quick. They guide preparation/attribution, never page design. |-| `icons/` | Prepared project icon pool | Bundled icons copied by `icon_sync.py` plus user-provided, template, imported, or custom icon SVGs | SVG authoring may choose any icon in this project-local pool per page; `spec_lock.icons.inventory` indexes the default plan's curated synced bundled pool rather than assigning page usage or defining an exhaustive whitelist. Preview, finalization, checking, and export resolve only complete `library/name` references under this root. |-| `${SKILL_DIR}/templates/{brands,styles,layouts,decks}/*_index.json` | Library discovery indexes | The complete registered option source for Default Stage-1 template selection and chat listing | The UI server or chat branch reads these indexes only to populate the Stage-1 choice, after the communication recommendation is authored. Never scan kind directories to add options or use index summaries as Stage-1 planning evidence. Derive a library root from kind + entry id. Exact unregistered roots remain explicit inputs. Quick does not read the catalog. |-| `templates/` | Project template reference | Stage-1-confirmed non-free selection or Quick direct-input installed specs, one file per selected workspace, the effective structural SVG roster (Layout when present, otherwise Deck), and non-image assets | Default template-aware Strategist work from Stage 2 onward, Quick's current agent before direct authoring, and every later role read this project-local state only, never the library/external installation root. The active planner reads every installed template Design Spec and the effective structural SVG roster; Brand and Style are intentionally roster-free, and Deck structure is shadowed when Layout is present. Continuous Executor reuses that context; fresh Executor reads the Design Spec once and each selected complete SVG, when any, only before first use or after its SHA changes. |-| `templates/template_execution_manifest.json` (`v1`) + `templates/template_execution/*.text-slots.json` (`v2-min`) | Derived template index | Compact prototype/source-import summary plus per-prototype text-slot diagnostics; the sidecar integrity hash is tool-only | Materialization may publish these deterministic records, but page-context does not inject or require them and models do not read them during page authoring. The complete prototype SVG is the sole visual/template authority; never author from either JSON artifact. |-| `<import_workspace>/svg/` | Imported native-payload backing | Complete PPTX-derived metadata, hidden carriers, fallback evidence, and source structure | Keep immutable; create-template materialization may resolve a validated source ref against these files, but models do not edit or bulk-read them |-| `<import_workspace>/svg-flat/` | Optional complete-page verification backing | Self-contained visual composition generated only by explicit `--inheritance-mode both` | Keep immutable when requested; never use as authoring or materialization input |-| `<import_workspace>/authoring-svg/` | Template-creation author source | Canonical compact layered SVG IR for imported Master, Layout, and Slide objects | The PPTX import transaction publishes it already normalized and decoration-factored; Template_Designer reads and edits it, and final template SVGs are materialized from it rather than copied from lossless backing |-| `<import_workspace>/authoring-svg/authoring_summary.json` | Model-readable authoring index | Current SVG roster plus compact per-file canvas, size, text, image, vector, placeholder, and source-ref counts | Models read this before authoring SVGs; regenerate after direct IR edits |-| `<import_workspace>/authoring-svg/authoring_manifest.json` | Tool-only authoring provenance contract | Per-document source/authoring hashes and document-local source-ref paths | Generated atomically with the IR; materialization validates it before reusing native payload; never load it into model context or duplicate raw payload here |-| `<import_workspace>/authoring-svg-flat/` | Optional complete-page verification IR | Self-contained page composition view with its own summary and provenance manifest | Generate only from an explicitly requested `svg-flat/`; use to verify composition, while layered `authoring-svg/` remains the canonical editable source |-| `<import_workspace>/icons/imported/` | Imported vector pool | One canonical copy of every factored vector subtree | Authoring SVGs reference `data-icon="imported/<name>"`; vector inventories retain source refs so expansion re-establishes IR identity |-| `confirm_ui/template_options.json`, `template_selection.json`, `template_handoff.json` | Default UI template-selection sidecar | Agent-authored candidate input, user-confirmed selection written beside the Stage-1 result, and agent-authored installation/free-design completion handoff | Step 3 writes options without launching UI. The Stage-1 submission writes `template_selection.json` alongside `result.json`; template choices never enter the Strategist contract. After installation/free-design closure, `--complete-template-selection` writes the bound handoff. Stage 2 is exposed only after that handoff and a fresh recommendation. Chat/delegated flows retain equivalent state without fabricating UI receipts; Quick creates none. |-| `confirm_ui/recommendations.stage1.json`, `.stage2.json` | Confirmation proposals | Template-independent communication contract, then template-aware complete solution plus production mechanics | Author the Stage-1 communication recommendation without using candidate indexes or workspaces as evidence; candidate display state may be prepared independently. Its page confirms communication plus template mode/selection in one submission. Create Stage 2 only after the selection is installed or free design closes and the handoff/equivalent state is ready. `template_application` decides only how to use installed project-local state. The active unconfirmed stage may be overwritten; normal progression leaves confirmed Stage 1 intact. |-| `confirm_ui/result.json` | Confirmation result | Persisted user-confirmed input evidence | Generate Step 4 reads the final object once into active context; Strategist consumes it completely into `design_spec.md`. Normal downstream work does not reopen it; fresh recovery may read it once when no retained final state exists. |-| `svg_output/` | Page-design author source | Main-agent handwritten SVG pages containing the complete visible design, including each native formula's exact LaTeX marker and ordinary SVG preview | Quality checker and native PPTX export read this as the canonical visual/page-layout source; templates and locks do not add missing visible objects at export. Formula export replaces only its explicit marker subtree under [`native-formula.md`](./native-formula.md). |-| `notes/total.md` | Conditional speaker-note source | Complete notes before splitting | Step 6 writes only when the effective Speaker Notes outcome is enabled; Step 7.1 or Quick §4 splits |-| `notes/slide_*.md` | Conditional split notes | Per-slide notes generated from `total.md` | Derived by `total_md_split.py` only when speaker notes are enabled |-| `svg_final/` | Default-only derived visual preview | Self-contained post-processed SVGs that may be opened directly or inserted as SVG pictures | Default rebuilds it from `svg_output/` with `finalize_svg.py`; Quick omits it. Never use it as a supported PPTX source. |-| `validation/workflow.log` | Cold workflow audit log | Append-only Python command envelopes, material tagged outcomes, bounded warning/OK/stderr samples, per-run omission counts, and selective manual entries for important details with no owning Python output | `project_manager.py init` creates the log and records its milestone. Later project-scoped Python tools find that existing log through the shared CLI bootstrap and record the bounded audit selection without a wrapper command; their full console output is not copied. A helper whose arguments/cwd do not identify the active project receives `PPT_MASTER_PROJECT_PATH=<project_path>` on the same Python command. A role may run `workflow_log.py` once for a material non-Python stage handoff or rework reason, user-approved exception, or manual recovery choice; never duplicate artifacts, routine progress, or private reasoning. Detached services retain detailed output in their component logs. Never read this log during normal generation/resume or use it as stage, artifact, or quality authority; inspect it only for an explicit user-requested run review. In Quick it remains an incomplete operational audit, not a design history or resume source. |-| `validation/svg_quality_report.json` | Final SVG quality provenance | Final SVG gate split into blocking / introduced / inherited / source-import categories, bound to the checked SVG bytes by SHA-256 | Default runs `svg_quality_checker.py --canonical-authoring --stage final --json`; Quick adds `--quick-generate` so the checker ignores Design Spec/lock and infers flat versus structured validation from the complete SVG roster. Export links the report only when fingerprints match; Quick requires that link to pass before PPTX creation. |-| `validation/<output_stem>.report.json` | Published-package audit | PPTX package/resource postflight status, part counts, and quality-gate linkage | Both Generate profiles write it and emit `[POSTFLIGHT]` after package validation. |-| `exports/` | Delivery artifacts | Native DrawingML PPTX and explicit native-object/narration variants | Default Step 7.3 or Quick direct export writes final deliverables from `svg_output/`. |-| `backup/<timestamp>/svg_output/` | Default-path frozen author-source archive | Re-export source without re-running LLM | Both Generate profiles write a snapshot for default-path exports; explicit `-o/--output` skips it. |-| `animations.json` | Optional animation config | Page-transition and object-animation sidecar | Existing files activate intent resolution: final Stage-2 `false` preserves, explicit objects-off exports `-a none`, and all-motion-off bypasses with `--no-animations`. Creation requires explicit instruction or enabled outcome; §IX advice never activates it |+| `sources/` content-type files | Content contract | Factual/text origin for content, tables, chart values, SmartArt wording | Default Strategist reads content-type files (`.md` / `.markdown` / `.txt` / `.csv` / `.tsv` / `.json` / `.jsonl` / `.yaml` / `.yml`), judges by content, and resolves approved semantics plus on-slide wording into §IX; Quick's agent resolves them in active context. Default Executor opens passages only for explicit verification. Never replace values with PPTX geometry JSON |+| `sources/*.facts.json` | Fact provenance contract | Stable external `fact_id` → claim/source mapping from topic research | Strategist cites IDs in §IX and Executor resolves them for attribution; Quick carries the same IDs into visible attribution. Scenario data never enters this file |+| `sources/` converted-source originals | Source archive | Imported originals (`.pdf` / `.pptx` / `.docx` / `.xlsx` / `.html` / `.epub` / `.tex` / `.rst` / `.ipynb` / `.typ`, …) plus extracted assets | Read via the converted `<stem>.md`; direct-PPTX workflows read the `.pptx` by route |+| `sources/*.conversion_profile.json`, `sources/*_files/image_manifest.json` | Pipeline sidecar | Conversion audit / asset index | Not slide content; open only to audit a conversion or resolve assets |+| `sources/` Image to PPTX containers | Visible-surface source contract | Immutable raster inputs, each holding one or several bounded page frames | The Codex-supported Quick profile normalizes them into the ordered frame roster without overwriting originals; frame count owns slide count |+| `analysis/source_profile.json` | Machine fact index | Compact PPTX intake digest | Read as factual context and recommendation candidates |+| `analysis/<stem>.identity.json` | Native deck identity facts | Canvas, theme palette/fonts, observed usage | Read selectively for detailed identity facts |+| `analysis/<stem>.slide_library.json` | Native PPTX structure facts | Text slots, geometry, native tables, chart caches, SmartArt nodes | Direct PPTX workflows use it as the native fill/structure contract; it never owns content values |+| `analysis/beautify_inventory.json` | Beautify frozen validation ledger | Self-contained per-slide ledger of frozen content/data and validation exceptions inlined from source extracts | Sole Beautify ledger; models consume `beautify_inventory.py --summary` / `--page` projections (`--with-geometry` only for raw geometry) and never persist a projection or treat it as a second authority |+| `analysis/image_analysis.csv` | Regenerated image fact view | Measured facts about current `images/` | Re-run `analyze_images.py` after changes; a view, not a durable cache |+| `analysis/reconstruction_inventory.json` | Image to PPTX evidence ledger | Container/frame mapping, hashes, page order/canvas, region bboxes, observed families, transcription confidence, overlap/z-order, unresolved evidence | Written by the Codex Quick agent before layer decisions; holds no final realization, prompts, output filenames, or SVG bindings |+| `design_spec.md` | Strategist design authority | Design intent, page brief, rationale, resources, production mechanics | Consume final confirmation once, write/audit here, apply refinement to this same file. §I records effective Speaker Notes / Custom Animations / Narration Audio outcomes plus provenance; a newer explicit instruction updates only its outcome without reopening Confirm UI. After Gate 1, later roles read this file instead of `result.json`; §IX owns Executor page content, while its layout/composition/capability/motif recommendations stay References unless an explicit user/template/resource constraint promotes them |+| `spec_lock.md` | Execution anchor and routing contract | Stable color/type roles, icons, images, page rhythm, visualizations, `template_reuse_scope`, PowerPoint structure mode; mirror/layout routes add input prototypes, Master roster, and page mapping | Strategist authors route-specific anchors from the audited Design Spec plus context. Executor retains the complete lock once per valid context and consults it before the Design Spec fragment on local uncertainty. Sparse page-local garnish needs no row; a recurring role or new adaptive Layout identity requires Strategist repair |+| `project_manager.py page-context` stdout | Derived on-demand page context | Read-only anchor set + current-page delta + fingerprints | Only for explicit diagnostics/telemetry or an unresolved path-SHA projection; never persisted, never a routine pre-page gate; `global` is a bounded anchor set, not a whitelist |+| `analysis/page-context/P<NN>.usage.json` | Optional context telemetry | Measured page-context size plus input hashes | `--record-usage` replaces only the invoked page's snapshot; `page-context-report` summarizes; token data evaluates cost, never content |+| `images/` | Runtime image pool | User, extracted, AI, web, slice, EMF/WMF assets | Default Step 5 or Quick resource preparation writes here |+| `images/image_prompts.json`, `image_queries.json`, `image_sources.json` | Conditional resource contracts | AI/web execution status and provenance | Created only for a triggered path; guide preparation/attribution, never page design |+| `icons/` | Prepared project icon pool | Bundled icons copied by `icon_sync.py` plus user, template, imported, or custom icon SVGs | Authoring may use any icon in this pool per page; `spec_lock.icons.inventory` indexes the default plan's curated synced pool, not page usage or a whitelist. Preview, finalization, checking, and export resolve only complete `library/name` references under this root |+| `${SKILL_DIR}/templates/{brands,styles,layouts,decks}/*_index.json` | Library discovery indexes | Complete registered option source for Stage-1 selection and chat listing | Read only to populate the Stage-1 choice after the communication recommendation is authored; never scan kind directories or use index summaries as planning evidence; derive a library root from kind + id; Quick does not read the catalog |+| `templates/` | Project template reference | Stage-1-confirmed or Quick-installed specs, one file per selected workspace, the effective structural SVG roster (Layout when present, otherwise Deck), non-image assets | Read this project-local state only, never the library root. The planner reads every installed Design Spec and the effective roster; Brand and Style are roster-free; Deck structure is shadowed by Layout. Continuous Executor reuses context; fresh Executor reads the Design Spec once and each selected SVG before first use or after its SHA changes |+| `templates/template_execution_manifest.json` (`v1`), `templates/template_execution/*.text-slots.json` (`v2-min`) | Derived template index | Prototype/source-import summary and text-slot diagnostics; integrity hash is tool-only | Never read during page authoring; the prototype SVG is the sole visual authority |+| `<import_workspace>/svg/` | Imported native-payload backing | PPTX-derived metadata, hidden carriers, fallback evidence, source structure | Immutable; materialization may resolve a validated source ref against it; models never edit or bulk-read it |+| `<import_workspace>/svg-flat/` | Optional verification backing | Self-contained composition from explicit `--inheritance-mode both` | Immutable; never authoring or materialization input |+| `<import_workspace>/authoring-svg/` | Template-creation author source | Compact layered SVG IR for imported Master, Layout, and Slide objects | Published normalized and decoration-factored by import; Template_Designer edits it; final template SVGs materialize from it |+| `<import_workspace>/authoring-svg/authoring_summary.json` | Model-readable authoring index | SVG roster plus per-file canvas, size, text, image, vector, placeholder, source-ref counts | Read before authoring SVGs; regenerate after direct IR edits |+| `<import_workspace>/authoring-svg/authoring_manifest.json` | Tool-only provenance | Per-document hashes and source-ref paths | Generated atomically with the IR; validated by materialization; never loaded into model context |+| `<import_workspace>/authoring-svg-flat/` | Optional verification IR | Self-contained page composition with its own summary/manifest | Generated only from an explicitly requested `svg-flat/`; verification only |+| `<import_workspace>/icons/imported/` | Imported vector pool | One canonical copy of every factored vector subtree | Referenced as `data-icon="imported/<name>"`; inventories retain source refs |+| `confirm_ui/template_options.json`, `template_selection.json`, `template_handoff.json` | Default UI template-selection sidecar | Agent-authored candidates, user-confirmed selection beside the Stage-1 result, installation/free-design handoff | Step 3 writes options without launching UI; the Stage-1 submission writes `template_selection.json`; `--complete-template-selection` writes the handoff; Stage 2 is exposed only after that handoff and a fresh recommendation. Chat/delegated flows keep equivalent state without fabricating receipts; Quick creates none |+| `confirm_ui/recommendations.stage1.json`, `.stage2.json` | Confirmation proposals | Template-independent communication contract, then template-aware complete solution plus production mechanics | Stage 1 is authored without candidate indexes or workspaces as evidence and confirms communication plus template mode/selection in one submission; Stage 2 is created only after installation or free-design closure; `template_application` decides only how to use installed state; only the active unconfirmed stage may be overwritten |+| `confirm_ui/result.json` | Confirmation result | Persisted user-confirmed evidence | Step 4 reads the final object once; Strategist consumes it completely into `design_spec.md`; downstream never reopens it except a fresh recovery with no retained state |+| `svg_output/` | Page-design author source | Handwritten SVG pages containing the complete visible design, including formula markers | Canonical source for the checker and native export; templates and locks never add missing visible objects at export |+| `notes/total.md`, `notes/slide_*.md` | Conditional speaker-note source / split notes | Complete notes; per-slide split by `total_md_split.py` | Written only when Speaker Notes is enabled; Step 7.1 or Quick §4 splits |+| `svg_final/` | Default-only derived preview | Self-contained post-processed SVGs | Rebuilt from `svg_output/` by `finalize_svg.py`; Quick omits it; never a PPTX source |+| `validation/workflow.log` | Cold workflow audit log | Append-only Python command envelopes, material outcomes, bounded samples, selective manual entries | Created by `project_manager.py init`; later project-scoped tools record automatically (a helper without project-identifying arguments receives `PPT_MASTER_PROJECT_PATH`). A role may run `workflow_log.py` once for a material non-Python handoff, rework reason, approved exception, or manual recovery. Never read during generation/resume or treat as stage/artifact/quality authority; inspect only on explicit user request |+| `validation/svg_quality_report.json` | Final SVG quality provenance | Final gate split into blocking / introduced / inherited / source-import, bound to SVG bytes by SHA-256 | Default: `svg_quality_checker.py --canonical-authoring --stage final --json`; Quick adds `--quick-generate` (ignores Design Spec/lock, infers flat vs structured from the roster). Export links the report only on matching fingerprints |+| `validation/<output_stem>.report.json` | Published-package audit | Package/resource postflight, part counts, quality-gate linkage | Both profiles write it and emit `[POSTFLIGHT]` |+| `exports/` | Delivery artifacts | Native PPTX and explicit native-object/narration variants | Default Step 7.3 or Quick export writes from `svg_output/` |+| `backup/<timestamp>/svg_output/` | Frozen author-source archive | Re-export source without re-running the LLM | Snapshot on default-path exports; explicit `-o/--output` skips it |+| `animations.json` | Optional animation config | Page-transition and object-animation sidecar | An existing file activates intent resolution (Stage-2 `false` preserves, explicit objects-off exports `-a none`, all-motion-off uses `--no-animations`); creation requires explicit instruction or an enabled outcome; §IX advice never activates it |---@@ -72,47 +59,34 @@ history, or resumable planning state. Context loss restarts the Quick run.| Invariant | Rule ||---|---|-| Content authority | Content-type files in `sources/` own the factual/text origin for content, tables, chart values, and SmartArt wording. For Beautify, `sources/<stem>.md` remains that origin; `analysis/beautify_inventory.json` only deterministically inlines the frozen values needed by its self-contained validation contract and does not become a second content authority. Default Strategist resolves source content into §IX and Executor realizes that contract without drafting a second outline. Quick's current agent resolves it once in active context before SVG authoring. `slide_library.json` does not own content values. |-| Sources read policy | In `sources/`, read content-type files (`.md` / `.markdown` / `.txt` / `.csv` / `.tsv` / `.json` / `.jsonl` / `.yaml` / `.yml`) and judge by content — a `.json` / `.csv` may be core content or just data. Exclude known sidecars: `*.conversion_profile.json` and `*_files/image_manifest.json`. `analysis/` facts (`source_profile.json`, `<stem>.slide_library.json`) are read per Step 4 / direct-PPTX workflow, not in the `sources/` content scan. |-| PPTX structure | `analysis/<stem>.slide_library.json` owns native geometry, slot facts, and SmartArt layout/relationships for direct PPTX workflows. The Beautify inventory only deterministically inlines the subset required by its validation contract; neither the full ledger nor its stdout projections replace `slide_library.json` as the native-structure fact source. |-| Design contract | Final confirmation once → audited `design_spec.md` → optional same-file refinement/approval → context-authored lock. Never maintain a parallel draft/lock. Executor may apply `Template Application` prose but never replace identity. Repair divergence from the approved Design Spec/context unless it fails active-decision fidelity. |-| Flat packaging authority | Free-design, brand-only, Style-only, and every plan with `template_reuse_scope: style` declare `pptx_structure.mode: flat` and omit `pptx_masters`, `pptx_layouts`, `page_pptx_layouts`, and `page_layouts`. A Style installed alongside Layout/Deck changes only Direction / method and does not force the non-Style structure plan to flat. `svg_output/` owns the complete Slide-local visual design without root Master/Layout identity, fixed-layer ownership, or placeholder metadata. Export materializes one clean project-owned Master plus one Blank Layout, applies the locked theme defaults, removes stock content placeholders/Layout inventory, and retains only the standard date/footer/slide-number capability hooks. |-| Template structure authority | `template_reuse_scope: mirror|layout` uses `page_layouts` for each page's authoring-input prototype. `pptx_masters` / `pptx_layouts` own the unique reusable output definitions, while `page_pptx_layouts` owns page assignment. Strict keeps the prototype; adaptive Layout choice is authorized by Strategist or Quick's frozen Template Application. A construction-discovered structural change returns upstream for definition and assignment repair before authoring resumes. Mirror additionally preserves ordinary authored visuals/text topology; only a JSON-first Chart/Table's derived preview children may regenerate while its metadata/structure remain fixed. Layout allows project-controlled reflow/re-skinning. Unused definitions may register without a published Slide. Templates validate provenance but never add missing visible page objects during export. |-| Fact classes | External facts resolve through `sources/*.facts.json`; invented demo KPIs/targets/internal ratios are labeled `scenario` in `design_spec.md §IX` and visibly in the page. Never promote scenario data into the external fact registry. |-| Imported-template authoring | Editable SVGs under `authoring-svg/` own create-template edits, `authoring_summary.json` owns model-facing orientation, and `authoring_manifest.json` owns tool-only source-object identity. Lossless `svg/` owns immutable native payload and fallback evidence; optional `svg-flat/` owns only complete-page verification. Materialized `templates/*.svg` own the validated deliverable contract and contain no IR-only source refs. |-| Legacy template input | Old unmapped/distilled/preserve structured projects and incomplete template packages are not migrated in place. [`create-template`](../workflows/create-template.md) authors a new current workspace: original PPTX Type A may preserve existing native topology in mirror; legacy SVG-only Type B is visual reference for `standard` / `fidelity`. Intentional free-design, Brand-only, and Style-only `flat` projects are already current. The exporter does not migrate or visually cluster legacy structure. |-| Image facts | `images/` is live state; `analysis/image_analysis.csv` is a regenerated view, not a durable cache. |-| Image to PPTX | Normalized page frames own visible-surface truth, not literal reuse of their pixel bytes; `analysis/reconstruction_inventory.json` owns only source evidence. Native text restores visible wording. Identity graphics use an exact vector, deterministic redraw, sufficient source asset, or Codex reference-based high-resolution reconstruction; data graphics stay native-and-verified or exact and are never generatively recreated. Scene imagery uses registered clean-base/midground/subject/foreground layers; padded-bbox-disjoint objects may share one generated plate before independent crop/slice realization. Never infer hidden semantics, substitute a merely similar graphic, or use a full-page screenshot skin as the editable result. |-| SVG source | `svg_output/` is the only author source for generated pages. |-| Page-design closure | On SVG-authoring routes, every visible exported-slide object exists in the corresponding page SVG or an explicitly referenced visual asset. |-| Package-behavior separation | Speaker notes, animations, transitions, narration, and direct native-PPTX workflows keep their owning artifacts; do not force them into SVG metadata. |-| Post-processed SVG | In Default Generate, `svg_final/` is an optional disposable preview rebuilt by Step 7.2; it serves only as a self-contained visual preview / manually insertable SVG picture. Quick omits it. |-| Workflow audit log | `validation/workflow.log` automatically records each project-scoped Python command envelope, all explicit error/failure and receipt/report lines, bounded warning/OK/stderr samples, summary context, and omission counts, plus explicitly selected manual audit entries. It does not retain the full console stream or automatically capture direct file-authoring actions, host-native tools, pre-project conversion, binary-buffer writes, hidden child output, or detached-service activity; absence of a detail line proves nothing about those stages. Automatic recording failure is advisory and never changes the owning tool's outcome; a failed explicit manual append reports failure because no entry was recorded. |-| Export source | The only supported generated-PPTX route reads `svg_output/` through the project SVG-to-DrawingML converter. A diagnostic `-s final` override does not change ownership or create a supported release route. |-| Shape-conversion boundary | PowerPoint's manual Convert-to-Shape operation on `svg_final/` is outside the project compatibility contract. |-| Confirmation | Final UI/chat confirmation overrides recommendations and is consumed once into `design_spec.md`. Enabled refinement applies arbitrary revisions there and requires approval; only then may active-decision fidelity release lock authoring. |-| Template selection | Default Step 3 prepares candidates without interaction or template reads. `template_options.default_mode` is `free_design` for ordinary requests and `templates` for explicit template intent or any exact root; Stage 1 keeps the mode switchable and confirms it with communication. Exactly one root may be preselected, while multiple roots remain unselected candidates. Template mode requires at least one selected candidate. Every applied selection becomes one project-local `templates/` state before Stage 2 reads it. Quick bypasses this gate and applies at most one exact root per kind directly. |-| Proactive production outcomes | Resolve notes/animation/narration from explicit instruction → final Stage 2 → defaults, then persist outcomes/provenance only in Design Spec §I. Explicit notes-off/audio-on applies Generate's dependency gate; final Stage-2 animation `false` does not suppress a sidecar. |+| Content authority | `sources/` content-type files own the factual/text origin; for Beautify, `sources/<stem>.md` remains that origin and `beautify_inventory.json` only inlines frozen validation values. Strategist resolves content into §IX and Executor realizes it without a second outline; Quick resolves once in active context. `slide_library.json` never owns content values |+| Sources read policy | Read content-type files and judge by content (a `.json` / `.csv` may be core content or just data); exclude `*.conversion_profile.json` and `*_files/image_manifest.json`. `analysis/` facts are read per Step 4 / direct-PPTX workflow, not in the `sources/` scan |+| PPTX structure | `analysis/<stem>.slide_library.json` owns native geometry, slot facts, and SmartArt relationships for direct PPTX workflows; the Beautify ledger and its projections never replace it |+| Design contract | Final confirmation once → audited `design_spec.md` → optional same-file refinement/approval → context-authored lock; never a parallel draft/lock. Executor may apply `Template Application` prose but never replaces identity; repair divergence from the approved Design Spec unless it fails active-decision fidelity |+| Packaging authority | Flat and structured routing, lock rows, and the Master/Layout/placeholder contract are owned by [`pptx-structure-interface.md`](./pptx-structure-interface.md) §1–§2 and planned under [`strategist-template.md`](./strategist-template.md) §3. `svg_output/` owns the complete visible design on every route; templates validate provenance but never add visible objects at export. A construction-discovered structural change returns upstream for definition and assignment repair |+| Fact classes | External facts resolve through `sources/*.facts.json`; invented demo KPIs/targets/ratios are labeled `scenario` in §IX and visibly on the page, never promoted into the fact registry |+| Imported-template authoring | `authoring-svg/` owns create-template edits, `authoring_summary.json` model-facing orientation, `authoring_manifest.json` tool-only identity; lossless `svg/` owns immutable payload, optional `svg-flat/` verification only; materialized `templates/*.svg` own the deliverable contract with no IR-only refs |+| Legacy template input | Old unmapped/distilled/preserve projects and incomplete packages are never migrated in place; [`create-template`](../workflows/create-template.md) authors a new workspace (original PPTX Type A may preserve native topology in mirror; legacy SVG-only Type B is visual reference). Intentional `flat` projects are current. The exporter never migrates or clusters legacy structure |+| Image to PPTX | Normalized frames own visible-surface truth, not literal pixel reuse; `reconstruction_inventory.json` owns only evidence. Native text restores wording; identity graphics use an exact vector, deterministic redraw, sufficient source asset, or Codex reference-based reconstruction; data graphics stay native-and-verified or exact; scene imagery uses registered clean-base/midground/subject/foreground layers, and padded-bbox-disjoint objects may share one plate before independent crops. Never infer hidden semantics, substitute a similar graphic, or use a full-page screenshot skin |+| SVG source and closure | `svg_output/` is the only author source; every visible exported object exists in its page SVG or an explicitly referenced asset. The only supported export route reads `svg_output/` through the project converter; diagnostic `-s final` creates no release route; PowerPoint's Convert-to-Shape on `svg_final/` is outside the contract |+| Package-behavior separation | Speaker notes, animations, transitions, narration, and direct native-PPTX workflows keep their owning artifacts, never forced into SVG metadata |+| Workflow audit log | Records command envelopes, error/failure and receipt/report lines, bounded samples, summary context, omission counts, and selected manual entries; it does not capture direct file authoring, host-native tools, pre-project conversion, binary writes, hidden child output, or detached services — absence of a line proves nothing. Automatic recording failure is advisory; a failed explicit manual append reports failure |+| Confirmation and template selection | Final UI/chat confirmation overrides recommendations and is consumed once; enabled refinement requires approval before lock authoring. Step 3 prepares candidates without reads; `template_options.default_mode` is `free_design` for ordinary requests and `templates` for explicit intent or any exact root; exactly one root may be preselected; template mode requires one selected candidate; every applied selection becomes project-local `templates/` state before Stage 2. Quick applies at most one exact root per kind directly |+| Proactive production outcomes | Resolve notes/animation/narration as explicit instruction → final Stage 2 → defaults; persist outcomes/provenance only in Design Spec §I. Explicit notes-off/audio-on applies Generate's dependency gate; a Stage-2 animation `false` does not suppress an existing sidecar |-**Forbidden - mixed ownership**: Do not copy chart values from Markdown into `analysis/` by hand, do not edit `svg_final/` as the source of a fix, do not edit imported lossless SVGs instead of their authoring IR, and do not treat `design_spec.md` prose as a replacement for `spec_lock.md`.+**Forbidden — mixed ownership**: copying chart values from Markdown into `analysis/` by hand, editing `svg_final/` as the source of a fix, editing imported lossless SVGs instead of their authoring IR, treating `design_spec.md` prose as a replacement for `spec_lock.md`.---## 3. Regeneration Rules-The table names each owning command. Generate profiles invoke these commands-directly; the bounded project-scoped Python command/outcome audit is recorded-automatically after initialization. Other routes retain their own invocation-contract.-| Derived artifact | Regenerate from | Command / owner ||---|---|---|| `analysis/image_analysis.csv` | Current `images/` | `python3 ${SKILL_DIR}/scripts/analyze_images.py <project_path>/images` |-| `<import_workspace>/authoring-svg/authoring_summary.json` | Current authoring SVGs plus tool-only manifest roster | `python3 ${SKILL_DIR}/scripts/svg_authoring_view.py <import_workspace>/authoring-svg --refresh-summary`; in-place vector/picture extraction refreshes it automatically |-| `notes/slide_*.md` | `notes/total.md`, when speaker notes are enabled | `python3 ${SKILL_DIR}/scripts/total_md_split.py <project_path>` |+| `<import_workspace>/authoring-svg/authoring_summary.json` | Current authoring SVGs plus tool-only manifest | `python3 ${SKILL_DIR}/scripts/svg_authoring_view.py <import_workspace>/authoring-svg --refresh-summary`; in-place extraction refreshes it automatically |+| `notes/slide_*.md` | `notes/total.md`, when notes are enabled | `python3 ${SKILL_DIR}/scripts/total_md_split.py <project_path>` || `svg_final/` | `svg_output/` plus project assets | `python3 ${SKILL_DIR}/scripts/finalize_svg.py <project_path>` |-| `validation/svg_quality_report.json` | `svg_output/`, plus locks/template provenance in Default Generate | Default: `python3 ${SKILL_DIR}/scripts/svg_quality_checker.py <project_path> --canonical-authoring --stage final --json`; Quick: append `--quick-generate` |-| Native PPTX + `validation/<output_stem>.report.json` | `svg_output/` plus notes/assets and final quality report | `python3 ${SKILL_DIR}/scripts/svg_to_pptx.py <project_path>` |-| Quick native PPTX | `svg_output/`, prepared resources, passing Quick final report | `python3 ${SKILL_DIR}/scripts/svg_to_pptx.py <project_path> --quick-generate` |+| `validation/svg_quality_report.json` | `svg_output/`, plus locks/template provenance in Default | Default: `python3 ${SKILL_DIR}/scripts/svg_quality_checker.py <project_path> --canonical-authoring --stage final --json`; Quick: append `--quick-generate` |+| Native PPTX + `validation/<output_stem>.report.json` | `svg_output/` plus notes/assets and the final report | `python3 ${SKILL_DIR}/scripts/svg_to_pptx.py <project_path>` (Quick: `--quick-generate`) |-**Default - regenerate derived views**: When a source artifact changes, regenerate the derived artifact at the owning step instead of patching the derived file directly.+**Default — regenerate derived views**: when a source artifact changes, regenerate the derived artifact at the owning step instead of patching it directly.diff --git a/skills/ppt-master/scripts/prompt_audit_manifest.json b/skills/ppt-master/scripts/prompt_audit_manifest.jsonindex 91059698..9ddda1ca 100644--- a/skills/ppt-master/scripts/prompt_audit_manifest.json+++ b/skills/ppt-master/scripts/prompt_audit_manifest.json@@ -49,7 +49,12 @@"skills/ppt-master/references/native-formula.md": 1500,"skills/ppt-master/references/semantic-svg.md": 1500,"skills/ppt-master/references/native-hyperlinks.md": 1250,- "skills/ppt-master/references/canvas-formats.md": 1250+ "skills/ppt-master/references/canvas-formats.md": 1250,+ "skills/ppt-master/workflows/routing.md": 3000,+ "skills/ppt-master/references/artifact-ownership.md": 4500,+ "skills/ppt-master/workflows/governance/failure-recovery.md": 2750,+ "skills/ppt-master/workflows/stages/resume-execute.md": 1750,+ "skills/ppt-master/workflows/stages/refine-spec.md": 1000},"load_sets": {"bootstrap.routing": {@@ -1915,7 +1920,7 @@{"path": "skills/ppt-master/workflows/routing.md","role": "consumer",- "fingerprint": "a287404b8f1e",+ "fingerprint": "b3ea6e828373","reason": "This consumer needs the field contract for deterministic execution."},{@@ -1965,12 +1970,6 @@"role": "compatibility","fingerprint": "39d5baf1e189","reason": "This site documents a legacy or omission compatibility boundary."- },- {- "path": "skills/ppt-master/workflows/stages/resume-execute.md",- "role": "compatibility",- "fingerprint": "023cf4d8ecbd",- "reason": "This site documents a legacy or omission compatibility boundary."}]},@@ -1978,12 +1977,6 @@"field": "page_layouts","owner_fingerprint": "64d28e112785","projections": [- {- "path": "skills/ppt-master/references/artifact-ownership.md",- "role": "reference",- "fingerprint": "be5e3881ee0d",- "reason": "This reference mirrors the owner field grammar or ownership boundary."- },{"path": "skills/ppt-master/references/executor-structured.md","role": "consumer",@@ -2020,12 +2013,6 @@"field": "page_pptx_layouts","owner_fingerprint": "f436e6ae4bb8","projections": [- {- "path": "skills/ppt-master/references/artifact-ownership.md",- "role": "reference",- "fingerprint": "e05b75f54145",- "reason": "This reference mirrors the owner field grammar or ownership boundary."- },{"path": "skills/ppt-master/references/executor-structured.md","role": "consumer",@@ -2110,12 +2097,6 @@"field": "pptx_layouts","owner_fingerprint": "1037e878eaa1","projections": [- {- "path": "skills/ppt-master/references/artifact-ownership.md",- "role": "reference",- "fingerprint": "447cd531facc",- "reason": "This reference mirrors the owner field grammar or ownership boundary."- },{"path": "skills/ppt-master/references/executor-structured.md","role": "consumer",@@ -2146,12 +2127,6 @@"field": "pptx_masters","owner_fingerprint": "7cbe6ec7056e","projections": [- {- "path": "skills/ppt-master/references/artifact-ownership.md",- "role": "reference",- "fingerprint": "7eba0fa766a6",- "reason": "This reference mirrors the owner field grammar or ownership boundary."- },{"path": "skills/ppt-master/references/executor-structured.md","role": "consumer",diff --git a/skills/ppt-master/workflows/governance/failure-recovery.md b/skills/ppt-master/workflows/governance/failure-recovery.mdindex af7e9639..d15b044c 100644--- a/skills/ppt-master/workflows/governance/failure-recovery.md+++ b/skills/ppt-master/workflows/governance/failure-recovery.md@@ -4,9 +4,9 @@ description: Cross-route stop/continue governance with a concrete recovery matri# Failure Recovery Governance-Global stop/continue rules for all three top-level routes, plus concrete failure handling for Generate PPTX. Section 2 applies across routes; Sections 1 and 3 apply only to Generate PPTX. Owning route and stage documents may add narrower handling, but must not weaken the global rules or duplicate this matrix.+Global stop/continue rules for all three routes plus concrete Generate PPTX handling. §2 applies across routes; §1 and §3 apply only to Generate PPTX. Owning route and stage documents may add narrower handling but never weaken these rules or duplicate the matrix.-**Hard rule**: A failed required artifact blocks the next gate. A failed convenience surface falls back to the canonical channel and does not block the active route.+**Hard rule**: a failed required artifact blocks the next gate. A failed convenience surface falls back to the canonical channel and does not block the route.---@@ -14,34 +14,33 @@ Global stop/continue rules for all three top-level routes, plus concrete failure| Failure point | Blocking | Automatic recovery | User intervention | Resume entry ||---|---:|---|---|---|-| Confirm UI launch failure | No | Re-check `confirm_ui/result.json` once, then use chat fallback | No | [`generate-pptx`](../generate-pptx.md) Step 4 chat confirmation |-| Confirm UI wait timeout | No, if no final result yet | Re-check `result.json` once; keep server cleanup mandatory | Only if user still wants the page | Step 4 same stage or chat fallback |-| User explicitly switches from Confirm UI to chat during any stage | Yes until the unresolved current stage is confirmed | Follow [`confirm_ui.md`](../../scripts/docs/confirm_ui.md)'s in-run switch, retain persisted confirmed stages, then continue the current and remaining stages in chat; never relaunch UI | Confirm in chat unless explicitly delegated | Step 4 current chat stage |-| Confirm UI Stage 1 completed then unexpectedly interrupted while UI remains selected | Yes until final Stage 2 is written/confirmed | Read existing Stage 1 `result.json`, derive a fresh `recommendations.stage2.json` without changing Stage 1, then `--wait-only` for final confirmation | Usually no | Step 4 final Stage 2 write/wait |-| Missing final confirmation | Yes | None | User must confirm or change the values | Step 4 final confirmation |-| Final confirmed value or a later explicit user override is missing, changed, substituted, or weakened in `design_spec.md` | Yes | Repair from the retained final-confirmation object plus any newer explicit instruction; only a fresh recovery turn with no retained state reads persisted final evidence once | Only when the effective value genuinely cannot be honored | Step 4 Gate 1 — confirmation fidelity |-| `spec_lock.md` changes confirmed identity or omits a required execution anchor/routing decision | Yes | Re-author the affected lock rows from the completed Design Spec and current context; do not enumerate page-local literals | No unless the Design Spec itself is incomplete | Step 4 Gate 2 — lock context fidelity |-| Execution exposes a missing Strategist-owned role/plan detail | Yes for the affected page | Repair affected Design Spec/lock fragments under [`executor-base.md`](../../references/executor-base.md) §2.1 | Only if confirmed intent changes | Step 4 Gate 1/2 → Step 6 current page |-| Execution context is fresh, resumed, restarted, compacted/summary-only, external, or unknown | Yes until rebuilt | Read complete Design Spec, then lock, once; reload triggered inputs and latest completed SVG when mid-deck | No | Step 6 current page |-| `apply-template-workspace` rejects a legacy or incomplete template contract | Yes | Stop template consumption; create a new current workspace through Create Template from the original PPTX/reference, then return with its exact workspace root | Only when required source evidence or template choices are unavailable | Create Template → Generate PPTX Step 4 Stage 1 (`apply-template-workspace`) |-| Native formula marker validation or LaTeX compilation failure | Yes for the affected page | Repair the marker metadata or source LaTeX and rerun the SVG checker; there is no formula-image fallback | Clarify the intended equation only when the source is ambiguous | Active SVG authoring step |-| AI image generation failure | Default blocks at the recovery decision; Quick does not | Default `auto`: try A → B, then ask once to repair/retry, generate manually, or cancel/replan affected AI images; explicit `api` / `host-native`: retry only that path, then ask the same question. Quick removes the exhausted AI/dependent-slice jobs, replans them with native editable text/SVG or already prepared non-AI assets, and continues | Default chooses one outcome; manual files are still required before export | Default: Step 5 decision → same path, Step 4 affected-plan repair, or Step 7 image readiness gate; Quick: current resource plan |-| Web image search/download failure | No | Adjust query/source per image-searcher rules, then mark `Needs-Manual` if unresolved | Only if the resource is required and no acceptable substitute exists | Step 5 |-| Slice sheet missing | Yes for derived slice rows | Wait for parent sheet; run `slice_images.py`; rerun image analysis | Yes when sheet was manual/offline | Step 5 slice handling / Step 7 image readiness gate |-| Strict-alpha slice failure | Yes for every named output | Return the parent to image preparation; correct an evidenced key/tolerance mismatch, then enlarge cells or split incompatible shape families and regenerate when content reaches an edge. A generated parent never substitutes for its missing slices | Only after the selected automated recovery is exhausted | Quick §2 resource closure / Default Step 5 slice handling |-| Residual `Pending` or `Failed` image row before Executor | Yes | Re-run the owning path; Default AI follows its three-outcome decision and reaches `Needs-Manual` only after manual confirmation; Quick automated AI follows its declared no-AI replan | Only when the owning rule requires a new choice or manual file | Step 5 terminal-state check |+| Confirm UI launch failure | No | Re-check `confirm_ui/result.json` once, then chat fallback | No | [`generate-pptx`](../generate-pptx.md) Step 4 chat confirmation |+| Confirm UI wait timeout | No, if no final result yet | Re-check `result.json` once; server cleanup stays mandatory | Only if the user still wants the page | Step 4 same stage or chat fallback |+| User switches from Confirm UI to chat mid-stage | Yes until the current stage is confirmed | Follow the in-run switch in [`confirm-surface.md`](../../references/confirm-surface.md): keep persisted confirmed stages, continue the current and remaining stages in chat, never relaunch UI | Confirm in chat unless delegated | Step 4 current chat stage |+| Stage 1 completed, then interrupted while UI remains selected | Yes until final Stage 2 is confirmed | Read Stage 1 `result.json`, derive a fresh `recommendations.stage2.json` without changing Stage 1, then `--wait-only` | Usually no | Step 4 final Stage 2 write/wait |+| Missing final confirmation | Yes | None | User confirms or changes the values | Step 4 final confirmation |+| Final confirmed value or later explicit override missing, changed, or weakened in `design_spec.md` | Yes | Repair from the retained final-confirmation object plus any newer explicit instruction; only a fresh recovery turn with no retained state reads persisted evidence once | Only when the value genuinely cannot be honored | Step 4 Gate 1 |+| `spec_lock.md` changes confirmed identity or omits a required anchor/routing decision | Yes | Re-author the affected rows from the completed Design Spec and context; do not enumerate page-local literals | No unless the Design Spec is incomplete | Step 4 Gate 2 |+| Execution exposes a missing Strategist-owned role/plan detail | Yes for the page | Repair the Design Spec/lock fragments under [`executor-base.md`](../../references/executor-base.md) §2.1 | Only if confirmed intent changes | Step 4 Gate 1/2 → Step 6 current page |+| Execution context is fresh, resumed, compacted, external, or unknown | Yes until rebuilt | Read the complete Design Spec, then lock, once; reload triggered inputs and the latest completed SVG when mid-deck | No | Step 6 current page |+| `apply-template-workspace` rejects a legacy or incomplete template | Yes | Stop template consumption; create a new workspace through Create Template from the original PPTX/reference and return with its exact root | Only when source evidence or template choices are unavailable | Create Template → Step 4 Stage 1 |+| Native formula marker validation or LaTeX compilation failure | Yes for the page | Repair the marker or LaTeX and rerun the checker; no formula-image fallback | Clarify the equation only when the source is ambiguous | Active SVG authoring step |+| AI image generation failure | Default blocks at the recovery decision; Quick does not | Default `auto`: try A → B, then ask once to repair/retry, generate manually, or cancel/replan; explicit `api` / `host-native`: retry that path, then ask. Quick removes exhausted AI/dependent-slice jobs, replans with native text/SVG or prepared non-AI assets, and continues | Default chooses one outcome; manual files still required before export | Default: Step 5 decision, Step 4 plan repair, or Step 7 image readiness gate; Quick: current resource plan |+| Web image search/download failure | No | Adjust query/source per image-searcher rules, then `Needs-Manual` if unresolved | Only if required with no substitute | Step 5 |+| Slice sheet missing | Yes for derived slice rows | Wait for the parent sheet; run `slice_images.py`; rerun image analysis | Yes when the sheet was manual/offline | Step 5 slice handling / Step 7 image readiness gate |+| Strict-alpha slice failure | Yes for every named output | Return the parent to preparation; correct an evidenced key/tolerance mismatch, then enlarge cells or split incompatible shape families and regenerate; a parent never substitutes for its slices | Only after automated recovery is exhausted | Quick §2 resource closure / Default Step 5 |+| Residual `Pending` or `Failed` image row before Executor | Yes | Re-run the owning path; Default AI follows its three-outcome decision and reaches `Needs-Manual` only after manual confirmation; Quick follows its no-AI replan | Only when the owning rule requires a new choice or file | Step 5 terminal-state check || User replaces/adds images after analysis | No | Re-run `analyze_images.py` before reading image facts | No | Step 4/5/6 image-fact read |-| Live preview fails to start | No | Continue generation; report that preview is unavailable | Only if user requires browser preview | Step 6 or `live-preview` Step 1 |-| Live preview closed by user | No | Continue generation | No | Restart through `live-preview` only if requested |-| Browser annotations submitted during generation | No | Defer application until after Step 7 | User asks to apply annotations | `live-preview` Step 2 |-| `svg_quality_checker.py` error | Yes | Review the complete issue set from one unfiltered run; fix all errors and selected warnings in one consolidated edit pass, then perform one verification rerun. If it still fails, use that complete result as the next batch; never check between individual fixes | No unless required asset is missing | Step 6 Visual Construction |-| `svg_quality_checker.py` warning | No | Continue without mandatory modification or acknowledgement; preserve compatible user syntax, and report material fidelity/quality advice when useful | No | Step 6 advisory warning handling |-| Missing `notes/total.md` while the effective Speaker Notes outcome is enabled | Yes | Generate speaker notes before Step 7 | No | Step 6 Logic Construction |-| Step 7 image readiness missing manual files | Yes | None for manual assets; list required filenames and prompts | Yes | Step 7 image readiness gate |-| `total_md_split.py` failure while speaker notes are enabled | Yes | Fix notes format/path, rerun only Step 7.1 | Usually no | Step 7.1 |-| `finalize_svg.py` failure | Yes | Fix SVG/assets, rerun Step 7.2 | Only if source asset is missing | Step 7.2 |-| `svg_to_pptx.py` failure | Yes | If no current matching passing final SVG quality report exists, obtain the complete blocking issue set from the final checker as needed, fix it, rerun the checker against the updated `svg_output/`, and proceed to Step 7.3 only after it reports `passed`; otherwise fix the conversion issue and rerun Step 7.3 | Only if a required artifact is missing | Step 6 final quality gate or Step 7.3 |-| Export succeeds but user wants direct browser edits re-exported | No | Rerun Step 7.2 and Step 7.3 after applied edits | No | Post-export live-preview handling |+| Live preview fails to start / closed by user | No | Continue generation; report unavailability | Only if the user requires browser preview | Step 6, or `live-preview` Step 1 on request |+| Browser annotations submitted during generation | No | Defer application until after Step 7 | User asks to apply | `live-preview` Step 2 |+| `svg_quality_checker.py` error | Yes | Review the complete issue set from one unfiltered run; fix all errors and selected warnings in one consolidated pass, then one verification rerun; a remaining failure is the next batch — never check between individual fixes | No unless a required asset is missing | Step 6 Visual Construction |+| `svg_quality_checker.py` warning | No | Continue without mandatory modification; preserve compatible user syntax, report material advice when useful | No | Step 6 advisory handling |+| Missing `notes/total.md` while Speaker Notes is enabled | Yes | Generate notes before Step 7 | No | Step 6 Logic Construction |+| Step 7 image readiness missing manual files | Yes | None; list required filenames and prompts | Yes | Step 7 image readiness gate |+| `total_md_split.py` failure | Yes | Fix notes format/path, rerun Step 7.1 | Usually no | Step 7.1 |+| `finalize_svg.py` failure | Yes | Fix SVG/assets, rerun Step 7.2 | Only if a source asset is missing | Step 7.2 |+| `svg_to_pptx.py` failure | Yes | Without a current passing final report: get the complete blocking set from the final checker, fix, rerun the checker, proceed only after `passed`; otherwise fix the conversion issue and rerun Step 7.3 | Only if a required artifact is missing | Step 6 final quality gate or Step 7.3 |+| Export succeeds but the user wants browser edits re-exported | No | Rerun Step 7.2 and 7.3 after the edits | No | Post-export live-preview handling |---@@ -49,50 +48,41 @@ Global stop/continue rules for all three top-level routes, plus concrete failure| Condition | Action ||---|---|-| Required gate artifact missing | Stop at that gate and name the missing artifact. |-| Optional stage not explicitly requested | Do not run it as recovery. |-| Convenience UI/server failure | Fall back to chat or continue without the surface. |-| Derived artifact stale | Regenerate it from its owning source. |-| Required manual artifact missing | Pause and name the exact required artifacts; resume only after they exist. |-| Validation or export failure | Fix the owning source artifact, then rerun the failed operation and affected downstream operations only. |-| Confirmed execution choice cannot be honored | Keep the confirmed requirement visible. Retry the confirmed provider, mode, voice, effect, or path only as its owning workflow allows; if it remains unavailable, stop, request a new decision, or use the owning workflow's declared recovery. Quick's AI-generation exception is an explicit no-AI replan that preserves the communication job; it never substitutes another image source. |+| Required gate artifact missing | Stop at that gate and name it |+| Optional stage not explicitly requested | Do not run it as recovery |+| Convenience UI/server failure | Fall back to chat or continue without the surface |+| Derived artifact stale | Regenerate from its owning source |+| Required manual artifact missing | Pause and name the exact artifacts; resume only after they exist |+| Validation or export failure | Fix the owning source artifact, then rerun only the failed and affected downstream operations |+| Confirmed execution choice cannot be honored | Keep the confirmed requirement visible; retry the confirmed provider, mode, voice, effect, or path only as its owning workflow allows; if still unavailable, stop, request a new decision, or use the owning workflow's declared recovery. Quick's AI-generation exception is an explicit no-AI replan that preserves the communication job and never substitutes another image source |-**Missing values**: For a field in an existing artifact, follow only the exact requiredness, inference procedure, or fixed default declared by its owning schema or workflow; an active omission with no such rule stops at the owning boundary. Empty values, inactive conditional fields, whole artifacts, derived artifacts, and file-format attributes keep their own declared semantics—do not extend a fallback by analogy. Owning rules label their fallbacks with two terms used across this repository: a **declared-inference / declared-procedure fallback** states its missing condition and a bounded procedure that needs no new user decision; a **fixed compatibility default** states the exact fallback value, applied with one warning.+**Missing values**: for a field in an existing artifact, follow only the requiredness, inference procedure, or fixed default declared by its owning schema or workflow; an active omission with no such rule stops at the owning boundary. Do not extend a fallback by analogy to empty values, inactive conditional fields, whole or derived artifacts, or file-format attributes. Two fallback terms are used across the repository: a **declared-inference / declared-procedure fallback** states its missing condition and a bounded procedure needing no new user decision; a **fixed compatibility default** states the exact value, applied with one warning.-**Forbidden — silent downgrade**: Do not skip a required gate because a downstream command might tolerate the missing file, and do not change a confirmed execution value merely to keep the route moving. Fix, pause, request a new decision, or apply an explicit profile-owned recovery at the owning boundary; Quick's documented AI-to-no-AI replan is the narrow exception.+**Forbidden — silent downgrade**: never skip a required gate because a downstream command might tolerate the missing file, and never change a confirmed execution value to keep the route moving. Fix, pause, request a new decision, or apply an explicit profile-owned recovery at the owning boundary.-**Proactive production resolution**: Keep final Stage-2 raw fields as evidence.-Resolve durable outcomes as explicit instruction → final Stage 2 → workflow defaults-`enabled` / `disabled` / `disabled`. Audio raises Notes only when Notes is not-explicitly disabled; an explicit notes-off/audio-on conflict stops at-Generate's one-question dependency gate. Keep raw values unchanged and record-outcomes/provenance only in Design Spec §I, never the lock.+**Proactive production resolution**: keep final Stage-2 raw fields as evidence; resolve durable outcomes as explicit instruction → final Stage 2 → workflow defaults `enabled` / `disabled` / `disabled`. Audio raises Notes only when Notes is not explicitly disabled; an explicit notes-off/audio-on conflict stops at Generate's one-question dependency gate. Record outcomes/provenance only in Design Spec §I, never the lock.---## 3. Generate PPTX Resume Pointers-Here, **final confirmation evidence** means either the explicit final confirmation in the current chat or `<project>/confirm_ui/result.json` with `status: confirmed` and `stage: final`. Planning artifacts alone do not prove that the user confirmed their values. After that gate, a newer explicit user instruction may update only its effective production outcome and provenance in the durable Design Spec; resume from the owning step without reopening Confirm UI.--The UI wait resume entries below apply only while UI remains the selected-surface. A newer explicit chat-surface instruction follows `confirm_ui.md`'s-in-run switch and resumes the unresolved stage in chat without relaunching UI.+**Final confirmation evidence** means the explicit final confirmation in the current chat or `<project>/confirm_ui/result.json` with `status: confirmed` and `stage: final`; planning artifacts alone prove nothing. After that gate, a newer explicit instruction updates only its effective production outcome and provenance in the Design Spec; resume from the owning step without reopening Confirm UI. UI wait entries apply only while UI remains the selected surface; a newer chat-surface instruction follows the in-run switch and resumes in chat.| Last good state | Resume from ||---|---|-| Stage 1 confirmation exists, final Stage 2 is missing or unconfirmed, and UI remains selected | Derive a fresh `recommendations.stage2.json` from confirmed Stage 1 and current inputs without changing Stage 1, then run `confirm_ui/server.py <project> --wait-only` for final confirmation. |-| Final confirmation evidence exists; `design_spec.md` is missing, with or without a surviving `spec_lock.md` | Return to Generate Step 4 and [`strategist.md`](../../references/strategist.md) §6.2; read final evidence once into the fresh context, read [`design_spec_reference.md`](../../templates/design_spec_reference.md), author the complete `design_spec.md` from scratch using that state plus source analysis, and pass Gate 1. Then read [`spec_lock_reference.md`](../../templates/spec_lock_reference.md) and re-author the complete `spec_lock.md` from the audited Design Spec plus current context, replacing any orphan lock. Never reconstruct the Design Spec from an orphan lock or retain orphan-lock choices as authority. |-| Final confirmation evidence exists; `design_spec.md` exists and `spec_lock.md` missing | Return to Generate Step 4; in this fresh recovery context read final evidence once to audit the existing Design Spec, then read [`spec_lock_reference.md`](../../templates/spec_lock_reference.md) and author the complete lock from the audited Design Spec plus current context. |-| Final confirmation evidence and both planning artifacts exist, but Gate 1 fails | In a fresh recovery context read final evidence once, repair `design_spec.md`, then re-author every affected lock row. Do not reopen recommendations or infer a replacement from the current lock. |-| Gate 1 passes but Gate 2 fails | Keep the Design Spec unchanged and re-author only the mismatched lock anchors/routing rows from it plus current context. |-| No final confirmation evidence is available | If `confirm_ui/result.json` proves Stage 1 confirmation, resume at final Stage 2; otherwise restart Step 4 at Stage 1. Do not infer confirmed choices from partial planning artifacts. |-| `design_spec.md` and `spec_lock.md` complete, split mode selected | [`resume-execute`](../stages/resume-execute.md) |-| Images acquired but SVGs not started | [`generate-pptx`](../generate-pptx.md) Step 6 |-| SVGs complete and checker passed; effective Speaker Notes outcome enabled and notes missing | Step 6 Logic Construction |-| SVGs complete; effective Speaker Notes outcome disabled | Run any applicable conditional motion handling, then Step 7.2 and export with `--no-notes` |-| SVGs and enabled notes complete | Step 7.1 |-| Step 7.1 complete, export not complete | Step 7.2 |-| Step 7.2 complete, PPTX not complete | Step 7.3 |+| Stage 1 confirmed, final Stage 2 missing or unconfirmed, UI selected | Derive a fresh `recommendations.stage2.json` from confirmed Stage 1 and current inputs, then `confirm_ui/server.py <project> --wait-only` |+| Final evidence exists; `design_spec.md` missing (with or without a surviving lock) | Step 4 and [`strategist.md`](../../references/strategist.md) §6.2: read final evidence once, read [`design_spec_reference.md`](../../templates/design_spec_reference.md), author the complete Design Spec from scratch, pass Gate 1; then read [`spec_lock_reference.md`](../../templates/spec_lock_reference.md) and re-author the complete lock, replacing any orphan. Never reconstruct the Design Spec from an orphan lock |+| Final evidence exists; Design Spec exists, lock missing | Step 4: read final evidence once to audit the Design Spec, then author the complete lock from it plus context |+| Both planning artifacts exist but Gate 1 fails | Read final evidence once, repair `design_spec.md`, re-author every affected lock row; do not reopen recommendations or infer from the lock |+| Gate 1 passes, Gate 2 fails | Keep the Design Spec; re-author only the mismatched lock rows |+| No final evidence | If `result.json` proves Stage 1, resume at final Stage 2; otherwise restart Step 4 at Stage 1. Never infer confirmed choices from partial artifacts |+| Both planning artifacts complete, split mode selected | [`resume-execute`](../stages/resume-execute.md) |+| Images acquired, SVGs not started | [`generate-pptx`](../generate-pptx.md) Step 6 |+| SVGs complete and checker passed; Speaker Notes enabled, notes missing | Step 6 Logic Construction |+| SVGs complete; Speaker Notes disabled | Conditional motion handling, then Step 7.2 and export with `--no-notes` |+| SVGs and notes complete | Step 7.1 |+| Step 7.1 complete | Step 7.2 |+| Step 7.2 complete, PPTX missing | Step 7.3 || Browser annotations saved after export | [`live-preview`](../stages/live-preview.md) Step 2 |-**Default - resume at the owning failed step**: Do not restart the planning session or regenerate prior artifacts unless the owning source has changed.+**Default — resume at the owning failed step**: do not restart planning or regenerate prior artifacts unless the owning source changed.diff --git a/skills/ppt-master/workflows/routing.md b/skills/ppt-master/workflows/routing.mdindex a6622c6e..5964dff7 100644--- a/skills/ppt-master/workflows/routing.md+++ b/skills/ppt-master/workflows/routing.md@@ -6,9 +6,7 @@ description: Deterministic selection among PPT Master's three top-level artifactRoute selection authority for PPT Master. Select exactly one top-level route, then activate only the child workflows, profiles, and stages owned by that route.-**Hard rule**: If this file conflicts with a route summary elsewhere in the-Skill package or in a repository-level user-facing document, this file wins for-route selection. After selection, the active runtime authority owns execution.+**Hard rule**: when this file conflicts with a route summary elsewhere in the Skill package or a repository-level document, this file wins for route selection. After selection, the active runtime authority owns execution.---@@ -17,12 +15,12 @@ route selection. After selection, the active runtime authority owns execution.| Rule | Behavior ||---|---|| One artifact lifecycle | Every request enters Generate PPTX, Create Template, or Edit Native PPTX |-| Supporting documents are not top-level routes | Create Template child workflows, generation profiles, stages, and governance documents refine the selected route; never offer them as competing top-level routes |-| Missing prerequisite | State the missing prerequisite and stop that route; do not invent an alternative |+| Supporting documents are not routes | Create Template child workflows, generation profiles, stages, and governance documents refine the selected route; never offer them as competing routes |+| Missing prerequisite | State it and stop that route; do not invent an alternative || Ambiguous existing-deck request | Ask one discriminator question only when needed: regenerate the visible design (Generate), or preserve the native deck and edit it (Edit Native PPTX)? || Explicit user override | Honor explicit route instructions only when the route preconditions are satisfied |-**Forbidden — route-choice menus**: Do not present multiple implementation paths when the request already matches one row in §2. Ordinary design choices remain at the selected route's existing confirmation gate.+**Forbidden — route-choice menus**: do not present multiple implementation paths when the request already matches one row in §2; ordinary design choices remain at the selected route's confirmation gate.---@@ -30,9 +28,9 @@ route selection. After selection, the active runtime authority owns execution.| Route | Request shape | Authority | Preconditions | Mutation model | Output contract ||---|---|---|---|---|---|-| Generate PPTX | Create, reconstruct, or visually regenerate a presentation/video from sources or a topic; templates remain optional | Image to PPTX: [`image-to-pptx`](./profiles/image-to-pptx.md), always Quick; Beautify: [`beautify-pptx`](./profiles/beautify-pptx.md), Default or Quick; ordinary [`generate-pptx`](./generate-pptx.md) / [`quick-generate`](./profiles/quick-generate.md) | Facts exist or research can gather them; Image to PPTX also requires Codex and an ordered page-frame roster | Author SVG pages and export a new PPTX | Default: spec/lock/SVG/PPTX; Quick: optional source/resource artifacts, no spec/lock, SVG/PPTX; either may derive narrated PPTX/MP4 |-| Create Template | Create a reusable brand/style/layout/deck template from one or more PPTX/SVG files, images/PDFs, direct or file-based text, documents/websites, brand assets, or a mixed reference bundle | [`create-template`](./create-template.md) | A reusable-template request exists; reference material is optional, and project scope additionally requires an initialized target project | Author a new portable workspace; never modify any reference file in place | Workspace with required `templates/`, optional `images/` / `icons/`, and optional review `exports/` |-| Edit Native PPTX | Keep an existing PPTX's native design: fill it with new content, edit or restructure selected pages, or add notes, narration, timings, or transitions with visible slides untouched | [`edit-native-pptx`](./edit-native-pptx.md) | Source PPTX exists; new material only when content changes | `pptx_to_svg.py --roundtrip` workspace: unchanged pages restore byte-for-byte, edited pages rebuild only edited objects, notes/motion overlay | New PPTX in workspace `exports/` |+| Generate PPTX | Create, reconstruct, or visually regenerate a presentation/video from sources or a topic; templates optional | Image to PPTX: [`image-to-pptx`](./profiles/image-to-pptx.md), always Quick; Beautify: [`beautify-pptx`](./profiles/beautify-pptx.md), Default or Quick; ordinary [`generate-pptx`](./generate-pptx.md) / [`quick-generate`](./profiles/quick-generate.md) | Facts exist or research can gather them; Image to PPTX also requires Codex and an ordered page-frame roster | Author SVG pages and export a new PPTX | Default: spec/lock/SVG/PPTX; Quick: optional source/resource artifacts, no spec/lock, SVG/PPTX; either may derive narrated PPTX/MP4 |+| Create Template | Create a reusable brand/style/layout/deck template from PPTX/SVG files, images/PDFs, direct or file-based text, documents/websites, brand assets, or a mixed bundle | [`create-template`](./create-template.md) | A reusable-template request; reference material optional; project scope also requires an initialized target project | Author a new portable workspace; never modify a reference file in place | Workspace with required `templates/`, optional `images/` / `icons/`, optional review `exports/` |+| Edit Native PPTX | Keep an existing PPTX's native design: fill with new content, edit or restructure selected pages, or add notes, narration, timings, or transitions with visible slides untouched | [`edit-native-pptx`](./edit-native-pptx.md) | Source PPTX exists; new material only when content changes | `pptx_to_svg.py --roundtrip` workspace: unchanged pages restore byte-for-byte, edited pages rebuild only edited objects, notes/motion overlay | New PPTX in workspace `exports/` |---@@ -40,46 +38,28 @@ route selection. After selection, the active runtime authority owns execution.| Request condition | Generate-route behavior ||---|---|-| One or more raster files represent page frames that must be reconstructed into a layered editable PPTX | Activate the Codex-supported [`image-to-pptx`](./profiles/image-to-pptx.md); normalize the represented frame roster and activate `quick-generate` directly without requiring a separate Quick request |-| Existing PPTX must preserve wording, page count, and page order 1:1 | Activate [`beautify-pptx`](./profiles/beautify-pptx.md); it selects `quick-generate` when that profile's explicit trigger also matches, otherwise `generate-pptx` |-| The effective delivery purpose is recorded, self-running, or video-directed | Inside the already selected Default or explicit Quick runtime, load [`video-design`](../references/video-design.md) before whole-solution/page planning. This is a conditional design reference, not a profile or fifth route; notes, animation, audio, and optional native MP4 remain owned by their existing stages |-| Explicit quick/fast, skip-strategy, or direct SVG-to-PPTX intent without an active fidelity profile | Load [`quick-generate`](./profiles/quick-generate.md) directly without loading `generate-pptx.md`: prepare sources/resources as needed, let the current agent decide without interaction, directly apply at most one exact workspace root per kind supplied for this run, otherwise use free design, omit Strategist/Confirm UI/spec/lock, hand-author SVG, run the lockless final checker, and export the final PPTX |-| Topic only, or supplied sources leave planning-critical factual gaps | Run [`topic-research`](./stages/topic-research.md) inside the selected Generate profile's source preparation: immediately for topic-only input, or after conversion and reading for source-backed input; research only the identified gaps |-| Existing PPTX must be split, merged, or re-outlined into newly designed pages | Treat the PPTX as source content through the selected Generate authority's source intake; continue Default unless explicit Quick intent selected that runtime |-| Existing PPTX pages are dropped, reordered, or repeated without redesign | Not Generate: route to Edit Native PPTX, whose `page_plan.json` owns selection, order, and repetition |-| Default Generate reaches planning | Step 3 prepares template candidates without interaction. Stage 1 then confirms the communication contract and free-design/template choice together; only a confirmed non-free choice runs [`apply-template-workspace`](./stages/apply-template-workspace.md) before Stage 2 |-| Explicit current brand/style/layout/deck workspace root outside Image to PPTX | Default Generate preserves the exact path as a Stage-1 template candidate; Quick Generate validates and installs it directly without Steps 3–4 or Confirm UI. Classify it as `library` only when its normalized root exactly matches a registered index entry; otherwise retain `explicit`. Consume the workspace root, never only its inner `templates/` directory |+| Raster files represent page frames to reconstruct into a layered editable PPTX | Activate the Codex-supported [`image-to-pptx`](./profiles/image-to-pptx.md); normalize the frame roster and activate `quick-generate` directly |+| Existing PPTX must preserve wording, page count, and order 1:1 | Activate [`beautify-pptx`](./profiles/beautify-pptx.md); Quick when that profile's explicit trigger also matches, otherwise `generate-pptx` |+| Effective delivery purpose is recorded, self-running, or video-directed | Inside the selected runtime, load [`video-design`](../references/video-design.md) before whole-solution/page planning; a design reference, not a profile — notes, animation, audio, and native MP4 stay with their stages |+| Explicit quick/fast, skip-strategy, or direct SVG-to-PPTX intent without an active fidelity profile | Load [`quick-generate`](./profiles/quick-generate.md) directly without `generate-pptx.md`: prepare sources/resources as needed, decide without interaction, apply at most one exact workspace root per kind supplied for this run (otherwise free design), omit Strategist/Confirm UI/spec/lock, hand-author SVG, run the lockless final checker, export |+| Topic only, or sources leave planning-critical factual gaps | Run [`topic-research`](./stages/topic-research.md) inside the selected profile's source preparation — immediately for topic-only input, after conversion and reading for source-backed input; research only the identified gaps |+| Existing PPTX must be split, merged, or re-outlined into newly designed pages | Treat the PPTX as source content through the selected Generate authority's intake; Default unless explicit Quick intent |+| Existing PPTX pages dropped, reordered, or repeated without redesign | Not Generate: Edit Native PPTX, whose `page_plan.json` owns selection, order, and repetition |+| Default Generate reaches planning | Step 3 prepares template candidates without interaction; Stage 1 confirms the communication contract and free-design/template choice together; only a confirmed non-free choice runs [`apply-template-workspace`](./stages/apply-template-workspace.md) before Stage 2 |+| Explicit current brand/style/layout/deck workspace root outside Image to PPTX | Default preserves the exact path as a Stage-1 candidate; Quick validates and installs it directly without Steps 3–4 or Confirm UI. Classify as `library` only when the normalized root exactly matches a registered index entry, otherwise `explicit`. Consume the workspace root, never only its inner `templates/` || Split-mode project resumes in a fresh chat | Run [`resume-execute`](./stages/resume-execute.md) inside the active Generate route |-| Existing generated project needs a deck-wide `colors.*` or universal `typography.font_family` substitution | Stay in Generate; load [`update_spec.py`](../scripts/docs/update_spec.md), honor its supported-key boundary, then rerun the final quality gate and Step 7 export |+| Generated project needs a deck-wide `colors.*` or universal `typography.font_family` substitution | Stay in Generate; load [`update_spec.py`](../scripts/docs/update_spec.md), honor its supported-key boundary, then rerun the final quality gate and Step 7 export || User explicitly requests spec refinement | Run [`refine-spec`](./stages/refine-spec.md) after Design Spec Gate 1 and before lock Gate 2 || Data charts exist | Run [`verify-charts`](./stages/verify-charts.md) before export || User explicitly requests visual review | Run [`visual-review`](./stages/visual-review.md) before post-processing |-| User requests preview, selection, or annotation application outside Image to PPTX | Use the default Generate pipeline and run [`live-preview`](./stages/live-preview.md) at the stage defined there; explicit Quick + preview intent falls back to default rather than dropping preview. Image to PPTX remains Quick-only and uses its mandatory canonical-frame recomposition comparison instead of this interactive stage |-| User requests page transitions, auto-advance, or deck-wide animation settings without page-specific motion planning or an existing `animations.json` | Load [`animations`](../references/animations.md) and apply its export-level contract |-| `<project_path>/animations.json` already exists, the user explicitly requests per-slide/object-level animation control, or the effective Custom Animations outcome in `design_spec.md §I` is enabled | Run [`customize-animations`](./stages/customize-animations.md) after the final SVG quality gate and any enabled speaker-note pass, before Generate Step 7. A §IX `Motion suggestion` informs an active pass but never triggers it alone |-| Generate PPTX receives an explicit narration request or has effective Narration Audio enabled in `design_spec.md §I`; Edit Native PPTX has narration confirmed in its plan | Run [`generate-audio`](./stages/generate-audio.md) after the owning route's notes readiness; audio implies notes on every output page |--**Hard rule — fidelity profiles, not fifth routes**: Image to PPTX and Beautify-change different source/page invariants and are mutually exclusive. Image to-PPTX always activates Quick; Beautify uses Quick only on explicit Quick intent-and otherwise uses Default. Neither defines a separate artifact lifecycle or-loads both runtimes.--**Hard rule — direct-generation profile, not a fifth route**: `quick-generate`-stays inside Generate PPTX but owns an explicit SVG → PPTX short circuit. Page-count alone never activates or blocks it. Conversion, bounded research, and-project-local resources remain available. Package capabilities may be requested-or agent-selected. Quick may consume exact Brand/Style/Layout/Deck workspaces,-with at most one contribution per kind. All four kinds may combine; Layout takes-structural precedence over Deck. A multi-kind project root contributes all of-its specs atomically. Brand/Style-only and free-design Quick pages remain flat;-when Layout or Deck owns structure, Quick authors the complete explicit-Master/Layout/slot metadata and its lockless checker/exporter infers structured-output from that all-page SVG contract. Runtime choice controls interaction and-durable planning, not whether an installed structural template survives. Once selected, Quick-is the complete runtime procedure and never loads `generate-pptx.md`; Default-never loads `quick-generate.md`. Image to PPTX is the narrow profile-owned-Quick activation; Beautify may select either runtime, but never both.+| User requests preview, selection, or annotation application outside Image to PPTX | Default pipeline plus [`live-preview`](./stages/live-preview.md) at its defined stage; explicit Quick + preview intent falls back to Default rather than dropping preview. Image to PPTX stays Quick-only with its canonical-frame recomposition comparison |+| Page transitions, auto-advance, or deck-wide animation settings without page-specific motion planning or an existing `animations.json` | Load [`animations`](../references/animations.md) and apply its export-level contract |+| `<project_path>/animations.json` exists, the user explicitly requests per-slide/object-level animation control, or the effective Custom Animations outcome in `design_spec.md §I` is enabled | Run [`customize-animations`](./stages/customize-animations.md) after the final SVG quality gate and any speaker-note pass, before Step 7. A §IX `Motion suggestion` informs an active pass but never triggers it |+| Explicit narration request or effective Narration Audio enabled in `design_spec.md §I`; Edit Native PPTX narration confirmed in its plan | Run [`generate-audio`](./stages/generate-audio.md) after the owning route's notes readiness; audio implies notes on every output page |++**Hard rule — fidelity profiles, not fifth routes**: Image to PPTX and Beautify change different source/page invariants and are mutually exclusive. Image to PPTX always activates Quick; Beautify uses Quick only on explicit Quick intent. Neither defines a separate lifecycle or loads both runtimes.++**Hard rule — direct-generation profile, not a fifth route**: `quick-generate` stays inside Generate PPTX and owns an explicit SVG → PPTX short circuit; page count alone never activates or blocks it. Conversion, bounded research, project-local resources, and package capabilities remain available. Quick may consume exact Brand/Style/Layout/Deck workspaces, at most one contribution per kind; all four may combine, Layout takes structural precedence over Deck, and a multi-kind root contributes all its specs atomically. Brand/Style-only and free-design Quick pages stay flat; when Layout or Deck owns structure, Quick authors the complete explicit Master/Layout/slot metadata and its lockless checker/exporter infers structured output from the all-page SVG contract. Once selected, Quick is the complete runtime and never loads `generate-pptx.md`; Default never loads `quick-generate.md`.---@@ -89,11 +69,11 @@ Quick activation; Beautify may select either runtime, but never both.| Input | Route behavior ||---|---|-| One or more images containing page frames + explicit final-deck reconstruction intent | Generate PPTX with the Codex-supported, Quick-only [`image-to-pptx`](./profiles/image-to-pptx.md); normalize page frames first and do not infer reusable native structure from pixels |+| Images containing page frames + explicit final-deck reconstruction intent | Generate PPTX with Quick-only [`image-to-pptx`](./profiles/image-to-pptx.md); normalize frames first, never infer reusable native structure from pixels || Raw PPTX called a template + new content | Edit Native PPTX unless the user explicitly asks for a reusable template workspace || Any supported reference bundle or direct-text brief + reusable template request | Create Template |-| Current template workspace root + content | Default: [`generate-pptx`](./generate-pptx.md) Stage-1 template choice; explicit Quick: direct validated workspace application |-| Semantic-legacy or incomplete structured package | Create a new workspace through Create Template; do not migrate in place |+| Current template workspace root + content | Default: [`generate-pptx`](./generate-pptx.md) Stage-1 template choice; explicit Quick: direct validated application |+| Semantic-legacy or incomplete structured package | New workspace through Create Template; never migrate in place || Request to add a master directly to an existing PPTX/SVG | Unsupported; explain the Create Template → Generate PPTX lifecycle |---@@ -102,31 +82,20 @@ Quick activation; Beautify may select either runtime, but never both.| Selected kind | Behavior ||---|---|-| `brand` | Dispatch to [`create-brand`](./create-template/create-brand.md); write identity only and no SVG roster |-| `style` | Dispatch to [`create-style`](./create-template/create-style.md); write reusable communication method and design direction only, with no SVG roster or native structure |-| `layout` | Dispatch to [`create-layout`](./create-template/create-layout.md); author brand-neutral, application-neutral structure and an SVG roster |-| `deck` | Dispatch to [`create-deck`](./create-template/create-deck.md); author descriptive recurring-application context with integrated identity, structure, and an SVG roster |+| `brand` | [`create-brand`](./create-template/create-brand.md): identity only, no SVG roster |+| `style` | [`create-style`](./create-template/create-style.md): reusable communication method and design direction only, no roster or native structure |+| `layout` | [`create-layout`](./create-template/create-layout.md): brand-neutral, application-neutral structure plus an SVG roster |+| `deck` | [`create-deck`](./create-template/create-deck.md): descriptive recurring-application context with integrated identity, structure, and an SVG roster |-Create Template remains the fixed route name and owns the shared contract. These four documents are mutually exclusive child workflows, not additional top-level routes.+Create Template remains the fixed route name and owns the shared contract; these four are mutually exclusive child workflows.-**Hard rule — classify reusable rules, not source completeness**: A complete-PPTX does not automatically select Deck. Use Brand when only identity is-stable; use Style when reusable communication method and design direction-should travel without identity truth, page prototypes, or native-structure; use Layout when structure is brand-neutral and the communication-application stays downstream-defined; use Deck when structure carries identity-or reusable scenario/content semantics.+**Hard rule — classify reusable rules, not source completeness**: a complete PPTX does not automatically select Deck. Brand when only identity is stable; Style when communication method and design direction should travel without identity truth, prototypes, or native structure; Layout when structure is brand-neutral and the application stays downstream-defined; Deck when structure carries identity or reusable scenario/content semantics.---## 6. Native and Shared Post-Processing Boundary-| Artifact state | Narration route |-|---|---|-| Main-generated project with notes and exported deck | Shared [`generate-audio`](./stages/generate-audio.md) stage |-| Arbitrary finished PPTX that must preserve visible slides | Edit Native PPTX; its narration module invokes the same shared audio-stage rules against the round-trip workspace |--Object animation for generated SVG projects uses the animation stage. Edit Native PPTX preserves source motion by default and writes requested motion as an overlay per [`animations.md`](../references/animations.md).+A main-generated project with notes and an exported deck narrates through the shared [`generate-audio`](./stages/generate-audio.md) stage; an arbitrary finished PPTX whose visible slides must be preserved goes to Edit Native PPTX, whose narration module invokes the same stage rules against the round-trip workspace. Object animation for generated SVG projects uses the animation stage; Edit Native PPTX preserves source motion by default and writes requested motion as an overlay per [`animations.md`](../references/animations.md).---@@ -134,21 +103,13 @@ Object animation for generated SVG projects uses the animation stage. Edit Nativ| User input | Behavior ||---|---|-| Default Generate | Step 3 prepares candidates only; Stage 1 confirms one communication contract plus either free design or template use in the same interaction |-| Explicit current workspace root exposing at least one `templates/` Design Spec | Preserve it as a Stage-1 candidate and initialize template mode; preselect that specific candidate only when it is the sole supplied root. An exact registered-root match may be displayed as `library` |-| No exact workspace root and no explicit template intent | Initialize Stage 1 to free design; the user may switch to template mode and select an indexed workspace |-| Explicit template intent or any exact workspace root | Initialize Stage 1 to template mode; exactly one root may be preselected, while multiple roots remain unselected candidates |-| Bare template/brand name or style label without an explicit template-use request | Do not resolve it to a local path or preselect a template; treat it as a style brief. An explicit request to use templates still initializes template mode, but leaves the specific candidate for the user to choose |-| “What templates exist?” in chat | List indexed workspace paths; Stage 1 still requires an explicit free-design/template choice |--The default UI and chat discovery read only these indexes. Never scan the-corresponding directories to construct or supplement the catalog:+| Default Generate | Step 3 prepares candidates only; Stage 1 confirms one communication contract plus free design or template use in one interaction |+| Explicit current workspace root exposing at least one `templates/` Design Spec | Preserve it as a Stage-1 candidate and initialize template mode; preselect it only when it is the sole supplied root; an exact registered-root match may display as `library` |+| No exact root and no explicit template intent | Initialize Stage 1 to free design; the user may switch to template mode and pick an indexed workspace |+| Explicit template intent or any exact root | Initialize Stage 1 to template mode; exactly one root may be preselected, others remain unselected candidates |+| Bare template/brand name or style label without an explicit template-use request | Never resolve to a local path or preselect; treat as a style brief. An explicit request to use templates initializes template mode but leaves the candidate to the user |+| "What templates exist?" in chat | List indexed workspace paths; Stage 1 still requires an explicit free-design/template choice |-| Kind | Discovery index |-|---|---|-| Brand | [`brands_index.json`](../templates/brands/brands_index.json) |-| Style | [`styles_index.json`](../templates/styles/styles_index.json) |-| Layout | [`layouts_index.json`](../templates/layouts/layouts_index.json) |-| Deck | [`decks_index.json`](../templates/decks/decks_index.json) |+Discovery reads only [`brands_index.json`](../templates/brands/brands_index.json), [`styles_index.json`](../templates/styles/styles_index.json), [`layouts_index.json`](../templates/layouts/layouts_index.json), and [`decks_index.json`](../templates/decks/decks_index.json); never scan kind directories to construct or supplement the catalog.-**Hard rule — index-derived roots only**: never resolve a bare name to a local template directory on the user's behalf; a library choice comes from an index-derived root, and an unregistered workspace requires an explicit root (including the exact workspace handed off by Create Template in the current conversation). Stage-1 ordering and delayed template reading are owned by [`generate-pptx`](./generate-pptx.md) Steps 3–4.+**Hard rule — index-derived roots only**: never resolve a bare name to a local template directory on the user's behalf; a library choice comes from an index-derived root, and an unregistered workspace requires an explicit root (including one handed off by Create Template in the current conversation). Stage-1 ordering and delayed template reading are owned by [`generate-pptx`](./generate-pptx.md) Steps 3–4.diff --git a/skills/ppt-master/workflows/stages/refine-spec.md b/skills/ppt-master/workflows/stages/refine-spec.mdindex a6c92c69..4c6395af 100644--- a/skills/ppt-master/workflows/stages/refine-spec.md+++ b/skills/ppt-master/workflows/stages/refine-spec.md@@ -4,59 +4,36 @@ description: Optional main-pipeline stage for reviewing and revising the complet# Refine Spec Stage-> **Opt-in Generate-PPTX stage**. Default writes `design_spec.md` + `spec_lock.md` and proceeds. With explicit refinement, produce and audit the complete Design Spec, then **stop before the lock** for unrestricted user review/revision.+> **Opt-in Generate-PPTX stage.** Default writes `design_spec.md` + `spec_lock.md` and proceeds. With explicit refinement, produce and audit the complete Design Spec, then **stop before the lock** for unrestricted user review.-This stage is **conditional**, same shape as the split-mode choice: it never fires on its own and the default path is unchanged. The Strategist confirmation stage settles design directions up front as abstract recommendations; this pass lets the user revise the **concrete spec** the Strategist produced from them. It is most valuable for a zero-background user, who can judge a finished spec far better than the up-front recommendations — and the spec's content outline (`§IX`) is usually what they most want to adjust.+The confirmation stage settles design directions as abstract recommendations; this pass lets the user revise the concrete spec produced from them — most valuable for a zero-background user, who judges a finished spec far better than up-front recommendations, and usually wants to adjust the content outline (§IX).## When to Run-The user **explicitly asks** to refine / review / revise the spec before generation. Recognize any of:--| Pattern | Example |-|---|---|-| "refine the spec / review the spec first" | "produce the spec first, let me review before slides" |-| "let me revise the spec, then continue" | "send me the spec to confirm, I'll edit it" |-| Any request to inspect/iterate the design spec before generation | "draft the full plan, I want to adjust it, then generate" |--**Default is OFF.** Strategist surfaces this option as one short opt-in line inside the Strategist confirmation stage (see [`generate-pptx`](../generate-pptx.md) Step 4). No request → the spec is written in one go and the pipeline auto-proceeds as usual; this stage never starts.--**Prerequisite**: the Strategist confirmation stage is settled (mode + visual style + the rest). This pass revises the spec produced from that stage; it does not re-open the confirmation stage itself.+Only when the user explicitly asks to refine / review / revise the spec before generation ("produce the spec first, let me review", "send me the spec to confirm, I'll edit it", "draft the full plan, I want to adjust it, then generate"). **Default is OFF**: Strategist surfaces it as one short opt-in line inside the confirmation stage ([`generate-pptx`](../generate-pptx.md) Step 4); without a request the spec is written in one go. **Prerequisite**: the confirmation stage is settled; this pass never reopens it.---## Step 1: Produce the complete Design Spec-Run [`generate-pptx`](../generate-pptx.md) Step 4 through the complete `design_spec.md` (§I–X) and initial Gate 1 audit. Read relevant `sources/` so §IX carries facts, not skeleton points.+Run [`generate-pptx`](../generate-pptx.md) Step 4 through the complete `design_spec.md` (§I–X) and the initial Gate 1 audit, reading relevant `sources/` so §IX carries facts, not skeleton points.-**Hard rule — no lock before approval**: Do not create, update, use, or validate `spec_lock.md` during review. On a resumed project, any prior lock is stale derived state until Gate 2 resynchronizes it after approval.+**Hard rule — no lock before approval**: do not create, update, use, or validate `spec_lock.md` during review; on a resumed project a prior lock is stale derived state until Gate 2 resynchronizes it after approval.---## Step 2: ⛔ HARD STOP — present, discuss, and revise-Present the Design Spec and **wait for explicit revision or approval before anything else**. Review the one project `design_spec.md` in chat; do not create a second draft, parallel summary, or fixed-field questionnaire.--The user may revise **any part of the spec** and request any number of changes per round. Discuss in **prose**; do not emit scores or force field-by-field confirmation. Let the user drive.--**Reference — review lenses, not a checklist or score**: raise these in plain language to surface what is worth discussing. They name a *direction*, never a number — never convert any into HEX values, px sizes, ratios, page quotas, or grades.--- *Outline*: logical clarity (do the points build on each other), information density (right amount per page — nothing padded or crammed), focus (each page lands one idea), register (spoken vs formal, matched to the audience), emotional resonance (a hook to open, a payoff to close), chapter balance (page budget not lopsided).-- *Color*: does the scheme fit the content's mood and audience, and is there enough hierarchy and contrast to read comfortably — not which exact HEX.-- *Typography*: do title and body form a clear contrast or a clean concord, is the size hierarchy legible, does the type character match the visual style — not which px.-- *Layout*: does structure follow each page's information weight, or does it fall back to one uniform symmetric grid (the "AI-generated" look).-- *Icon / image*: one consistent icon character throughout; images that serve the content (hero / atmosphere used on purpose) rather than decorate.-- *Page rhythm*: do `anchor` / `dense` / `breathing` track the narrative, or is everything flatly dense.--These overlap with what the confirmed `mode`, visual style, and §6.1 already shape — treat them as discussion angles to surface what is worth talking about, not permission for the Strategist to redo a decision without the user's explicit revision.+Present the one project `design_spec.md` in chat and wait for explicit revision or approval — no second draft, parallel summary, fixed-field questionnaire, scores, or field-by-field confirmation. The user may revise any part, any number of rounds; discuss in prose and let the user drive.-**Revise one Design Spec only**: Apply each user-requested round incrementally to `design_spec.md`; affected decisions supersede earlier values, while unaffected confirmed decisions and cross-section coherence remain intact. Do not regenerate the document for a local change or touch lock anchors. Iterate until explicit approval.+**Reference — review lenses, not a checklist**: raise these in plain language as directions, never numbers (no HEX, px, ratios, page quotas, or grades): outline — logical build, information density, one idea per page, register matched to the audience, hook and payoff, chapter balance; color — fit to mood and audience, enough hierarchy and contrast; typography — clear contrast or clean concord between title and body, legible size hierarchy, character matched to the visual style; layout — structure following each page's information weight rather than one uniform symmetric grid; icon/image — one consistent icon character, images that serve the content; page rhythm — `anchor` / `dense` / `breathing` tracking the narrative. They overlap what the confirmed `mode`, visual style, and §6.1 already shape; they are discussion angles, not permission to redo a decision without the user's explicit revision.-**Re-run the route/template preflight after reuse revisions.** For changed reuse/prototype decisions, repeat [`strategist-template.md`](../../references/strategist-template.md) preflight before approval. `style` later locks flat; `mirror` / `layout` require a complete structured contract. Update only human-facing Design Spec decisions during review; Gate 2 derives structure mappings. Legacy prototypes remain unselectable.+**Revise one Design Spec only**: apply each round incrementally; affected decisions supersede earlier values while unaffected confirmed decisions and cross-section coherence stay intact. Do not regenerate the document for a local change or touch lock anchors. After a changed reuse/prototype decision, repeat the [`strategist-template.md`](../../references/strategist-template.md) preflight before approval (`style` later locks flat; `mirror` / `layout` require a complete structured contract; Gate 2 derives structure mappings; legacy prototypes stay unselectable). Iterate until explicit approval.---## Step 3: Approve and author the lock-After explicit approval, return to [`generate-pptx`](../generate-pptx.md) Step 4 Gate 2. Author or resynchronize `spec_lock.md` once from the approved Design Spec plus current context, validate, then continue to Step 5 or Step 6. Do not reopen `result.json`.+After explicit approval, return to [`generate-pptx`](../generate-pptx.md) Step 4 Gate 2: author or resynchronize `spec_lock.md` once from the approved Design Spec plus current context, validate, then continue to Step 5 or Step 6. Do not reopen `result.json`.-> Note: this stage does NOT duplicate Strategist content. It inserts a review-and-revise checkpoint between Design Spec Gate 1 and lock Gate 2. [`strategist.md`](../../references/strategist.md) and [`generate-pptx`](../generate-pptx.md) remain authoritative for artifact content and route sequencing.+> This stage inserts a review-and-revise checkpoint between Gate 1 and Gate 2; [`strategist.md`](../../references/strategist.md) and [`generate-pptx`](../generate-pptx.md) remain authoritative for content and sequencing.diff --git a/skills/ppt-master/workflows/stages/resume-execute.md b/skills/ppt-master/workflows/stages/resume-execute.mdindex 47be82af..63a19749 100644--- a/skills/ppt-master/workflows/stages/resume-execute.md+++ b/skills/ppt-master/workflows/stages/resume-execute.md@@ -4,130 +4,52 @@ description: Main-pipeline control stage for resuming execution in a fresh chat# Resume Execute Stage-> Generate-PPTX control stage for a fresh execution session. Run when [`generate-pptx`](../generate-pptx.md) Step 1–5 completed in a previous chat and the user wants to continue with SVG generation + export. Loads project state from disk and runs Step 6 + Step 7 inside the already selected Generate route.+> Generate-PPTX control stage for a fresh execution session: [`generate-pptx`](../generate-pptx.md) Steps 1–5 completed in a previous chat and the user wants SVG generation + export. Loads project state from disk and runs Steps 6–7 inside the already selected Generate route.-This stage is **context-independent**: it owns the execution session starting from a fresh chat — no upstream conversation context required. Persisted project artifacts replace the planning session's confirmation dialogue and image-acquisition history.--`validation/workflow.log` is a cold command/outcome audit log with optional-important manual entries, not persisted planning state. Do not open or replay-it while resuming. Use the real artifacts in Step 1 to establish current state;-inspect the log only when the user explicitly asks to review the prior run. Run-inherited Python commands normally; their shared CLI bootstrap records a-bounded material outcome selection automatically, not the full console stream.+Context-independent: persisted project artifacts replace the planning session's confirmation dialogue and image-acquisition history. `validation/workflow.log` is a cold audit log, not planning state — never open or replay it while resuming; inspect it only when the user asks to review the prior run.## When to Run-The user opens a new chat and gives a phrase that names a project path and signals continuation. Recognize any of:--| Pattern | Example |-|---|---|-| "继续生成 projects/<project_name>" | "继续生成 projects/ppt169_joe_hisaishi" |-| "resume execution projects/<project_name>" | "resume execution projects/ppt169_joe_hisaishi" |-| Project path + any "继续 / 恢复 / 继续做 / 接着做" semantic | "把 projects/ppt169_joe_hisaishi 继续做完" |--**Prerequisite**: the planning session must have completed in the named project. Verified by file presence in Step 1; do NOT auto-trigger planning on missing state.+The user opens a new chat naming a project path with continuation intent — "继续生成 projects/<name>", "resume execution projects/<name>", or a project path plus any 继续 / 恢复 / 接着做 semantic. **Prerequisite**: planning completed in that project, verified by file presence in Step 1; never auto-trigger planning on missing state.---## Step 1: Sanity check-Verify the two root planning artifacts exist before loading their contents:--| File | Required when | Reason |-|---|---|---|-| `<project_path>/design_spec.md` | Always | Upstream approved design narrative and §IX page outline; its complete read occurs after the Executor role core loads |-| `<project_path>/spec_lock.md` | Always | Downstream execution anchors and routing contract; its complete read follows the Design Spec |--If either file is missing, report it and stop this stage. Recover through-[`failure-recovery.md`](../governance/failure-recovery.md) §3; do not enter Step-6, read an orphan lock as authority, or invent a replacement artifact.+`<project_path>/design_spec.md` (approved narrative and §IX outline) and `<project_path>/spec_lock.md` (execution anchors and routing contract) must both exist; their complete reads happen after the Executor role core loads. If either is missing, stop and recover through [`failure-recovery.md`](../governance/failure-recovery.md) §3 — never enter Step 6, treat an orphan lock as authority, or invent a replacement.---## Step 2: Load the Generate authority, proceed from Step 6-```-Read skills/ppt-master/workflows/generate-pptx.md-```--Then jump to `### Step 6: Executor Phase`. It first loads `executor-base.md`,-then applies that role core's context policy:+Read `skills/ppt-master/workflows/generate-pptx.md` and jump to `### Step 6: Executor Phase`, which loads `executor-base.md` and applies its context policy: read the complete Design Spec, then the complete lock, once; resolve the effective Speaker Notes / Custom Animations / Narration Audio outcomes from `design_spec.md §I` (missing outcomes default `enabled` / `disabled` / `disabled`; never from the lock).-- Read the complete project Design Spec, then the complete `spec_lock.md`, once to establish the fresh execution context-- Resolve the effective Speaker Notes, Custom Animations, and Narration Audio- outcomes from `design_spec.md §I`. Missing outcomes use the workflow defaults- `enabled` / `disabled` / `disabled`; these production decisions never come- from `spec_lock.md`+Before the first SVG, verify every conditional dependency discoverable from that pair:-Before the first SVG, verify every conditional dependency now discoverable-from that retained pair:--| File / Directory | Required when | Reason |+| File / Directory | Required when | Recovery when missing ||---|---|---|-| `<project_path>/notes/total.md` | Design Spec §X records a supplied final/literal narration script | Frozen verbatim narration input; never reconstruct it from the planning chat |-| `<project_path>/images/` plus files whose row status requires existence | `spec_lock images` references any image | `Existing` / `Generated` / `Sourced` files must exist; an absent `Needs-Manual` file remains allowed until the Step 7 readiness gate |-| `<project_path>/templates/` | `spec_lock page_layouts` references any | Layout / mirror prototypes required by execution |-| Resolver-returned Chart/Table SVG | `spec_lock page_visualizations` or legacy `page_charts` references a live Chart/Table key | Shared page-local SVG selected through the two live catalogs |+| `notes/total.md` | §X records a supplied final/literal narration script | Return to Step 4's prepared final narration branch; never rewrite the script from memory |+| `images/` plus files whose row status requires existence (`Existing` / `Generated` / `Sourced`; an absent `Needs-Manual` file is allowed until the Step 7 gate) | `spec_lock images` references any image | By provenance: `Acquire Via: user` / `Existing` is a required manual artifact (`failure-recovery.md` §2, wait for the exact file); a template-bundled bitmap returns to Step 3 to restore the workspace; AI, web, or slice output uses its `failure-recovery.md` §1 row. Formula markers never create a required image file |+| `templates/` | `spec_lock page_layouts` references any prototype | Restore the workspace through Step 3 and [`apply-template-workspace`](apply-template-workspace.md); if unavailable or invalid, run Create Template again rather than reconstructing a template here |+| Resolver-returned Chart/Table SVG | `page_visualizations` or legacy `page_charts` references a live key | Failed, missing, or ambiguous resolution is a missing planning dependency and stops this stage |-Resolve every live Chart/Table value through the shared catalog resolver.-Validate canonical `family/key` from `page_visualizations` directly; opt into-bare-key resolution only for a live Chart/Table value read from legacy-`page_charts`:+Resolve every live Chart/Table value through the shared resolver — canonical `family/key` directly, `--legacy-bare` only for a value read from legacy `page_charts` — and require every returned SVG to exist; never construct a path from the key. A retired Structure bare key is semantic intent only: recover it from §IX or return to Step 4 when §IX is insufficient.```bash-python3 skills/ppt-master/scripts/visualization_recall.py validate \- <family/key> [<family/key> ...]-python3 skills/ppt-master/scripts/visualization_recall.py validate \- --legacy-bare <legacy-key> [<legacy-key> ...]+python3 skills/ppt-master/scripts/visualization_recall.py validate <family/key> [<family/key> ...]+python3 skills/ppt-master/scripts/visualization_recall.py validate --legacy-bare <legacy-key> [...]```-Require every returned SVG to exist. Never construct a path from the key,-guess a family directory, or prefer one registry. Failed, missing, or ambiguous-live resolution is a missing planning dependency and stops this stage. A-retired Structure bare key carries semantic intent only and requires no SVG;-recover its relationship from §IX, or return to Step 4 when §IX is insufficient.--If a conditional dependency is missing, stop before page authoring and recover-by artifact owner:--- Missing frozen `notes/total.md` when §X declares a final/literal script → return to Generate Step 4's prepared final narration branch; never rewrite the script from memory.-- Missing `images/`, or a file whose status requires existence → recover by provenance: an `Acquire Via: user` / `Status: Existing` file is a required manual artifact, so use `failure-recovery.md` §2 and wait for the user to restore that exact file; a template-bundled bitmap returns to [`generate-pptx`](../generate-pptx.md) Step 3 to restore the selected workspace; an AI, web, or slice output uses its matching row in `failure-recovery.md` §1 to reacquire or derive it. An absent `Needs-Manual` file is not a resume failure. Formula markers are SVG authoring content and never create a required image file.-- Missing `templates/` inputs → restore the selected workspace through [`generate-pptx`](../generate-pptx.md) Step 3 and [`apply-template-workspace`](apply-template-workspace.md). If the workspace is unavailable or invalid, run Create Template again rather than reconstructing a template inside this stage.--Then continue the documented pipeline:--- When §X records a final/literal narration script, read the verified frozen `notes/total.md` once and retain its page segments through SVG authoring and the late notes validation-- If resuming mid-deck, read the latest completed SVG and current image metadata after their required paths have been verified-- Read the remaining Step 6 construction core exactly as listed in [`generate-pptx.md`](../generate-pptx.md), then read one locked preset file or only the exact `*_references` of a custom; apply one basis under its behavior or synthesize several by their stated contributions. Never reopen or glob the mode or visual-style catalogs, and load only the branches selected by the condition table-- For each page, make the mandatory Structure decision from retained §IX after its content/communication move is established and before any geometry; a `yes` result loads `executor-structure.md` before realization and creates no artifact or lock row-- Design Parameter Confirmation-- When structured, read the template Design Spec and each selected prototype once; retain unchanged references in the fresh context. A later bounded repair follows [`executor-base.md`](../../references/executor-base.md) §2.1 only while that context remains valid and uncompacted-- Generate pages sequentially from the retained planning artifacts. Use `page-context` only for explicit diagnostics/telemetry or an unresolved path-SHA question ([`artifact-ownership.md`](../../references/artifact-ownership.md) §1), never as a routine pre-page load-- Quality Check Gate-- Speaker notes generation only when the effective Speaker Notes outcome is enabled-- Conditional custom-animation handling under the effective outcome,- provenance, explicit instruction, and existing-sidecar rules-- Step 7: Post-processing & Export (conditional `total_md_split` → `finalize_svg`- → `svg_to_pptx`; disabled speaker notes use `--no-notes`)-- After the base export, run `generate-audio` when the effective Narration Audio- outcome is enabled; narration implies speaker notes are enabled--Reload the Generate authority and required execution references; do not reconstruct or replay the earlier planning conversation.--If the user gives a newer explicit instruction after final Stage 2, update only the-affected effective outcome and provenance in `design_spec.md §I`, then resume at-its owning step. Do not reopen Confirm UI or add the decision to-`spec_lock.md`. Before writing, apply Generate's single notes/audio dependency-gate; at export, apply its sidecar suppression rules.--**Source verification**: the execution session is fresh. Read only the relevant `sources/` passages needed to resolve explicit `Fact IDs` / source references or verify facts, quotes, names, and data required by the current §IX block. Follow [`executor-base.md`](../../references/executor-base.md) §2.1's content-vs-expression contract; source verification never authorizes a second outline. If §IX lacks executable content or evidence, stop and return to Generate Step 4 for Design Spec repair.--> Note: this stage does NOT duplicate Step 6 / Step 7 content. `generate-pptx.md` is the authoritative procedure; resume-execute only adds the resumption entry, sanity check, and source-verification guidance.+Then continue the documented Step 6–7 pipeline exactly as `generate-pptx.md` lists it: read the frozen `notes/total.md` once when §X declares a final/literal script; when mid-deck, read the latest completed SVG and current image metadata after their paths are verified; read the Step 6 construction core and one locked preset file or only the exact `*_references` of a custom, never reopening the mode or visual-style catalogs; load only the branches the condition table selects; make the per-page Structure decision from retained §IX before any geometry; when structured, read the template Design Spec and each selected prototype once. Use `page-context` only for explicit diagnostics or an unresolved path-SHA question ([`artifact-ownership.md`](../../references/artifact-ownership.md) §1), never as a routine pre-page load. Then the quality gate, conditional notes, conditional custom animation, Step 7 (`total_md_split` → `finalize_svg` → `svg_to_pptx`; disabled notes use `--no-notes`), and `generate-audio` when Narration Audio is enabled.++A newer explicit instruction after final Stage 2 updates only its effective outcome and provenance in `design_spec.md §I`, then resumes at the owning step — no Confirm UI, no lock entry; apply Generate's notes/audio dependency gate before writing and its sidecar suppression rules at export.++**Source verification**: read only the `sources/` passages needed to resolve explicit `Fact IDs` / source references or verify facts, quotes, names, and data required by the current §IX block, under [`executor-base.md`](../../references/executor-base.md) §2.1's content-vs-expression contract; verification never authorizes a second outline. If §IX lacks executable content, stop and return to Step 4 for Design Spec repair.++> This stage does not duplicate Steps 6–7; `generate-pptx.md` is the authoritative procedure. Resume adds only the entry, sanity check, and source-verification guidance.---## Step 3: Hand-back-When Step 7 completes and `exports/<project_name>_<timestamp>.pptx` is produced, the stage ends. Report the export path to the user.--If the deck contains data charts, the [`verify-charts`](verify-charts.md) stage runs between Step 6 and Step 7 as documented in [`generate-pptx`](../generate-pptx.md); resume mode handles it the same way as continuous mode.+When Step 7 produces `exports/<project_name>_<timestamp>.pptx`, the stage ends; report the export path. [`verify-charts`](verify-charts.md) runs between Steps 6 and 7 exactly as in continuous mode.