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
fix(native-shapes): make semantic inspection execution-safe
hugohe324f4630acac5
diff --git a/AGENTS.md b/AGENTS.mdindex 973028c1..511d8144 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -2,7 +2,15 @@This file is the project entry point for general AI agents.-**You MUST read [`skills/ppt-master/SKILL.md`](skills/ppt-master/SKILL.md) before any PPT generation task or repo modification.** It owns global execution discipline and points to the route selector; after routing, the selected runtime authority owns its steps, gates, and commands. The rest of this file only points to where related material lives.+**You MUST read [`skills/ppt-master/SKILL.md`](skills/ppt-master/SKILL.md) before any PPT generation task or repo modification.** It owns global execution discipline and points to the route selector; after routing, the selected runtime authority owns its steps, gates, and commands.++**Repository execution anchor**: resolve the absolute repository root from this+file's supplied path and retain the absolute `skills/ppt-master` root before the+first command. Paths in this file are repository-relative notation only; invoke+them through those absolute roots, retain the absolute project path returned by+initialization, and never issue `cd skills/ppt-master` or `cd projects/...`.+When parsing machine-readable stdout, keep stderr separate and never place+`2>&1` upstream of a JSON or XML parser.## Project Overviewdiff --git a/skills/ppt-master/references/native-shape-authoring.md b/skills/ppt-master/references/native-shape-authoring.mdindex 48ecc733..6d6ea0af 100644--- a/skills/ppt-master/references/native-shape-authoring.md+++ b/skills/ppt-master/references/native-shape-authoring.md@@ -28,13 +28,13 @@ The plain `list` command remains a compatibility view of exact registry names;it does not replace grouped discovery. For each page entering ordinary contourselection, run `recommend --limit 6` from the actual page role and applicablerelationship, direction, aspect, text capacity, scope, or intent terms before-choosing a contour, then run `describe <name>` on the serious candidates. Grouped-discovery followed by direct `describe` does not satisfy page-local recall.-Those commands supply the full match reasons, intended uses, and misuse-boundaries omitted from the compact entry index. Recommendation is diverse-candidate recall, not a whitelist, automatic choice, or shape quota; a neutral-primitive remains valid when it fits best. Each page still resolves the final-contour through §§1–2.1.+choosing a contour, then run `describe <name> --compact` on the serious+candidates. Grouped discovery followed by direct `describe` does not satisfy+page-local recall. Those commands supply the full match reasons, intended uses,+misuse boundaries, adjustments, and key geometry facts omitted from the compact+entry index. Recommendation is diverse candidate recall, not a whitelist,+automatic choice, or shape quota; a neutral primitive remains valid when it+fits best. Each page still resolves the final contour through §§1–2.1.## 1. Contour Selection and Materialization Gate@@ -105,7 +105,7 @@ Apply this page-local sequence before drawing:|---|---|---|| Job | State what the object must do for the reader before naming a shape. | Page role plus any real relationship, direction, aspect, text load, or literal scope. || Recall | Run `recommend` with the known criteria. Keep the default `general` scope unless the page truly needs `literal`, `flowchart`, or `navigation`. | A group-diverse candidate set with match reasons and misuse boundaries. |-| Inspect | Run `describe` for candidates whose contour could fit; compare `intent`, `recommended_for`, `avoid_for`, adjustments, text rectangle, and connection sites. | Evidence for choosing or rejecting each serious candidate. |+| Inspect | Run `describe --compact` for candidates whose contour could fit; compare `intent`, `recommended_for`, `avoid_for`, adjustments, text rectangle, and connection sites. | Evidence for choosing or rejecting each serious candidate. || Select | Choose the contour whose inference and visual character fit the page, including a neutral primitive when neutrality is useful. | One page-fit contour; no syntax decision yet. || Encode | Apply §1's materialization gate. | Ordinary SVG primitive, helper-authored preset, Boolean result, or necessary freeform. |@@ -115,7 +115,7 @@ Example recall and inspection commands:python3 ${SKILL_DIR}/scripts/preset_shape_svg.py recommend \--role spine --relationship order --directionality horizontal --aspect wide \--limit 6-python3 ${SKILL_DIR}/scripts/preset_shape_svg.py describe chevron+python3 ${SKILL_DIR}/scripts/preset_shape_svg.py describe chevron --compactpython3 ${SKILL_DIR}/scripts/preset_shape_svg.py recommend \--scope flowchart --role node --relationship flow --query decision --limit 6diff --git a/skills/ppt-master/scripts/README.md b/skills/ppt-master/scripts/README.mdindex b86d31b9..c6365de8 100644--- a/skills/ppt-master/scripts/README.md+++ b/skills/ppt-master/scripts/README.md@@ -200,7 +200,7 @@ Native preset shape authoring (one or more registry-backed fragments on stdout):python3 scripts/preset_shape_svg.py list --groupedpython3 scripts/preset_shape_svg.py recommend --role spine --relationship order \--directionality horizontal --aspect wide --limit 6-python3 scripts/preset_shape_svg.py describe rightArrow+python3 scripts/preset_shape_svg.py describe rightArrow --compactpython3 scripts/preset_shape_svg.py render rightArrow --id process-arrow --frame 120 180 240 96 --fill '#2563EB'python3 scripts/preset_shape_svg.py render-batch --input - <<'JSON'[@@ -218,12 +218,13 @@ reasons, intended uses, and misuse boundaries remain page-local in `recommend`and `describe` instead of being repeated in the mandatory discovery output.`recommend` recalls candidates from page-job criteria; its default `general`scope excludes literal-only symbols, flowchart notation, and action controls.-Its result is neither a whitelist nor an automatic selection. `describe`-combines the selected preset's semantic record with its technical geometry-metadata. A zero-match recommendation is valid JSON with exit code 0 so the-caller can relax its criteria; a zero-match `list --search` remains a failed-lookup with exit code 1. Plain `list [--search QUERY]` remains the compatibility-name view.+Its result is neither a whitelist nor an automatic selection. The+`describe --compact` view returns one flat object with semantic boundaries,+adjustments, connection/text facts, and path count. Plain `describe` preserves+the full nested geometry/semantics payload. A zero-match recommendation is+valid JSON with exit code 0 so the caller can relax its criteria; a zero-match+`list --search` remains a failed lookup with exit code 1. Plain+`list [--search QUERY]` remains the compatibility name view.The helper never writes a page or project file. Select one exact semanticstock-shape match, inspect the emitted fragment, and insert it into thediff --git a/skills/ppt-master/scripts/preset_shape_svg.py b/skills/ppt-master/scripts/preset_shape_svg.pyindex c7b5d8cf..f54f37d9 100644--- a/skills/ppt-master/scripts/preset_shape_svg.py+++ b/skills/ppt-master/scripts/preset_shape_svg.py@@ -8,7 +8,7 @@ page or template.Usage:python3 scripts/preset_shape_svg.py list [--grouped] [--search QUERY]- python3 scripts/preset_shape_svg.py describe PRESET+ python3 scripts/preset_shape_svg.py describe PRESET [--compact]python3 scripts/preset_shape_svg.py recommend --role ROLE [options]python3 scripts/preset_shape_svg.py render PRESET --id ID --frame X Y W Hpython3 scripts/preset_shape_svg.py render-batch --input FILE_OR_DASH@@ -17,7 +17,7 @@ Examples:python3 scripts/preset_shape_svg.py list --groupedpython3 scripts/preset_shape_svg.py recommend --role spine \--relationship order --directionality horizontal- python3 scripts/preset_shape_svg.py describe rightArrow+ python3 scripts/preset_shape_svg.py describe rightArrow --compactpython3 scripts/preset_shape_svg.py render rightArrow --id next-step \--frame 160 210 320 112 --fill "#2563EB" --stroke nonepython3 scripts/preset_shape_svg.py render-batch --input shapes.json@@ -103,9 +103,17 @@ def build_parser() -> argparse.ArgumentParser:describe_parser = subparsers.add_parser("describe",- help="Print preset adjustment and path metadata as JSON.",+ help="Print preset geometry and semantic metadata as JSON.",)describe_parser.add_argument("preset", help="DrawingML preset name.")+ describe_parser.add_argument(+ "--compact",+ action="store_true",+ help=(+ "Print one flat selection view with semantic boundaries and key "+ "geometry facts."+ ),+ )recommend_parser = subparsers.add_parser("recommend",@@ -293,18 +301,39 @@ def main(argv: Sequence[str] | None = None) -> int:print(f"Unknown DrawingML preset: {args.preset!r}", file=sys.stderr)return 1definition = registry.get(args.preset)- payload = {+ adjustments = [+ {"name": guide.name, "formula": guide.formula}+ for guide in definition.adjustments+ ]+ connector_preset = definition.name in CONNECTOR_PRESET_TYPES+ path_count = len(definition.paths)+ connection_site_count = len(definition.connections)+ has_text_rectangle = definition.text_rectangle is not None+ semantics = get_preset_shape_semantics().describe(args.preset)+ full_payload = {"preset": definition.name,- "connector_preset": definition.name in CONNECTOR_PRESET_TYPES,- "adjustments": [- {"name": guide.name, "formula": guide.formula}- for guide in definition.adjustments- ],- "path_count": len(definition.paths),- "connection_site_count": len(definition.connections),- "has_text_rectangle": definition.text_rectangle is not None,- "semantics": get_preset_shape_semantics().describe(args.preset),+ "connector_preset": connector_preset,+ "adjustments": adjustments,+ "path_count": path_count,+ "connection_site_count": connection_site_count,+ "has_text_rectangle": has_text_rectangle,+ "semantics": semantics,}+ payload = (+ {+ "preset": definition.name,+ "intent": semantics["intent"],+ "recommended_for": semantics["recommended_for"],+ "avoid_for": semantics["avoid_for"],+ "adjustments": adjustments,+ "connector_preset": connector_preset,+ "path_count": path_count,+ "connection_site_count": connection_site_count,+ "has_text_rectangle": has_text_rectangle,+ }+ if args.compact+ else full_payload+ )print(json.dumps(payload, ensure_ascii=False, indent=2))return 0diff --git a/skills/ppt-master/scripts/prompt_audit_manifest.json b/skills/ppt-master/scripts/prompt_audit_manifest.jsonindex 668c80b3..ce6978d2 100644--- a/skills/ppt-master/scripts/prompt_audit_manifest.json+++ b/skills/ppt-master/scripts/prompt_audit_manifest.json@@ -16,7 +16,7 @@"max_tokens": 555000},"file_budgets": {- "AGENTS.md": 2750,+ "AGENTS.md": 3250,"skills/ppt-master/SKILL.md": 1250,"skills/ppt-master/references/executor-base.md": 12000,"skills/ppt-master/references/executor-structured.md": 5500,diff --git a/skills/ppt-master/workflows/profiles/quick-generate.md b/skills/ppt-master/workflows/profiles/quick-generate.mdindex 7136f0e6..50b4dcfd 100644--- a/skills/ppt-master/workflows/profiles/quick-generate.md+++ b/skills/ppt-master/workflows/profiles/quick-generate.md@@ -565,11 +565,11 @@ capability menu, visualization recall, template geometry, or a later check.and any applicable topology resolve, but before choosing any contour, run thepage-local `recommend --limit 6` defined by[`native-shape-authoring.md`](../../references/native-shape-authoring.md) from-the actual job, then `describe` only serious candidates. Registry discovery-followed by direct `describe` does not satisfy this recall. Apply §2.1 to the-transient geometry job, actual content, resolved style, and complete native-vocabulary before writing coordinates. It owns the exact-fit geometry gate,-independent relationship / carrier fit,+the actual job, then `describe --compact` only serious candidates. Registry+discovery followed by direct `describe` without `recommend` does not satisfy+this recall. Apply §2.1 to the transient geometry job, actual content, resolved+style, and complete native vocabulary before writing coordinates. It owns the+exact-fit geometry gate, independent relationship / carrier fit,contour-family / exact-result choice, reader effect for a generic or undrawnresult, running actual-geometry signature, and materialization boundary. Aprimitive remains valid when it wins this comparison; there is no preset quota.