Pack Availability Guard
Before telling the user to run a skill from another project-local pack, check .agents/project.json.enabled_packs. If the target pack is not enabled, recommend /pack install <pack> instead of the target skill. Global skills are always valid. Skills from this same pack are valid because the current skill is already running from that pack.
Research Roadmap - Documentation Queue Manager
Use this skill to make the project documentation contract complete before build work continues. It scans research, specs, and task docs, then updates tasks/todo.md with immediately actionable documentation work and uses tasks/record-todo.md or tasks/recurring-todo.md for non-blocking future documentation records.
Do not run the queued research skills from this skill. The job here is to maintain the documentation queue so the user can complete research and planning artifacts in the right order.
Process
0. Parse Mode Arguments
Parse $ARGUMENTS for mode flags:
--post-prototype: Post-prototype research refresh mode--post-spec: Post-spec research refresh mode- No flags: default documentation queue mode (existing behavior)
If --post-prototype is present, skip to the Post-Prototype Process below.
If --post-spec is present, skip to the Post-Spec Process below.
Otherwise, continue with the standard process starting at step 1.
1. Resolve Project Pack
- Read
.agents/project.jsonif it exists. - Use
project_typeandenabled_packsto decide which project-pack research skills apply. - If
.agents/project.jsonis missing, infer the project type from repository signals:- game: game engine files, Steam/store assets, playable prototypes, or game-specific README/spec language
- devtool: SDK, CLI, API, library, infra, docs, examples, or package-first developer workflow
- business-app: SaaS, marketplace, productivity, workflow, enterprise, or user-facing app
- If the project type cannot be inferred, default to
business-app. - If an expected pack is not installed, add a priority todo for
/pack install <pack>before pack-specific research todos.
2. Resolve Documentation Roots
Treat top-level research/, specs/, and tasks/ as canonical.
- If a canonical root exists, use it directly.
- If a canonical root is missing, search shallowly near the repo root for likely aliases such as
docs/,planning/,notes/, orwork/. - Prefer roots that contain multiple expected documentation files over isolated matches.
- If no credible task root exists, create/update top-level
tasks/todo.md; createtasks/record-todo.mdortasks/recurring-todo.mdonly when advisory items exist. - If a fallback root is used for research or specs, mention it in the generated todo item reasons.
For writing the priority queue, prefer tasks/todo.md. Use a fallback task root only when the project already has a clear existing task contract and no top-level tasks/ directory. Do not put condition-gated records or recurring obligations into tasks/todo.md unless they are immediately actionable execution work.
3. Discover Research-Producing Skills
Build the research queue from enabled project packs. Include every enabled research-producing skill whose output is missing or stale, even if its prerequisites are not yet present. When prerequisites are missing, keep the item in the queue but note that it is blocked by earlier documentation items.
Prefer dynamic discovery when skill files are available:
- Inspect enabled pack skill files under
.claude/skills/*/SKILL.mdorpacks/<pack>/claude/*/SKILL.md. - Include skills with
type: research. - Also include skills whose
## Outputsection writesresearch/*.md,research/{app}/*.md,research/experiments/*.md, or dated research files.
If dynamic discovery is unavailable, use these fallback maps.
Business-app research outputs:
| Skill | Output |
|---|---|
/icp |
research/icp.md |
/competitive-analysis |
research/competitive-analysis.md |
/positioning |
research/positioning.md |
/journey-map |
research/journey-map.md |
/metrics |
research/metrics.md |
/gtm |
research/gtm.md |
/monetization |
research/monetization.md |
/landing-copy |
research/landing-copy.md |
/customer-feedback |
research/customer-feedback.md |
/assumption-tracker |
research/assumption-tracker.md |
/experiment |
research/experiments/<experiment>.md |
/enterprise-icp |
research/enterprise-icp.md |
/risk-register |
research/risk-register.md |
/burn-rate |
research/burn-rate.md |
/runway-model |
research/runway-model.md |
/cohort-review |
research/cohort-review-YYYY-MM-DD.md |
/retro |
research/retro-YYYY-MM-DD.md |
/investor-update |
research/investor-update-YYYY-MM.md |
/platform-strategy |
research/platform-strategy.md |
/mvp-gap |
research/mvp-gap.md |
Game research outputs:
| Skill | Output |
|---|---|
/game-audience |
research/game-audience.md |
/game-fantasy |
research/game-fantasy.md |
/game-genre-map |
research/game-genre-map.md |
/game-comparables |
research/game-comparables.md |
/game-core-loop |
research/game-core-loop.md |
/game-prototype-test |
research/game-prototype-test.md |
/game-playtest-metrics |
research/game-playtest-metrics.md |
/game-store-page-test |
research/game-store-page-test.md |
/game-launch |
research/game-launch.md |
Devtool research outputs:
| Skill | Output |
|---|---|
/devtool-user-map |
research/devtool-user-map.md |
/devtool-integration-map |
research/devtool-integration-map.md |
/devtool-dx-journey |
research/devtool-dx-journey.md |
/devtool-adoption |
research/devtool-adoption.md |
/devtool-positioning |
research/devtool-positioning.md |
/devtool-monetization |
research/devtool-monetization.md |
/devtool-docs-audit |
research/devtool-docs-audit.md |
Also include documentation-producing non-research skills when their outputs are missing or stale:
| Skill | Output |
|---|---|
/idea-scope-brief |
research/concept-brief.md or research/{app}/concept-brief.md |
/spec-interview |
specs/*.md |
/ux-variations |
specs/ux-variations-*.md |
/ui-interview |
specs/ui-*.md |
/scale-audit |
specs/scale-audit.md |
/roadmap |
tasks/roadmap.md, tasks/todo.md |
/game-roadmap |
tasks/roadmap.md, tasks/todo.md |
/reconcile-research fix all |
research/reconciliation-report.md |
/reconcile-dev-docs fix all |
reconciled tasks/, specs/, and phase archives |
/youtube-audit |
research/youtube-audit-YYYY-MM-DD.md |
4. Scan Documentation State
Record existence and last-modified timestamps for:
- all discovered research outputs
research/concept-brief.mdand app-scopedresearch/{app}/concept-brief.mdwhen presentresearch/*-search-log.mdandresearch/*-interview.mdonly as supporting context, not primary completion artifactsspecs/*.mdand app-scopedspecs/{app}/*.mdspecs/ux-variations-*.mdand app-scopedspecs/{app}/ux-variations-*.mdspecs/ui-*.mdand app-scopedspecs/{app}/ui-*.mdtasks/roadmap.mdtasks/todo.mdtasks/history.mdtasks/ideas.mdtasks/manual-todo.mdtasks/record-todo.mdtasks/recurring-todo.md
When research/ contains app subdirectories, treat it as monorepo mode. Build a separate documentation queue per app and include app arguments in commands, such as /icp web.
5. Classify Missing And Stale Items
An item is missing when its expected output file does not exist.
An item is stale when a newer upstream document should invalidate or refresh it. Include the exact timestamps in the todo reason. Use these default rules:
| Newer input | Stale target |
|---|---|
research/concept-brief.md or research/{app}/concept-brief.md |
matching research/icp.md or research/{app}/icp.md |
research/customer-feedback.md |
research/icp.md, research/journey-map.md, research/monetization.md, research/landing-copy.md |
research/icp.md |
research/competitive-analysis.md, research/positioning.md, research/gtm.md, research/monetization.md, research/landing-copy.md |
research/competitive-analysis.md |
research/positioning.md, research/gtm.md, research/monetization.md, research/landing-copy.md |
research/positioning.md |
research/gtm.md, research/landing-copy.md |
research/journey-map.md |
research/metrics.md, research/gtm.md, research/monetization.md, research/landing-copy.md |
research/metrics.md |
research/cohort-review-*.md, research/runway-model.md, research/investor-update-*.md |
research/gtm.md |
research/monetization.md, research/runway-model.md, research/investor-update-*.md |
research/monetization.md |
research/burn-rate.md, research/runway-model.md, research/investor-update-*.md |
research/experiments/*.md with results |
research/assumption-tracker.md |
research/cohort-review-*.md latest |
research/metrics.md, research/gtm.md, research/monetization.md, research/investor-update-*.md |
research/enterprise-icp.md |
specs/scale-audit.md |
research/journey-map.md |
specs/*.md, specs/ux-variations-*.md, specs/ui-*.md, research/metrics.md, research/gtm.md, research/monetization.md, research/landing-copy.md |
any non-UX/UI specs/*.md |
specs/ux-variations-*.md, specs/ui-*.md, tasks/roadmap.md |
specs/ux-variations-*.md |
specs/ui-*.md, tasks/roadmap.md |
specs/ui-*.md |
tasks/roadmap.md |
research/runway-model.md |
tasks/roadmap.md |
Also flag potentially stale specs when source code has commits newer than the spec files. Add /spec-drift fix all as a priority documentation item when specs are probably behind implementation.
Do not queue a missing /idea-scope-brief item for established projects that already have research/icp.md, research/competitive-analysis.md, research/journey-map.md, or specs/. Queue it only for idea-only projects where no concept brief or downstream research/spec artifact exists.
6. Order The Priority Queue
Order immediately actionable todo items so the user can complete documentation without guessing:
- Pack installation needed for the selected project type.
- Stale foundational research.
- Missing foundational research.
- Stale downstream research.
- Missing downstream research.
- Missing or stale specs.
- Missing or stale UX/UI planning artifacts for user-facing work.
- Missing or stale roadmap/task docs.
- Reconciliation items when conflicting docs are detected.
Within research items, use this dependency order when relevant. When emitting queued commands for pack-based skills, apply the Pack Availability Guard — if the target skill's pack is not in .agents/project.json enabled_packs, queue /pack install <pack> before the skill:
/idea-scope-brief
-> /icp
-> /competitive-analysis
-> /positioning
-> /journey-map
-> /spec-interview
-> /ux-variations
-> /ui-interview
-> /prototype
-> /consolidate-variations
-> /roadmap
-> /metrics
-> /gtm
-> /monetization
-> /landing-copy
3+ research docs -> /assumption-tracker -> /experiment -> /customer-feedback
/enterprise-icp -> /scale-audit
/metrics + launch data -> /cohort-review
/monetization -> /burn-rate -> /runway-model
quarterly/outcome data -> /retro
stakeholder reporting -> /investor-update
multi-product expansion -> /platform-strategy
For game and devtool projects, follow the default pack flow from docs/skills-reference.md when available. Add review or planning skills such as /devtool-docs-audit and /game-roadmap only when their documented output is missing from the documentation contract.
Default devtool order:
/devtool-user-map
-> /devtool-integration-map
-> /devtool-dx-journey
-> /devtool-adoption
-> /devtool-positioning
-> /devtool-monetization
-> /devtool-docs-audit
-> /research-roadmap
6b. Classify Advisory Documentation Work
Before writing any queue, choose the correct task surface:
tasks/todo.md: missing/stale documentation work that can be performed now with available repo context and normal skill inputs.tasks/record-todo.md: one-time documentation records or measurements that are blocked on future conditions, production aggregate access, external reports, user-provided data, or launch data, and are not launch gates.tasks/recurring-todo.md: cohort reviews, retros, investor updates, playtest/adoption checks, docs-health checks, or other documentation jobs that recur on a cadence.
Record items must include task, source, condition, non-blocking reason, required data/access, measurement/query, target/acceptance note, revisit cadence/date, completion evidence, and promotion rule. Recurring items must include task, cadence, owner/agent, scope, trigger, last run, next due, command/skill, evidence/output path, and escalation conditions.
7. Update tasks/todo.md
Write a single top-level section named exactly:
## Priority Documentation Todo
Rules:
- If
tasks/todo.mddoes not exist, create it. - If a previous
## Priority Documentation Todosection exists, replace only that section. - Put the section before existing implementation work. If the file starts with a title or status block, keep that orientation text at the top and insert the priority section immediately after it.
- Preserve all other todo content exactly unless it is inside the old priority section.
- Do not mark existing implementation tasks complete.
- Do not remove unrelated todo sections.
- Use unchecked boxes only for missing/stale documentation work that is immediately actionable.
- Use checked boxes only when an item is already current.
Todo item format:
- [ ] `/skill [optional-app-or-argument]` - create/update `path/to/output.md` because [missing/stale reason with evidence].
If prerequisites are missing:
- [ ] `/metrics` - create/update `research/metrics.md` after `/journey-map`; currently blocked because `research/journey-map.md` is missing.
Do not write unavailable-data or cadence-gated items here. Write those to tasks/record-todo.md or tasks/recurring-todo.md instead.
7b. Update tasks/record-todo.md
When non-blocking condition-gated documentation records exist, append or replace a ## Documentation Records section in tasks/record-todo.md. Preserve all other sections exactly.
Use this item format:
- [ ] [record task]
- Source: [skill/spec/phase/criterion]
- Condition: [future condition or required access]
- Non-blocking reason: [why this does not block launch or current execution]
- Required data/access: [data, aggregate, portal, credential, or user-provided output]
- Measurement/query: [how to produce the record]
- Target/acceptance note: [threshold or expected note]
- Revisit: [date or cadence]
- Completion evidence: [research path, history entry, or report path]
- Promotion rule: [when to move into `tasks/todo.md`]
7c. Update tasks/recurring-todo.md
When recurring documentation work exists, append or replace a ## Documentation Recurring Work section in tasks/recurring-todo.md. Preserve all other sections exactly.
Use this item format:
- [ ] [recurring task]
- Cadence: [daily/weekly/monthly/quarterly/on release/etc.]
- Owner/agent: [/skill or responsible role]
- Scope: [project/app/area]
- Trigger: [time, release, data threshold, user request]
- Last run: [date or never]
- Next due: [date or rule]
- Command/skill: [/skill args]
- Evidence/output path: [research/report path]
- Escalation conditions: [when this becomes executable or blocking]
If all documentation is current:
- [x] Documentation is current; no missing or stale research, spec, roadmap, or task artifacts found.
8. Output To User
After editing, summarize:
## Research Roadmap Updated
- Wrote/updated `tasks/todo.md` and any needed advisory task files
- Priority documentation items: N
- Stale items: N
- Missing items: N
- Blocked-by-prerequisite items: N
- Record items: N
- Recurring items: N
Next: start at the first unchecked item in `tasks/todo.md`; review advisory task files separately.
If fallback discovery was used, include a short note naming the inferred roots.
Post-Prototype Process (--post-prototype)
Gate
A consolidated prototype must exist at prototypes/{topic}/consolidated/. If missing, halt and recommend /consolidate-variations first.
Scan
- Read the consolidated prototype directory to understand what was built.
- Read all research docs:
research/concept-brief.md,research/icp.md,research/competitive-analysis.md,research/journey-map.md, and any otherresearch/*.mdfiles. - For each research document, compare against the consolidated prototype:
- User flows: Does the prototype's flow match the journey map's discovery -> onboarding -> aha -> conversion -> retention path?
- Onboarding: Does the prototype's first-run experience match ICP expectations for technical sophistication and time-to-value?
- Density and copy: Does the prototype's information density and copy tone match ICP communication preferences?
- Interactions: Do the prototype's interaction patterns match journey-map touchpoints and competitive differentiation?
- Differentiation: Does the prototype demonstrate the competitive advantages identified in competitive analysis?
- Flag research documents that are contradicted or made stale by prototype decisions.
Output
Populate tasks/todo.md ## Priority Documentation Todo with research skills that need re-running, using the same format as the standard process. Each item must explain what the prototype revealed that contradicts or supersedes the current research document.
Next step: first unchecked queued item in tasks/todo.md.
Post-Spec Process (--post-spec)
Gate
A production spec must exist at specs/{topic}.md. If missing, halt and recommend /spec-interview first.
Scan
- Read the production spec to understand implementation constraints.
- Read all research docs.
- For each research document, compare against spec constraints:
- Auth model: Does the research assume an auth model that the spec changed?
- Data model: Does the research assume data structures that the spec redesigned?
- Performance: Does the research assume performance characteristics that the spec's architecture contradicts?
- Deployment: Does the research assume a deployment model that the spec changed?
- Flag research documents that are invalidated by spec constraints.
Output
Populate tasks/todo.md ## Priority Documentation Todo with research skills that need re-running. Each item must explain what spec constraint invalidates the current research document.
Next step: first unchecked queued item in tasks/todo.md.
Constraints
- This skill updates
tasks/todo.md,tasks/record-todo.md, andtasks/recurring-todo.md; it must not run the queued skills. - Preserve user-authored todo content outside
## Priority Documentation Todo. - Preserve user-authored record/recurring content outside
## Documentation Recordsand## Documentation Recurring Work. - Every stale item must include timestamp evidence.
- Every enabled research-producing skill must be represented unless its output is present and fresh.
- Prefer canonical
research/,specs/, andtasks/paths over aliases. - In monorepo mode, include app-scoped commands and output paths.
- Do not put condition-gated measurements, future validation records, or cadence-based research jobs into
tasks/todo.mdunless they are immediately executable. - Do not create or modify source code.
Alignment Page
When this skill produces durable deliverables (research, specs, plans, reports, prototypes, or any document output), build a full-depth HTML alignment page at alignment/research-roadmap-{topic}.html. Use a normalized topic slug derived from the app, feature, research subject, report subject, or output filename.
Full content requirement. The alignment page must contain the complete content of every proposed markdown deliverable -- every section, every finding, every detail, every list item. It is a thorough interactive review document, not a summary. Render the full deliverable content in clean, readable HTML with appropriate hierarchy, styling, and navigation. If the skill writes multiple scoped deliverables in one run, build one alignment page that contains all deliverables with anchor-linked navigation. Durable tracker artifacts, such as research/assumption-tracker.md, remain canonical markdown outputs but must also be fully rendered into the alignment page before approval.
Dark-mode styling. Use a dark color scheme by default. Base CSS variables: --bg: #0d1117; --surface: #161b22; --border: #30363d; --text: #c9d1d9; --text-muted: #8b949e; --accent: #58a6ff; --green: #3fb950; --red: #f85149; --orange: #d29922; --purple: #bc8cff;. Apply background: var(--bg); color: var(--text); on body. Use --surface for cards, nav, and table headers. Use --border for all borders. Use --purple for question blocks and gate headings. Use --accent for links and section headings. Keep headings color: #fff or var(--accent) for hierarchy. Question block backgrounds should use #1c2333.
Alignment gates. Treat gates as explicit review sections inside the HTML page. A gate blocks finalization until its required inline questions are answered and compiled into YAML. Include every gate that applies to the skill output, and include these gate types whenever relevant: evidence coverage, assumptions/confidence, scope/non-goals, candidate/verdict decisions, artifact destination, proposed file changes, coverage checkpoint, and post-approval route.
Report-only research gates. For report-only or pre-approval research skills, the alignment page must explicitly contain evidence coverage, assumptions/confidence, recommended path, proposed file changes, and approval gates before any canonical research, spec, or task file is created or updated.
Required inline questions. Each gate must contain at least one required inline question placed directly under the content it governs, inside a visually distinct question block. Each question must use radio-button inputs and include two standing options after the skill-generated choices: "Other / None of the above" backed by a multi-line text box for free-form input, and "Need clarification" backed by an optional notes box where the user can explain what is unclear. When any radio option other than "Other" or "Need clarification" is selected, show an optional "Additional notes" text box beneath it so the user can qualify their choice. Generate questions based on what genuinely needs user input -- do not add filler questions. Do not create a separate bottom "Decisions & Clarifications" section.
Gate YAML contract. At the bottom of the page, include a "Compile Answers" button that aggregates answers from all inline gate questions throughout the page, including free-text notes. The button remains disabled until every required question has a selection, shows a count of remaining unanswered questions, and scrolls to the first unanswered question if clicked early. When every question is answered, generate a structured YAML block with one item per gate answer using this stable shape: section, gate_type, status (answered, other, or needs-clarification), answer, optional notes, and optional target_artifact or target_path when the gate controls file output. After successful compilation, automatically attempt to copy the YAML to the clipboard with the Clipboard API, display copy status, and display the YAML in a read-only textarea with an explicit "Copy YAML" button. The copy button must retry clipboard copy when supported and fall back to selecting the textarea contents when clipboard access is unavailable or blocked.
Pre-approval stop. Before user approval, the next action is review of the HTML alignment page, not downstream routing. Ask the user to review the page and provide the compiled YAML answers. Do not include Recommended next skill, Recommended next command, or downstream routing language until after compiled YAML has been provided and the approved artifacts have been written or updated.
Diff highlighting on updates. When the agent updates an existing alignment page after receiving compiled answers, highlight what changed since the previous version. The agent chooses inline annotation or side-by-side layout per situation.
Archiving. Before replacing an existing alignment page, archive it to docs/history/archive/YYYY-MM-DD/HHMMSS/alignment/research-roadmap-{topic}.html.
Browser open. Attempt to open the resulting HTML page in the browser and report whether the open succeeded or was blocked. A blocked browser-open attempt does not make the skill fail when the files were written correctly.
Archive-First Replacement Policy
- Before replacing or substantively rewriting an existing canonical research/spec document (
research/**/*.md,specs/**/*.md, ordocs/specifications/**/*.md), copy the current file todocs/history/archive/YYYY-MM-DD/HHMMSS/<original-relative-path>. - Preserve the archived snapshot exactly as it existed before the change; do not edit the archived copy after creating it.
- After the archive snapshot exists, write the updated document to the original canonical path.
- Report both the archive path and the updated canonical path in the final output.
- New files do not need archive snapshots. Append-only updates do not need archive snapshots unless an existing section is regenerated or rewritten.
- Keep any existing user approval requirement before overwriting or replacing a document; archiving does not replace asking when the skill already requires approval.
Default Shipping Contract
- Default next-step routing: when reporting completion, include either
Recommended next skill: <command>or the two-line pair**Next work:** <specific task or "none">and**Recommended next command:** <one command or route>so the next operator has a concrete handoff. - If this skill creates or modifies tracked repository files, finish by committing and pushing all intended changes to the repository primary branch (
mainwhen present, otherwisemaster) before stopping, even if the user did not explicitly ask for commit/push. - Do not leave tracked changes or unpushed commits behind. If unrelated tracked work is already present, either include it in sensible commits too or stop and explain the blocker.
- This contract does not override stricter safety rules about secrets, destructive history changes, release publication/tag confirmation, or production deploy confirmation.