Logo: Visio Image Rebuilder

Visio Image Rebuilder

CommunautéitBeléift
pengjunchi0
visio-image-rebuilder

Rebuild or restyle editable Microsoft Visio diagrams from reference images and existing .vsdx files, then export deliverables as .vsdx, PNG, SVG, PDF, or PPTX. Use when the user asks Codex to open Visio, recreate a diagram from a PNG/JPG/screenshot/reference image, match a scientific model figure, update colors/typography/layout in a .vsdx, calibrate panel coordinates to avoid shifted or overlapping submodules, or make publication/presentation outputs while preserving Visio native editable shapes rather than embedding the reference image as a flat picture.

Iwwersiicht

Editeurpengjunchi0
Repositorycodex-visio-paper-figure-skill
Skill-Nummvisio-image-rebuilder
Stären
1K
Forks
48
Matgeliwwert Dateien
5
LizenzMIT
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 5 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    pengjunchi0 huet de Skill op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Visio Image Rebuilder an TypingMind, fir e mat all LLM ze benotzen, oder setzt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vu GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier, déi hei drënner steet, an a bestätegt d'Installatioun.
    https://github.com/pengjunchi0/codex-visio-paper-figure-skill/tree/main
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill derbäisetzen → Iwwer eng GitHub-URL. Pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an d'Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/pengjunchi0/codex-visio-paper-figure-skill.git \
  .claude/skills/visio-image-rebuilder
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Visio Image Rebuilder an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Visio Image Rebuilder automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Visio Image Rebuilder net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Schlësselen.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

Visio Image Rebuilder

Core Rule

Recreate the reference as editable Visio content. Do not satisfy a rebuild request by inserting the whole reference image into the page. Embedding the reference image is only allowed as a temporary locked tracing layer if it is removed or hidden before delivery and the final .vsdx remains native shapes, text, connectors, and groups.

Treat .vsdx as the source of truth. Export PNG, SVG, PDF, or PPTX only after the Visio page has been rebuilt or restyled and checked for native editability.

Workflow

  1. Inspect inputs.

    • Confirm paths for the target .vsdx, reference image, requested output formats, and output directory.
    • Export the current Visio page to PNG before editing when a target file already exists.
    • Inspect the .vsdx package for pages, media entries, and shape counts.
    • Back up the target file before any write.
    • If Visio is already open, close only the target document or ask before terminating a stuck process.
  2. Decode the reference image.

    • Identify page orientation, panel boundaries, module colors, captions, text hierarchy, arrows, dashed lines, and repeated motifs.
    • Build an object inventory: containers, titles, process boxes, icons, charts, graphs, equations, connectors, captions.
    • Calibrate the canvas first, then calibrate each major panel or subpanel with explicit top-left bounds or four corner points.
    • Draw panel internals in panel-local normalized coordinates whenever the figure has dense multi-panel content.
    • Decide whether the task is a full rebuild, color/style transfer, local edit, or export-only job.
    • For dense scientific figures, first create a coarse panel map, then draw panel internals. Do not start with small decorative details.
  3. Prefer Visio automation for native edits.

    • Use COM automation on Windows when Visio is installed.
    • Use DrawRectangle, DrawOval, DrawLine, Page.Import only for small source assets, and shape cells such as FillForegnd, LineColor, LineWeight, Char.Size, Char.Color, Rounding.
    • Use explicit coordinates and IDs for fragile edits.
    • Keep grouped structure meaningful: major panels, submodules, repeated blocks, legends.
    • For nested modules, use helpers such as RectRel, TextRel, LineRel, and OvalRel so child shapes are constrained by their calibrated parent panel.
  4. Use package XML edits only for narrow, deterministic changes.

    • XML patching is appropriate for recoloring existing shapes, replacing font tables, or changing known cell values.
    • Preserve Visio XML ordering: shape-level Cell nodes should be before Section, Text, or child Shapes.
    • Avoid rebuilding complex geometry by raw XML unless COM automation is unavailable.
  5. Export requested formats from the verified Visio source.

    • Use scripts/visio_page_tools.ps1 for export-only jobs.
    • Use scripts/visio_rebuild_scaffold.ps1 with -ExportFormats for rebuilds that should immediately create deliverables.
    • Prefer SVG for vector web/manuscript handoff, PDF for review/print, and PPTX for presentation decks.
    • For PPTX, use PowerPoint COM when available; the generated slide contains the Visio page render, usually inserted from SVG.
  6. Verify without overtrusting a single signal.

    • Export at least one preview after editing when possible.
    • Inspect the .vsdx package to confirm that no full-size reference PNG/JPG was left in visio/media.
    • Check shape count and representative text labels.
    • Check that major panels do not overlap and that child shapes stay within their intended panel bounds.
    • Check every requested output file exists and is non-empty.
    • If Visio automation hangs, stop safely, close the document if possible, and report whether the file was actually modified.

Implementation Pattern

For full rebuilds, generate a script that:

  • Opens the target .vsdx with Visio COM.
  • Saves a timestamped or descriptive backup.
  • Clears or duplicates the page depending on user preference.
  • Sets page size to match the reference aspect ratio.
  • Draws native shapes in top-left reference coordinates converted to Visio coordinates.
  • Defines calibrated panel bounds for complex regions and uses panel-local coordinates for their internals.
  • Adds reusable helpers for rectangles, text boxes, ovals, lines, arrows, mini charts, graph nodes, and image-like stacks.
  • Saves the document and exports requested formats.

Start from scripts/visio_rebuild_scaffold.ps1 when building a full reconstruction script. Copy it into the workspace and customize the Draw-ReferenceFigure function rather than editing the skill copy.

For style transfer, generate a script that:

  • Reads existing shape IDs, text, approximate geometry, fill, and line colors.
  • Maps known modules to target palettes by text and group context.
  • Applies fills, borders, text colors, line patterns, and font changes to existing shapes.
  • Avoids repositioning unless the user asks for layout changes.
  • Exports only after the .vsdx has been saved and inspected.

For export-only requests, run:

powershell
powershell -ExecutionPolicy Bypass -File scripts\visio_page_tools.ps1 `
  -VsdxPath "C:\path\figure.vsdx" `
  -ExportFormats svg,pdf,pptx `
  -OutputDir "C:\path\exports" `
  -InspectPackage

For rebuild plus multi-format export, run:

powershell
powershell -ExecutionPolicy Bypass -File scripts\visio_rebuild_scaffold.ps1 `
  -VsdxPath "C:\path\figure.vsdx" `
  -PageW 16 `
  -PageH 9 `
  -RefW 1600 `
  -RefH 900 `
  -PreviewPath "C:\path\exports\figure.png" `
  -ExportFormats svg,pdf,pptx `
  -OutputDir "C:\path\exports"

Safety Checklist

  • Back up before writing outside the workspace.
  • Close any open Visio document that locks the target file before direct package edits.
  • Never delete or revert unrelated user files.
  • If a previous attempt embedded the reference image, restore from backup or remove the image shape before continuing.
  • Tell the user clearly whether the final file is native editable shapes or a flat embedded image.
  • Tell the user when PPTX export is a rendered slide rather than native PowerPoint shapes.

Acceptance Criteria

A Visio rebuild is acceptable only when:

  • Main panel positions, flow direction, captions, and module hierarchy match the reference at first glance.
  • Major panels are aligned to calibrated bounds, with no obvious submodule drift, collision, or cross-panel overlap.
  • Text remains editable and uses a consistent academic font, usually Times New Roman.
  • Repeated motifs are represented with reusable native shapes rather than pasted raster crops.
  • The final .vsdx package has no full-page raster reference image in visio/media.
  • Requested PNG/SVG/PDF/PPTX deliverables were exported from the saved .vsdx and are non-empty.
  • A preview export or package inspection was performed, or the final response explicitly states why verification was skipped.

Useful Resource

Use scripts/visio_page_tools.ps1 for common inspection, backup, preview export, multi-format export, and package checks. Use scripts/visio_export_formats.ps1 when a custom task script needs reusable export helpers. Use scripts/visio_rebuild_scaffold.ps1 as the starting point for native-shape drawing scripts; it includes both global top-left helpers and panel-local calibrated helpers. Read references/rebuild-guidelines.md when a task requires a full figure reconstruction or careful one-to-one scientific diagram matching.

Matgeliwwert Dateien

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Visio Image Rebuilder?

Rebuild or restyle editable Microsoft Visio diagrams from reference images and existing .vsdx files, then export deliverables as .vsdx, PNG, SVG, PDF, or PPTX. Use when the user asks Codex to open Visio, recreate a diagram from a PNG/JPG/screenshot/reference image, match a scientific model figure, update colors/typography/layout in a .vsdx, calibrate panel coordinates to avoid shifted or overlapping submodules, or make publication/presentation outputs while preserving Visio native editable shapes rather than embedding the reference image as a flat picture.

Firwat Visio Image Rebuilder op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Visio Image Rebuilder besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt, amplaz en Abonnement pro Benotzerplaz ze bezuelen. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Visio Image Rebuilder an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/pengjunchi0/codex-visio-paper-figure-skill/tree/main an. TypingMind liest d'Datei SKILL.md, bëndelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Visio Image Rebuilder benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Visio Image Rebuilder benotzen?

Esou vill wéi Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Visio Image Rebuilder domat benotzen – zum Beispill mat GPT, Claude, Gemini, Grok, DeepSeek, Mistral oder Llama – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Visio Image Rebuilder gratis?

Jo. pengjunchi0 huet de Skill ënner der Lizenz MIT op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbare Pak vun Instruktiounen, deen engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt e maache soll a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a kee Lafzäitëmfeld a funktionéiere mat all Modell.

Alleguer weisen

Elo Ären eegene KI-Aarbechtsberäich ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇