Skip to content

Unify poster HTML, PDF, PNG, and Reel pixel fidelity - #41

Merged
LingAo Xiao (ArmandXiao) merged 1 commit into
microsoft:mainfrom
ArmandXiao:codex/unified-backfill-pixel-fidelity
Aug 17, 2026
Merged

Unify poster HTML, PDF, PNG, and Reel pixel fidelity#41
LingAo Xiao (ArmandXiao) merged 1 commit into
microsoft:mainfrom
ArmandXiao:codex/unified-backfill-pixel-fidelity

Conversation

@ArmandXiao

Copy link
Copy Markdown
Contributor

Summary

  • unify Fix poster HTML and Reel pixel fidelity #39's durable HTML, PDF/PNG, PPTX, and Reel fidelity pipeline with Fix poster figure shrinkage during HTML backfill #40's metric-compatible Arimo mapping and pre-freeze figure-regression gate
  • migrate fresh Arial, legacy Arial/DejaVu, and local-first Arimo posters to packaged-first Arimo while preserving media identity, enforcing the absolute 90% research-figure fill floor, and rejecting new axis overflow above 101%
  • persist renderer-derived geometry across warm reloads and brand-new browser contexts, then require decoded-RGBA equality before promoting HTML, PDF, and PNG artifacts
  • make logo packing rerender-idempotent for both new width-cached zones and completed legacy zones that only stored the old height cache
  • keep Reel canonical poster copies and inline srcdoc identical over HTTP and direct file://, with the wordmark bundled as a runtime asset

This PR supersedes #39 and #40 and is the only one that should be merged.

Root cause

PR #37 made the standalone HTML reload path durable, but Arial was frozen to DejaVu Sans before the source baseline was captured. On the real MSRA117 poster, the metric change reflowed a research figure from 95.20% fill to 79.16%. The later validator only saw the already-shrunken layout.

The combined implementation maps Arial to bundled Arimo, validates migration before accepting a new authoritative baseline, and keeps all of #39's later durable and pixel-equality gates. It also preserves completed legacy logo bakes whose original auto-track width can no longer be recovered safely.

Validation

All tests below were rerun on this combined branch. Test data and results stayed under /tmp and are not included in the PR.

  • all 6 modified Python modules compile; fit_logos.py --selftest, changed CLI help paths, git diff --check, and skill-creator validation for paper2poster and paper2reel pass
  • MSRA117: four research figures render at 95%+; warm/cold 5760x3456 screenshots have 0 differing decoded-RGBA pixels; verify-final passes; repeated legacy and new-format rerenders produce byte-identical PNGs
  • RSR-X1, RSR-X2, and Design-as-Code: research figures remain at 93% to 97%; independent cold-open HTML and PNG have 0 RGBA differences; repeated renders remain stable
  • P01 legacy and local-first Arimo migrations: warm/cold and repeated-render comparisons have 0 RGBA differences; PDF decoded pages are identical; verify-final passes. The historical 79.898% figure is preserved only with the explicit legacy minimum-floor token
  • negative fault injection maps Arial back to DejaVu Sans: the gate rejects the MSRA117 regression 95.20% -> 79.16% with exit 2 and rolls back HTML, PDF, PNG, and font assets unchanged
  • additional low-fill real posters at 81.52%, 79.09%, 75.44%, and 83.06% are rejected rather than destructively backfilled
  • full DS-1000 Reel bundle rebuild succeeds with 10 sections, 10 slides, and 10 timeline clips; package browser checks report 0 errors and 0 warnings
  • Reel HTTP versus direct file:// screenshots are byte-identical at 1365x768, 1440x900, 1920x1080, and 2560x1440, with 0 differing pixels; repeated warm captures also have 0 differences; HTTP Range returns 206

Design-as-Code's page dimensions and page count are correct, but its pre-existing 24.26 MB PDF remains above the checker's 20 MB size cap.

PR hygiene

Exactly 12 production skill/runtime paths are included, matching the union of #39 and #40. No test files, screenshots, logs, generated posters, or audit results are included.

@ArmandXiao
LingAo Xiao (ArmandXiao) merged commit 739f47f into microsoft:main Aug 17, 2026
1 check 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