amw-diagram-webpage-sync

Regenerates an existing HTML webpage from an edited ASCII, SVG, or Mermaid diagram source.

Updated Jul 8, 2026
One-click install
npx skills add https://github.com/Emasoft/ai-maestro-webdesign --skill amw-diagram-webpage-sync-emasoft
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: amw-diagram-webpage-sync
Source: https://github.com/Emasoft/ai-maestro-webdesign/tree/main/skills/amw-diagram-webpage-sync
Command: npx skills add https://github.com/Emasoft/ai-maestro-webdesign --skill amw-diagram-webpage-sync-emasoft

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires lxml, beautifulsoup4.

What problem does it solve? When you edit a diagram that was used to generate a webpage, the HTML page becomes stale. This Skill closes the round-trip by re-emitting the webpage from the edited diagram source, backing up the original file, and showing exactly what changed. ## Core Features & Use Cases - Diagram-to-webpage re-emission: Parses the old page and the new diagram into an intermediate representation (IR), computes a structural diff, then regenerates the HTML via the ascii-to-html pipeline. - Safe overwrite with rollback: Atomically backs up the original page to a .bak file before overwriting, and automatically restores it if validation fails. - Dual diff reporting: Surfaces both an IR-level diff (nodes added/removed/moved) and an HTML-level structural diff so you can review changes before and after regeneration. - Use Case: You generated a landing page from an ASCII wireframe, then edited the wireframe to add a pricing section. Run this Skill to sync the page: it shows the added section in the diff, rewrites the HTML, and keeps the old version in .bak. ## Quick Start Ask the AI to sync your edited diagram back into your webpage, for example: re-emit landing.html from the updated wireframe in layout.txt and show me what changed.

Frequently Asked Questions about amw-diagram-webpage-sync

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I update a webpage after editing its source diagram?▼

Provide the existing HTML file and the edited ASCII, SVG, or Mermaid diagram. The skill parses both into an intermediate representation, shows a structural diff, backs up the original to a .bak file, and re-emits the page through the ascii-to-html pipeline.

What diagram formats can be synced back into an HTML page?▼

ASCII wireframes, SVG, and Mermaid diagrams are supported. SVG and Mermaid sources are first converted to intermediate ASCII via the IR before re-emission. HTML as a diagram source is rejected because source and target would collide.

Can I sync a webpage whose diagram is an embedded PNG image?▼

No. Pages whose diagram region is an img tag pointing to a PNG or a base64 PNG data URI are refused outright, because the skill does not perform OCR. You must supply the original source artifact such as ASCII, SVG, or Mermaid.

Will syncing overwrite my manual CSS and custom edits in the HTML?▼

Yes. The current version re-emits the entire page, so manual post-generation edits like custom CSS or third-party scripts are lost from the live file, though they remain in the .bak backup. DOM-surgical patching is planned for a later phase.

What happens if the regenerated webpage fails validation?▼

The validator runs on the new HTML after re-emission. On failure, the original file is automatically restored from the .bak backup via an atomic move, and the validator's FIX hints are surfaced so you can correct the diagram source.