ruby_reactor 0.5.3 → 0.6.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 (72) hide show
  1. checksums.yaml +4 -4
  2. data/.claude/skills/speckit-agent-context-update/SKILL.md +32 -0
  3. data/.claude/skills/speckit-analyze/SKILL.md +262 -0
  4. data/.claude/skills/speckit-checklist/SKILL.md +374 -0
  5. data/.claude/skills/speckit-clarify/SKILL.md +286 -0
  6. data/.claude/skills/speckit-constitution/SKILL.md +157 -0
  7. data/.claude/skills/speckit-converge/SKILL.md +277 -0
  8. data/.claude/skills/speckit-implement/SKILL.md +224 -0
  9. data/.claude/skills/speckit-plan/SKILL.md +171 -0
  10. data/.claude/skills/speckit-specify/SKILL.md +346 -0
  11. data/.claude/skills/speckit-tasks/SKILL.md +215 -0
  12. data/.claude/skills/speckit-taskstoissues/SKILL.md +110 -0
  13. data/.release-please-manifest.json +1 -1
  14. data/.specify/extensions/.registry +19 -0
  15. data/.specify/extensions/agent-context/README.md +66 -0
  16. data/.specify/extensions/agent-context/agent-context-config.yml +5 -0
  17. data/.specify/extensions/agent-context/commands/speckit.agent-context.update.md +27 -0
  18. data/.specify/extensions/agent-context/extension.yml +34 -0
  19. data/.specify/extensions/agent-context/scripts/bash/update-agent-context.sh +282 -0
  20. data/.specify/extensions/agent-context/scripts/powershell/update-agent-context.ps1 +353 -0
  21. data/.specify/extensions.yml +23 -0
  22. data/.specify/feature.json +3 -0
  23. data/.specify/init-options.json +9 -0
  24. data/.specify/integration.json +15 -0
  25. data/.specify/integrations/claude.manifest.json +17 -0
  26. data/.specify/integrations/speckit.manifest.json +17 -0
  27. data/.specify/memory/constitution.md +134 -0
  28. data/.specify/scripts/bash/check-prerequisites.sh +189 -0
  29. data/.specify/scripts/bash/common.sh +619 -0
  30. data/.specify/scripts/bash/create-new-feature.sh +299 -0
  31. data/.specify/scripts/bash/setup-plan.sh +84 -0
  32. data/.specify/scripts/bash/setup-tasks.sh +91 -0
  33. data/.specify/templates/checklist-template.md +40 -0
  34. data/.specify/templates/constitution-template.md +50 -0
  35. data/.specify/templates/plan-template.md +113 -0
  36. data/.specify/templates/spec-template.md +131 -0
  37. data/.specify/templates/tasks-template.md +252 -0
  38. data/.specify/workflows/speckit/workflow.yml +77 -0
  39. data/.specify/workflows/workflow-registry.json +13 -0
  40. data/CHANGELOG.md +14 -0
  41. data/README.md +146 -65
  42. data/lib/ruby_reactor/adapters/active_job/compat.rb +24 -0
  43. data/lib/ruby_reactor/adapters/active_job/map_collector_worker.rb +19 -0
  44. data/lib/ruby_reactor/adapters/active_job/map_element_worker.rb +19 -0
  45. data/lib/ruby_reactor/adapters/active_job/router.rb +91 -0
  46. data/lib/ruby_reactor/adapters/active_job/sweeper_worker.rb +16 -0
  47. data/lib/ruby_reactor/adapters/active_job/worker.rb +24 -0
  48. data/lib/ruby_reactor/adapters/sidekiq/map_collector_worker.rb +15 -0
  49. data/lib/ruby_reactor/adapters/sidekiq/map_element_worker.rb +15 -0
  50. data/lib/ruby_reactor/adapters/sidekiq/router.rb +91 -0
  51. data/lib/ruby_reactor/adapters/sidekiq/sweeper_worker.rb +19 -0
  52. data/lib/ruby_reactor/adapters/sidekiq/worker.rb +25 -0
  53. data/lib/ruby_reactor/configuration.rb +24 -4
  54. data/lib/ruby_reactor/dsl/template_helpers.rb +7 -1
  55. data/lib/ruby_reactor/map/element_executor.rb +1 -1
  56. data/lib/ruby_reactor/rspec/active_job_helpers.rb +52 -0
  57. data/lib/ruby_reactor/rspec/async_test_helpers.rb +41 -0
  58. data/lib/ruby_reactor/rspec/sidekiq_helpers.rb +3 -3
  59. data/lib/ruby_reactor/rspec/test_subject.rb +11 -7
  60. data/lib/ruby_reactor/rspec.rb +4 -0
  61. data/lib/ruby_reactor/step.rb +4 -0
  62. data/lib/ruby_reactor/sweeper_job.rb +70 -0
  63. data/lib/ruby_reactor/version.rb +1 -1
  64. data/lib/ruby_reactor/worker.rb +226 -0
  65. data/lib/ruby_reactor.rb +40 -1
  66. data/specs/active_job.md +259 -0
  67. metadata +54 -6
  68. data/lib/ruby_reactor/sidekiq_adapter.rb +0 -87
  69. data/lib/ruby_reactor/sidekiq_workers/map_collector_worker.rb +0 -13
  70. data/lib/ruby_reactor/sidekiq_workers/map_element_worker.rb +0 -13
  71. data/lib/ruby_reactor/sidekiq_workers/sweeper_worker.rb +0 -73
  72. data/lib/ruby_reactor/sidekiq_workers/worker.rb +0 -222
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 778bc5305c6d1f20833819afd9ccd46f5a5b4c2c135d8e63344d6530f9a733f1
4
- data.tar.gz: 32e769816eba846f419e3f31e8290b94e8ff04fe6ea71fef125bb128b3085b82
3
+ metadata.gz: 7ab75328ca5dda28377061047d7ac45c1515266e6e1386778470e57a2b21a674
4
+ data.tar.gz: 8877cc95bc390355f86a02abff2a1a405c9d021b055d842306ac78abd4145efe
5
5
  SHA512:
6
- metadata.gz: 592db1d0ef94153a4ea028aa3cdeb59f7e4c73929ebec5afd5a9795a93d27a0cfb0c4bd3e135ccf1b14c0329123be6cf0905ad4a141018993832d21212754db3
7
- data.tar.gz: 2fd90e47af8e26cf2d58468a1f0629fd1dc04890df0a6e1704e8d6cba5c65b1e050f10f56628c27c7c90b0545d081e33169e3bfd62f416affd761b62edeb24a0
6
+ metadata.gz: 778ed5734e8fbc634e00d93d5af7282d4dd44665b0345d07589b94a3eb866f7e85e1e7b12346369c4066d8d62462ff0b84b621f7c7fc268285aeb3680013e56f
7
+ data.tar.gz: bf90e0ee6d4da42d7ea783fb81039f978d1deb41e5b2936f1bcb51aecc49952fd05eb7ae90b98fe8ad76352931df48fcd7b978506d6cf53751a4168794d6acbf
@@ -0,0 +1,32 @@
1
+ ---
2
+ name: speckit-agent-context-update
3
+ description: Refresh the managed Spec Kit section in coding agent context file(s)
4
+ compatibility: Requires spec-kit project structure with .specify/ directory
5
+ metadata:
6
+ author: github-spec-kit
7
+ source: agent-context:commands/speckit.agent-context.update.md
8
+ ---
9
+
10
+ # Update Coding Agent Context
11
+
12
+ Refresh the managed Spec Kit section inside the active coding agent's context/instruction file (e.g. `CLAUDE.md`, `.github/copilot-instructions.md`, `AGENTS.md`).
13
+
14
+ ## Behavior
15
+
16
+ The script reads the agent-context extension config at
17
+ `.specify/extensions/agent-context/agent-context-config.yml` to discover:
18
+
19
+ - `context_file` — the path of the coding agent context file to manage.
20
+ - `context_files` — optional project-relative paths for multiple coding agent context files. When non-empty, the script updates each listed file and the list takes precedence over `context_file`.
21
+ - `context_markers.start` / `.end` — the delimiters surrounding the managed section. Defaults to `<!-- SPECKIT START -->` and `<!-- SPECKIT END -->` when the field is missing.
22
+
23
+ It then creates, replaces, or appends the managed block so that the section points at the most recent plan path when one can be discovered (`specs/<feature>/plan.md`).
24
+
25
+ If `context_files` and `context_file` are empty, the command reports nothing to do and exits successfully. Context file paths must stay project-relative; absolute paths, Windows drive paths, backslash separators, and `..` path segments are rejected.
26
+
27
+ ## Execution
28
+
29
+ - **Bash**: `.specify/extensions/agent-context/scripts/bash/update-agent-context.sh [plan_path]`
30
+ - **PowerShell**: `.specify/extensions/agent-context/scripts/powershell/update-agent-context.ps1 [plan_path]`
31
+
32
+ When `plan_path` is omitted, the script auto-detects the most recently modified `specs/*/plan.md`.
@@ -0,0 +1,262 @@
1
+ ---
2
+ name: "speckit-analyze"
3
+ description: "Perform a non-destructive cross-artifact consistency and quality analysis across spec.md, plan.md, and tasks.md after task generation."
4
+ argument-hint: "Optional focus areas for analysis"
5
+ compatibility: "Requires spec-kit project structure with .specify/ directory"
6
+ metadata:
7
+ author: "github-spec-kit"
8
+ source: "templates/commands/analyze.md"
9
+ user-invocable: true
10
+ disable-model-invocation: false
11
+ context: fork
12
+ agent: general-purpose
13
+ ---
14
+
15
+
16
+ ## User Input
17
+
18
+ ```text
19
+ $ARGUMENTS
20
+ ```
21
+
22
+ You **MUST** consider the user input before proceeding (if not empty).
23
+
24
+ ## Pre-Execution Checks
25
+
26
+ **Check for extension hooks (before analysis)**:
27
+ - Check if `.specify/extensions.yml` exists in the project root.
28
+ - If it exists, read it and look for entries under the `hooks.before_analyze` key
29
+ - If the YAML cannot be parsed or is invalid, skip hook checking silently and continue normally
30
+ - Filter out hooks where `enabled` is explicitly `false`. Treat hooks without an `enabled` field as enabled by default.
31
+ - For each remaining hook, do **not** attempt to interpret or evaluate hook `condition` expressions:
32
+ - If the hook has no `condition` field, or it is null/empty, treat the hook as executable
33
+ - If the hook defines a non-empty `condition`, skip the hook and leave condition evaluation to the HookExecutor implementation
34
+ - When constructing slash commands from hook command names, replace dots (`.`) with hyphens (`-`). For example, `speckit.git.commit` → `/speckit-git-commit`.
35
+ - For each executable hook, output the following based on its `optional` flag:
36
+ - **Optional hook** (`optional: true`):
37
+ ```
38
+ ## Extension Hooks
39
+
40
+ **Optional Pre-Hook**: {extension}
41
+ Command: `/{command}`
42
+ Description: {description}
43
+
44
+ Prompt: {prompt}
45
+ To execute: `/{command}`
46
+ ```
47
+ - **Mandatory hook** (`optional: false`):
48
+ ```
49
+ ## Extension Hooks
50
+
51
+ **Automatic Pre-Hook**: {extension}
52
+ Executing: `/{command}`
53
+ EXECUTE_COMMAND: {command}
54
+
55
+ Wait for the result of the hook command before proceeding to the Goal.
56
+ ```
57
+ - If no hooks are registered or `.specify/extensions.yml` does not exist, skip silently
58
+
59
+ ## Goal
60
+
61
+ Identify inconsistencies, duplications, ambiguities, and underspecified items across the three core artifacts (`spec.md`, `plan.md`, `tasks.md`) before implementation. This command MUST run only after `/speckit-tasks` has successfully produced a complete `tasks.md`.
62
+
63
+ ## Operating Constraints
64
+
65
+ **STRICTLY READ-ONLY**: Do **not** modify any files. Output a structured analysis report. Offer an optional remediation plan (user must explicitly approve before any follow-up editing commands would be invoked manually).
66
+
67
+ **Constitution Authority**: The project constitution (`.specify/memory/constitution.md`) is **non-negotiable** within this analysis scope. Constitution conflicts are automatically CRITICAL and require adjustment of the spec, plan, or tasks—not dilution, reinterpretation, or silent ignoring of the principle. If a principle itself needs to change, that must occur in a separate, explicit constitution update outside `/speckit-analyze`.
68
+
69
+ ## Execution Steps
70
+
71
+ ### 1. Initialize Analysis Context
72
+
73
+ Run `.specify/scripts/bash/check-prerequisites.sh --json --require-tasks --include-tasks` once from repo root and parse JSON for FEATURE_DIR and AVAILABLE_DOCS. Derive absolute paths:
74
+
75
+ - SPEC = FEATURE_DIR/spec.md
76
+ - PLAN = FEATURE_DIR/plan.md
77
+ - TASKS = FEATURE_DIR/tasks.md
78
+
79
+ Abort with an error message if any required file is missing (instruct the user to run missing prerequisite command).
80
+ For single quotes in args like "I'm Groot", use escape syntax: e.g 'I'\''m Groot' (or double-quote if possible: "I'm Groot").
81
+
82
+ ### 2. Load Artifacts (Progressive Disclosure)
83
+
84
+ Load only the minimal necessary context from each artifact:
85
+
86
+ **From spec.md:**
87
+
88
+ - Overview/Context
89
+ - Functional Requirements
90
+ - Success Criteria (measurable outcomes — e.g., performance, security, availability, user success, business impact)
91
+ - User Stories
92
+ - Edge Cases (if present)
93
+
94
+ **From plan.md:**
95
+
96
+ - Architecture/stack choices
97
+ - Data Model references
98
+ - Phases
99
+ - Technical constraints
100
+
101
+ **From tasks.md:**
102
+
103
+ - Task IDs
104
+ - Descriptions
105
+ - Phase grouping
106
+ - Parallel markers [P]
107
+ - Referenced file paths
108
+
109
+ **From constitution:**
110
+
111
+ - Load `.specify/memory/constitution.md` for principle validation
112
+
113
+ ### 3. Build Semantic Models
114
+
115
+ Create internal representations (do not include raw artifacts in output):
116
+
117
+ - **Requirements inventory**: For each Functional Requirement (FR-###) and Success Criterion (SC-###), record a stable key. Use the explicit FR-/SC- identifier as the primary key when present, and optionally also derive an imperative-phrase slug for readability (e.g., "User can upload file" → `user-can-upload-file`). Include only Success Criteria items that require buildable work (e.g., load-testing infrastructure, security audit tooling), and exclude post-launch outcome metrics and business KPIs (e.g., "Reduce support tickets by 50%").
118
+ - **User story/action inventory**: Discrete user actions with acceptance criteria
119
+ - **Task coverage mapping**: Map each task to one or more requirements or stories (inference by keyword / explicit reference patterns like IDs or key phrases)
120
+ - **Constitution rule set**: Extract principle names and MUST/SHOULD normative statements
121
+
122
+ ### 4. Detection Passes (Token-Efficient Analysis)
123
+
124
+ Focus on high-signal findings. Limit to 50 findings total; aggregate remainder in overflow summary.
125
+
126
+ #### A. Duplication Detection
127
+
128
+ - Identify near-duplicate requirements
129
+ - Mark lower-quality phrasing for consolidation
130
+
131
+ #### B. Ambiguity Detection
132
+
133
+ - Flag vague adjectives (fast, scalable, secure, intuitive, robust) lacking measurable criteria
134
+ - Flag unresolved placeholders (TODO, TKTK, ???, `<placeholder>`, etc.)
135
+
136
+ #### C. Underspecification
137
+
138
+ - Requirements with verbs but missing object or measurable outcome
139
+ - User stories missing acceptance criteria alignment
140
+ - Tasks referencing files or components not defined in spec/plan
141
+
142
+ #### D. Constitution Alignment
143
+
144
+ - Any requirement or plan element conflicting with a MUST principle
145
+ - Missing mandated sections or quality gates from constitution
146
+
147
+ #### E. Coverage Gaps
148
+
149
+ - Requirements with zero associated tasks
150
+ - Tasks with no mapped requirement/story
151
+ - Success Criteria requiring buildable work (performance, security, availability) not reflected in tasks
152
+
153
+ #### F. Inconsistency
154
+
155
+ - Terminology drift (same concept named differently across files)
156
+ - Data entities referenced in plan but absent in spec (or vice versa)
157
+ - Task ordering contradictions (e.g., integration tasks before foundational setup tasks without dependency note)
158
+ - Conflicting requirements (e.g., one requires Next.js while other specifies Vue)
159
+
160
+ ### 5. Severity Assignment
161
+
162
+ Use this heuristic to prioritize findings:
163
+
164
+ - **CRITICAL**: Violates constitution MUST, missing core spec artifact, or requirement with zero coverage that blocks baseline functionality
165
+ - **HIGH**: Duplicate or conflicting requirement, ambiguous security/performance attribute, untestable acceptance criterion
166
+ - **MEDIUM**: Terminology drift, missing non-functional task coverage, underspecified edge case
167
+ - **LOW**: Style/wording improvements, minor redundancy not affecting execution order
168
+
169
+ ### 6. Produce Compact Analysis Report
170
+
171
+ Output a Markdown report (no file writes) with the following structure:
172
+
173
+ ## Specification Analysis Report
174
+
175
+ | ID | Category | Severity | Location(s) | Summary | Recommendation |
176
+ |----|----------|----------|-------------|---------|----------------|
177
+ | A1 | Duplication | HIGH | spec.md:L120-134 | Two similar requirements ... | Merge phrasing; keep clearer version |
178
+
179
+ (Add one row per finding; generate stable IDs prefixed by category initial.)
180
+
181
+ **Coverage Summary Table:**
182
+
183
+ | Requirement Key | Has Task? | Task IDs | Notes |
184
+ |-----------------|-----------|----------|-------|
185
+
186
+ **Constitution Alignment Issues:** (if any)
187
+
188
+ **Unmapped Tasks:** (if any)
189
+
190
+ **Metrics:**
191
+
192
+ - Total Requirements
193
+ - Total Tasks
194
+ - Coverage % (requirements with >=1 task)
195
+ - Ambiguity Count
196
+ - Duplication Count
197
+ - Critical Issues Count
198
+
199
+ ### 7. Provide Next Actions
200
+
201
+ At end of report, output a concise Next Actions block:
202
+
203
+ - If CRITICAL issues exist: Recommend resolving before `/speckit-implement`
204
+ - If only LOW/MEDIUM: User may proceed, but provide improvement suggestions
205
+ - Provide explicit command suggestions: e.g., "Run /speckit-specify with refinement", "Run /speckit-plan to adjust architecture", "Manually edit tasks.md to add coverage for 'performance-metrics'"
206
+
207
+ ### 8. Offer Remediation
208
+
209
+ Ask the user: "Would you like me to suggest concrete remediation edits for the top N issues?" (Do NOT apply them automatically.)
210
+
211
+ ### 9. Check for extension hooks
212
+
213
+ After reporting, check if `.specify/extensions.yml` exists in the project root.
214
+ - If it exists, read it and look for entries under the `hooks.after_analyze` key
215
+ - If the YAML cannot be parsed or is invalid, skip hook checking silently and continue normally
216
+ - Filter out hooks where `enabled` is explicitly `false`. Treat hooks without an `enabled` field as enabled by default.
217
+ - For each remaining hook, do **not** attempt to interpret or evaluate hook `condition` expressions:
218
+ - If the hook has no `condition` field, or it is null/empty, treat the hook as executable
219
+ - If the hook defines a non-empty `condition`, skip the hook and leave condition evaluation to the HookExecutor implementation
220
+ - When constructing slash commands from hook command names, replace dots (`.`) with hyphens (`-`). For example, `speckit.git.commit` → `/speckit-git-commit`.
221
+ - For each executable hook, output the following based on its `optional` flag:
222
+ - **Optional hook** (`optional: true`):
223
+ ```
224
+ ## Extension Hooks
225
+
226
+ **Optional Hook**: {extension}
227
+ Command: `/{command}`
228
+ Description: {description}
229
+
230
+ Prompt: {prompt}
231
+ To execute: `/{command}`
232
+ ```
233
+ - **Mandatory hook** (`optional: false`):
234
+ ```
235
+ ## Extension Hooks
236
+
237
+ **Automatic Hook**: {extension}
238
+ Executing: `/{command}`
239
+ EXECUTE_COMMAND: {command}
240
+ ```
241
+ - If no hooks are registered or `.specify/extensions.yml` does not exist, skip silently
242
+
243
+ ## Operating Principles
244
+
245
+ ### Context Efficiency
246
+
247
+ - **Minimal high-signal tokens**: Focus on actionable findings, not exhaustive documentation
248
+ - **Progressive disclosure**: Load artifacts incrementally; don't dump all content into analysis
249
+ - **Token-efficient output**: Limit findings table to 50 rows; summarize overflow
250
+ - **Deterministic results**: Rerunning without changes should produce consistent IDs and counts
251
+
252
+ ### Analysis Guidelines
253
+
254
+ - **NEVER modify files** (this is read-only analysis)
255
+ - **NEVER hallucinate missing sections** (if absent, report them accurately)
256
+ - **Prioritize constitution violations** (these are always CRITICAL)
257
+ - **Use examples over exhaustive rules** (cite specific instances, not generic patterns)
258
+ - **Report zero issues gracefully** (emit success report with coverage statistics)
259
+
260
+ ## Context
261
+
262
+ $ARGUMENTS