Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 4 additions & 11 deletions starter/.agents/context-templates/BROWSER-VALIDATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,9 @@ alone does not prove application bootstrap or route readiness.

## Canvas host and identifiers

Find the intended Copilot host, handle reuse and page-identifier contracts.
Record where runtime identifiers come from, not universal fixed IDs. Runtime
discovery is authoritative for current schemas and actions. Configuration is
not availability. Missing canvas support does not authorize silent substitution.
Find the intended Copilot host, handle reuse and page-identifier contracts. Record where runtime identifiers come from, not universal fixed IDs. Runtime discovery is authoritative for current schemas and actions. Inspect a schema before the first required operation, then reuse it only for the same provider and session. Rediscover after provider reload/reconnect, a schema mismatch or an explicit request to check changed capabilities; a timeout alone does not invalidate it.

Configuration is not availability. Missing canvas support does not authorize silent substitution.

Keep `canvasId` and `instanceId` distinct. Actions addressed by the panel handle
need no separate page acquisition. Record separate page identifiers only when
Expand Down Expand Up @@ -105,13 +104,7 @@ Identify what the run may close without disturbing user-owned sessions.
Link lifecycle policy in [REPOSITORY.md](./REPOSITORY.md). Do not install tools,
repair daemons, create auth or start undeclared infrastructure during validation.

Allow one bounded same-panel recovery attempt: check documented readiness,
refocus the same owned instance, rediscover schemas, and retry inspection once
only if required runtime identifiers are available. Do not loop or open duplicate
panels. A timed-out interaction may already have succeeded; inspect its resulting
state before considering another action. Do not restart a healthy server because
its canvas timed out. A separate MCP browser starts with a fresh read of the
authorized route, not a replay or an assumption of shared state.
Allow one bounded same-panel recovery attempt: check documented readiness, refocus the same owned instance, and retry inspection once only if required runtime identifiers are available. Reuse the current schema unless its invalidation condition applies. Do not loop or open duplicate panels. A timed-out interaction may already have succeeded; inspect its resulting state before considering another action. Do not restart a healthy server because its canvas timed out. A separate MCP browser starts with a fresh read of the authorized route, not a replay or an assumption of shared state.

If MCP is unavailable, report the actual blocker, repository trust/fresh-session
setup and remaining checks as unverified. Do not silently install browser engines.
Expand Down
3 changes: 1 addition & 2 deletions starter/.agents/context-templates/DESIGN-SYSTEM.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ and tasks belong in [RESPONSIVE-DESIGN.md](./RESPONSIVE-DESIGN.md).

## Navigation primitives

Distinguish tabs, breadcrumbs, side navigation, and action menus. Verify link
versus button semantics, selection and focus behavior. Product owns destinations.
Distinguish tabs, breadcrumbs, side navigation, and action menus. Verify link versus button semantics, selection and focus behavior. Product owns destinations. For a standalone link that preserves existing navigation structure, identify the semantic link guidance and any shared navigation rules that apply without requiring research into unrelated composite patterns. Read composition-specific guidance when a navigation pattern is introduced or changed.

## Forms

Expand Down
22 changes: 9 additions & 13 deletions starter/.agents/skills/browser-canvas-validation/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,30 +27,26 @@ If a required companion or sibling skill is missing, stop and name its path
before checks. Do not auto-install dependencies.

Select the first existing root, `.agents/context/`, then `.github/contexts/`.
Read `PRODUCT-DESIGN.md`, `REPOSITORY.md` and `BROWSER-VALIDATION.md`
directly there. Read `DESIGN-SYSTEM.md` for component-specific assertions.
No manifest or canvas-specific pack file is required. Never mix roots.
Read the applicable `BROWSER-VALIDATION.md` sections and owner topics for target/readiness, canvas identifiers, safe state and recovery. In the shared template, these are `Target and readiness`, `Canvas host and identifiers`, `Sessions, safe state and artifacts`, and `Recovery and cleanup`. Read `Configured Playwright MCP fallback` or `Existing CLI adapter` only when that fallback is needed.

Read the applicable `REPOSITORY.md` section for the target (`Where UI lives` in the shared template), `Commands` when a command is needed, and `Constraints` for relevant permissions or lifecycle. Follow applicable owner links. If a consumer uses different headings, select the equivalent sections by owner rather than reading the entire file.

Read `PRODUCT-DESIGN.md` when expected product behavior is unresolved, when assessing scenario behavior or fidelity, or when checking forms, persistence, destructive actions or externally visible changes. A fully specified, read-only route or menu check can use the request as its expected outcome. Read `DESIGN-SYSTEM.md` for component-specific assertions, `ACCESSIBILITY.md` for accessibility checks and `RESPONSIVE-DESIGN.md` for responsive checks. No manifest or canvas-specific pack file is required. Never mix roots.

Missing required context stops validation. Report the selected root/file and
offer `setup-skills` to author or refresh context under the shared
resolution rules. Do not invoke it
automatically. Never read drafts as active context. Follow relevant owner links
and evidence anchors, preserve `proposed-default` labels and disclose conflicts.
Read current owner guidance on every run. Product context owns scenarios and
state policy. Browser context owns target URL, server, routes and recovery.
automatically. Never read drafts as active context. Follow relevant owner links and evidence anchors, preserve `proposed-default` labels and disclose conflicts. Read the complete applicable owner sections, not unrelated sections or topics. Product context owns scenarios and state policy. Browser context owns target URL, server, routes and recovery.

Use only permitted sources. Do not research remotely or broaden exclusions
during validation. Request explicit refresh if required documentation is stale
or missing. A document with gaps does not prove runtime capabilities.

## Runtime contract

Discover the available canvas types. If `browser` or the necessary canvas tools
are absent, report the missing runtime and stop this path, not a pass or a silent
backend substitution. Use the explicit configured MCP handoff in
[WORKFLOW.md](./WORKFLOW.md) if available. Call `list_canvas_capabilities` for the actual browser
type before opening or acting. Use its advertised open input and action schemas.
No frozen action list in this skill overrides the runtime.
Do not discover canvas capabilities for source-only tasks. For rendered checks, identify the browser canvas and inspect its actual schemas before the first required operation. Reuse a schema already discovered for the same provider in this session. Rediscover only after provider reload/reconnect, a schema mismatch or an explicit request to check for changed capabilities; a timeout alone does not invalidate it. Never carry schemas across providers or sessions.

If the browser canvas or required tools are absent, report the blocker and use only the explicit configured MCP handoff in [WORKFLOW.md](./WORKFLOW.md) when applicable. Use the advertised open input and action schemas; no frozen action list overrides the runtime.

Keep the canvas type and caller-chosen `instanceId` handle distinct.
Address the panel with that handle through `invoke_canvas_action`. If the
Expand Down
25 changes: 8 additions & 17 deletions starter/.agents/skills/browser-canvas-validation/WORKFLOW.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@

## Browser selection

Use the browser canvas first for every agent-driven rendered check, interaction
test, screenshot and visual, responsive or accessibility review. Discover its
current capabilities rather than assuming an earlier host's limitations.
The Replica prototype canvas remains the preview and publishing surface;
discover the separate browser canvas for page inspection.
Use the browser canvas first for every agent-driven rendered check, interaction test, screenshot and visual, responsive or accessibility review. Discover its current capabilities before the first required operation, then reuse the same-provider schema in this session until it is invalidated under [the runtime contract](./SKILL.md#runtime-contract). Source-only work does not enter this workflow.

The Replica prototype canvas remains the preview and publishing surface; use the separate browser canvas for page inspection.

Use configured Playwright MCP only when the canvas is unavailable for the
required check: absent runtime, absent action, unsatisfied required identifier
Expand All @@ -26,18 +24,13 @@ derive branch instance IDs from another repository's scripts. A missing running
target is a blocker unless starting the declared server is already authorized.
Never start a second infrastructure project to supply validation.

Read the requested outcome and product-design scenario/state owner. Establish
expected results before interacting. Use the smallest connected flow that proves
the request. Invalid-input submission, destination and reload-persistence checks
apply when the requested behavior needs them and test mutations are authorized.
Otherwise report those assertions untested. Do not submit real data to prove a
read-only audit, or treat a disabled button alone as proof of safe persistence.
Read the requested outcome and establish expected results before interacting. Read product-design guidance when required by the [context requirements](./SKILL.md#required-reads-and-dependencies). Use the smallest connected flow that proves the request. Invalid-input submission, destination and reload-persistence checks apply when the requested behavior needs them and test mutations are authorized. Otherwise report those assertions untested. Do not submit real data to prove a read-only audit, or treat a disabled button alone as proof of safe persistence.

## Discover, read, act, assert

Inspect browser canvas capabilities and satisfy the actual schemas as described
in [SKILL.md](./SKILL.md). Call `open_canvas` with the declared type and a session
handle. Use `invoke_canvas_action` with that same handle to address the instance.
Use browser canvas capabilities and schemas as described in [SKILL.md](./SKILL.md).
Call `open_canvas` with the declared type and a session handle. Use
`invoke_canvas_action` with that same handle to address the instance.
Action inputs follow the discovered schema. When an action takes only the panel
handle and its advertised inputs, invoke it directly without page acquisition.
Supply a separate page identifier only if that schema requires one and the
Expand Down Expand Up @@ -76,9 +69,7 @@ For follow-up changes reuse the correct session preview, assert changed content
and relevant behavior. If content is missing, use supported reload and re-read
once before reporting stale rendering.

A read timeout can be retried once after checking the declared readiness signal.
Refocus the same owned panel, rediscover capabilities and retry inspection only
with valid required identifiers. Do not loop or create duplicate panels.
A read timeout can be retried once after checking the declared readiness signal. Refocus the same owned panel and retry inspection only with valid required identifiers and the existing schema. Rediscover only if the runtime contract's invalidation condition applies, not because a read timed out. Do not loop or create duplicate panels.
For further failures use only the repository's authorized recovery procedure.
Do not replay a timed-out state-changing action, its effect may already have
occurred. Inspect resulting state first. Restarting servers, installing packages
Expand Down
8 changes: 6 additions & 2 deletions starter/.agents/skills/create-prototype/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ prototype" is iteration.
| ------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- |
| Clear new build, such as "build an offline inventory prototype" | [create](./workflows/create.md) |
| Change to an existing prototype, such as "add filtering to this page" | [iterate](./workflows/iterate.md) |
| Candidate narrow edit to an existing prototype | [iterate](./workflows/iterate.md), then apply the root instructions' narrow-edit path |
| Consequential missing information, including an unresolved target or create-versus-iterate choice | [clarify](./workflows/clarify.md), then the selected build or iteration workflow |
| Behavior-preserving test-only work | Use the root instructions' task-scope guidance; do not load a prototype workflow |
| Unrelated task or routine command | Stop using this skill and continue the original task |

Load only the selected workflow, not all companions as a required-read bundle.
Expand All @@ -40,8 +42,10 @@ different destination. A reference URL is not permission to fork, duplicate,
publish, delete or activate anything. Approved references are 1:1 requirements
except for the requested delta, not design inspiration.

The selected workflow reads the shared
[authoring reference](./references/authoring.md) before implementation.
The selected create or normal iteration workflow reads the shared
[authoring reference](./references/authoring.md) before implementation. A
candidate narrow edit follows the iteration workflow's classification step and,
when eligible, skips that reference and its context dependencies.
It owns context resolution, design evidence, data boundaries and completion.
It does not load another workflow. Install `product-design`, `setup-skills`
and the `context-templates` library alongside this skill.
Expand Down
24 changes: 15 additions & 9 deletions starter/.agents/skills/create-prototype/references/authoring.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,17 @@ This reference does not dispatch or load workflow companions.

Read [context resolution](../../product-design/references/context-resolution.md).
Select the first existing root, `.agents/context/`, then `.github/contexts/`.
Read `DESIGN-SYSTEM.md`, `PRODUCT-DESIGN.md`, `REPOSITORY.md` and
`BROWSER-VALIDATION.md` directly there. No manifest or prototype-specific pack
file is required. Never mix roots or read drafts as active context.
Read `SEED-DATA.md` for new or changed fixtures, `RESPONSIVE-DESIGN.md` for
responsive decisions and `ACCESSIBILITY.md` for product accessibility environments.
For application work, read the applicable sections of these owners and follow relevant topic links:

- `REPOSITORY.md`: `Where UI lives`, `Commands` and `Constraints`.
- `DESIGN-SYSTEM.md`: shared defaults and task-relevant sections before component, token or pattern decisions.
- `PRODUCT-DESIGN.md`: when creating or changing behavior, states, flows, messaging or product decisions.
- `BROWSER-VALIDATION.md`: before starting a preview or performing rendered validation.
- `SEED-DATA.md`: for new or changed fixtures; `RESPONSIVE-DESIGN.md`: for responsive decisions; `ACCESSIBILITY.md`: for product accessibility environments.

If a consumer uses different headings, select the equivalent sections by owner rather than reading the entire file.

Read only relevant sections and directly linked owner topics, retaining shared authority, safety rules and limitations. Use the resolution rules to determine when an owner topic applies; do not read every topic as a checklist. A missing conditional document blocks only the decision that needs it. No manifest or prototype-specific pack file is required. Never mix context roots or read drafts as active context.

Read shared defaults, safety rules, relevant headings and limitations.
Follow relevant owner links, evidence anchors and local documentation indexes
Expand All @@ -29,10 +35,7 @@ installed files, including this reference or
[product-design](../../product-design/SKILL.md), stop affected work with the
exact path. Do not install dependencies or invent fallback policy.

Use product-design's workflow for relevant UI decisions and convert its
context-backed behavior into implementation checks. Unrelated known gaps do
not block supported work. Consequential contradictions or missing rules remain
unresolved and return to the selected workflow's conditional clarification.
Use product-design's workflow for relevant UI decisions and convert its context-backed behavior into implementation checks. Reuse unchanged decisions already established for the task rather than repeating a design pass. Select additional audit or review skills only when the user requests them or their applicable skill/repository instructions require them. Loading a skill is not evidence that its review was completed; preserve required accessibility checks and visual-approval boundaries, and report incomplete reviews as incomplete. Unrelated known gaps do not block supported work. Consequential contradictions or missing rules remain unresolved and return to the selected workflow's conditional clarification.

## Task inputs, not setup requirements

Expand Down Expand Up @@ -78,6 +81,7 @@ named page or a catalog example is the target implementation.

Use the active design-system context's declared evidence sources, installed
APIs and fallback rules under context resolution's applied-guidance contract.
Reuse an established composition when it satisfies the requested behavior. Use a consumer-declared recipe, catalogue or research tool only when a specific composition or requirement remains unresolved; do not repeat lookup for general reassurance.
When a named gap requires source inspection, read full relevant component,
token and pattern sections, including accessibility requirements, not whole catalogues.
Local documentation is sufficient when the context declares it. For MCP
Expand All @@ -96,6 +100,8 @@ verify their names, semantic roles and applicable constraints. Do not guess
from a token name or substitute another provider. Use existing supported
compositions rather than recreating primitives.

For a JavaScript package, resolve a public import from its package metadata: follow the applicable `exports` condition, including `types` when checking declarations, or its declared `types`, `typings` or package entry. Follow re-exports to the component definition. Package metadata and the installed version are authoritative; do not guess a component path from its name. Use the consumer's documented resolver when one exists. Other ecosystems use their declared package and API discovery mechanisms.

Stop API discovery once the selected import, composition, required props, states,
narrow behavior and keyboard/focus contract are established for this task.
Evidence may combine approved guidance and installed source; implementation
Expand Down
Loading
Loading