@wavilikhin/ralph-wiggum 0.1.0 → 0.1.12
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.
- package/README.md +22 -6
- package/package.json +5 -2
package/README.md
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
# Ralph Wiggum
|
|
2
2
|
|
|
3
|
-
Autonomous coding loop for [OpenCode](https://opencode.ai). One task, one commit, fresh context per iteration.
|
|
4
|
-
|
|
5
3
|
```
|
|
6
4
|
____ _ _ __ ___
|
|
7
5
|
| _ \ __ _| |_ __ | |__ \ \ / (_) __ _ _ _ _ _ _ __
|
|
@@ -11,11 +9,25 @@ Autonomous coding loop for [OpenCode](https://opencode.ai). One task, one commit
|
|
|
11
9
|
|_| |___/
|
|
12
10
|
```
|
|
13
11
|
|
|
12
|
+
This is a near-vanilla implementation of the [Ralph Wiggum autonomous loop](https://ghuntley.com/ralph/) pattern by Geoffrey Huntley. The core idea: run an AI coding agent in a loop where each iteration gets fresh context, picks exactly one task, implements it, validates it passes all checks, commits, and repeats until done. This produces clean atomic commits and avoids context window bloat.
|
|
13
|
+
|
|
14
|
+
Built for [OpenCode](https://opencode.ai), but should work with any CLI-based coding agent that can read files and run commands.
|
|
15
|
+
|
|
16
|
+
**Additions to the original pattern:**
|
|
17
|
+
- `npx` initialization that scaffolds everything into a `.ralph/` directory
|
|
18
|
+
- Structured logging with timestamps (`.ralph/logs/ralph.log`)
|
|
19
|
+
- `--verbose` flag to preserve full agent output per iteration
|
|
20
|
+
- Enforces exactly one commit per iteration (fails if zero or multiple)
|
|
21
|
+
- Verifies clean working tree after each iteration
|
|
22
|
+
- Phases-based `IMPLEMENTATION_PLAN.md` template
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
14
26
|
## What is this?
|
|
15
27
|
|
|
16
|
-
Ralph Wiggum runs
|
|
28
|
+
Ralph Wiggum runs your coding agent in a loop, where each iteration:
|
|
17
29
|
|
|
18
|
-
1. Starts with **fresh context** (new
|
|
30
|
+
1. Starts with **fresh context** (new process, no memory of previous iterations)
|
|
19
31
|
2. Picks **exactly one task** from your implementation plan
|
|
20
32
|
3. Implements it and runs **validation gates** (lint, test, build)
|
|
21
33
|
4. Creates **exactly one commit** (local only, no push)
|
|
@@ -41,7 +53,7 @@ This approach keeps context focused and produces clean, atomic commits.
|
|
|
41
53
|
|
|
42
54
|
## Prerequisites
|
|
43
55
|
|
|
44
|
-
- [OpenCode CLI](https://opencode.ai) installed and configured
|
|
56
|
+
- [OpenCode CLI](https://opencode.ai) installed and configured (or another CLI agent)
|
|
45
57
|
- Node.js 18+
|
|
46
58
|
- Git repository
|
|
47
59
|
- **AGENTS.md file in your repo root** (see below)
|
|
@@ -90,7 +102,7 @@ See [OpenCode AGENTS.md documentation](https://opencode.ai/docs/agents-md) for b
|
|
|
90
102
|
|
|
91
103
|
```bash
|
|
92
104
|
cd your-project
|
|
93
|
-
npx ralph-wiggum init
|
|
105
|
+
npx @wavilikhin/ralph-wiggum init
|
|
94
106
|
```
|
|
95
107
|
|
|
96
108
|
This creates a `.ralph/` directory with:
|
|
@@ -335,6 +347,10 @@ This often indicates the model isn't capable enough for autonomous operation. Tr
|
|
|
335
347
|
- Simplifying tasks in IMPLEMENTATION_PLAN.md
|
|
336
348
|
- Adding more context to AGENTS.md
|
|
337
349
|
|
|
350
|
+
## Credits
|
|
351
|
+
|
|
352
|
+
Based on the [Ralph Wiggum pattern](https://ghuntley.com/ralph/) by Geoffrey Huntley.
|
|
353
|
+
|
|
338
354
|
## License
|
|
339
355
|
|
|
340
356
|
MIT
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wavilikhin/ralph-wiggum",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.12",
|
|
4
4
|
"description": "Autonomous coding loop for OpenCode - one task, one commit, fresh context per iteration",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
|
-
"ralph-wiggum": "
|
|
7
|
+
"ralph-wiggum": "src/cli.js"
|
|
8
8
|
},
|
|
9
9
|
"files": [
|
|
10
10
|
"src/",
|
|
@@ -26,5 +26,8 @@
|
|
|
26
26
|
},
|
|
27
27
|
"engines": {
|
|
28
28
|
"node": ">=18.0.0"
|
|
29
|
+
},
|
|
30
|
+
"publishConfig": {
|
|
31
|
+
"access": "public"
|
|
29
32
|
}
|
|
30
33
|
}
|