一键导入
critic-perf-budget
Critic that forces every behavior to declare explicit performance thresholds (TTI, p95 latency, error rate). Invoked by contract-verify.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Critic that forces every behavior to declare explicit performance thresholds (TTI, p95 latency, error rate). Invoked by contract-verify.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
The PM-side readiness gate — "airport security for PRDs." A PM (or anyone) gives a PRD as any source — JIRA / Linear / Notion / Confluence / Google Doc / Slack link / GitHub issue / Figma URL, pasted text, an image, or a plain description — and the agent scores it against the Definition of Ready, surfaces the blockers the PM can fix themselves in plain language, and (when ready) mints a tamper-evident gate code + a clean hand-off for dev. Runs identically in Claude Code and Cowork. Use when the user says "ready check", "is this PRD ready", "check my PRD before dev", "gate this requirement", or invokes `/ready-check <source>` / `/ready <source>`. This is Level 1; the dev-side deep pass is `/contract pickup`.
Turn a Large contract into a dependency-ordered sequence of Small/Medium child contracts, with risky parts (migrations, auth) flagged as human-led. Use when a contract is sized Large and the user says "decompose", "break this down", "split this epic", or invokes `/contract decompose <ID>`. Large isn't refused — it's made tractable.
Author a new Manifest contract from a rough idea, a one-liner, OR a link to an existing source of truth — JIRA ticket, Linear issue, Notion page, Confluence doc, GitHub issue, or Figma file. Use when the user says "new contract", "draft PRD", "spec out a feature", "pull contract from this JIRA ticket", or invokes `/contract new` with either prose or a URL. Pre-fills as much of the contract as possible from the source, then asks the user only what's still missing.
The canonical Spec entry for Manifest. Dev gives any source — JIRA / Linear / Notion / Confluence / Google Doc / Slack message / GitHub issue / Figma URL, pasted text, an image, or a free-form description — and the agent does the code archaeology, drafts the contract, runs the critics + a Figma design audit inline, and sorts every gap into three buckets (auto-fill from code, dev decides, PM must answer). PM stays in their normal tool (JIRA comment, Slack DM); they never have to touch Manifest. Use when the user says "pick up this PRD", "start on this ticket", "spec out this feature", "I got a doc from PM", or invokes `/contract pickup <source>` / `/pickup <source>`. Replaces the older `/contract new` → `/contract verify` two-step flow with a single conversational pass.
Freeze a verified contract into an immutable revision and start the SLA timer. Use when the user says "promote contract", "ship this PRD", "start the pipeline", or invokes `/contract promote <ID>`. Creates a JIRA epic, opens a tracking issue, kicks off implementation.
Implement a promoted contract — write code in the target repo's stack, generate tests in that stack's idiom, iterate until they pass, open the PR. Also runs in fix-mode (review→fix loop) to address open PR-review/verify-pr findings on an existing PR. Stack-agnostic: works for web (React/Next/Vue/...), mobile (Flutter/Swift/Kotlin/RN), and backend (Node/Python/Go/...). Use when the user says "implement contract", or in CI when a PR comment matches `@claude /implement <ID>` or `@claude /fix-pr <ID>`.
基于 SOC 职业分类
| name | critic-perf-budget |
| description | Critic that forces every behavior to declare explicit performance thresholds (TTI, p95 latency, error rate). Invoked by contract-verify. |
Protocol: Follow
reference/CRITIC-RULES.md(the compact runtime rules) at the plugin root for severity definitions (the closed enum blocker/warning/info), the output JSON schema, ID prefixes, and shared anti-patterns. This skill defines only WHAT to look for. Do not invent severities like "high"/"medium" — the validator rejects them. Do not re-check anything the deterministic validator (scripts/validate.mjs) already covers; add the judgment layer on top.
A feature without a perf budget can't fail performance review — by definition. This critic prevents that loophole.
Gating is contextual + configurable (handled by the validator, not you). Field presence is governed by
conventions.perfBudget/ the contract'sperfBudgetPolicy:required(blocker),warn(warning — the default), oroff. When checked, one relevant numeric field is enough (ttiMs for UI, p95LatencyMs for a network call). Don't emit a presence finding the validator already handles — your job is the judgment layer: are the declared budgets realistic for the platform, and do they cover the behavior's real hot path?
perfBudgetEach ### B<N> must declare:
- perfBudget:
ttiMs: <integer> # Time to Interactive for the screen
p95LatencyMs: <integer> # backend response time
errorRatePct: <number> # max acceptable error rate %
Missing any field → blocker.
If any field is TBD or a string, emit a blocker with a suggested
default based on the behavior type:
If the contract's platforms includes mobile and the perf budget assumes
desktop-class network (tti ≤ 500ms), flag as warning — mobile p95
network is generally 1500ms+ for cold loads.
If a success metric implies a certain UX speed (e.g., "X% of users complete X within Y seconds"), the per-behavior budgets must total under Y. Flag inconsistencies.
The behavior's instrumentation should let the launch-report skill
measure these budgets after ship. Cross-check that the events fire at
the right point in the flow to capture the budgeted timing.
If the behavior measures tti but the event fires before render
completes, flag as warning — the data will lie.
Same JSON array shape as other critics.