ux-extract

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

UX Extract

UX 提取

Exhaustively study a reference web app and produce a reusable pattern library. Goes everywhere, captures everything, then organises it into a document another audit or build can reference.
The inverse of
ux-audit
:
  • Audit asks: does this match a bar?
  • Extract asks: what is the bar?
Audits without extracts implicitly compare to "my memory of other apps" — fragile and inconsistent. Extracts turn that memory into a concrete, navigable artifact. An audit can then say: "Empty state on /app/clients shows no CTA. Reference (claude.ai) shows 3 keyboard shortcuts plus 'New chat' in the same position" instead of "feels a bit sparse".
全面研究参考Web应用并生成可复用的模式库。遍历所有页面,捕获所有信息,然后整理成可供其他审计或开发工作参考的文档。
这是
ux-audit
的反向操作:
  • 审计提出的问题:是否符合标杆?
  • 提取提出的问题:标杆是什么?
没有提取工作的审计会默认将“我对其他应用的记忆”作为对比标准——这种方式既脆弱又不一致。提取工作能将这种模糊的记忆转化为具体、可导航的成果。之后审计就可以明确指出:“/app/clients页面的空状态没有行动召唤按钮。参考应用(claude.ai)在相同位置显示了3个键盘快捷键和‘新建聊天’按钮”,而非笼统地说*“感觉有点空洞”*。

When to use

使用场景

  • Before building a new feature — study how best-in-class apps handle it
  • Benchmarking a build — extract the reference, then audit against it
  • Onboarding designers or engineers — here's what good looks like, concretely
  • Competitor research — document the competitor's UX so you can meaningfully differentiate
  • Refreshing an old app — extract patterns from modern equivalents to guide the update
  • 开发新功能前——研究顶尖应用如何处理同类功能
  • 项目基准测试——先提取参考应用的模式,再以此为基准进行审计
  • 设计师或工程师入职培训——直观展示优秀的UX标准
  • 竞品调研——记录竞品的UX,以便进行有意义的差异化设计
  • 老旧应用翻新——从现代同类应用中提取模式,指导更新工作

Scope and ethics

范围与伦理规范

Before starting, confirm the target is fair game:
  1. Use your own account — don't scrape anything that requires credentials you don't legitimately hold
  2. Respect
    robots.txt
    for unauthenticated crawling
  3. Rate-limit — act like a human user, not a crawler. Pause between pages.
  4. Check ToS — most SaaS Terms of Service permit individual inspection but prohibit automated scraping
  5. Don't redistribute screenshots of a live competitor's app publicly — pattern libraries are internal references
If the target is behind a paywall or requires a trial account, ask the user whether they have legitimate access before proceeding.
开始前,请确认目标应用允许进行此类操作:
  1. 使用自己的账号——不要抓取需要未合法获取的凭证才能访问的内容
  2. 遵守
    robots.txt
    规则
    ——针对无需认证的爬取操作
  3. 限制请求频率——像人类用户一样操作,不要像爬虫。页面间要暂停。
  4. 查看服务条款——大多数SaaS服务条款允许个人查看,但禁止自动化抓取
  5. 不要公开分发——不要公开分享竞品应用的截图——模式库仅供内部参考
如果目标应用需要付费订阅或试用账号,请先询问用户是否拥有合法访问权限再继续。

Setup

准备工作

1. Browser tool

1. 浏览器工具

TargetToolNotes
Authenticated reference (you have an account)Chrome MCPUses your logged-in session
Public reference (marketing pages, docs, public demos)Playwright MCPNo login needed
See ../ux-audit/references/browser-tools.md for commands.
目标场景工具说明
已认证参考应用(你拥有账号)Chrome MCP使用你的已登录会话
公开参考应用(营销页面、文档、公开演示)Playwright MCP无需登录
查看../ux-audit/references/browser-tools.md获取命令说明。

2. Viewport

2. 视口设置

Pin 1440×900 as baseline (MacBook standard). Also capture 768 and 375 for responsive patterns. Don't exceed 2000px wide.
将1440×900设为基准视口(MacBook标准)。同时捕获768和375尺寸的截图以记录响应式模式。宽度不要超过2000px。

2b. Screenshot post-processing

2b. 截图后处理

On Retina Macs, Chrome captures at 2× the logical viewport — a 1440-wide window produces a 2880-wide PNG. Post-process after each batch so the library isn't full of oversized files:
bash
img-process batch ./screenshots --action optimise --max-width 1440
Idempotent — no-op on already-small files. Run at the end of each route's capture, or across the whole
screenshots/
folder at the end of the extract. Playwright MCP users can set
deviceScaleFactor: 1
in the context options and skip this step.
在Retina屏Mac上,Chrome会以逻辑视口2倍的尺寸捕获截图——1440宽的窗口会生成2880宽的PNG图片。每次批量捕获后进行后处理,避免模式库中充满过大的文件:
bash
img-process batch ./screenshots --action optimise --max-width 1440
此操作具有幂等性——对已压缩的文件无影响。可在每条路由捕获完成后运行,或在整个提取工作结束后对
screenshots/
文件夹批量处理。Playwright MCP用户可在上下文选项中设置
deviceScaleFactor: 1
,跳过此步骤。

3. Scope

3. 范围确定

Decide before starting:
  • Whole app — traverse everything reachable (can take hours, produces a comprehensive library)
  • Feature area — one section ("the settings flow", "the dashboard", "the billing flow")
  • Pattern class — just empty states, just error handling, just onboarding
Narrower scope produces tighter, more useful libraries. "Whole app" is only worth it for apps you'll be building a direct analogue of.
开始前明确提取范围:
  • 整个应用——遍历所有可访问的内容(可能需要数小时,生成全面的模式库)
  • 功能区域——仅针对某一板块(“设置流程”、“仪表盘”、“账单流程”)
  • 模式类别——仅提取空状态、错误处理或引导流程等特定类别
范围越窄,生成的模式库越精炼实用。只有当你要开发直接竞品时,“整个应用”的范围才值得选择。

4. Focus lens (optional)

4. 聚焦视角(可选)

Optional bias for capture. Examples:
  • "Focus on patterns for data-heavy lists" — prioritise table, filter, search, virtualisation screenshots
  • "Focus on onboarding and empty states" — prioritise first-run flows and zero-data views
  • "Focus on permission boundaries" — log in as multiple roles, document the differences
If no focus is given, capture broadly.
可为捕获工作设置偏向性。示例:
  • “聚焦数据密集型列表的模式”——优先捕获表格、筛选、搜索、虚拟化等相关截图
  • “聚焦引导流程和空状态”——优先捕获首次运行流程和零数据视图
  • “聚焦权限边界”——以不同角色登录,记录差异
如果未指定聚焦方向,则进行全面捕获。

Discovery

发现阶段

Sitemap crawl

站点地图爬取

Build the full route inventory:
  1. Public sitemap — check
    /sitemap.xml
    ,
    /robots.txt
    for discoverability
  2. Nav crawl — click through every section visible in the top nav, sidebar, footer
  3. In-app discovery — once inside, note every link that appears (breadcrumbs, tabs, contextual menus)
  4. URL inspection — some apps have useful patterns in
    /settings
    ,
    /preferences
    ,
    /admin
    that aren't in the main nav
Record each route with its purpose:
/settings/billing — subscription plan, payment method, invoice history
.
构建完整的路由清单:
  1. 公开站点地图——检查
    /sitemap.xml
    /robots.txt
    以发现可访问的路由
  2. 导航栏爬取——点击顶部导航、侧边栏、页脚中可见的所有板块
  3. 应用内发现——进入应用后,记录出现的所有链接(面包屑、标签页、上下文菜单)
  4. URL检查——部分应用的
    /settings
    /preferences
    /admin
    等路径中有未在主导航显示的实用模式
记录每条路由及其用途:
/settings/billing — 订阅计划、支付方式、发票历史

Pattern inventory

模式清单

Before deep-capture, scan the app once and list pattern types you'll document. Typical categories:
  • Wayfinding (nav, breadcrumbs, current-location, back)
  • Lists & tables (row, hover, action reveal, selection, sort, filter, paginate, empty)
  • Forms (label, validation, error, required, inline help)
  • Modals & dialogs (trigger, focus, escape, scroll, confirm)
  • Feedback (toast, inline, progress, loading, saved)
  • Onboarding & empty states (first-run, zero-data CTA, guided tour)
  • Permissions & roles (restricted views, denied-access, role indicators)
  • Copy & microcopy (buttons, headings, errors, placeholders, tooltips)
  • Keyboard (shortcut sheet, focus, tab order, command palette)
  • Motion (transition, reveal, loading, gesture)
  • Responsive (breakpoints, mobile-specific: bottom sheet, tabs, swipe)
Not every app uses every category. Mark which apply.
在深度捕获前,先快速浏览应用,列出要记录的模式类型。典型类别:
  • 导航(导航栏、面包屑、当前位置、返回按钮)
  • 列表与表格(行、悬停、操作显示、选择、排序、筛选、分页、空状态)
  • 表单(标签、验证、错误、必填项、内联帮助)
  • 模态框与对话框(触发方式、焦点、ESC关闭、滚动、确认)
  • 反馈(提示框、内联提示、进度条、加载状态、保存确认)
  • 引导流程与空状态(首次运行、零数据行动召唤、引导 tour)
  • 权限与角色(受限视图、访问拒绝、角色标识)
  • 文案与微文案(按钮、标题、错误提示、占位符、工具提示)
  • 键盘操作(快捷键面板、焦点、Tab顺序、命令面板)
  • 动效(过渡、显示、加载、手势)
  • 响应式设计(断点、移动端专属:底部面板、标签页、滑动操作)
并非所有应用都会用到所有类别,标记出适用的类别即可。

Capture Phase

捕获阶段

For each route, capture exhaustively. Screenshots are cheap — err toward more.
针对每条路由进行全面捕获。截图成本低,宁多勿少。

Screenshot all states

捕获所有状态的截图

Per meaningful element, capture:
StateTrigger
Defaultpage loaded, nothing interacted with
Hovermouse over a button, row, nav item
Focuskeyboard-focused via Tab
Activebutton mid-click, input being typed into
Opendropdown open, menu expanded
Closeddropdown closed, menu collapsed
Expandedaccordion open, detail panel expanded
Collapsedaccordion closed
Selectedcheckbox ticked, row selected, tab active
Loadingskeleton, spinner, pending state
Emptylist with no items
Populatedlist with many items
Errorinline, toast, or full-page error
Successpost-action confirmation
See references/capture-checklist.md for the full per-pattern checklist.
针对每个有意义的元素,捕获以下状态:
状态触发方式
默认状态页面加载完成,未进行任何交互
悬停状态鼠标悬停在按钮、行、导航项上
焦点状态通过Tab键使元素获得键盘焦点
激活状态按钮点击中、输入框正在输入
展开状态下拉菜单打开、菜单展开
收起状态下拉菜单关闭、菜单折叠
展开状态手风琴面板打开、详情面板展开
收起状态手风琴面板关闭
选中状态复选框勾选、行选中、标签页激活
加载状态骨架屏、加载 spinner、等待状态
空状态列表无内容
填充状态列表包含大量内容
错误状态内联错误、提示框错误或全屏错误
成功状态操作后的确认状态
查看references/capture-checklist.md获取完整的逐模式捕获清单。

Capture copy verbatim

原文复制文案

Copy the text exactly, including punctuation, ellipses, and tone:
  • Button labels:
    "Start chat"
    ,
    "Upgrade plan"
    ,
    "Delete forever"
  • Empty states: "No conversations yet. Start one to see it here."
  • Error messages: "We couldn't save that change. Try again, or contact support if it keeps happening."
  • Confirmation dialogs: "Delete this project? All 14 tasks and 3 members will be removed. This cannot be undone."
  • Placeholder text:
    "e.g. smith@company.com"
  • Tooltips:
    "Pressing Cmd+K opens this from anywhere"
Raw copy is gold for writers and informs your app's voice.
精确复制文本内容,包括标点、省略号和语气:
  • 按钮标签:
    "Start chat"
    "Upgrade plan"
    "Delete forever"
  • 空状态文案:"No conversations yet. Start one to see it here."
  • 错误提示:"We couldn't save that change. Try again, or contact support if it keeps happening."
  • 确认对话框:"Delete this project? All 14 tasks and 3 members will be removed. This cannot be undone."
  • 占位符文本:
    "e.g. smith@company.com"
  • 工具提示:
    "Pressing Cmd+K opens this from anywhere"
原始文案对文案撰写人员来说非常宝贵,还能为你的应用语气提供参考。

Capture interactions

捕获交互模式

For each interactive element, note:
  • Trigger: click / hover / keyboard / long-press / drag
  • Target: what it affects (opens modal, filters list, navigates)
  • Feedback: immediate visual response? delayed confirmation?
  • Reversibility: undoable? destructive?
针对每个交互元素,记录:
  • 触发方式:点击 / 悬停 / 键盘操作 / 长按 / 拖拽
  • 作用对象:影响的内容(打开模态框、筛选列表、导航跳转)
  • 反馈:是否有即时视觉响应?是否有延迟确认?
  • 可逆性:可撤销?具有破坏性?

Capture keyboard patterns

捕获键盘操作模式

  • Shortcut sheet: is there a
    ?
    or
    Cmd+/
    that reveals the shortcut list? Capture it.
  • Command palette:
    Cmd+K
    or similar? Capture the palette open, searching, a result selected, and an action executed.
  • Focus indicators: tab through the page, note the ring style, colour, thickness
  • Tab order: is it logical? Any unexpected jumps?
  • 快捷键面板:是否有
    ?
    Cmd+/
    快捷键可显示快捷键列表?捕获该面板。
  • 命令面板:是否有
    Cmd+K
    或类似快捷键?捕获命令面板打开、搜索、选中结果、执行操作的状态。
  • 焦点指示器:按Tab键遍历页面,记录焦点环的样式、颜色、厚度
  • Tab顺序:是否符合逻辑?有无意外跳转?

Capture responsive treatments

捕获响应式处理

For each route, screenshot at 1440, 768, 375. Note what changes, not just "it works":
  • Navigation moves from sidebar to hamburger at [breakpoint]
  • Table collapses to stacked cards at [breakpoint]
  • Modal becomes full-screen at [breakpoint]
  • Multi-column form becomes single-column at [breakpoint]
针对每条路由,分别在1440、768、375尺寸下截图。记录具体变化,而非仅说“适配正常”:
  • 导航栏在[断点]处从侧边栏变为汉堡菜单
  • 表格在[断点]处从多列变为堆叠卡片
  • 模态框在[断点]处变为全屏显示
  • 多列表单在[断点]处变为单列

Capture motion

捕获动效

Record a GIF (Chrome MCP's
gif_creator
) of any animation worth documenting:
  • Page transitions
  • Modal enter/exit
  • List item enter/exit
  • Loading → loaded
  • Success animations (confetti, checkmarks)
  • Drag-and-drop feedback
One 3-second GIF is worth a paragraph of description.
记录所有值得记录的动画为GIF(使用Chrome MCP的
gif_creator
):
  • 页面过渡
  • 模态框进入/退出
  • 列表项进入/退出
  • 加载→完成
  • 成功动效(彩屑、对勾)
  • 拖拽反馈
一段3秒的GIF胜过一段描述文字。

Dedup Phase

去重阶段

After capture, many patterns will appear on multiple pages. Deduplicate:
  • Same row pattern on 5 list pages → one "list row" entry with a note "used on: /clients, /projects, /invoices, /reports, /team"
  • Same empty state layout with different copy → one "empty state" entry with copy variants listed
  • Same modal chrome → one "modal" entry; specific modals listed as usages
Keep two counts per pattern:
  • Occurrences — how many times this pattern appears
  • Variants — meaningful differences (icon vs no icon, small vs large, with CTA vs without)
A pattern that appears once is rarely worth documenting unless it's unique and notable.
捕获完成后,许多模式会在多个页面重复出现。进行去重:
  • 5个列表页面使用相同的行模式→保留一个“列表行”条目,并标注*“应用于:/clients、/projects、/invoices、/reports、/team”*
  • 空状态布局相同但文案不同→保留一个“空状态”条目,并列出不同的文案变体
  • 模态框框架相同→保留一个“模态框”条目;具体模态框作为使用案例列出
为每个模式保留两个统计数据:
  • 出现次数——该模式出现的次数
  • 变体数量——有意义的差异(带图标/无图标、小尺寸/大尺寸、带行动召唤/无行动召唤)
仅出现一次的模式除非独特且值得关注,否则无需记录。

Output

输出结果

Write to
docs/ux-extracts/<app-name>/
(or
.jez/artifacts/ux-extracts/<app-name>/
if that directory exists):
docs/ux-extracts/claude-ai/
├── pattern-library.md      ← main document
├── copy-corpus.md          ← optional, raw copy by page (for writers)
└── screenshots/
    ├── 001-home-default.png
    ├── 002-home-hover-cta.png
    ├── 003-new-chat-empty.png
    └── ...
See references/pattern-library-template.md for the output structure.
The pattern library should be:
  • Navigable — table of contents at the top, jump links to every section
  • Cross-referenced — "see also: Modal Chrome"
  • Screenshot-dense — every claim backed by a referenced screenshot
  • Copy-accurate — verbatim text in code blocks or blockquotes, not paraphrased
  • Honest — note what's missing or weak as well as what's good. A reference library isn't gospel.
将文件写入
docs/ux-extracts/<app-name>/
(如果
.jez/artifacts/ux-extracts/<app-name>/
目录存在,则写入该目录):
docs/ux-extracts/claude-ai/
├── pattern-library.md      ← 主文档
├── copy-corpus.md          ← 可选,按页面整理的原始文案(供文案人员使用)
└── screenshots/
    ├── 001-home-default.png
    ├── 002-home-hover-cta.png
    ├── 003-new-chat-empty.png
    └── ...
查看references/pattern-library-template.md获取输出结构模板。
模式库应具备以下特点:
  • 可导航——顶部有目录,每个板块都有跳转链接
  • 交叉引用——“另见:模态框框架
  • 截图丰富——每个结论都有对应的截图作为支撑
  • 文案准确——原文文案放在代码块或引用块中,不进行意译
  • 客观诚实——既要记录优点,也要记录缺失或不足的地方。参考库并非绝对标准。

How ux-audit consumes this

ux-audit如何使用此成果

ux-audit
checks for pattern libraries at
.jez/artifacts/ux-extracts/<ref>/pattern-library.md
or
docs/ux-extracts/<ref>/pattern-library.md
. If found, it uses them as the bar for comparison. Audit findings can then cite specific patterns:
"Empty state on /app/clients has no explanatory copy and no CTA. Reference library [claude.ai § Empty States] shows CTA + 2 example prompts in the same position."
No integration is required beyond producing the library in the expected path.
ux-audit
会在
.jez/artifacts/ux-extracts/<ref>/pattern-library.md
docs/ux-extracts/<ref>/pattern-library.md
路径下查找模式库。如果找到,会将其作为对比基准。审计结果可以引用具体模式:
“/app/clients页面的空状态没有说明文案和行动召唤按钮。参考库[claude.ai § 空状态]显示在相同位置有行动召唤按钮+2个示例提示。”
无需额外集成,只需将模式库放在预期路径即可。

Autonomy

自主操作规则

  • Just do it: Navigate, screenshot, copy text, inject JavaScript to read computed styles, download static assets (logo, icons) for reference
  • Ask first: Any login that requires credentials the user hasn't authorised you to use, any scraping of a site where ToS or rate limiting is ambiguous
  • Stop and confirm: If the target has a login wall and you don't have clear authorisation, stop and confirm before proceeding
  • 直接执行:导航、截图、复制文本、注入JavaScript读取计算样式、下载静态资源(Logo、图标)作为参考
  • 先询问:任何需要用户未授权的凭证才能登录的操作,或服务条款、请求频率限制不明确的站点爬取操作
  • 停止并确认:如果目标应用有登录墙且你没有明确授权,请停止操作并确认后再继续

Reference files

参考文件

WhenRead
Building the pattern-library.md outputreferences/pattern-library-template.md
Per-pattern capture checklist (what to screenshot, what to note)references/capture-checklist.md
Browser tool commands../ux-audit/references/browser-tools.md
使用场景参考文档
构建pattern-library.md输出文件references/pattern-library-template.md
逐模式捕获清单(需要截图和记录的内容)references/capture-checklist.md
浏览器工具命令../ux-audit/references/browser-tools.md

Tips

小贴士

  • Screenshots are cheap — capture generously. Easier to drop a screenshot from the library than to rerun the extract to get one.
  • Capture copy the moment you see it — don't plan to come back; come back and it'll be behind a different state.
  • Note what's absent — if an app has no keyboard shortcut sheet, that's a pattern decision worth documenting too.
  • Separate observation from evaluation — extract records what exists, not whether it's good. Opinions belong in an audit, not an extract.
  • Extracts decay — apps change. Timestamp the library, link to the date on archive.org if possible, plan to re-extract every 6–12 months for apps you compare against often.
  • Build incrementally — open the library file at the start, append as you go. Don't try to structure it all at the end.
  • 截图成本低——尽量多捕获。从库中删除多余截图比重新提取要容易得多。
  • 看到文案立即复制——不要计划稍后回来复制;等你回来时,它可能处于不同状态。
  • 记录缺失的内容——如果应用没有快捷键面板,这也是一个值得记录的模式决策。
  • 区分观察与评价——提取工作记录实际存在的内容,而非判断其好坏。评价属于审计工作,而非提取工作。
  • 模式库会过时——应用会更新。为库添加时间戳,尽可能链接到archive.org上的对应日期,对于经常对比的应用,计划每6-12个月重新提取一次。
  • 增量构建——开始时就打开库文件,边捕获边追加内容。不要等到最后再进行结构化整理。