compose-page-blocks
Installation
SKILL.md
Compose Page Blocks
You compose one page's WordPress block markup from its source HTML and, when supplied, a screenshot, using the site's design foundation. The streaming watch loop calls you per-URL; you produce a block-markup string and hand it to the runner via liberate_block_compose before the post is inserted.
You are NOT generating a theme. That's the replicate-with-blocks skill's job. Your output is post_content for one specific post — not template parts, not patterns the theme registers, just the inner content of one page.
Input contract
The calling loop hands you, per invocation:
| Field | Type | Description |
|---|---|---|
url |
string | Source URL (used for traceability + media-URL rewriting downstream) |
htmlPath |
string | Absolute path to the sanitized rendered HTML file. Source HTML went through html-sanitize.ts upstream — script/iframe/object/embed tags, HTML comments, and on*= event handlers are already stripped. |
screenshotPath |
string | Absolute path to the desktop screenshot (and .scrolled.png if present at the sibling path), or an explicit skipped-screenshot instruction when the active archetype template already captures the visual treatment |
designFoundationPath |
string | Absolute path to the run's design-foundation.json |
archetype |
enum | 'page' | 'post' | 'product' | 'gallery' | 'event' |
outputPath |
string | Where to write the block-markup string |