drawio-reconstruction
Skill này làm gì
Skill này biến ảnh một sơ đồ, slide hoặc ảnh chụp màn hình thành tệp Draw.io có thể chỉnh sửa. Skill dành cho người muốn sửa một sơ đồ mà họ chỉ có dưới dạng hình ảnh.
Khi nào nên dùng
- ✓Khi bạn có ảnh sơ đồ và muốn một bản Draw.io có thể chỉnh sửa.
- ✓Khi bạn cần dựng lại sơ đồ kiến trúc, hình trong bài nghiên cứu hoặc slide thành tệp.
- ✓Khi bạn muốn biến ảnh chụp giao diện hoặc một thư mục ảnh thành XML Draw.io.
Liên kết skill
https://github.com/HKUSTDial/Supervisor-Skills/blob/main/skills/drawio-reconstruction/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Biến ảnh chụp sơ đồ kiến trúc này thành tệp Draw.io có thể chỉnh sửa, với cùng các hộp và mũi tên.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
AI dựng lại chữ và các hình đơn giản thành các phần Draw.io gốc, và chỉ dùng ảnh cho các hình ảnh phức tạp. Sau đó AI so sánh bản xem trước với ảnh gốc để kiểm tra bố cục có khớp không.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Draw.io Reconstruction
Use this skill for high-quality reconstruction of diagram images into .drawio files.
Helper Script Location
Resolve SKILL_DIR to the absolute directory containing this SKILL.md before running any bundled helper. Use the resolved skill location provided by the runtime; never assume the skill is installed under ~/.codex, ~/.agents, or any other fixed directory.
All commands below use $SKILL_DIR to mean that resolved absolute directory.
Fidelity Contract
The primary goal is visual fidelity to the reference image. Editability is secondary.
Do not treat semantic equivalence as success. A generic icon, generic curve, generic font size, approximate panel, or approximate background is a defect when the reference has a specific visual style.
Script checks only prove technical validity. A diagram is not complete merely because .drawio opens, exports, or passes check_drawio.py / batch_verify.py. Completion requires visual comparison against the reference at full size.
Work only in the target directory or target files named by the user. Do not repair, overwrite, or improve neighboring diagrams because they look related. If the requested target is ambiguous, inspect and report the ambiguity before editing.
Never silently rewrite the user's content. If the user asks for larger fonts or a more professional PPT style, first distinguish:
- Layout-only refinement: increase font size, resize boxes, improve spacing, align elements, adjust line breaks without changing words.
- Content compression: shorten sentences, remove details, rewrite labels. Ask permission before doing this.
Batch Folder Workflow
Use this workflow when the user provides a directory of images or asks for batch reconstruction.
Batch Intent And Scheduling
Before opening images for detailed visual analysis, decide whether the request is a batch reconstruction task:
- Treat the request as batch reconstruction when it names a folder, multiple image files, a glob/pattern, or any target that resolves to 2 or more image entries.
- Create and review the manifest before detailed per-image work begins.
- When sub-agent tooling is available and useful, use a bounded worker pool no larger than the available concurrency and the number of pending images. Give each active worker exactly one image and an exclusive write set for that image's
.drawio, exported.png, audit file, and private asset/crop directory. Reuse a free slot for the next image instead of trying to start every worker at once. - When sub-agent tooling is unavailable, disabled, capacity-limited, or unnecessary for a small batch, process entries serially in manifest order. Preserve the same inventory, reconstruction, export, check, and visual-audit requirements.
- Tell the user about scheduling limitations only when they materially affect timing or delivery. Do not block a valid batch solely because parallel execution is unavailable.
- The coordinating agent may inspect thumbnails or file metadata to confirm scope, naming, orientation, and shared style constraints before choosing the schedule.
Identify the input directory, output directory, naming convention, and overwrite policy.
Create a batch manifest:
python "$SKILL_DIR/scripts/batch_manifest.py" path/to/images --output-dir path/to/output --writeReview the manifest before editing. Process only entries in the manifest unless the user expands scope.
For each image, define the expected
<stem>.drawio,<stem>.png, and lightweight<stem>.audit.mdoutputs in the target output directory.Choose a bounded parallel schedule or a serial schedule:
- Assign exclusive output files for each active entry.
- Tell workers they are not alone in the codebase and must not revert or edit other workers' outputs.
- Require every entry to follow the same full workflow as a standalone single-image task. Batch mode is only a scheduling strategy; it does not reduce fidelity, inventory, reconstruction, export, check, or visual-audit requirements.
- Apply this quality gate to every entry: produce
.drawio,.png, and<stem>.audit.md; create the complete visible-element inventory; classify non-text visuals; use crops/SVG/native elements according to the normal medium rules; run required checks/exports; visually compare the exported preview against the reference; mark unresolved visual defects instead of claiming completion. - Keep final batch v
Câu hỏi thường gặp
Tệp mới có giống hệt ảnh không?
Skill hướng đến độ trung thực thị giác cao. Skill so sánh kết quả với ảnh gốc ở kích thước đầy đủ và sửa các chỗ khác biệt.
Skill có thay đổi nội dung không?
Skill được thiết lập để không viết lại nội dung của bạn trừ khi bạn yêu cầu thay đổi.
Tôi nhận được gì ở cuối?
Một tệp Draw.io mà bạn có thể mở và chỉnh sửa trong ứng dụng Draw.io.
Chi tiết
Mô tả gốc của tác giả
Reconstructs reference images into high-fidelity, editable Draw.io files with rendered previews: native Draw.io elements carry text and structure, SVG covers simple icons that match the reference, and cropped or transparent PNGs preserve complex visuals. Use when the user wants a diagram image, research figure, architecture diagram, slide, UI screenshot, or image folder turned into `.drawio` XML; batch requests use a manifest with bounded parallelism when available and a full-fidelity serial fallback otherwise.
Độ phổ biến
- Sao GitHub
- 11k
- Vị trí xếp hạng
- #11689
- Giấy phép
- —
- Cập nhật
- 16/10/2026
Bình luận
- …
Thêm skill từ kho mã này
benchmark-paper-template
11kGiúp agent của bạn lên kế hoạch và kiểm tra bài báo về benchmark, từ khoảng trống nghiên cứu và bộ dữ liệu đến thí nghiệm và danh sách kiểm tra.
deep-research
11kGiúp agent của bạn thực hiện tổng quan tài liệu kiểu khảo sát, với trích dẫn đã kiểm tra, cách phân loại rõ ràng và báo cáo dựa trên bằng chứng.
figure-designer
11kGiúp agent của bạn chọn bố cục và loại biểu đồ cho các hình chính của bài báo nghiên cứu, rồi kiểm tra theo các quy tắc chất lượng phổ biến.
idea-evaluator
11kGiúp agent của bạn đánh giá ý tưởng nghiên cứu còn nháp về tính mới, khả thi và rủi ro, rồi đưa ra kết luận rõ ràng trước khi bạn dốc sức.
Skill tương tự
gifgrep
394kCho phép agent của bạn tìm thư viện GIF, xem trước kết quả, tải một GIF, và lấy một khung hình tĩnh hoặc bảng ghép nhiều khung hình.
meme-maker
394kCho phép agent của bạn chọn một mẫu meme, thêm chú thích của riêng bạn và tạo meme dưới dạng ảnh SVG hoặc PNG.
ios-icon-gen
280kGiúp agent tạo biểu tượng cho ứng dụng iOS. Dùng biểu tượng của Apple hoặc từ các nguồn khác để tạo đúng định dạng tệp.