一键导入
task-workflow
Canonical workflow for a task. Read and follow strictly end to end while working on the task.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Canonical workflow for a task. Read and follow strictly end to end while working on the task.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Primary Playwright governance skill for sandbox browser verification and deterministic end-to-end authoring or rewrite work.
Persistent browser interaction through a normal Node.js Playwright script for fast iterative web UI debugging.
This skill is strict implementation instruction, not advisory reference text. The skill treats the HTML as discovery-only input, forces interactive Playwright route/state capture, then moves through scored gates for source acceptance, implementation planning, authored UI reproduction, implementation integrity, visual verification, and adversarial proof before signoff.
Strict frontend design guardrails for building modern, minimal-visual-noise, airy, non-generic app UIs. Use whenever creating or changing frontend UI, React components, shadcn/ui themes, Tailwind styles, app layouts, or first-version product screens. This skill complements vertical/domain skills like CPQ, CRM, and similar app builders: follow the selected domain skill's workflow and layout requirements, then enforce this skill's shared visual rules for brand-aware theming, generous spacing, typography, contrast, roundedness, shadows, surface hierarchy, cardless defaults, no-sidebar defaults, and anti-pattern avoidance.
Use this skill for Customware existing-project migration tasks that move uploaded customer apps from other builders into the standard Customware stack while preserving the source product's routes, workflows, UI, UX, and styling with no intentional user-facing changes while replacing only the runtime foundation. This skill covers both `Migration build` and `Migration verify` and includes self-grading quality gates that must pass before the task can complete.
Configure-Price-Quote (CPQ) vertical skill for the Customware SPA. Defines patterns, minimum standards, layout patterns, lifecycle indicators, product configurator patterns, business rule templates, and mapping rules for transforming a DOMAIN.md into a CPQ-shaped application. Targeted at SMB customers (5-50 employees) migrating from spreadsheets and email-based quoting workflows. The prototype must feel dramatically better than Excel without feeling enterprise-overcomplicated. Patterns are defaults, not mandates — adapt them when the actual workflow deviates. Trigger signals: quoting, pricing, product configuration, calculators, guided intake forms, assessment tools, estimate builders, proposal workflows, eligibility checkers, any "fill in fields → calculate → produce a deliverable" pattern.
| name | task-workflow |
| description | Canonical workflow for a task. Read and follow strictly end to end while working on the task. |
This file is strict implementation instruction, not loose guidance and not optional reference material.
This is the canonical workflow for task execution. It is not one possible way to do the task; it is the required way.
If the Agent reads this skill, it must execute it exactly as written, in order, to the letter.
Required behavior:
If the Agent is uncertain, it must resolve that uncertainty inside the workflow defined here and not invent its own workflow. If the skill says to perform a step, gate, checklist, review, or loop, that step is mandatory. If the skill says a later phase is blocked, the Agent must treat it as blocked. If the Agent cannot prove a phase passed in the required artifact, it must treat that phase as failed.
There is no successful stopping point before Phase 7. Stopping early can directly harm the user because they may depend on the completed workflow for job-critical work. It is a do-or-die situation: the user can be harmed if the run has not reached Phase 7 correctly, and the user can lose his job if the Agent stops early, signs off weak work, skips a gate, or damages live data. Treat premature stopping, partial signoff, live-data damage, or "mostly done" summaries as a serious failure of duty.
The first filesystem action in the target repo must be Phase 0 artifact reset and scaffolding.
Before task-workflow/phase-0-artifact-reset.md exists, the Agent may only:
SKILL.mdtask-workflow/ artifacts from templatesBefore Phase 1 passes, the Agent must not edit or generate implementation files, build outputs, databases, route types, migrations, tests, package files, or source files.
Production and live workspace databases, especially .dbs/database.db, are do-or-die user data. Deleting, resetting, reseeding, truncating, inspecting with ad hoc writes, or modifying them outside the app's legitimate migration command can destroy user work and can cause the user to lose his job. The only permitted production/live DB action is the repo's required app migration command for a real schema change. That exception does not permit "working on" the production DB: no manual query, data manipulation, seed, reset, fixture load, data repair, cleanup, delete, truncate, direct SQLite command, or debug mutation is allowed.
After Phase 1 passes and before any implementation edit, the Agent must set task-workflow/CURRENT_PHASE.txt to phase-2-execution.
If CURRENT_PHASE.txt still says phase-0-artifact-reset or phase-1-task-research, implementation files must remain unchanged.
If implementation files, generated app files, build outputs, or database files are changed before Phase 0 artifacts exist and Phase 1 passes, the run has failed and must be restarted from a clean fixture.
Re-read this SKILL.md after every compaction before continuing work. Re-load the phase references and current task artifacts too. Do not rely on conversational memory.
This skill is a gated execution protocol, not a loose set of suggestions. It turns a task into a repeatable, artifact-driven workflow. The target app must be implemented from the task, target repo, and local codebase evidence, then proven through Phase 3 check/lint evidence, Phase 4 unit-test coverage decision, Phase 5 interactive Playwright verification, Phase 6 E2E coverage decision, and final audit.
Assume this skill may run fully autonomously and may be compacted mid-run. No human is expected to watch the run line by line. The artifact files are therefore the enforcement system. A phase is not complete because the Agent feels confident. A phase is complete only when its required artifact shows a real passing score and all critical items pass.
task-workflow/progress.md is the compact resume ledger. It must summarize the task, current phase, completed phase context, active work queue, verification state, and next local action. Hard rule: after compaction, resume, retry, reconnect, or new coding session, read it and task-workflow/CURRENT_PHASE.txt before doing any new work. Keep it current as work proceeds; it is the first file that should restore enough context to continue without conversation memory.
Never promote work from one phase to the next on optimism, partial evidence, a green build alone, or broad product similarity.
The workflow is intentionally looped. A failed gate means the Agent must rework that phase, update evidence, rerun the needed checks or verification, rescore the gate, and repeat until the gate passes. Quality gates are not reports to the user; they are control points that force more work before promotion.
When running in a MITB sandbox, use these repo-relative workspace inputs:
.agents/skills/task-workflow/SKILL.md.tasks/task.md.tasks/domain.md.tasks/files/.agents/skills/AGENTS.md is the target repo's binding development-instructions file. It defines project-specific rules for architecture, type safety, tests, UX, commands, code style, docs, prohibited patterns, and completion. Phase 1 must extract the task-relevant rules from AGENTS.md before planning edits, including any required docs it points to. Later gates must verify the implementation follows those extracted rules.
Phase 1 must read .tasks/domain.md. It must enumerate .tasks/files/ even when the folder is empty, then read or inspect every task attachment/supporting file in that folder before planning.
Available skills are kept under .agents/skills/. Discover available skills from the prompt's Skills section and .agents/skills/, then read only the selected skill SKILL.md files relevant to the current task. Do not bulk-read every skill file in .agents/skills/.
All Phase 1 input/reference files are read-only. This includes AGENTS.md, .tasks/task.md, .tasks/domain.md, every file under .tasks/files/, and every selected skill file under .agents/skills/. Treat files under .tasks/ as canonical task inputs, not editable workspace artifacts. Do not rewrite, normalize, consolidate, clean up, trim, reformat, or "fix" these files unless the task explicitly asks to update that exact reference file. If a reference file appears inconsistent, record the ambiguity in task-workflow/phase-1-task-research.md or task-workflow/open-gaps.md; never resolve it by editing the reference input.
Record every .tasks/files/ attachment/supporting file read or inspected, plus every selected skill path and why it was relevant, in task-workflow/phase-1-task-research.md and task-workflow/progress.md. After compaction or resume, re-read the selected relevant skill files listed in progress.md along with AGENTS.md, .tasks/task.md, .tasks/domain.md, and the relevant .tasks/files/ attachments/supporting files recorded in Phase 1.
In MITB, .tasks/task.md or the prompt always provides the task completion command. Phase 7 must run the exact completed command only after every Phase 7 audit check passes. If any Phase 7 audit check fails, do not run task completion. Return to the earliest failing phase, repair the work, update evidence, rescore that phase, loop forward through the gates, and then re-enter Phase 7.
<mandatory_process_shape>
This workflow shape is not optional:
AGENTS.md, .tasks/domain.md, every task attachment/supporting file in .tasks/files/, only relevant available skill files from .agents/skills/, and relevant project docs. Extract the task-relevant development rules from AGENTS.md before planning. These instruction, task, domain, attachment, and skill-reference files are read-only unless the task explicitly asks to edit them.If the work skips one of those phase boundaries, the run is off track.
| Phase | Owns | Required evidence |
|---|---|---|
| Phase 0 | artifact reset and scaffold | fresh artifacts, helper scripts, marker, no source edits |
| Phase 1 | task intake and research | task/domain/attachments/AGENTS/selected skills read, codebase research, implementation plan |
| Phase 2 | primary implementation | scoped work packets, file evidence, readback/diff/search proof |
| Phase 3 | second execution, integrity, check/lint validation | connected-surface review, repo check, focused lint when useful, build, reusable build evidence |
| Phase 4 | unit-test coverage decision | add/update/remove/skip decision, existing-test inspection, minimal unit command or N/A |
| Phase 5 | interactive Playwright verification | Stage 1 behavior proof, Stage 2 UI/responsive proof, screenshots, lifecycle evidence |
| Phase 6 | E2E coverage decision | add/update/remove/skip decision, connected E2E inspection, minimal E2E command or N/A |
| Phase 7 | final audit and signoff | artifact integrity review, current evidence, MITB completion command after audit |
</mandatory_process_shape>
Every phase follows the same loop:
task-workflow/CURRENT_PHASE.txt, and immediately start the next phase.This loop is mandatory for Phase 0, Phase 1, Phase 2, Phase 3, Phase 4, Phase 5, Phase 6, and Phase 7.
Do not lower a gate threshold to escape the loop. Do not summarize failure as progress when the next local repair is available. Do not wait for the user to tell you to continue when the phase can be repaired locally. Do not move forward with a weak artifact because the implementation "probably works".
The only acceptable end state is Phase 7 passed with every earlier phase still passing. The only acceptable non-Phase-7 stop is a real external blocker that cannot be solved locally and is fully recorded in the current phase artifact and task-workflow/open-gaps.md.
<autonomous_run_contract>
Treat these rules as always active.
task-workflow/CURRENT_PHASE.txt is only a resume pointer. It is not proof that earlier phases passed.task-workflow/progress.md is the compact resume ledger. It is not proof that gates passed, but it must stay current enough to resume the run after compaction.task-workflow/progress.md with the current phase, earliest failing phase if any, last completed gate, next local action, and a compact summary of relevant context.Current Phase Pointers, Phase Artifact Index, and Artifact Pointers in task-workflow/progress.md current. They must point to the current phase artifact, current phase reference, and high-signal active files only. Do not duplicate full researched-file, edited-file, Playwright, screenshot, log, or test inventories from phase artifacts into progress.md.SKILL.md, task-workflow/progress.md, task-workflow/CURRENT_PHASE.txt, the current phase artifact, task-workflow/open-gaps.md, and the required current phase reference file or files before choosing the next action. If they disagree, inspect the phase artifacts and continue from the earliest failing phase.Decision: Pass, a passing score, all critical items passing, and no placeholder Pending rows in the gate or required evidence sections.CURRENT_PHASE.txt points past the earliest failing phase artifact, artifact gates win. Correct CURRENT_PHASE.txt back to the earliest failing phase and continue there.task-workflow/open-gaps.md is a gate artifact. A later phase may not claim a gap is resolved unless the gap ledger is updated in the same phase.Open after the phase named in its owner or next-action field has passed. If the later phase completed the work, move the gap to Resolved Gaps; if the gap is not real, reclassify or close it with evidence.task-workflow/open-gaps.md must not contain template placeholder rows such as Pending after Phase 0. If there are no gaps, replace placeholder rows with explicit None currently recorded rows.Open, stale, or contradicted by another phase artifact.task-workflow/playwright or tests/e2e is a gate failure. Do not justify it. Replace it with deterministic Playwright waits/assertions such as locator.waitFor(...), expect(locator)..., waitForURL(...), waitForResponse(...), or persisted-state assertions, then rerun verification.sed, rg, ls, git diff, or the repo's normal inspection command to prove the file exists and contains the intended change..dbs/database.db, any repo-declared live/default user-data database, or any database path used by the normal app outside an isolated test/E2E config. The only allowed action on .dbs/database.db or any production/live database is the repo's required application migration command for a real schema change, run in the phase that owns that migration and recorded as migration evidence. This is a narrow migration-execution exception, not permission to work on the production DB. If the task creates or changes a migration, running the repo's app migration command against the production/live default DB is mandatory after the migration exists and before Phase 3 promotes; the user uses the completed app immediately, so unapplied migrations make the delivered change invisible or broken. No other production/live DB action is allowed: no manual query, data manipulation, seed, reset, fixture, Playwright, E2E, probe, debugging, cleanup, rm, truncate, direct SQLite, custom data repair, or data inspection with write risk. If the command might touch production data and the artifact cannot prove it is the repo migration command for a real schema change or an isolated test DB operation, do not run it.task-workflow/scripts/server-probe.mjs. It owns PID capture, readiness, bounded probe commands, runtime logs, and PID-only cleanup. Server readiness is usually 5-10 seconds; use 15-20 seconds as the normal budget and 30 seconds as the maximum startup-readiness limit. Broad process-name cleanup is only for explicit sandbox-owned recovery when PID/port cleanup is impossible and the artifact records why.task-workflow/scripts/playwright-lifecycle.mjs by default. Do not run against an assumed existing server first and then infer that fetch failed, stale data, redirects, or wrong build output means manual server management is needed.pnpm exec playwright test ... through the helper's --run by default. Use native Playwright with repo webServer ownership only when the helper cannot own the server for that exact command after a diagnosed reason, and record that reason before running it.--env is not a database-path override mechanism. Never set E2E_DATABASE_FILE_PATH, DATABASE_PATH, DB_PATH, or any similar database file/path variable in helper, setup, server, or run commands. The agent must not change the repo's internal E2E/end-to-end database file path. Test database paths must come from the repo's checked-in E2E/end-to-end config or the already-materialized environment. .dbs/database.db is the live workspace/production database; production databases must never be used for testing. Using .dbs/database.db for Playwright, E2E, fixtures, seed, reset, inspection, cleanup, or debugging is a critical failure even if it appears only in task-workflow/. The user can lose his job if this database is deleted or corrupted.AGENTS.md, package.json, README/docs, Playwright config, and tests/e2e helpers before running Phase 5 or Phase 6. Prefer a repo-owned setup command that prepares isolated E2E/test state by resetting only the test DB, applying test-targeted migrations, and seeding deterministic verification data, plus a repo-owned server command that starts the app against that isolated state. If the target repo has no named scripts for this pattern, simulate the same pattern with the smallest repo-owned/test-only commands and record the mapping before running them; never replace the pattern with production DB writes, raw DB path overrides, or manual cleanup chains.--setup "..." for helper-owned runs. Treat setup plus server startup as reusable for the current verification batch: prefer one helper-owned run with the needed script/spec commands, or rerun setup only after code, migrations, fixtures, DB state, build inputs, or the prior setup output changed. Do not repeatedly delete/recreate the DB or restart the server before each targeted script/spec just because another E2E command is next. If cleanup is needed, do it as a separate recorded recovery step before the helper run, then run the helper alone. If server state, database state, port ownership, or build freshness looks wrong, diagnose through the current lifecycle owner logs/readiness first and rerun through that owner after any code/setup fix. If the helper times out or produces no useful output, treat that as lifecycle/setup evidence, inspect task-workflow/runtime/server.log, task-workflow/runtime/setup-*.log, readiness output, and task-workflow/runtime/run-*.log, then change the setup, server command, ready URL, test command, fixture, or diagnostic before rerunning. If the helper fails once or twice with a diagnosed lifecycle/tooling issue after a corrected invocation, record the helper logs and switch to the smallest fallback that can prove the task: repo Playwright webServer, explicit PID/port cleanup, or manual server management with captured PID/log/readiness/cleanup evidence. Broad process-name cleanup is only a recorded sandbox recovery after PID/port cleanup is impossible.playwright install, playwright install chromium, or equivalent browser downloads during task verification. The managed lifecycle helper sets PLAYWRIGHT_BROWSERS_PATH=/ms-playwright when available and fails early if the project Playwright version does not match the sandbox browser cache.pnpm run check to their owning later phases unless a concrete compile/type issue blocks the current packet and is recorded before the command.Tests are production code. Extra tests are not harmless evidence; they are maintenance load, false confidence risk, and future workflow drag.
Phase 4 and Phase 6 must treat test work as a pruning and minimal-coverage decision, not as a "more tests is safer" step.
| Rule | Required behavior |
|---|---|
| Existing tests are not grandfathered | If an older agent added unnecessary, obsolete, brittle, convoluted, duplicated, or non-core tests, the owning phase must remove or simplify them when they are connected to the current changed behavior. |
| New tests are exceptions | Add a new test only after proving the behavior is stable/core and no connected existing test can carry the warranted assertion cleanly. |
| Passing extra tests is not quality evidence | A large passing count does not improve the gate. The gate values necessary coverage, useful assertions, and removal of bad tests. |
| Test bulk is a warning | If added tests cause max-lines, fixture churn, helper churn, slow commands, broad reruns, or new maintenance structure, stop and re-evaluate whether the tests should be merged, reduced, updated in place, or removed. Do not solve self-created test bulk by adding more structure unless the artifact proves every test remains necessary. |
| Every new test needs a burden ledger | For each new unit or E2E test case/file, record the core risk, the connected existing tests inspected, why update/remove/N/A was insufficient, why the assertion is minimal, and what cheaper proof was rejected. |
webServer, or "run tests" script is not enough. After warranted targeted or connected E2E evidence passes and no related code, test, config, fixture, migration, or build input changed, do not add a full E2E run as final confidence, final signoff, state discovery, or reviewer-satisfaction evidence.15000-20000 ms for Phase 5 launch/page-state/custom-script probes and up to 30000 ms for first-run Phase 6 targeted E2E where Playwright runner startup adds overhead. If the run fails with any useful error, assertion output, not-found state, console/runtime error, route error, fixture/DB miss, or helper diagnostic, use that evidence to diagnose; do not retry with a larger timeout. A larger timeout is allowed only when the first run ended only because the timer expired with no useful response or explanation, and only after helper logs, readiness, URL, not-found/error state, required DB/fixture records, server runtime logs, browser console, and network/page state prove the app and test are in the correct state to run. Only then may one rerun use 60000 ms, and never more than 120000 ms for one targeted script/spec. If a single targeted run needs more than two minutes, stop increasing timeouts; split the verifier or diagnose lifecycle, setup, fixture, page-state, console, network, or test-design failure first.Decision: Fail, Score: 0/..., pending gate rows, or unresolved locally-fixable warnings and then produce a final response.</autonomous_run_contract>
Before producing any final response, stopping message, or ending an OpenCode turn with control returned to the user, run this guard against the artifact files:
task-workflow/CURRENT_PHASE.txt must be phase-7-final-signoff.task-workflow/progress.md must say the current phase is phase-7-final-signoff, the last completed gate is Phase 7, and there is no next local action except final response.task-workflow/progress.md must include current phase pointers, a phase artifact index, and artifact pointers that identify where detailed evidence lives.task-workflow/progress.md must not duplicate full file inventories from phase artifacts; it may list only high-signal active files needed for immediate resume.task-workflow/progress.md must list the repo-relative instruction/context files to re-read after compaction, including AGENTS.md, .tasks/task.md, .tasks/domain.md, relevant task attachments/supporting files from .tasks/files/, and only the relevant available skill files from .agents/skills/ selected in Phase 1.Decision: Pass.Pending or template defaults.task-workflow/open-gaps.md must have no critical open gaps, no stale open gaps owned by passed phases, and no placeholder rows.N/A coverage decision. When tests are removed, the owning phase and Phase 7 must record the removal reason and diff/readback evidence.console.*. Temporary console.* is allowed only during Phase 5 interactive testing when it directly helps debug browser/runtime behavior by reading console output, and it must be removed before the Phase 5 rerun, Phase 3 re-pass, or Phase 7 signoff.8/10 in every category.Pass, its score meets threshold, required evidence rows are complete, and it does not contradict CURRENT_PHASE.txt, progress.md, or open-gaps.md..tasks/task.md or the prompt must run only after all Phase 7 audit checks pass. Treat it as the final external task action: plan and run all checks, tests, builds, server probes, and verification commands before task completion. If any Phase 7 check fails before completion, the agent must loop back to the earliest failing phase and must not call task completion.If any item fails and the problem can be solved locally, continue the workflow from the earliest failing phase. Do not answer as if the task is complete.
If an actual external blocker prevents completion, record the blocker in the current phase artifact and open-gaps.md, including commands run, files inspected, why local recovery cannot solve it, and the smallest next action.
When running inside OpenCode or another tool-driven coding session, the Agent must not end its assistant turn just because a command finished, a check passed, lint started, files were edited, or a phase artifact is temporarily failing.
After every tool result, before returning control to the user, check:
CURRENT_PHASE.txt earlier than phase-7-final-signoff?Decision: Fail?Pending, 0/..., or missing evidence?If the answer to any of the first three is yes and the next action is locally available, immediately continue with that next action in the same run. Do not stop at a narrative checkpoint such as "now run lint", "check passes", "next I will update the artifact", or "remaining work is...".
The only valid stopping states are:
open-gaps.md.If the session is long, keep the phase artifacts current and continue dispatching the next tool/action. Do not rely on the user to type "continue" to finish an unblocked phase.
These are hard constraints:
8/10 in each quality category: functional result, skill compliance/artifact integrity, code quality/maintainability, test quality, and overall result.<reference_loading_rules>
Do not load every reference file by default.
After compaction, resume, retry, reconnect, or a new coding session, use task-workflow/progress.md and task-workflow/CURRENT_PHASE.txt to identify the current status, then re-read:
SKILL.mdtask-workflow/progress.mdtask-workflow/CURRENT_PHASE.txttask-workflow/open-gaps.mdprogress.mdDo not rely on conversation memory after compaction. progress.md and CURRENT_PHASE.txt identify where the run is, but they do not replace the main skill, current phase reference, current phase artifact, or gap ledger. The run may continue only after those files have been reloaded.
Every time a phase starts, including immediately after a phase promotion, read the required reference file or files for that new phase before doing phase work.
If CURRENT_PHASE.txt changes, the next local action is to load the reference file or files named for the new marker in the Phase Reference Map. Phase work before that read is invalid.
On a fresh run:
SKILL.md.references/phase-0-1-startup-research.md.After compaction, resume, retry, reconnect, or new coding session:
SKILL.md.task-workflow/progress.md.task-workflow/CURRENT_PHASE.txt.task-workflow/open-gaps.md.progress.md, including AGENTS.md, .tasks/task.md, .tasks/domain.md, the relevant attachments/supporting files recorded from .tasks/files/, and only the selected relevant skill files from .agents/skills/.progress.md, CURRENT_PHASE.txt, and the phase artifacts disagree, continue from the earliest failing phase artifact.references/playwright-interactive.md only when the current phase reference requires interactive Playwright work.Phase reference map:
| Current phase marker | Reference to load |
|---|---|
missing task-workflow/ | references/phase-0-1-startup-research.md |
phase-0-artifact-reset | references/phase-0-1-startup-research.md |
phase-1-task-research | references/phase-0-1-startup-research.md |
phase-2-execution | references/phase-2-4-execution-integrity.md |
phase-3-second-execution | references/phase-2-4-execution-integrity.md |
phase-4-unit-coverage | references/phase-2-4-execution-integrity.md |
phase-5-playwright-verification | references/phase-5-7-verification-signoff.md and references/playwright-interactive.md |
phase-6-e2e-verification | references/phase-5-7-verification-signoff.md |
phase-7-final-signoff | references/phase-5-7-verification-signoff.md |
The phase references are grouped by connected workstream, not one file per phase. This matches the reference skill pattern: SKILL.md holds the strict global protocol and the reference files hold detailed process for the current workstream.
</reference_loading_rules>
<operating_modes>
Use this when improving or testing the skill itself.
Use this when the user wants the real target app or task completed.
</operating_modes>
These are mandatory:
task-workflow/task-workflow/phase-0-artifact-reset.mdtask-workflow/phase-1-task-research.mdtask-workflow/phase-2-execution.mdtask-workflow/phase-3-second-execution.mdtask-workflow/phase-4-unit-coverage.mdtask-workflow/phase-5-playwright-verification.mdtask-workflow/phase-6-e2e-verification.mdtask-workflow/phase-7-final-signoff.mdtask-workflow/progress.mdtask-workflow/open-gaps.mdtask-workflow/CURRENT_PHASE.txttask-workflow/playwright/task-workflow/screenshots/task-workflow/scripts/task-workflow/scripts/playwright-lifecycle.mjstask-workflow/scripts/server-probe.mjstask-workflow/runtime/The templates in assets/templates/ are enforcement artifacts. Copy their structure directly. If a required table is replaced by prose or stripped down until rows are no longer auditable, the run fails.
<multi_phase_protocol>
Follow the phases in order:
Delete the previous task's task-workflow/ artifacts, recreate the required artifact files from templates, and prove no implementation files were edited.
Detailed process: references/phase-0-1-startup-research.md.
Read the task, root AGENTS.md, .tasks/domain.md, every task attachment/supporting file in .tasks/files/, only relevant available skill files from .agents/skills/, relevant docs, and codebase. Treat AGENTS.md as binding development instructions; extract its task-relevant rules before planning. These are reference inputs: read and cite them, but do not edit them. Record task understanding, development rules, task files read or inspected, selected skills, affected files, patterns to reuse, risks, and an ordered implementation plan.
Detailed process: references/phase-0-1-startup-research.md.
Execute the researched plan in order, keep changes scoped, and record implementation evidence.
Detailed process: references/phase-2-4-execution-integrity.md.
Review the implementation as a continuation pass, close missing or weak work, propagate consistency to associated UI/API/data surfaces, run implementation integrity review, and complete the ordered check/build checkpoint. Do not write or run unit/Vitest or E2E tests in Phase 3.
Detailed process: references/phase-2-4-execution-integrity.md.
Decide whether unit, service, component, or integration-style tests are needed. Add, update, remove, or explicitly skip that coverage, then run only the warranted unit-level commands. Remove tests that are unnecessary, obsolete, convoluted, or protecting non-core/non-complex behavior.
Detailed process: references/phase-2-4-execution-integrity.md.
Use standalone interactive Playwright scripts in two stages. Stage 1 proves the changed behavior works through real user interaction. Stage 2 verifies UI quality: no broken, cramped, overlapping, clipped, ill-placed, or non-responsive UI on the affected surfaces. Treat responsive design as a first-class Phase 5 guarantee, equal to proving the task's functional changes work. Some whitespace is fine, but standard desktop viewports such as 1920x1080 must not look broken, clipped, overlapped, unusable, or excessively sparse. Large desktop viewports such as 2560x1440 may have some extra whitespace, but not broad empty regions that make the UI feel unfinished. Very large 4K/ultrawide whitespace is acceptable when the layout is intentionally constrained and still coherent.
The Phase 4/Phase 6 test-minimality rules do not shrink Phase 5. Phase 5 is the main user-facing verification phase and may take the time needed to cover changed flows, relevant bad cases, surrounding UI, responsive breakpoints, screenshots, and visual correctness. Use multiple focused Playwright scripts, probes, viewport passes, or reruns when needed to prove the affected user experience is correct; keep them scoped to the changed and adjacent surfaces, but do not reduce Phase 5 to a shallow smoke check.
Detailed process: references/phase-5-7-verification-signoff.md and references/playwright-interactive.md.
Make the E2E coverage decision. Review existing E2E coverage first, update it when a warranted core flow already belongs there, add new E2E tests only for critical or complex workflows that cannot be cleanly covered by existing tests, remove unwanted E2E tests that protect non-core/non-complex or convoluted flows, and avoid E2E for small, visual-only, or incidental UI changes.
Detailed process: references/phase-5-7-verification-signoff.md.
Re-read every artifact, confirm all previous gates still pass after the last edit, review the final diff, run the required MITB completed command only after all Phase 7 audit checks pass, and sign off only if the artifact trail proves completion.
Phase 7 is an evidence validator for missed work, not a validation rerun phase. If a required check, build, test, Playwright run, E2E run, or other phase-owned command was already completed correctly in its owning phase and the evidence is current, Phase 7 must only verify that evidence. Rerun a command only when the owning phase missed the required command, the recorded evidence is missing/incomplete/stale, or later changes invalidated it; otherwise never rerun checks, builds, tests, Playwright, or E2E in Phase 7.
Detailed process: references/phase-5-7-verification-signoff.md.
The phase references are not optional expansion material. They are the detailed execution instructions for the current workstream.
</multi_phase_protocol>
<automatic_fails>
These automatically fail the run:
task-workflow/CURRENT_PHASE.txt still says phase-0-artifact-reset or phase-1-task-researchtask-workflow/phase-2-execution.md does not record that the marker was set to phase-2-execution before source editstask-workflow/progress.md current enough to resume the runtask-workflow/progress.md and task-workflow/CURRENT_PHASE.txt to identify status, then re-reading SKILL.md, the current phase artifact, open-gaps.md, and the required current phase reference file or filestask-workflow/progress.md, including AGENTS.md, .tasks/task.md, .tasks/domain.md, relevant task attachments/supporting files from .tasks/files/, and relevant available skill files from .agents/skills/AGENTS.md only as context instead of extracting and following the task-relevant development rules it defines.tasks/task.md, .tasks/domain.md, .tasks/files/, selected skill files under .agents/skills/, or AGENTS.md without the user/task explicitly requesting an edit to that exact reference filetask-workflow/progress.md Current Phase Pointers, Phase Artifact Index, or Artifact Pointers stale, missing, or contradicting phase artifactstask-workflow/progress.md as a duplicate file inventory instead of pointing to the owning phase artifacts for detailstask-workflow/CURRENT_PHASE.txt while the current or any previous phase artifact still says Decision: Failtask-workflow/CURRENT_PHASE.txt while the current or any previous phase artifact still has placeholder Pending gate evidencewebServer or manual fallback only with a recorded reason/diagnostic made before the command.dbs/database.db, repo default user-data DB paths, and any equivalent live DB path.dbs/database.db or any equivalent live DB pathpnpm run check in Phase 2 without a concrete compile/type blocker recorded before the commandtail/head output alone is not enough if it hides issue groups, and temporary full-output logs must be deleted after extractionpnpm exec playwright test ... in Phase 6 instead of running it through task-workflow/scripts/playwright-lifecycle.mjs --run ..., unless repo webServer ownership is required and recorded before the commandrm, seed, migrate, sqlite3, tsx server/db/seed, fixture setup, or any DB cleanup command from Phase 5/6 unless the artifact first proves the command targets an isolated repo-owned test/E2E database and not production/live user data20000 ms or a first-run targeted Phase 6 E2E above 30000 ms without a task-specific artifact reasonplaywright install, playwright install chromium, or equivalent browser downloads during task verification instead of using the sandbox browser cache or recording the helper's browser-preflight mismatchconsole.* outside the active Phase 5 debug loopCURRENT_PHASE.txt is before phase-7-final-signoffDecision: Fail, has a failing score, or contains pending gate evidencetask-workflow/phase-2-execution.md execution log remains blank or all Pendingtask-workflow/open-gaps.md contains stale open gaps that a passed later phase claims to have resolvedtask-workflow/open-gaps.md still contains template placeholder rows such as Pendingtask-workflow/playwright or tests/e2e8/10progress.md and CURRENT_PHASE.txt for status and re-reading this skill, required phase reference files, and artifacts.tasks/files/ even when it is empty.tasks/files/ before Phase 1 planning.agents/skills/ instead of selecting and reading only task-relevant skillsAGENTS.md development rules</automatic_fails>
references/phase-0-1-startup-research.md: artifact reset, template copying, task intake, and codebase research.references/phase-2-4-execution-integrity.md: primary execution, second execution, gap closure, and integrity checks.references/phase-5-7-verification-signoff.md: interactive Playwright verification, E2E coverage decisions, and final audit.references/playwright-interactive.md: how this skill uses standalone interactive Playwright scripts.assets/templates/phase-0-artifact-reset.mdassets/templates/phase-1-task-research.mdassets/templates/phase-2-execution.mdassets/templates/phase-3-second-execution.mdassets/templates/phase-4-unit-coverage.mdassets/templates/phase-5-playwright-verification.mdassets/templates/phase-6-e2e-verification.mdassets/templates/phase-7-final-signoff.mdassets/templates/progress.mdassets/templates/open-gaps.mdassets/scripts/playwright-lifecycle.mjs: managed server/readiness/Playwright execution helper copied into task-workflow/scripts/ during Phase 0.assets/scripts/server-probe.mjs: managed API/runtime server probe helper copied into task-workflow/scripts/ during Phase 0 for pre-Phase-5 server checks.The task is complete only when Phase 7 passes. If the task cannot be completed, the final artifact must identify the exact blocking condition, the phase where it occurred, commands run, files inspected, and the smallest next action needed.