{"id":50754719,"url":"https://github.com/JimLiu/baoyu-design","last_synced_at":"2026-06-28T04:01:03.091Z","repository":{"id":363015787,"uuid":"1261650101","full_name":"JimLiu/baoyu-design","owner":"JimLiu","description":"Run Claude Design locally as an Agent Skill — Cursor, Claude Code \u0026 more. Produce polished UI mockups, prototypes, decks \u0026 wireframes as self-contained HTML, without claude.ai/design. Best with Opus 4.8.","archived":false,"fork":false,"pushed_at":"2026-06-22T22:13:46.000Z","size":7672,"stargazers_count":1778,"open_issues_count":0,"forks_count":129,"subscribers_count":4,"default_branch":"main","last_synced_at":"2026-06-22T23:16:00.953Z","etag":null,"topics":["agent-skills","claude","claude-code","claude-design","cursor","design","prototyping","ui-design"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JimLiu.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-06-07T01:16:18.000Z","updated_at":"2026-06-22T22:13:50.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/JimLiu/baoyu-design","commit_stats":null,"previous_names":["jimliu/baoyu-design"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/JimLiu/baoyu-design","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JimLiu%2Fbaoyu-design","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JimLiu%2Fbaoyu-design/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JimLiu%2Fbaoyu-design/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JimLiu%2Fbaoyu-design/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JimLiu","download_url":"https://codeload.github.com/JimLiu/baoyu-design/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JimLiu%2Fbaoyu-design/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34876271,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-28T02:00:05.809Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent-skills","claude","claude-code","claude-design","cursor","design","prototyping","ui-design"],"created_at":"2026-06-11T04:00:27.564Z","updated_at":"2026-06-28T04:01:03.084Z","avatar_url":"https://github.com/JimLiu.png","language":"JavaScript","funding_links":[],"categories":["🧠 Agent Skills","⭐ 精选第三方技能"],"sub_categories":["🏆 明星技能（万星以上）"],"readme":"# baoyu-design\n\n**Run Claude Design on your own local agent — Cursor, Claude Code, Claude Desktop, or any file‑capable coding agent.**\n\n[English](README.md) · [简体中文](README.zh-CN.md) · [Changelog](CHANGELOG.md)\n\n![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg) ![Best with Opus 4.8](https://img.shields.io/badge/Best%20with-Opus%204.8-d97757) ![Harness](https://img.shields.io/badge/Cursor%20%C2%B7%20Claude%20Code%20%C2%B7%20Codex-supported-1f6feb)\n\n`baoyu-design` packages **Claude Design** — the design engine behind [claude.ai/design](https://claude.ai/design) — as a portable **Agent Skill**. Drop it into a local agent and you get most of what the website does, right inside your editor: polished UI mockups, interactive prototypes, wireframes, landing pages, dashboards, mobile apps, and slide decks — all produced as self‑contained HTML.\n\nNo website, no separate subscription, no upload step. The agent already on your machine does the work, and every artifact stays in your repo.\n\n---\n\n## Screenshots\n\nThe same Reader Mac App prompt was used in Cursor, Codex, Claude, and Claude Design.\n\n| Cursor | Codex | Claude | Claude Design |\n|---|---|---|---|\n| \u003cimg src=\"assets/screenshots/cursor-reader-mac-app.webp\" alt=\"Cursor running baoyu-design\" width=\"240\"\u003e | \u003cimg src=\"assets/screenshots/codex-reader-mac-app.webp\" alt=\"Codex running baoyu-design\" width=\"240\"\u003e | \u003cimg src=\"assets/screenshots/claude-reader-mac-app.webp\" alt=\"Claude running baoyu-design\" width=\"240\"\u003e | \u003cimg src=\"assets/screenshots/claude-design-reader-mac-app.webp\" alt=\"Claude Design running the same Reader Mac App prompt\" width=\"240\"\u003e |\n\n\u003cdetails\u003e\n\u003csummary\u003ePrompt used for all screenshots\u003c/summary\u003e\n\n```markdown\nBuild a Reader Mac app that helps me read and save articles better. All data is stored locally.\n\n## Information collection\n\n1. Manual adding\nSupport manually adding different types of information:\n- URL: enter a URL and automatically fetch content and images\n- Attachments: upload PDFs, videos, and images\n- Markdown editing: like publishing a blog post, enter the title, body, and cover image\n- Other\n\n2. Automatic subscriptions\n- RSS feeds\n- Social media accounts: X, Weibo, YouTube\n- Other\n\n## Editing and organization\n\n1. Tags\nEvery item can have tags.\n\n2. Categories and folders\nCreate tree-structured folders and place content in different categories.\n\n3. Favorites\nUsers can click to favorite an item.\n\n4. Editing\nEvery item can be edited with a built-in Markdown editor.\n\n## AI assistance\n\n1. Automatic translation\nSupport translation across different languages.\n\n2. Summaries and abstracts\nGenerate summaries for captured content.\n\n3. Derivative creation\nCreate new work based on one or more pieces of content.\n\n4. Integrated AI Chat\nUse AI Chat to call AI Agents that help process content.\n```\n\n\u003c/details\u003e\n\n---\n\n## Why run it locally\n\n- **Free yourself from the website.** You get the vast majority of `claude.ai/design`'s capabilities without ever leaving your editor — same methodology, same craft standards, same output format.\n- **Best with Opus 4.8.** The skill is a long, demanding design brief; the stronger the model, the better the result. Pair it with **Claude Opus 4.8** for the best output, and it still works well on other capable models.\n- **Iterate by pointing, not describing.** Because the deliverable is plain HTML served on `localhost`, you can lean on your agent's built‑in browser preview and element‑annotation tools (Cursor Browser / DevTools, Claude Preview, or Codex Browser). Point at a button in the live preview, say what you want changed, and the agent edits the underlying source — a tight, visual second‑pass editing loop that's hard to get on a website.\n- **Everything is yours.** Output lands in `designs/\u003cproject\u003e/` as self‑contained HTML you can version, fork, export, or ship.\n\n---\n\n## What it can make\n\nThe skill drives a full design process — clarifying questions → gathering design context → producing one or more HTML deliverables → previewing and verifying. It ships a deep bench of **built‑in skills** and a set of ready‑made component scaffolds.\n\n| Area | Built‑in skills |\n|---|---|\n| **Core design** | Hi‑fi design · Interactive prototype · Wireframe · Frontend aesthetic direction |\n| **Decks** | Make a deck · Speaker notes |\n| **Mobile \u0026 motion** | Mobile prototype · Animated video · Sound effects |\n| **Design systems** | Create design system · Use design system · Design system preview · Design Components (`.dc.html`) · Make tweakable |\n| **Import sources** | Figma `.fig` (offline decode) · GitHub repo · Existing HTML/CSS |\n| **Export \u0026 handoff** | Standalone HTML · PDF · PPTX (editable) · PPTX (screenshots) · Video (MP4) · Send to Figma · Send to Canva · Handoff to Claude Code |\n| **AI assets \u0026 integration** | Gemini image generation · Call Claude from prototypes · Read PDF |\n\n**Starter components** (in [`starter-components/`](skills/baoyu-design/starter-components/)) save the agent from hand‑rolling the basics: iOS / Android / macOS / browser frames, a pan‑zoom design canvas, a slide‑deck stage, a timeline animation engine, a tweaks panel, and a fillable image slot.\n\n---\n\n## How it works\n\nThe skill is plain Markdown plus a few JSX/JS scaffolds — no build step, no runtime.\n\n```\nskills/baoyu-design/\n├── SKILL.md              # Entry point — orchestrates the whole flow\n├── system-prompt.md      # The design methodology \u0026 craft standards (source of truth)\n├── references/\n│   ├── claude.md         # Tool map for Claude Code\n│   ├── cursor.md         # Tool map for Cursor\n│   └── codex.md          # Tool map for Codex Agent\n├── built-in-skills/      # Specialized prompts (decks, mobile, import, export, …)\n└── starter-components/   # Device frames, deck stage, canvas, animation engine, …\n```\n\nWhen you ask for a design, the agent reads `SKILL.md`, loads the core methodology from `system-prompt.md`, detects whether it's running in Cursor, Claude Code, Codex Agent, or a generic file‑capable harness, and reads the matching reference doc when one exists. It then pulls in only the built‑in skill(s) the task needs. The split keeps craft rules harness‑independent while each environment resolves its own tools for *asking questions*, *previewing*, *screenshotting*, and *verifying*.\n\n---\n\n## Quick start\n\n### Prerequisites\n\n- A local agent — **[Cursor](https://cursor.com)**, **[Claude Code](https://claude.com/claude-code)**, **[Codex](https://developers.openai.com/codex/)**, or any of the 70+ agents the installer supports (Cline, Roo Code, GitHub Copilot…). Cursor, Claude Code, and Codex have first‑class tool references inside the skill.\n- **Claude Opus 4.8** selected as the model, for best results.\n- **Node.js** (to run the `npx` installer below). **Python 3** is also handy for the local preview server.\n\n### Install\n\n**Recommended — the `skills` CLI.** [`npx skills`](https://github.com/vercel-labs/skills) (from Vercel Labs) reads this repo, finds `skills/baoyu-design/`, and drops it into the right folder for whatever agent it detects:\n\n```bash\n# Install into the current project (auto‑detects your agent)\nnpx skills add JimLiu/baoyu-design\n\n# …or install globally, for every project\nnpx skills add JimLiu/baoyu-design -g\n\n# Target a specific agent explicitly\nnpx skills add JimLiu/baoyu-design --agent claude-code\nnpx skills add JimLiu/baoyu-design --agent cursor\nnpx skills add JimLiu/baoyu-design --agent codex\n\n# Just list what's in the repo first\nnpx skills add JimLiu/baoyu-design --list\n```\n\nIt installs to `.claude/skills/` for Claude Code and `.agents/skills/` for Cursor/Codex-style agents (add `-g` for the `~/`‑level user install).\n\n**Alternative — hand the repo URL to your agent.** Don't want to install anything? Paste the URL into chat and let the agent fetch the skill itself:\n\n\u003e Read https://github.com/JimLiu/baoyu-design and follow its `skills/baoyu-design/SKILL.md` to design a settings screen for a meditation app.\n\nThe agent clones or fetches the repo, loads `SKILL.md`, and proceeds — perfect for a one‑off.\n\n### Use it\n\nOnce the skill is installed (or fetched), just describe a design task in plain language — it auto‑activates from its description:\n\n\u003e Design 3 hi‑fi variations of a settings screen for a meditation app.\n\nIn Claude Code you can also trigger it explicitly with `/baoyu-design`; in Codex, mention `$baoyu-design` when skills are available. The agent asks a few clarifying questions, builds the HTML under `designs/`, and previews it over `localhost`. **Point at any element in the live preview and say what to change** — the agent edits the underlying source for a fast, visual second pass.\n\n### Preview server\n\nDeliverables are previewed over HTTP (multi‑file prototypes won't load from `file://`). The agent normally starts this for you; to run it by hand:\n\n```bash\npython3 -m http.server 4311 --directory designs\n# then open http://localhost:4311/\u003cproject\u003e/\u003cfile\u003e.html\n```\n\n---\n\n## Design systems\n\nBeyond one‑off mockups, the skill can hold a whole project to a **design system** — a versioned bundle of a brand's tokens, fonts, components, and full UI kits. Systems live next to your projects under `designs/`: author one with the *Create design system* built‑in skill, drop in a pre‑built one, or import one from a Figma `.fig` file (see the next section). Once a system exists, two flows let any project consume it.\n\n### Import an existing design system\n\nWhen you start a design, the agent asks **where to save it** and **which design system(s) to use** — it discovers every system under `designs/` and lists them, so you can pick none (free design), one, or several. Name one up front and it skips the menu:\n\n\u003e Design a settings screen using the **Fluent 2** design system.\n\nFor each system you choose, the agent syncs a **self‑contained, version‑pinned copy** into your project at `_ds/\u003cslug\u003e/`, wires its CSS and component bundle into the page, and records the binding in the project's `_d_meta.json`. That local copy is what keeps the project portable and reproducible — nothing reaches outside the folder, and re‑running the import is how you pull updates later. Choose several systems and one becomes **primary** — it owns the overall look and wins any token collision, while the others lend specific components.\n\n### Use an imported design system\n\nOnce a system is bound it acts as a **binding visual contract**, not a loose suggestion: every screen is built from the system's real tokens, type, spacing, and components, and the agent won't invent off‑system colors or styles. If the system ships **starting points** — ready‑made screens or components — you can seed a new design from one instead of starting blank.\n\nThe binding travels with the project. Reopen it later and the agent reads `_d_meta.json`, reloads the system, and keeps designing in‑style — no need to re‑pick. From there you can **refresh** a system to pull updates, **add** another, **swap** which one is primary, or **remove** one entirely.\n\n---\n\n## Import design sources\n\nReal context beats description. Three built‑in import skills turn material you already have into design ground truth the agent works from directly:\n\n- **Figma `.fig` files — decoded fully offline.** Export any Figma file as `.fig` (or grab a community kit), point the agent at it, and a vendored decoder reads it right on your machine — no Figma account, API token, or MCP server. The agent inventories pages, components, and variables, confirms scope with you, then either cherry‑picks components as React code or emits the whole kit as a design system: components regrouped semantically, curated token CSS, real SVG/PNG assets extracted from the file (copied, never redrawn), guideline cards, and a brand‑guide README.\n- **GitHub repos.** Hand it a repo URL as a design source. The agent browses the tree with `gh api` before cloning anything, sparse‑checkouts only the paths it needs into a scratch dir outside your project, and records the repo URL as provenance.\n- **Existing HTML/CSS.** Saved pages or a local codebase work as a design reference: the agent reads the real stylesheets instead of squinting at screenshots, lifts exact values (colors, type, spacing, radii, shadows, interaction states) into your project's own custom properties, and copies referenced assets out.\n\nAnything imported as a design system compiles into a single self‑contained, interactive `preview.html`. This is the community **Chakra UI Figma Kit** `.fig` after one import conversation — 28 components in semantic groups, 400+ curated tokens, guideline cards, and a self‑authored showcase, all browsable in one file:\n\n\u003cimg src=\"assets/screenshots/figma-import-chakra-preview.webp\" alt=\"preview.html of a design system imported from the Chakra UI Figma Kit .fig\" width=\"720\"\u003e\n\n---\n\n## Decks \u0026 PPTX export\n\nAsk for a slide deck and the skill builds it the same way it builds everything else — as a **self‑contained HTML page**, using the `deck-stage` component and the *Make a deck* built‑in skill. Because the deck is just a web page, the whole editing loop stays where you already are:\n\n- **Preview and tweak by pointing.** Open the deck in your agent's browser preview (Cursor Browser, Codex Browser, or Claude Preview), point at a headline or a chart and say what to change — or just ask in chat — and the agent edits that slide's source.\n- **Present full‑screen.** Press **`F`** (or click the fullscreen button in the deck toolbar) to present the deck full‑screen, with the thumbnail rail hidden. `Cmd/Ctrl+F` is left untouched, so the browser's Find still works.\n\nWhen the deck is ready, **export it to PowerPoint by saying so in the same conversation** — \"export this to PPTX\", \"export to PowerPoint\", or \"做个 PPT\" all route to the export flow (it only exports decks this skill builds, not arbitrary HTML). Two modes:\n\n- **Editable** — native PowerPoint text, shapes, and images you can keep editing in PowerPoint or Keynote, laid out to closely match the web deck.\n- **Screenshots** — one full‑bleed PNG per slide: pixel‑perfect, but flat.\n\n\u003e **Running locally:** on `claude.ai/design`, PPTX export is a built‑in `gen_pptx` tool — and that tool isn't there when you run the skill on your own agent. So the skill ships its own: a local CLI (`agents/gen-pptx/`) that drives headless Chromium via Playwright and writes the `.pptx` with PptxGenJS. In Claude Code it runs after a one‑time build (`cd skills/baoyu-design/agents/gen-pptx \u0026\u0026 npm install \u0026\u0026 npx playwright install chromium \u0026\u0026 npm run build`); from then on the agent serves the deck and invokes the CLI for you.\n\n### How gen_pptx works\n\nThe core idea: **don't parse HTML — render it in a real browser, then translate the result into PowerPoint**.\n\n\u003cp align=\"center\"\u003e\u003cimg src=\"assets/gen-pptx-pipeline.svg\" alt=\"gen_pptx export pipeline\" width=\"680\"\u003e\u003c/p\u003e\n\nThe CLI launches a headless Chromium via Playwright and loads the deck as a live web page (which is why it needs an `http://` URL, not `file://`). A capture bundle is injected into the page and exposed as `window.__genpptx`; the Node driver talks to it through `page.evaluate()` — everything that needs the real browser (layout, computed styles, font metrics, image decoding) runs in‑page and returns pure data to Node.\n\nBefore any slides are captured, `setup()` hides UI chrome, applies font substitutions (injecting `@font-face` rules or fetching from Google Fonts), undoes `transform: scale()` wrappers so measurements reflect authored dimensions, waits for `document.fonts.ready`, and collects speaker notes.\n\nThen slides are processed one by one — `showJs` navigates to each slide, a delay lets transitions settle, and images are `.decode()`'d. From here the two modes diverge:\n\n- **Screenshot mode** simply calls `page.screenshot()` at 2× device scale and drops each PNG as a full‑bleed slide image. Pixel‑perfect, but flat.\n- **Editable mode** recursively walks the live DOM, serializing every element into a `{ tag, rect, style, children }` JSON tree with pixel‑precise bounding boxes (text uses `Range.getBoundingClientRect()`). Back in Node, `renderNodeToPptx` translates each node into native PptxGenJS objects: backgrounds and borders become `addShape`, text becomes `addText` with the exact font/size/color from computed styles, images (including rasterized SVGs and canvas snapshots) become `addImage`. Coordinates convert at `px ÷ 96 = inches`, font sizes at `px × 0.75 = points`.\n\nFinally, a validation pass compares captures against the input — djb2‑hashing consecutive slides to flag navigation failures, checking slide dimensions, and verifying speaker‑note counts — and the result is printed as a single JSON line for the agent to read.\n\n---\n\n## Example prompts\n\n- *\"Design 3 hi‑fi variations of a pricing page using the brand in this screenshot.\"*\n- *\"Prototype a working onboarding flow — real state, transitions, form validation.\"*\n- *\"Make a 10‑slide deck from this PRD for an engineering all‑hands.\"*\n- *\"Wireframe a few layout ideas for a mobile expense‑tracker home screen.\"*\n- *\"Recreate the composer UI from this codebase, then export it as standalone HTML.\"*\n- *\"Turn this UI kit `.fig` into a design system, then build a dashboard with it.\"*\n- *\"Build a dashboard using our design system, starting from its analytics screen.\"*\n\nFor best results, **give it design context** — a screenshot, a UI kit, a Figma `.fig` export, or a codebase. Starting from real context is the single biggest lever on quality; the skill will ask for it if you don't provide it.\n\n---\n\n## Credits \u0026 license\n\nThis project repackages **Claude Design**, the design skill by **Anthropic** that powers [claude.ai/design](https://claude.ai/design), so it can run on local agents. It is an independent, community effort and is not affiliated with or endorsed by Anthropic.\n\nRepackaged and maintained by **Jim Liu 宝玉**. Released under the [MIT License](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FJimLiu%2Fbaoyu-design","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FJimLiu%2Fbaoyu-design","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FJimLiu%2Fbaoyu-design/lists"}