@arvorco/relentless 0.1.23 → 0.1.26

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.
@@ -90,7 +90,11 @@ Read and analyze project documentation:
90
90
 
91
91
  ## Step 4: Generate Personalized Prompt
92
92
 
93
- Using the generic template from relentless, create a personalized `prompt.md` with:
93
+ Load the base template from `templates/prompt.md` and personalize it:
94
+
95
+ **Base Template Location:** `templates/prompt.md`
96
+
97
+ Create a personalized `prompt.md` with:
94
98
 
95
99
  **Section 1: Quality Gates**
96
100
  ```markdown
@@ -7,6 +7,11 @@ description: "Execute implementation workflow phase by phase. Use after analysis
7
7
 
8
8
  Guide systematic implementation of features using TDD and quality-first approach.
9
9
 
10
+ > **Note:** This skill uses generic placeholders. Adapt commands and paths to your project:
11
+ > - Quality commands: Check your `package.json`, `Makefile`, or build config
12
+ > - File paths: Adjust based on your project structure
13
+ > - Examples show common conventions - your project may differ
14
+
10
15
  ---
11
16
 
12
17
  ## The Job
@@ -17,27 +22,32 @@ Implement user stories one at a time, following strict TDD and updating all trac
17
22
 
18
23
  ## Before You Start
19
24
 
20
- 1. **Read the Constitution** - Review `relentless/constitution.md` for project principles
21
- 2. **Read prompt.md** - Review `relentless/prompt.md` for workflow guidelines
25
+ 1. **Read the Constitution** - Review your project's constitution (if exists) for governance principles
26
+ 2. **Read prompt.md** - Review workflow guidelines (if exists)
22
27
  3. **Read progress.txt** - Check learnings from previous iterations
23
28
  4. **Review artifacts** - Ensure spec.md, plan.md, tasks.md, checklist.md exist
24
- 5. **Run `/relentless.analyze`** - Must pass with no CRITICAL issues
29
+ 5. **Identify Quality Commands** - Find your project's typecheck, lint, and test commands
25
30
 
26
31
  ---
27
32
 
28
33
  ## CRITICAL: Quality Gates (Non-Negotiable)
29
34
 
30
- Before marking ANY story as complete, ALL checks must pass:
35
+ Before marking ANY story as complete, ALL quality checks must pass.
36
+
37
+ **Find your project's commands** (examples for different ecosystems):
31
38
 
32
39
  ```bash
33
- # TypeScript strict mode check
34
- bun run typecheck
40
+ # JavaScript/TypeScript (npm/yarn/bun/pnpm):
41
+ npm run typecheck && npm run lint && npm test
35
42
 
36
- # ESLint with zero warnings policy
37
- bun run lint
43
+ # Python:
44
+ mypy . && ruff check . && pytest
38
45
 
39
- # All tests must pass
40
- bun test
46
+ # Go:
47
+ go build ./... && golangci-lint run && go test ./...
48
+
49
+ # Rust:
50
+ cargo check && cargo clippy && cargo test
41
51
  ```
42
52
 
43
53
  **If ANY check fails, DO NOT mark the story as complete. Fix the issues first.**
@@ -52,19 +62,19 @@ For EVERY story, follow strict Test-Driven Development:
52
62
  ```bash
53
63
  # Create test file if needed
54
64
  # Write tests that define expected behavior
55
- bun test # Tests MUST fail initially
65
+ # Run your test command - tests MUST fail initially
56
66
  ```
57
67
 
58
68
  ### Step 2: Implement Minimum Code (GREEN)
59
69
  ```bash
60
70
  # Write only enough code to pass tests
61
- bun test # Tests MUST pass
71
+ # Run tests - they MUST pass now
62
72
  ```
63
73
 
64
74
  ### Step 3: Refactor
65
75
  ```bash
66
76
  # Clean up while keeping tests green
67
- bun test # Tests MUST still pass
77
+ # Run tests - they MUST still pass
68
78
  ```
69
79
 
70
80
  **Do NOT skip TDD. Tests are contracts that validate your implementation.**
@@ -83,7 +93,7 @@ For each story (in dependency order):
83
93
  ### 2. Find Relevant Checklist Items
84
94
  - Open `checklist.md`
85
95
  - Find items tagged with `[US-XXX]` for this story
86
- - Note constitution compliance items `[Constitution]`
96
+ - Note any governance/compliance items
87
97
 
88
98
  ### 3. Implement with TDD
89
99
  Follow the TDD workflow above for each acceptance criterion.
@@ -110,9 +120,8 @@ For each verified checklist item:
110
120
 
111
121
  ### 6. Run Quality Checks
112
122
  ```bash
113
- bun run typecheck # 0 errors required
114
- bun run lint # 0 warnings required
115
- bun test # All tests must pass
123
+ # Run your project's quality commands
124
+ # All must pass with 0 errors/warnings
116
125
  ```
117
126
 
118
127
  ### 7. Commit Changes
@@ -142,18 +151,15 @@ Append progress entry:
142
151
  - Key decisions made
143
152
 
144
153
  **Files Changed:**
145
- - path/to/file.ts (new/modified)
154
+ - path/to/file (new/modified)
146
155
 
147
156
  **Tests Added:**
148
- - path/to/file.test.ts
157
+ - path/to/test.file
149
158
 
150
159
  **Learnings:**
151
160
  - Patterns discovered
152
161
  - Gotchas encountered
153
162
 
154
- **Constitution Compliance:**
155
- - Principle N: How it was followed
156
-
157
163
  ---
158
164
  ```
159
165
 
@@ -165,23 +171,23 @@ Append progress entry:
165
171
  **Current:** US-001: Test Infrastructure Setup
166
172
 
167
173
  **Acceptance Criteria:**
168
- - [ ] `bun test` command runs successfully
169
- - [ ] Test files with pattern `*.test.ts` are auto-discovered
170
- - [ ] `bun test --coverage` shows coverage report
171
- - [ ] Typecheck passes
172
- - [ ] Lint passes
174
+ - [ ] Test command runs successfully
175
+ - [ ] Test files are auto-discovered
176
+ - [ ] Coverage report available
177
+ - [ ] Type checking passes
178
+ - [ ] Linting passes
173
179
 
174
180
  **Relevant Checklist Items:**
175
- - [ ] CHK-001 [US-001] `bun test` command executes successfully
176
- - [ ] CHK-002 [US-001] Test files with `*.test.ts` pattern are auto-discovered
177
- - [ ] CHK-007 [Constitution] Tests written BEFORE implementation
181
+ - [ ] CHK-001 [US-001] Test command executes successfully
182
+ - [ ] CHK-002 [US-001] Test files are auto-discovered
183
+ - [ ] CHK-007 Tests written BEFORE implementation
178
184
 
179
185
  **Implementation Steps:**
180
186
  1. Write a simple failing test first
181
- 2. Configure bun test runner
187
+ 2. Configure test runner for your project
182
188
  3. Verify test discovery works
183
- 4. Run `bun run typecheck` - must pass
184
- 5. Run `bun run lint` - must pass with 0 warnings
189
+ 4. Run type checking - must pass
190
+ 5. Run linting - must pass with 0 warnings
185
191
  6. Update tasks.md - check off completed criteria
186
192
  7. Update checklist.md - mark verified items
187
193
  8. Commit: "feat: US-001 - Test Infrastructure Setup"
@@ -238,5 +244,4 @@ After completing each story, these files MUST be updated:
238
244
 
239
245
  ---
240
246
 
241
- *Reference: See `relentless/prompt.md` for additional guidelines*
242
- *Reference: See `relentless/constitution.md` for project principles*
247
+ *Adapt all commands and paths to your project's specific setup*
@@ -237,18 +237,21 @@ After creating relentless/prd.json, run the orchestrator:
237
237
 
238
238
  ```bash
239
239
  # With Claude Code (default)
240
- ./relentless/bin/relentless.sh
240
+ relentless run --feature <feature-name>
241
241
 
242
242
  # With a specific agent
243
- ./relentless/bin/relentless.sh --agent amp
244
- ./relentless/bin/relentless.sh --agent codex
245
- ./relentless/bin/relentless.sh --agent gemini
243
+ relentless run --feature <feature-name> --agent amp
244
+ relentless run --feature <feature-name> --agent codex
245
+ relentless run --feature <feature-name> --agent gemini
246
246
 
247
247
  # Smart routing (auto-select best agent per story)
248
- ./relentless/bin/relentless.sh --agent auto
248
+ relentless run --feature <feature-name> --agent auto
249
249
 
250
250
  # Custom max iterations
251
- ./relentless/bin/relentless.sh --max-iterations 30
251
+ relentless run --feature <feature-name> --max-iterations 30
252
+
253
+ # With TUI interface
254
+ relentless run --feature <feature-name> --tui
252
255
  ```
253
256
 
254
257
  ---
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arvorco/relentless",
3
- "version": "0.1.23",
3
+ "version": "0.1.26",
4
4
  "description": "Universal AI agent orchestrator - works with Claude Code, Amp, OpenCode, Codex, Droid, and Gemini",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -49,9 +49,17 @@ const relentlessRoot = getRelentlessRoot();
49
49
 
50
50
  /**
51
51
  * Files to create in the relentless/ directory
52
+ * These can be force-updated with -f flag
52
53
  */
53
54
  const RELENTLESS_FILES: Record<string, () => string> = {
54
55
  "config.json": () => JSON.stringify(DEFAULT_CONFIG, null, 2),
56
+ };
57
+
58
+ /**
59
+ * Files that should NEVER be overwritten, even with -f flag
60
+ * These are personalized files that users customize for their project
61
+ */
62
+ const PROTECTED_FILES: Record<string, () => string> = {
55
63
  "prompt.md": () => PROMPT_TEMPLATE,
56
64
  };
57
65
 
@@ -171,7 +179,7 @@ export async function initProject(projectDir: string = process.cwd(), force: boo
171
179
  }
172
180
  }
173
181
 
174
- // Create relentless files
182
+ // Create relentless files (can be force-updated)
175
183
  console.log(chalk.dim("\nCreating relentless files..."));
176
184
 
177
185
  for (const [filename, contentFn] of Object.entries(RELENTLESS_FILES)) {
@@ -187,6 +195,19 @@ export async function initProject(projectDir: string = process.cwd(), force: boo
187
195
  console.log(` ${chalk.green("✓")} relentless/${filename} ${force ? `(${action})` : ""}`);
188
196
  }
189
197
 
198
+ // Create protected files (NEVER overwritten, even with -f)
199
+ for (const [filename, contentFn] of Object.entries(PROTECTED_FILES)) {
200
+ const path = join(relentlessDir, filename);
201
+
202
+ if (existsSync(path)) {
203
+ console.log(` ${chalk.yellow("⚠")} relentless/${filename} already exists (protected, not overwriting)`);
204
+ continue;
205
+ }
206
+
207
+ await Bun.write(path, contentFn());
208
+ console.log(` ${chalk.green("✓")} relentless/${filename} (created)`);
209
+ }
210
+
190
211
  // Note: constitution.md is NOT copied - it should be created by /relentless.constitution command
191
212
  // This ensures each project gets a personalized constitution
192
213
 
@@ -0,0 +1,72 @@
1
+ # Relentless Agent Instructions
2
+
3
+ You are an autonomous coding agent. Follow these instructions exactly.
4
+
5
+ **This is a generic template. Personalize it for your project using:**
6
+ ```bash
7
+ /relentless.constitution
8
+ ```
9
+
10
+ ---
11
+
12
+ ## Your Task (Per Iteration)
13
+
14
+ 1. Read `relentless/features/<feature>/prd.json`
15
+ 2. Read `relentless/features/<feature>/progress.txt`
16
+ 3. Check you're on the correct branch from PRD `branchName`
17
+ 4. Pick the **highest priority** story where `passes: false`
18
+ 5. Review existing code to understand patterns
19
+ 6. Implement the story
20
+ 7. Run quality checks (typecheck, lint, test)
21
+ 8. If ALL checks pass, commit: `feat: [Story ID] - [Story Title]`
22
+ 9. Update PRD: set `passes: true`
23
+ 10. Append progress to `progress.txt`
24
+
25
+ ---
26
+
27
+ ## Quality Requirements
28
+
29
+ Before marking a story complete:
30
+ - [ ] All quality checks pass (typecheck, lint, test)
31
+ - [ ] Zero errors and zero warnings
32
+ - [ ] No debug code (console.log, debugger)
33
+ - [ ] No unused imports or variables
34
+ - [ ] Follows existing patterns
35
+
36
+ ---
37
+
38
+ ## Progress Report Format
39
+
40
+ APPEND to progress.txt:
41
+ ```
42
+ ## [Date/Time] - [Story ID]
43
+ - What was implemented
44
+ - Files changed
45
+ - Learnings for future iterations
46
+ ---
47
+ ```
48
+
49
+ ---
50
+
51
+ ## Stop Condition
52
+
53
+ After completing a story, check if ALL stories have `passes: true`.
54
+
55
+ If ALL complete:
56
+ ```
57
+ <promise>COMPLETE</promise>
58
+ ```
59
+
60
+ Otherwise, end normally (next iteration continues).
61
+
62
+ ---
63
+
64
+ ## Notes
65
+
66
+ This is the default template. You should personalize `relentless/prompt.md` with:
67
+ - Your project's specific quality commands
68
+ - Your testing framework and patterns
69
+ - Your coding conventions
70
+ - Project-specific gotchas
71
+
72
+ Run `/relentless.constitution` to generate a personalized prompt.