relay-workflow 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/.claude/skills/relay-analyze/SKILL.md +6 -0
  2. package/.claude/skills/relay-analyze/workflow.md +108 -0
  3. package/.claude/skills/relay-brainstorm/SKILL.md +6 -0
  4. package/.claude/skills/relay-brainstorm/workflow.md +114 -0
  5. package/.claude/skills/relay-cleanup/SKILL.md +6 -0
  6. package/.claude/skills/relay-cleanup/workflow.md +53 -0
  7. package/.claude/skills/relay-design/SKILL.md +6 -0
  8. package/.claude/skills/relay-design/workflow.md +108 -0
  9. package/.claude/skills/relay-discover/SKILL.md +6 -0
  10. package/.claude/skills/relay-discover/workflow.md +56 -0
  11. package/.claude/skills/relay-help/SKILL.md +6 -0
  12. package/.claude/skills/relay-help/workflow.md +165 -0
  13. package/.claude/skills/relay-new-issue/SKILL.md +6 -0
  14. package/.claude/skills/relay-new-issue/workflow.md +90 -0
  15. package/.claude/skills/relay-notebook/SKILL.md +6 -0
  16. package/.claude/skills/relay-notebook/workflow.md +264 -0
  17. package/.claude/skills/relay-order/SKILL.md +6 -0
  18. package/.claude/skills/relay-order/workflow.md +51 -0
  19. package/.claude/skills/relay-plan/SKILL.md +6 -0
  20. package/.claude/skills/relay-plan/workflow.md +133 -0
  21. package/.claude/skills/relay-resolve/SKILL.md +6 -0
  22. package/.claude/skills/relay-resolve/workflow.md +135 -0
  23. package/.claude/skills/relay-review/SKILL.md +6 -0
  24. package/.claude/skills/relay-review/workflow.md +163 -0
  25. package/.claude/skills/relay-scan/SKILL.md +6 -0
  26. package/.claude/skills/relay-scan/workflow.md +103 -0
  27. package/.claude/skills/relay-setup/SKILL.md +6 -0
  28. package/.claude/skills/relay-setup/workflow.md +296 -0
  29. package/.claude/skills/relay-verify/SKILL.md +6 -0
  30. package/.claude/skills/relay-verify/workflow.md +100 -0
  31. package/LICENSE +21 -0
  32. package/README.md +374 -0
  33. package/package.json +43 -0
  34. package/tools/cli.js +186 -0
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-analyze
3
+ description: 'Analyze and validate an item before implementation. Checks if the problem still exists, identifies root cause, and maps blast radius. Use as the first step when starting work on an item from relay-ordering.md.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.
@@ -0,0 +1,108 @@
1
+ # Relay: Code — Analyze & Validate
2
+
3
+ **Sequence**: **`/relay-analyze`** → `/relay-plan` → `/relay-review` → *implement* → `/relay-verify` → `/relay-notebook` → `/relay-resolve`
4
+
5
+ I want to work on [PHASE/ITEM from relay-ordering.md, e.g. "Phase 1A"].
6
+
7
+ Before writing any code, analyze and validate:
8
+
9
+ 1. Read .relay/relay-ordering.md to understand the target item(s) and their
10
+ context within the broader work sequence
11
+ 2. Read the full project landscape — current, archived, and implemented:
12
+ a. Read EVERY file in .relay/issues/ and .relay/features/ — not just the
13
+ target. You need the full picture of known problems and planned work
14
+ so your changes don't conflict with or ignore related items.
15
+ b. Read .relay/archive/issues/ and .relay/archive/features/ to understand
16
+ what was previously resolved and how. This prevents re-introducing
17
+ old bugs or duplicating past work.
18
+ c. Read .relay/implemented/ to understand the approaches taken for past
19
+ work — patterns, trade-offs, and caveats documented there may directly
20
+ affect your current work.
21
+ Summarize the relevant connections across all directories.
22
+ 3. Read the actual source files cited in the target item(s). The codebase may
23
+ have changed since the item was written. Verify:
24
+ - Does the bug/gap/requirement still exist at the cited line numbers?
25
+ - Has the code been refactored, moved, or partially addressed?
26
+ - Are the proposed implementation steps still valid?
27
+ If the item is stale, say so and recommend archiving or updating.
28
+ If the item is PARTIAL (some aspects already addressed outside the
29
+ pipeline): document what was already done, narrow the scope to what
30
+ remains, and proceed with analysis of the remaining work only.
31
+ 4. Root cause / requirements analysis — ask: are we addressing a symptom or
32
+ the real problem?
33
+ - Trace the problem upstream: what creates the bad state? (For features:
34
+ what creates the need?)
35
+ - Trace it downstream: what consumes the output? How will it change?
36
+ - Is there a deeper architectural issue that would make this change fragile?
37
+ - Are any OTHER items in .relay/issues/ or .relay/features/ caused by the
38
+ same root cause or motivated by the same need?
39
+ If so, should they be addressed together?
40
+ - Was this root cause previously addressed (check .relay/archive/issues/,
41
+ .relay/archive/features/, and .relay/implemented/)? If so, did the previous
42
+ work regress, or is this a different manifestation of the same
43
+ underlying problem?
44
+ 5. Blast radius mapping — for every proposed change, identify:
45
+ - Direct callers (who calls this function/method?)
46
+ - Indirect consumers (who uses the output downstream?)
47
+ - Test coverage (which tests exercise this path? which don't?)
48
+ - Config surface (does this change interact with any config options?)
49
+ - Related items (does this change affect any other known issue or feature,
50
+ positively or negatively?)
51
+ - Past work at risk (does this change touch code that was modified by a
52
+ previous change in .relay/implemented/? Could it undo or destabilize
53
+ that work?)
54
+ 6. Produce a structured analysis covering: validation, root cause,
55
+ blast radius, and approach. See step 7 for the exact format to persist.
56
+
57
+ Do NOT write code yet. Do NOT create a plan yet. Just analyze.
58
+
59
+ 7. Persist the analysis by APPENDING it to each relevant issue/feature file in
60
+ .relay/issues/ or .relay/features/. Add a horizontal rule separator, then
61
+ append the structured analysis:
62
+
63
+ ---
64
+
65
+ ## Analysis
66
+
67
+ *Analyzed: [YYYY-MM-DD]*
68
+
69
+ ### Validation
70
+ - Problem/requirement still exists: YES/NO (with current line numbers if shifted)
71
+ - Proposed approach still valid: YES/NO/NEEDS ADJUSTMENT
72
+
73
+ ### Root Cause
74
+ - What creates the bad state / what drives the requirement
75
+ - Whether this is a symptom of something deeper
76
+ - Related issues/features that share the same root cause or motivation
77
+
78
+ ### Blast Radius
79
+ - Files affected (with function names)
80
+ - Callers and consumers
81
+ - Test coverage status
82
+ - Config interactions
83
+ - Cross-item interactions (current .relay/issues/ and .relay/features/)
84
+ - Past work regression risk (.relay/archive/ + .relay/implemented/)
85
+
86
+ ### Approach
87
+ - Recommended approach (may differ from the issue/feature file's proposal)
88
+ - Alternatives considered and why they were rejected
89
+ - Open questions or decisions needed before implementation
90
+
91
+ Output: Updated issue/feature file(s) in .relay/issues/ or .relay/features/ with analysis appended
92
+
93
+ ## Navigation
94
+ When finished, tell the user the next step based on the outcome:
95
+ - If the item is stale (the bug/gap no longer exists in the code, was already addressed outside the pipeline, or the requirement is no longer valid):
96
+ "This item is stale. Run **/relay-resolve** to archive it as a stale close-out. Then run **/relay-scan** to refresh project status."
97
+ - Otherwise:
98
+ "Next: run **/relay-plan** to create the implementation plan."
99
+
100
+ ## Notes
101
+
102
+ - The analysis is persisted in the issue/feature file so it survives across conversations and is available to /relay-plan
103
+ - This skill forces validation before planning — catching stale items and wrong approaches early
104
+ - The "read all items" step is critical: it prevents changes that conflict with other known problems or planned features
105
+ - Reading archive/ and implemented/ provides historical context — knowing what was already tried, what approaches worked, and what caveats were noted prevents repeating mistakes and protects past work from regression
106
+ - If the analysis reveals the item is stale, the right action is to update/archive the issue/feature file, not proceed with implementation
107
+ - If multiple items share a root cause, consider proposing a combined approach
108
+ - If past work is at risk of regression, call it out explicitly in the Blast Radius section
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-brainstorm
3
+ description: 'Interactive brainstorming session for a new feature idea. Explores approaches, trade-offs, and produces a brainstorm file. Use when you have a feature idea to explore.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.
@@ -0,0 +1,114 @@
1
+ # Relay: Feature — Brainstorm & Explore
2
+
3
+ **Sequence**: **`/relay-brainstorm`** → `/relay-design` → `/relay-scan` → `/relay-order` → `/relay-analyze` → `/relay-plan` → `/relay-review` → *implement* → `/relay-verify` → `/relay-notebook` → `/relay-resolve`
4
+
5
+ I want to explore a feature idea: [DESCRIPTION]
6
+
7
+ Guide me through brainstorming this feature interactively.
8
+
9
+ 1. Understand the idea:
10
+ - Ask clarifying questions about what I'm trying to achieve
11
+ - Don't assume scope — let me define it through conversation
12
+ - Identify the core problem or opportunity this feature addresses
13
+
14
+ 2. Explore the codebase for context:
15
+ - What existing code, patterns, and abstractions are relevant?
16
+ - What architectural constraints exist that shape what's possible?
17
+ - Check for related work across the full docs landscape:
18
+ - .relay/features/ — is something similar already planned?
19
+ - .relay/issues/ — are there known issues this feature would affect?
20
+ - .relay/implemented/ — has something similar been built before?
21
+ - .relay/archive/features/ and .relay/archive/issues/ — was this
22
+ previously attempted, designed, or rejected?
23
+ - What would this feature interact with in the current codebase?
24
+
25
+ 3. Identify implementation approaches:
26
+ - Present 2-3 distinct approaches with trade-offs
27
+ - For each: how it fits the current architecture, complexity,
28
+ what it enables, what it limits
29
+ - Surface constraints I might not know about
30
+ - Ask me which direction resonates
31
+
32
+ 4. As the conversation progresses, manage the brainstorm file explicitly:
33
+ - Ask before CREATING the file for the first time:
34
+ "Should I create the brainstorm file with what we have so far?"
35
+ - Once the file exists, update it as decisions land — record each
36
+ decision when it is settled without asking each time.
37
+ - Ask before STRUCTURAL changes: adding or removing a feature from
38
+ the Feature Breakdown table, changing the Development Order, or
39
+ updating the brainstorm status. Example:
40
+ "We've landed on [feature X] as a separate feature — should I add
41
+ it to the breakdown table?"
42
+ Do NOT silently accumulate decisions and batch them — record each
43
+ decision as it is settled, not at the end.
44
+
45
+ 5. Create and maintain a brainstorm file in .relay/features/:
46
+ - Naming: [topic]_brainstorm.md (e.g., rls_brainstorm.md)
47
+ - This is a LIVING DOCUMENT — update it throughout the conversation
48
+ as decisions are made, not just at the end.
49
+ - Structure:
50
+
51
+ # Feature Brainstorm: [Topic]
52
+
53
+ *Created: [YYYY-MM-DD]*
54
+ *Status: BRAINSTORMING*
55
+ (Lifecycle: BRAINSTORMING → READY FOR DESIGN → DESIGN COMPLETE → COMPLETE)
56
+
57
+ ## Goal
58
+ [What we're trying to achieve — refined through conversation]
59
+
60
+ ## Context
61
+ [Relevant codebase patterns, constraints, existing code discovered]
62
+
63
+ ## Approaches Considered
64
+ ### Approach A: [name]
65
+ - Description, trade-offs, verdict (selected/rejected + why)
66
+ ### Approach B: [name]
67
+ - Description, trade-offs, verdict (selected/rejected + why)
68
+
69
+ ## Decisions Made
70
+ - [numbered list of decisions with rationale, accumulated as we go]
71
+
72
+ ## Feature Breakdown
73
+
74
+ [If this brainstorm produces multiple features, list ALL of them
75
+ here as an accumulation. If it produces a single feature, this
76
+ table has one row.]
77
+
78
+ | # | Feature File | Description | Suggested Order | Dependencies |
79
+ |---|-------------|-------------|-----------------|--------------|
80
+ | 1 | `[name].md` | ... | Build first | None |
81
+ | 2 | `[name].md` | ... | Build second | Depends on 1 |
82
+
83
+ ## Development Order
84
+ [Recommended order with rationale. This is advisory —
85
+ /relay-order makes the final project-wide call,
86
+ but this captures the intra-feature dependencies.]
87
+
88
+ ## Open Questions
89
+ [Anything unresolved that /relay-design needs to address]
90
+
91
+ 6. When brainstorming feels complete:
92
+ - Update the brainstorm file status to READY FOR DESIGN
93
+ - Confirm the feature breakdown and proposed file names with the user
94
+ - Confirm the suggested development order with the user
95
+
96
+ Do NOT design implementation details yet — that's /relay-design.
97
+ Do NOT create individual feature files — only the brainstorm file.
98
+ Focus on WHAT and WHY, not HOW.
99
+
100
+ ## Navigation
101
+ When brainstorming is complete, tell the user:
102
+ - "Next: run **/relay-design** to design each feature in detail."
103
+
104
+ ## Notes
105
+
106
+ - This is intentionally interactive — ask questions, don't monologue
107
+ - The brainstorm file is updated throughout the conversation as decisions are made, not dumped at the end
108
+ - Ask before the first creation; once the file exists, update routine decisions freely. Ask before structural changes (new Feature Breakdown entry, Development Order changes, status transitions)
109
+ - Only ONE brainstorm file is created, even for multi-feature ideas — it accumulates all the areas/namespaces
110
+ - The Feature Breakdown table is the handoff contract to /relay-design — it names the files and describes what each one covers. /relay-design will create the individual feature files listed in the table.
111
+ - Suggested development order is recorded so /relay-design and eventually /relay-order can use it
112
+ - If the idea is simple (one feature, obvious approach), this phase can be brief
113
+ - If the idea is complex (architectural decisions, multiple features), this phase may take several rounds
114
+ - If the brainstorm reveals this is actually a bug/gap rather than a feature, pivot to /relay-new-issue
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-cleanup
3
+ description: 'Archive abandoned brainstorm files in .relay/features/. Use periodically to clean up brainstorms that were started but never completed through relay-design.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.
@@ -0,0 +1,53 @@
1
+ # Relay: Feature — Cleanup Abandoned Brainstorms
2
+
3
+ **Sequence**: **`/relay-cleanup`** (standalone utility)
4
+
5
+ Clean up orphaned brainstorm files in .relay/features/.
6
+
7
+ This utility handles brainstorm files that were started but abandoned.
8
+ Brainstorms with status DESIGN COMPLETE or COMPLETE are managed by the
9
+ main workflow (/relay-resolve archives COMPLETE brainstorms automatically).
10
+
11
+ 1. Read every *_brainstorm.md file in .relay/features/.
12
+
13
+ 2. For each brainstorm file, check its status:
14
+ - COMPLETE — should already have been archived by /relay-resolve.
15
+ If found here, archive it (see step 3) with banner:
16
+ > **ARCHIVED** — All features resolved.
17
+ - DESIGN COMPLETE — features may still be in progress. Check the
18
+ Feature Breakdown table: if ALL listed feature files have been
19
+ archived (exist in .relay/archive/features/ but not in .relay/features/),
20
+ this brainstorm was missed by /relay-resolve. Treat it like COMPLETE
21
+ and archive it with banner:
22
+ > **ARCHIVED** — All features resolved.
23
+ If some features are still active in .relay/features/, leave it alone.
24
+ - READY FOR DESIGN — this brainstorm is waiting for /relay-design.
25
+ Ask the user: "Brainstorm [filename] has status READY FOR DESIGN.
26
+ Should I archive it, or leave it for /relay-design?"
27
+ - BRAINSTORMING — this brainstorm was started but never completed.
28
+ Ask the user: "Brainstorm [filename] has status BRAINSTORMING
29
+ (incomplete). Should I archive it?"
30
+
31
+ 3. For each brainstorm the user wants archived:
32
+ - Move it from .relay/features/[file].md to .relay/archive/features/[file].md
33
+ - Add the appropriate banner at the top based on status:
34
+ - COMPLETE: `> **ARCHIVED** — All features resolved.`
35
+ - READY FOR DESIGN: `> **ARCHIVED** — Abandoned. Was ready for design but not progressed.`
36
+ - BRAINSTORMING: `> **ARCHIVED** — Abandoned. Brainstorming was not completed.`
37
+ - If any individual feature files in .relay/features/ reference this
38
+ brainstorm (check the *Brainstorm:* metadata line), warn the user
39
+ that orphaned feature files exist and ask how to handle them.
40
+
41
+ 4. Report what was archived and what was left in place.
42
+
43
+ ## Navigation
44
+ When finished, tell the user:
45
+ - "Cleanup complete. Run **/relay-scan** if you want to refresh the project status."
46
+
47
+ ## Notes
48
+
49
+ - This is a utility skill — run it when brainstorm files accumulate
50
+ - COMPLETE brainstorms are normally archived by /relay-resolve — this skill is a fallback if one was missed
51
+ - DESIGN COMPLETE brainstorms are left alone — their features are in the code pipeline
52
+ - Always ask the user before archiving BRAINSTORMING and READY FOR DESIGN files — they may be intentionally paused, not abandoned
53
+ - If a brainstorm has associated feature files that were already created by /relay-design, those feature files are independent and should NOT be archived just because the brainstorm is
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-design
3
+ description: 'Design features from a brainstorm file into detailed specs. Creates individual feature files with architecture, interfaces, and data flow. Use after relay-brainstorm produces a READY FOR DESIGN brainstorm.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.
@@ -0,0 +1,108 @@
1
+ # Relay: Feature — Design & Specify
2
+
3
+ **Sequence**: `/relay-brainstorm` → **`/relay-design`** → `/relay-scan` → `/relay-order` → `/relay-analyze` → `/relay-plan` → `/relay-review` → *implement* → `/relay-verify` → `/relay-notebook` → `/relay-resolve`
4
+
5
+ Design the features from the brainstorm file.
6
+
7
+ A brainstorm file (*_brainstorm.md with status READY FOR DESIGN) must exist
8
+ in .relay/features/ before running this skill. If none exists, tell the user
9
+ to run **/relay-brainstorm** first.
10
+
11
+ 1. Read the brainstorm file in .relay/features/:
12
+ - Find all *_brainstorm.md files with status READY FOR DESIGN
13
+ - If multiple brainstorm files have status READY FOR DESIGN, list
14
+ them and ask the user which one to design first. Process one
15
+ brainstorm per invocation.
16
+ - Read it for the Feature Breakdown table, decisions, development
17
+ order, and open questions
18
+
19
+ 2. For each feature listed in the Feature Breakdown, in the suggested
20
+ development order:
21
+
22
+ a. Deep-dive into the codebase:
23
+ - Read the specific files, modules, and interfaces this feature touches
24
+ - Understand the existing patterns and abstractions it must fit into
25
+ - Check .relay/issues/ for known problems that interact with this feature
26
+ - Check .relay/implemented/ and .relay/archive/ for past work that's relevant
27
+ - Identify what's new code vs modifications to existing code
28
+
29
+ b. Design the feature iteratively with the user:
30
+ - Present the proposed architecture: components, data flow, interfaces
31
+ - Highlight decisions that need user input
32
+ - Ask: "Does this design match what you had in mind?"
33
+ - Adjust based on feedback before committing to the file
34
+
35
+ c. Create the individual feature file in .relay/features/:
36
+ - Use the filename specified in the brainstorm's Feature Breakdown
37
+ - Structure:
38
+
39
+ # Feature: [Title]
40
+
41
+ *Created: [YYYY-MM-DD]*
42
+ *Brainstorm: [link to brainstorm file — include both paths:
43
+ Active: .relay/features/[topic]_brainstorm.md
44
+ Archived: .relay/archive/features/[topic]_brainstorm.md]*
45
+ *Status: DESIGNED*
46
+
47
+ ## Summary
48
+ [1-2 sentence description of what this feature does]
49
+
50
+ ## Motivation
51
+ [Why this feature is needed — from the brainstorm decisions]
52
+
53
+ ## Design
54
+
55
+ ### Architecture
56
+ [Components, how they fit into the existing codebase]
57
+
58
+ ### Interfaces
59
+ [New or modified APIs, function signatures, data structures]
60
+
61
+ ### Data Flow
62
+ [How data moves through the feature]
63
+
64
+ ### Integration Points
65
+ [Where this connects to existing code — specific files and functions]
66
+
67
+ ## Affected Files
68
+ - [list of files that need creation or modification]
69
+
70
+ ## Dependencies
71
+ - [Other features or issues that must be completed first]
72
+ - Brainstorm: [link to brainstorm file]
73
+ - Related features: [links to sibling feature files from same brainstorm]
74
+
75
+ ## Development Order
76
+ [Position in the sequence from the brainstorm, with rationale.
77
+ e.g., "2 of 3 — requires [feature_1].md to be implemented first
78
+ because it depends on the interfaces defined there."]
79
+
80
+ ## Open Questions
81
+ [Anything deferred or needing resolution during implementation]
82
+
83
+ d. After creating each feature file, explicitly ask the user:
84
+ - "Does this design look right before I move to the next feature?"
85
+ - If changes are needed, update the file before proceeding
86
+
87
+ 3. After all feature files are created:
88
+ - Set the brainstorm file's status to DESIGN COMPLETE
89
+ - Update the Feature Breakdown table with links to the created files
90
+ - Summarize what was created and the development order
91
+
92
+ Do NOT update relay-status.md or relay-ordering.md — that is the
93
+ responsibility of the prepare skills.
94
+ Do NOT create implementation plans — that is /relay-plan's job.
95
+
96
+ ## Navigation
97
+ When finished, tell the user:
98
+ - "Next: run **/relay-scan** to update project status, then **/relay-order** to integrate these into the backlog. Then run **/relay-analyze** to begin implementation."
99
+
100
+ ## Notes
101
+
102
+ - Each feature file is self-contained but links back to the brainstorm for context and links to sibling features
103
+ - The design should be detailed enough for /relay-plan to create an implementation plan from it
104
+ - Development order is recorded in each file, but /relay-order makes the final project-wide prioritization
105
+ - If designing reveals the brainstorm's breakdown was wrong (features should be split or merged differently), update the brainstorm file and confirm with the user before proceeding
106
+ - For simple single-feature brainstorms, this phase creates one file and is brief
107
+ - For multi-feature brainstorms, iterate through each feature in the suggested order — earlier designs inform later ones
108
+ - If the design reveals new issues or conflicts with existing code, note them in the feature file's Open Questions section — do not create issue files mid-design
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-discover
3
+ description: 'Scan the codebase to discover bugs, gaps, inconsistencies, and technical debt. Creates issue files in .relay/issues/. Use periodically or after significant code changes.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.
@@ -0,0 +1,56 @@
1
+ # Relay: Discover Issues
2
+
3
+ **Sequence**: **`/relay-discover`** → `/relay-scan` → `/relay-order` → `/relay-analyze` → ...
4
+
5
+ Scan the codebase to discover issues. For each issue found, create a
6
+ new .md file in .relay/issues/.
7
+
8
+ 1. Read the full docs landscape to understand what's already known:
9
+ - .relay/issues/ — currently tracked problems
10
+ - .relay/features/ — planned work
11
+ - .relay/implemented/ — completed work and how it was done
12
+ - .relay/archive/issues/ — previously resolved issues
13
+ - .relay/archive/features/ — previously resolved features
14
+ Do NOT re-report anything that is already documented, previously
15
+ resolved, or archived. If an archived issue has regressed, reference
16
+ the archive file and explain what changed.
17
+ 2. Read .relay/relay-status.md (if it exists) for current tracked items
18
+ 3. Scan the codebase systematically. Look for:
19
+ - Bugs: logic errors, unhandled edge cases, broken code paths
20
+ - Gaps: missing functionality referenced in docs, specs, or PRDs but not implemented
21
+ - Inconsistencies: mismatches between schema and code, API docs vs actual signatures
22
+ - Dead code: unused imports, unreachable branches, stale config options
23
+ - Security: injection risks, missing validation, unsafe defaults
24
+ - Performance: N+1 queries, unbounded loops, missing indexes
25
+ - Test gaps: untested critical paths, assertions that don't verify behavior
26
+ - Error handling: swallowed exceptions, missing error paths, unhelpful messages
27
+ 4. For each distinct issue found:
28
+ a. Check .relay/issues/ — skip if already documented
29
+ b. Check .relay/features/ — if a feature file with the same name or topic
30
+ exists, note the overlap and use a distinct filename that clarifies this
31
+ is an issue (e.g., prefix with the specific problem)
32
+ c. Create .relay/issues/[descriptive_name].md with:
33
+ - *Created: [YYYY-MM-DD]*
34
+ - Title and severity (P0 critical / P1 high / P2 medium / P3 low)
35
+ - Problem statement: what's wrong and why it matters
36
+ - Current state: exact file paths, line numbers, code snippets
37
+ - Impact: what breaks, what's degraded, who's affected
38
+ - Proposed fix: concrete remediation steps
39
+ - Affected files: list of files that need changes
40
+ Focus on real, actionable issues. Do not report style preferences,
41
+ minor naming quibbles, or hypothetical problems that require unlikely inputs.
42
+
43
+ Output: New issue files in .relay/issues/
44
+
45
+ ## Navigation
46
+ When finished, tell the user:
47
+ - "Next: run **/relay-scan** to update project status, then **/relay-order** to prioritize the work."
48
+
49
+ ## Scoping Variants
50
+
51
+ To narrow the scan, the user can append one of these:
52
+
53
+ - **Scope to a module**: `Focus your scan on src/search/ and src/extraction/`
54
+ - **Scope to a concern**: `Focus on security issues only`
55
+ - **Scope to recent changes**: `Focus on files changed in the last 5 commits (use git diff)`
56
+ - **Depth**: `Do a deep scan — read every function body` vs `Do a quick scan — focus on public API and integration points`
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-help
3
+ description: 'Navigate the Relay workflow. Analyzes current project state, helps you decide what to do, and routes you to the right skill. Use when you need guidance, want to file something but are not sure if it is an issue or feature, or say what should I do next.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.
@@ -0,0 +1,165 @@
1
+ # Relay: Help & Navigation
2
+
3
+ Analyze the user's intent and current project state, then guide them to the right skill.
4
+
5
+ ## Execution
6
+
7
+ ### Step 0 — Parse user input
8
+
9
+ The user may invoke this skill in several ways:
10
+
11
+ **With a description** (intent-based):
12
+ ```
13
+ /relay-help I want to add authentication
14
+ /relay-help The search API is returning duplicates
15
+ /relay-help What should I do next?
16
+ /relay-help I found a bug in the parser
17
+ ```
18
+
19
+ **Without a description** (state-based):
20
+ ```
21
+ /relay-help
22
+ ```
23
+
24
+ If the user provided a description, go to **Step 1 (Intent routing)**.
25
+ If no description, skip to **Step 2 (Setup check)**.
26
+
27
+ ---
28
+
29
+ ### Step 1 — Intent routing
30
+
31
+ The user described what they want. Classify their intent and route them:
32
+
33
+ **a) They describe a problem, bug, or gap** (something broken, missing, wrong):
34
+ → "This sounds like an issue. Run **/relay-new-issue** to file it:
35
+ `/relay-new-issue [their description]`
36
+ The skill will investigate, confirm it's an issue, and create the file. If it turns out to be a feature, it will redirect you to **/relay-brainstorm**."
37
+
38
+ **b) They describe a feature, enhancement, or new capability** (something to build):
39
+ → "This sounds like a feature. Run **/relay-brainstorm** to explore it:
40
+ `/relay-brainstorm [their description]`
41
+ The skill will ask clarifying questions and help you design it interactively."
42
+
43
+ **c) They're unsure or it's ambiguous** (could be either):
44
+ → "Not sure if this is a bug or a feature? Run **/relay-new-issue** — it will investigate the codebase, determine whether it's an issue or a feature, and route you accordingly. Features get redirected to **/relay-brainstorm** automatically."
45
+
46
+ **d) They want to scan for problems** ("find issues", "what's broken", "audit"):
47
+ → "Run **/relay-discover** to systematically scan the codebase for bugs, gaps, and issues."
48
+
49
+ **e) They want to continue or resume work** ("what's next", "where was I", "continue"):
50
+ → Skip to **Step 2** and proceed with state-based detection.
51
+
52
+ **f) They ask about Relay itself** ("how does relay work", "what skills are available"):
53
+ → Show the **Available Relay Skills** table and **Workflow Paths** section below. Explain that Relay has three entry points: scan for issues, file a specific item, or brainstorm a feature — and all paths lead through the same code pipeline.
54
+
55
+ After routing, also mention the current project state if relevant (e.g., "You also have 2 items in progress — run `/relay-help` without a description to see their status").
56
+
57
+ ---
58
+
59
+ ### Step 2 — Check if Relay is set up
60
+
61
+ - Look for `.relay/` directory. If it doesn't exist, tell the user:
62
+ "Relay is not set up in this project. Run **/relay-setup** to initialize."
63
+ Stop here.
64
+
65
+ ### Step 3 — Read current state
66
+
67
+ - Read `.relay/version.md` (if it exists) for installed version info
68
+ - Read `.relay/relay-status.md` (if it exists) for item counts, in-progress work, and staleness flags
69
+ - Read `.relay/relay-ordering.md` (if it exists) for the current work plan
70
+ - Check `.relay/issues/` and `.relay/features/` for active items
71
+ - Check `.relay/notebooks/` for in-progress notebooks
72
+
73
+ ### Step 4 — Detect where the user is in the workflow
74
+
75
+ **No items at all** (empty issues/ and features/):
76
+ → "Your project has no tracked items yet. What would you like to do?
77
+ - **/relay-discover** — scan the codebase for bugs, gaps, and issues
78
+ - **/relay-new-issue** — file a specific bug or gap you already know about
79
+ - **/relay-brainstorm** — explore a new feature idea
80
+ Tell me what you're thinking and I'll point you to the right skill."
81
+
82
+ **Items exist but no relay-status.md or it's stale (>1 day old)**:
83
+ → "Your status file needs refreshing. Run **/relay-scan** to update, then **/relay-order** to prioritize."
84
+
85
+ **Items exist with up-to-date status but no relay-ordering.md**:
86
+ → "Status is current but work isn't prioritized. Run **/relay-order** to create the work plan."
87
+
88
+ **Ordering exists with outstanding phases**:
89
+ Check if any items are in-progress (have pipeline sections appended):
90
+ - If in-progress items found, recommend resuming from their current stage.
91
+ Check sections in the item file to determine stage (check in this order —
92
+ later conditions take precedence over earlier ones):
93
+ - Has ## Analysis but no ## Implementation Plan → "Resume with **/relay-plan** on [item]"
94
+ - Has ## Implementation Plan but no ## Adversarial Review → "Resume with **/relay-review** on [item]"
95
+ - Has ## Adversarial Review with verdict REJECTED → "Plan was rejected. Resume with **/relay-plan** on [item] to revise"
96
+ - Has ## Adversarial Review (APPROVED/APPROVED WITH CHANGES) but no ## Implementation Guidelines → "Ready to implement [item]. Say **'implement the plan'**"
97
+ - Has ## Implementation Guidelines but no ## Verification Report → "Implementation may be done. Resume with **/relay-verify** on [item]"
98
+ - Has ## Verification Report with verdict INCOMPLETE or HAS ISSUES → "Verification found issues. Resume with **/relay-verify** on [item]"
99
+ - Has ## Verification Report with verdict COMPLETE but no notebook in .relay/notebooks/ → "Resume with **/relay-notebook** on [item]"
100
+ - Has matching notebook in .relay/notebooks/ → "Ready to close out. Run **/relay-resolve** on [item]"
101
+ - If no in-progress items, recommend starting the next phase:
102
+ → "Next up: [Phase X] from relay-ordering.md. Run **/relay-analyze** to begin."
103
+ - Always add: "You can also file new items anytime with **/relay-new-issue** or **/relay-brainstorm**."
104
+
105
+ **All phases complete**:
106
+ → "All planned work is complete! Options:
107
+ - **/relay-discover** — scan for new issues
108
+ - **/relay-brainstorm** — explore new features
109
+ - **/relay-new-issue** — file a specific bug or gap
110
+ - **/relay-scan** — refresh status to confirm everything is clean"
111
+
112
+ **Feature pipeline in progress**:
113
+ - Brainstorm with status BRAINSTORMING → "Continue brainstorming with **/relay-brainstorm**"
114
+ - Brainstorm with status READY FOR DESIGN → "Design the features with **/relay-design**"
115
+ - Features DESIGNED but not in ordering → "Run **/relay-scan** then **/relay-order** to integrate features into the work plan"
116
+ - Brainstorms with BRAINSTORMING or READY FOR DESIGN that are older than 7 days → also mention: "You have stale brainstorms. Run **/relay-cleanup** to archive abandoned ones."
117
+
118
+ ### Step 5 — Present recommendations
119
+
120
+ - Show the current state summary (items count, what's in progress)
121
+ - Recommend the specific next action with the skill command
122
+ - If multiple paths are available, list them with brief explanations
123
+ - If the user seems unsure, ask what they're trying to accomplish
124
+
125
+ ## Available Relay Skills
126
+
127
+ | Skill | Purpose |
128
+ |-------|---------|
129
+ | **/relay-setup** | Initialize Relay in a new project |
130
+ | **/relay-discover** | Scan codebase for bugs, gaps, issues |
131
+ | **/relay-new-issue** | File a specific bug or gap |
132
+ | **/relay-brainstorm** | Explore a new feature idea |
133
+ | **/relay-design** | Design features from brainstorm |
134
+ | **/relay-cleanup** | Archive abandoned brainstorms |
135
+ | **/relay-scan** | Update project status |
136
+ | **/relay-order** | Prioritize work |
137
+ | **/relay-analyze** | Validate item before implementation |
138
+ | **/relay-plan** | Create implementation plan |
139
+ | **/relay-review** | Adversarial review of plan |
140
+ | **/relay-verify** | Verify implementation |
141
+ | **/relay-notebook** | Create verification notebook |
142
+ | **/relay-resolve** | Close out and archive completed work |
143
+
144
+ ## Workflow Paths
145
+
146
+ ```
147
+ Specific issue → /relay-new-issue → /relay-scan → /relay-order → /relay-analyze → ... → /relay-resolve
148
+ Systematic scan → /relay-discover → /relay-scan → /relay-order → /relay-analyze → ... → /relay-resolve
149
+ Feature idea → /relay-brainstorm → /relay-design → /relay-scan → /relay-order → /relay-analyze → ... → /relay-resolve
150
+ ```
151
+
152
+ ## Code Pipeline
153
+
154
+ ```
155
+ /relay-analyze → /relay-plan → /relay-review → implement → /relay-verify → /relay-notebook → /relay-resolve
156
+ ```
157
+
158
+ ## Notes
159
+
160
+ - This skill reads .relay/ state files but does not modify them
161
+ - If relay-status.md exists, use its dates and in-progress tables rather than re-scanning the codebase
162
+ - When multiple paths are available, present all options but highlight the recommended one
163
+ - Run each Relay skill in a fresh conversation for best results
164
+ - When the user provides a description, prioritize intent routing (Step 1) over state detection (Step 4)
165
+ - /relay-new-issue is the universal entry point for uncertain items — it investigates and redirects features automatically
@@ -0,0 +1,6 @@
1
+ ---
2
+ name: relay-new-issue
3
+ description: 'File a specific bug or gap as an issue. Redirects features to relay-brainstorm. Use when you have identified a specific problem to document.'
4
+ ---
5
+
6
+ Follow the instructions in ./workflow.md.