Skip to content

v1.91.264.0 feat(design-motion): new /design-motion skill for showcase loops, adapted from Elaya's design-to-motion (GSTA-92 phase 2) - #3430

Merged
capy-ai[bot] merged 17 commits into
mainfrom
garrytan/gsta92-design-motion
Oct 27, 2026
Merged

capy-ai[bot] merged 17 commits into
mainfrom
garrytan/gsta92-design-motion

Conversation

@garrytan

@garrytan garrytan commented Oct 25, 2026 •

Copy link
Copy Markdown
Owner
{
  "schema_version": 1,
  "pr": 3430,
  "head": "ac0228a416975fa5ea2f8a39d013e92a552258c1",
  "version": "1.91.260.0",
  "base": "main",
  "gate": {
    "remote-free": {
      "pass": 18843,
      "fail": 0,
      "skip": 30
    },
    "free-tests-ci": {
      "pass": 1,
      "fail": 0,
      "skip": 0
    },
    "windows-free-tests-ci": {
      "pass": 1,
      "fail": 0,
      "skip": 0
    }
  },
  "spend_usd": 1.78,
  "session_kind": "unattended",
  "pregate": "requires-remote cleared @60a3dfcb63a2 (1 checks, current for ac0228a41697)",
  "requires_remote": [
    "free-tests.yml/macos-named-regressions: https://github.com/garrytan/gstack/actions/runs/40431613945",
    "windows-free-tests.yml/windows-free-shard: https://github.com/garrytan/gstack/actions/runs/40431613925",
    "pregate.json/remote_gate: remote-gate tree=60a3dfcb63a2 tests=18873"
  ],
  "issues": {
    "fixes": [],
    "refs": [
      3420,
      3433
    ],
    "flakes": []
  },
  "review_loop": {
    "passes": 1,
    "blocking_found": 0,
    "deferred": 0,
    "noted": 0,
    "fixed": 0,
    "scope": "frozen"
  }
}

Phase 2 of GSTA-92: a new /design-motion skill that turns an approved /design-shotgun PNG, a /design-html finalized.html or a URL into a showcase loop. It produces an MP4 for X, a website loop GIF and an 800×500 GIF, and checks that the loop is clean before it exports. Adapted from Elaya's MIT-licensed design-to-motion and rewritten for gstack. Phase 1 is #3420.

https://api.capy.ai/pr-assets/v_6Il-6KhjRfiT_4Etp5DgLJXuh3AJmk6qMDrpvNXqLAE.mp4

After: the MP4 the skill exported from a fixture page (recorded at an earlier head of this PR; the export recipe is unchanged since). The bars breathe and the dot steps across the queue card, ending on the same empty frame it starts from. Before this PR, gstack had no way to produce this from a design.

Contact sheet from gstack-motion-encode check

The contact sheet gstack-motion-encode check writes for review (earlier head): the empty start, the cards loading, the story, the rest and the dissolve back to empty. It passed the seam, empty-beat, rest and overflow checks.

What changed

  • design-motion/: the skill template plus three on-demand sections (fidelity, motion, and figma read only with a token). A motion doctrine block puts gstack's rules first: one authored moment on a website, content visible without script, no bounce and no gradient text; pulses, marquees and carets only in the showcase recording.
  • bin/gstack-motion-capture.ts (lib/motion-capture.ts): deterministic frames from gstack's Playwright Chromium on a fake clock, with the __start/__tick/__lt/__mark page contract, whole-millisecond steps averaging 1000/60, PRE frames and an overflow mask from [data-motion-clip].
  • bin/gstack-motion-encode (lib/motion-encode.ts): check (seam, empty beat, rest, overflow via ffmpeg PSNR, contact sheet), export (Elaya's MP4, loop GIF and 800×500 GIF recipes), compare (still fidelity). ffmpeg is optional (FFMPEG_MISSING, exit 3).
  • /ship review fixes (this run, 8 commits): filter-graph injection through --pad/--crop closed; unknown options, bad --formats, blank numbers and a capture.json whose fields are not what capture writes are refused; --out is reused only when its .gstack-motion-capture marker is there; lazy images, slow loads and a __tick that never returns can no longer hang a capture; an overflow check can no longer pass on zero frames or a mask that covers everything (a full-bleed app frame reports clean (overflow not checked)); exports are written to .partial- files and renamed; a story's class-toggled CSS transition is seeked from its own frame instead of popping; portrait frames scale to 1200×1920; --cycle must be a multiple of 0.05 s so the seam is exact; the Figma token goes to curl on stdin; native Windows stops before the first capture.
  • Registration: skill tables in AGENTS.md, README and docs; doctor components; the carve guard; the context-budget entry; the placeholder allowlist (<motion-dir>, stricter <hex-color>); touchfiles rows. The catalog budget goes from main's 1,289 to 1,314 (1,289 + ceil(99/4): this skill's 99-byte description, re-measured on the merged tree, 5,249 bytes = 1,313 token-equivalents). No SKILL.md size pin, context budget or parity cap moved; the design-motion skeleton is 39,868 of its 39,900-byte cap.
  • Merge of main (6c5b2d4, v1.91.260.0, rule-19 grant from GStack Minder): bin/gstack-doctor-components.sh takes main's lines (captain, ubicloud, floor) with design-motion after design-html; NOTICE.md keeps main's craft-audit bullet and hallmark section around the design-motion bullets; PROJECT_STRUCTURE, touchfiles, context-budget and the placeholder allowlist keep both sides; the CHANGELOG entry stays under ## [Unreleased] (15 insertions, 0 deletions vs main); design-motion/SKILL.md regenerated with main's preamble.

Why

Garry asked to absorb the interesting parts of Elaya's design skills (Oct 25), then approved a new top-level skill for this one ("Do it"). Turning a design into a launch loop is its own workflow with its own deliverables, so it lives in its own skill. Garry's 2026-10-25 rule ("we should really be using the gstack ship skill before merging PRs") is why this head went through gstack's /ship; its reviews drove the fixes above.

Approvals

Date Asked Exact words Outcome Covers Still pending
2026-10-25 Absorb the Elaya design skills “Absorb all the interesting parts of this design skill https://github.com/elayadesign/ai-design-skills” (Garry) approved Phase 1 (#3420) none
2026-10-25 Plan ask incl. /design-motion as a new skill (via GStack Minder) “Do it” (Garry (via GStack Minder)) approved /design-motion as a new top-level skill in its own PR; budgets raised to measured size only (autoplan gate_rev=1, rec_hash=2592f8063bfc) none

Source: gstack-approvals record for garrytan/gsta92-design-motion (display only; not an approval citation).

Summary

  • New /design-motion skill, its capture and encode bins and libraries, registration and docs.
  • /ship review and QA fixes across three invocations (input validation, capture robustness, overflow-check honesty, atomic exports, story-transition seeking), each with tests.
  • docs/PROJECT_STRUCTURE.md names Elaya's MIT material.

Test Coverage

Step 7 audit (invocation 2, audit only): 86% of 28 paths have a test, 82% value-weighted, 1 weak path; later review commits added tests for the remaining review findings (test/motion-pipeline.test.ts now runs 9 real Chromium + ffmpeg cases locally). Remaining gaps: BROWSER_UNAVAILABLE, CSS-keyframe-only pages [→E2E], ffmpeg failure handlers, the win32 guard (Windows lane only). motion-pipeline.test.ts self-skips where ffmpeg is absent, which includes the CI images.

Pre-Landing Review

This invocation (head ac0228a, after the main merge): one frozen-scope pass over git diff 6095e65 ac0228a restricted to the PR's files. Testing + Maintainability and Red Team + adversarial (Claude) reviewers: NO FINDINGS; Security, Performance, Design, Simplification and State Machines not dispatched (no PR-owned code in the delta). Converged with zero edits.

REVIEW_LOOP: passes=1 blocking_found=0 deferred=0 noted=0 fixed=0 scope=frozen

Earlier invocations (head 6095e65 and before): final pass (invocation 3, pass 2, head fc8264c): Testing, Maintainability, Security, Performance, Design, Simplification and State Machines plus Red Team: no findings beyond advisories; converged with zero edits. Earlier passes found and fixed the defects listed under What changed; recurring regressions introduced by fixes were caught by the next pass each time. Codex is not installed here, so outside review coverage is unavailable; the Claude adversarial pass ran on every pass (final verdict: "Ship as-is").

Deferred with recorded reasons (follow-ups, none blocking): frames left on disk after export, serial exports, loopTime unused, --min-db has no floor, the 1970 fake clock, no upper bound on --cycle/--pre/--tail/--scale, the reference render of a page with a requestAnimationFrame intro getting one frame, file:// subresources outside the page directory, non-WAAPI media (SMIL, video, animated images), --mask-grow counted in device pixels, ffmpeg spawn errors printing null, alpha dropped by compare.

Gate edits: 14 listed, 1 read, 1 finding — 1 kept (reasons below), 0 restored, 0 open

  • kept: catalog-budget, test/catalog-budget.test.ts — the ceiling moves 1,289 → 1,314 by exactly the new skill's measured description (99 bytes, new-skill ratchet documented in the test), approved scope "budgets raised to measured size only".

Exploratory QA

Functional probes on the bins: capture, check and export pass; --pad '#ffffff,hue=s=0' and compare --crop '100:100:0:0,hue=s=0' were accepted at aaa1f98 (filter-graph injection) and exit 2 since 41a720d.

Eval Results

design-motion-showcase (marathon, behavior, 3 trials) at ac0228a: PASS 3/3 ($0.59, $0.62, $0.51). Before the merge, at 6095e65: PASS 3/3 ($0.49, $0.63, $0.70).

Greptile Review

No Greptile comments on this PR.

Scope Drift

None: every change serves the /design-motion skill, its review fixes, or its registration and docs.

Plan Completion

Plan completion audit: not run (no plan is bound to this branch and no docs/designs/ file matches). Fix: add "Plan: " to the PR body, or run /autoplan.

Issues

Refs #3420
Refs #3433

Verification Results

Remote free tier (Ubicloud, full free suite) at tree 60a3dfcb63a2 / head ac0228a: 18,873 tests (30 skipped), 0 failed, $0.06. Every pull_request check at ac0228a green (45 passed, 0 failed, 11 skipped), including Free Tests and Windows Free Tests.

TODOS

None changed.

Documentation

Audited at fc8264c and committed as 6095e65, before the main merge; the merge changed no PR-owned doc claim except the catalog figure, which CLAUDE.md and the test now both give as 1,314.

Status: updated — one factual fix in docs/PROJECT_STRUCTURE.md; no blockers.

Scope: ship-owned audit (edit mode, spawned; SESSION_KIND: spawned echoed by the preamble) of garrytan/gsta92-design-motion at fc8264c against base 7bd3fb4: 33 committed files and 14 commits, with nothing staged, unstaged or untracked. All 138 candidate hashes match the working tree. The audit covered the new /design-motion skill (template plus the fidelity, motion and figma section templates), its two bins and libraries, the doctor and test metadata, and every doc the branch touches or that names the design skills. Doc claims were checked against lib/motion-capture.ts, lib/motion-encode.ts, bin/gstack-motion-capture.ts and bin/gstack-motion-encode: flags, defaults, output names, exit codes, the 744-frame and 1744×1200 example arithmetic, and the 1,222 catalog budget all match. Generated output is fresh (gen-skill-docs --dry-run exit 0, gen-llms-txt up to date), and the banned-terms check found no list. Steps 5, 7, 8, 9 and the cross-model review were skipped under ship-owned mode.

Documentation health:
  docs/PROJECT_STRUCTURE.md        Updated (NOTICE.md row now names Elaya's MIT-derived material; licenses/ row lists MIT-elaya.txt beside Apache-2.0.txt)
  README.md                        Current (/design-motion row matches the bins)
  AGENTS.md                        Current (skill table row present)
  CLAUDE.md                        Current (catalog budget 1,222 matches test/catalog-budget.test.ts)
  NOTICE.md                        Current (attributed paths exist)
  docs/skills.md                   Current (table row, anchor and example verified against capture/encode math)
  gstack/llms.txt                  Current (generated, fresh)
  design-motion/SKILL.md.tmpl      Current (commands, flags, outputs and defaults match the bins)
  design-motion/sections/*.md.tmpl Current (fidelity, motion, figma)
  docs/troubleshooting.md          Current (Smart App Control skill lists don't apply; /design-motion uses Playwright Chromium, not a compiled binary)
  CHANGELOG.md                     Not audited for voice (ship-owned; Unreleased entry facts spot-checked against source)
  TODOS.md                         Skipped (ship-owned)

Documentation coverage:

  [entity]                       [reference]                 [how-to]          [tutorial] [explanation]
  /design-motion                 ✅ AGENTS/README/skills.md   ✅ skills.md        ❌          ✅ skills.md
  gstack-motion-capture.ts       ✅ skill template only       ❌                  ❌          ❌
  gstack-motion-encode           ✅ skill template only       ❌                  ❌          ❌
  GSTACK_FFMPEG, FIGMA_TOKEN     ✅ skill template/CHANGELOG  ❌                  ❌          ❌
  FFMPEG_MISSING, MOTION_* codes ❌ no troubleshooting anchor ❌                  ❌          ❌

Documentation Debt

  • ⚠️ FFMPEG_MISSING, MOTION_CONTRACT_MISSING, MOTION_MASK_EMPTY, MOTION_CAPTURE_FAILED have no docs/troubleshooting.md entries (explanation/how-to).
  • ⚠️ The motion bins and GSTACK_FFMPEG are documented only inside the skill (reference only, no how-to).
  • ⚠️ README's "Design is at the heart" narrative and /plan-design-review's design-skill recommendations don't mention /design-motion (narrative, so left to the author).
  • No tutorial covers the shotgun → html → motion chain.

Diagram drift: none. The branch only adds entities, and no ARCHITECTURE diagram names motion components.

Suggest a docs-debt label.

Test plan

🤖 Generated with Claude Code

garrytan and others added 6 commits October 25, 2026 21:03
…laya design skills (GSTA-92)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…drop a $-digit literal from craft.md; count only craft-check executions in design-html-slop-gate

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…b-elaya-design

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

# Conflicts:
#	CHANGELOG.md
…oops from a design, adapted from Elaya design-to-motion (GSTA-92 phase 2)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
… the periodic census is at its 38-slice cap (GSTA-92)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…3420)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@capy-ai
capy-ai Bot changed the base branch from garrytan/gsta92-absorb-elaya-design to main October 26, 2026 00:36
@trunk-io

trunk-io Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

😎 This pull request was merged.

@github-actions github-actions Bot changed the title feat(design-motion): new /design-motion skill for showcase loops, adapted from Elaya's design-to-motion (GSTA-92 phase 2) v1.91.225.0 feat(design-motion): new /design-motion skill for showcase loops, adapted from Elaya's design-to-motion (GSTA-92 phase 2) Oct 26, 2026
garrytan and others added 11 commits October 26, 2026 01:15
- encode: refuse unknown options and --formats tokens, validate --pad (#RRGGBB[AA])
  and --crop (compare too) so nothing but a colour or crop reaches ffmpeg's filter graph
- encode: export refuses a capture with missing window frames; check prints
  MOTION_SETTINGS for any threshold/phase override; contact sheet drops -fps_mode
- capture: portrait-aware scale, --cycle must be whole 60 fps frames, stills with
  CSS animations disabled, pauseAt tolerates slow loads, clears stale manifest/stills
- skill: <motion-dir> placeholder instead of a cross-block shell variable,
  GSTACK_FFMPEG-aware probe, stop points before the first capture, doctrine fixes
- tests: refusal rows, portrait scale, cycle guard

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…nd ffmpeg

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
- capture: refuse an --out that holds a still or frames but no capture.json
  instead of deleting them; --cycle must be a multiple of 0.05 s so the seam
  frame lands exactly one cycle later for every PRE (nearest value round-trips)
- encode: a capture without a mask ends 'MOTION_RESULT: clean (overflow not checked)'
- skill: Step 5 names window.__mark in the capture contract
- tests: foreign/previous --out handling on real Chromium, cycle guard and PRE sweep

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
- capture: an ownership marker (.gstack-motion-capture) replaces the
  capture.json test, so the rerun after MOTION_CONTRACT_MISSING or a crash
  works and a foreign --out is still refused; offscreen lazy images are made
  eager and font/image loading is bounded at 30 s instead of hanging
- encode: refuse a capture.json whose fields are not what capture writes
  (they reach ffmpeg args and paths); a cards overflow with no story frames
  is a planning error, and a zero-frame job never passes
- tests: retry after a refused page, no-mask clean line, lazy image still,
  manifest validator, empty story span

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…Figma token off argv

- check fails overflow when the grown mask covers >90% of the frame (an app
  frame whose clip surfaces fill the stage passed vacuously); --mask-grow is
  0-32; --mask refuses braces and semicolons
- manifestError checks fps/windowFrames >= 1 and that the window fits the frames
- skill: native Windows stops before the first capture call; the Figma token
  reaches curl on stdin (-H @-) instead of argv
- tests: split the --out ownership scenario out of the contract test, full-frame
  mask, --still --scale 2 size and STILL_OK, manifest relations, coverage parse

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
- capture: each frame is bounded at 10 s (a __tick that never returns fails
  with MOTION_CAPTURE_FAILED instead of hanging); a --mask that matches no
  element stops with MOTION_MASK_EMPTY
- check: a grown mask covering >90% of the frame (full-bleed app frame)
  reports overflow as skipped and ends 'clean (overflow not checked)'
- export: writes .partial- files and renames on success, so a failed
  re-export keeps the last good file; a GIF fps that does not divide the
  cycle is refused; a missing GSTACK_FFMPEG override is named
- fidelity: URL source is untrusted data; full-bleed note
- tests: spinning __tick, empty mask, failed re-export, drifting gif fps

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…mask

- check: the >90% coverage skip applies only to an app frame's own surfaces
  (ungrown mask); in cards, or when --mask-grow pushes coverage over 90%,
  overflow fails with what to change (a cards capture with real overflow
  passed as 'clean (overflow not checked)' after a large grow)
- export: --gif-fps/--small-fps capped at 50 (GIF delays are 1/100 s)
- compare resolves its paths (a colon in a relative path read as a protocol)
- capture: MOTION_MASK_EMPTY is checked before the first frame
- tests: cards vs app full-frame mask, fps cap, no frames on an empty mask

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
- capture: an animation first seen in a frame where window.__mark did not
  move (a story's class toggle) is seeked from that frame instead of the
  last mark, so it eases in the export instead of popping ~100 ms ahead
- encode: an empty numeric option is refused instead of read as 0
- figma: only fill a file key and node id that look like Figma's
- tests: class-toggled transition mid-fade at its midpoint, blank --min-db

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…laya.txt

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…ded); catalog budget re-measured for design-motion

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
….0 (train slot 2)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@github-actions github-actions Bot changed the title v1.91.225.0 feat(design-motion): new /design-motion skill for showcase loops, adapted from Elaya's design-to-motion (GSTA-92 phase 2) v1.91.264.0 feat(design-motion): new /design-motion skill for showcase loops, adapted from Elaya's design-to-motion (GSTA-92 phase 2) Oct 27, 2026
@capy-ai
capy-ai Bot merged commit c2e01e4 into main Oct 27, 2026
62 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant