ralph-lisa-loop 0.3.10 → 0.3.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 +40 -214
- package/dist/cli.js +50 -4
- package/dist/commands.d.ts +31 -0
- package/dist/commands.js +1467 -75
- package/dist/policy.d.ts +1 -0
- package/dist/policy.js +71 -0
- package/dist/state.d.ts +19 -1
- package/dist/state.js +62 -3
- package/package.json +1 -1
- package/templates/claude-commands/check-turn.md +1 -1
- package/templates/claude-commands/submit-work.md +1 -1
- package/templates/codex-skills/check-turn.md +2 -2
- package/templates/roles/lisa.md +28 -13
- package/templates/roles/ralph.md +53 -14
- package/templates/skill.json +1 -1
package/README.md
CHANGED
|
@@ -1,268 +1,94 @@
|
|
|
1
1
|
# Ralph-Lisa Loop
|
|
2
2
|
|
|
3
3
|
<p align="center">
|
|
4
|
-
<img src="
|
|
4
|
+
<img src="https://raw.githubusercontent.com/YW1975/Ralph-Lisa-Loop/main/rll_cat.png" alt="Ralph-Lisa Loop" width="256" />
|
|
5
5
|
</p>
|
|
6
6
|
|
|
7
7
|
Turn-based dual-agent collaboration: Ralph codes, Lisa reviews, consensus required.
|
|
8
8
|
|
|
9
|
-
[](LICENSE)
|
|
9
|
+
[](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/LICENSE)
|
|
10
10
|
[](https://www.npmjs.com/package/ralph-lisa-loop)
|
|
11
11
|
|
|
12
|
-
## The Problem
|
|
13
|
-
|
|
14
|
-
Single-agent coding is like grading your own exam. The same model writes code AND decides if it's done. No external validation. No second opinion.
|
|
15
|
-
|
|
16
|
-
## The Solution
|
|
17
|
-
|
|
18
|
-
**Ralph-Lisa Loop** enforces a strict turn-based workflow:
|
|
19
|
-
|
|
20
|
-
```
|
|
21
|
-
Ralph writes → Lisa reviews → Consensus → Next step
|
|
22
|
-
↑ |
|
|
23
|
-
└────────────────────────────────────────┘
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
- **Ralph** (Claude Code): Lead developer - researches, plans, codes, tests
|
|
27
|
-
- **Lisa** (Codex): Code reviewer - reviews, provides feedback
|
|
28
|
-
- **Turn Control**: Only one agent works at a time
|
|
29
|
-
- **Consensus Required**: Both must agree before proceeding
|
|
30
|
-
- **Research First**: When involving reference implementations/protocols/APIs, Ralph must submit [RESEARCH] before coding
|
|
31
|
-
- **Test Results Required**: [CODE] and [FIX] submissions must include test results
|
|
32
|
-
- **Policy Layer**: Configurable warn/block mode for submission quality checks
|
|
33
|
-
|
|
34
12
|
## Quick Start
|
|
35
13
|
|
|
36
|
-
### 1. Install
|
|
37
|
-
|
|
38
14
|
```bash
|
|
39
15
|
npm i -g ralph-lisa-loop
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
### 2. Initialize Project
|
|
43
|
-
|
|
44
|
-
```bash
|
|
45
16
|
cd your-project
|
|
46
17
|
ralph-lisa init
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
### 3. Start Collaboration
|
|
50
|
-
|
|
51
|
-
```bash
|
|
52
|
-
# Manual mode (recommended)
|
|
53
18
|
ralph-lisa start "implement login feature"
|
|
54
|
-
|
|
55
|
-
# Or auto mode (experimental, requires tmux)
|
|
56
|
-
ralph-lisa auto "implement login feature"
|
|
57
19
|
```
|
|
58
20
|
|
|
59
|
-
|
|
21
|
+
## How It Works
|
|
60
22
|
|
|
61
|
-
**Terminal 1 - Ralph (Claude Code)**:
|
|
62
|
-
```bash
|
|
63
|
-
ralph-lisa whose-turn # Check turn
|
|
64
|
-
# ... do work, write submission to .dual-agent/submit.md ...
|
|
65
|
-
ralph-lisa submit-ralph --file .dual-agent/submit.md
|
|
66
23
|
```
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
ralph-lisa whose-turn # Check turn
|
|
71
|
-
ralph-lisa read work.md # Read Ralph's work
|
|
72
|
-
# ... write review to .dual-agent/submit.md ...
|
|
73
|
-
ralph-lisa submit-lisa --file .dual-agent/submit.md
|
|
74
|
-
```
|
|
75
|
-
|
|
76
|
-
## Features
|
|
77
|
-
|
|
78
|
-
### Turn Control
|
|
79
|
-
Agents must check `whose-turn` before any action. Submissions automatically pass the turn.
|
|
80
|
-
|
|
81
|
-
### Tag System
|
|
82
|
-
Every submission requires a tag:
|
|
83
|
-
|
|
84
|
-
| Ralph Tags | Lisa Tags | Shared |
|
|
85
|
-
|------------|-----------|--------|
|
|
86
|
-
| `[PLAN]` | `[PASS]` | `[CHALLENGE]` |
|
|
87
|
-
| `[RESEARCH]` | `[NEEDS_WORK]` | `[DISCUSS]` |
|
|
88
|
-
| `[CODE]` | | `[QUESTION]` |
|
|
89
|
-
| `[FIX]` | | `[CONSENSUS]` |
|
|
90
|
-
|
|
91
|
-
- `[RESEARCH]`: Submit research results before coding (when involving reference implementations, protocols, or external APIs)
|
|
92
|
-
- `[CHALLENGE]`: Explicitly disagree with the other agent's suggestion, providing counter-argument
|
|
93
|
-
- `[CODE]`/`[FIX]`: Must include Test Results section
|
|
94
|
-
|
|
95
|
-
### Consensus Protocol
|
|
96
|
-
Lisa's verdict is advisory. Ralph can agree or use `[CHALLENGE]` to disagree. Both must reach genuine consensus before `/next-step`. Silent acceptance (bare `[FIX]` without reasoning) is not allowed.
|
|
97
|
-
|
|
98
|
-
### Minimal Init (Zero Intrusion)
|
|
99
|
-
|
|
100
|
-
When using the Claude Code plugin + Codex global config, you don't need project-level role files:
|
|
101
|
-
|
|
102
|
-
```bash
|
|
103
|
-
ralph-lisa init --minimal
|
|
104
|
-
```
|
|
105
|
-
|
|
106
|
-
This only creates `.dual-agent/` session state. No CLAUDE.md, CODEX.md, or command files are written. Requires:
|
|
107
|
-
- Claude Code plugin installed (provides Ralph role via hooks)
|
|
108
|
-
- Codex global config at `~/.codex/` (provides Lisa role)
|
|
109
|
-
|
|
110
|
-
`start` and `auto` commands work with both full and minimal init.
|
|
111
|
-
|
|
112
|
-
### Policy Layer
|
|
113
|
-
|
|
114
|
-
**Inline checks** (during `submit-ralph`/`submit-lisa`):
|
|
115
|
-
|
|
116
|
-
```bash
|
|
117
|
-
# Enable warn mode (prints warnings, doesn't block)
|
|
118
|
-
export RL_POLICY_MODE=warn
|
|
119
|
-
|
|
120
|
-
# Enable block mode (rejects non-compliant submissions)
|
|
121
|
-
export RL_POLICY_MODE=block
|
|
122
|
-
|
|
123
|
-
# Disable
|
|
124
|
-
export RL_POLICY_MODE=off
|
|
125
|
-
```
|
|
126
|
-
|
|
127
|
-
**Standalone checks** (for scripts/hooks — always exit non-zero on violations, ignoring `RL_POLICY_MODE`):
|
|
128
|
-
|
|
129
|
-
```bash
|
|
130
|
-
ralph-lisa policy check ralph # Check Ralph's latest submission
|
|
131
|
-
ralph-lisa policy check lisa # Check Lisa's latest submission
|
|
132
|
-
ralph-lisa policy check-consensus # Both agents submitted [CONSENSUS]?
|
|
133
|
-
ralph-lisa policy check-next-step # Comprehensive: consensus + all policy checks
|
|
134
|
-
```
|
|
135
|
-
|
|
136
|
-
Policy rules:
|
|
137
|
-
- Ralph's [CODE]/[FIX] must include "Test Results" section
|
|
138
|
-
- Ralph's [RESEARCH] must have substantive content
|
|
139
|
-
- Lisa's [PASS]/[NEEDS_WORK] must include at least 1 reason
|
|
140
|
-
|
|
141
|
-
### Mid-Session Task Update
|
|
142
|
-
Change direction without restarting:
|
|
143
|
-
```bash
|
|
144
|
-
ralph-lisa update-task "switch to REST instead of GraphQL"
|
|
24
|
+
Ralph writes → Lisa reviews → Consensus → Next step
|
|
25
|
+
↑ |
|
|
26
|
+
└────────────────────────────────────────┘
|
|
145
27
|
```
|
|
146
|
-
Appends to task.md (preserving history). Task context is auto-injected into work.md submissions and watcher trigger messages so both agents always see the current goal.
|
|
147
28
|
|
|
148
|
-
|
|
149
|
-
|
|
29
|
+
- **Ralph** (Claude Code): Lead developer — researches, plans, codes, tests
|
|
30
|
+
- **Lisa** (Codex): Code reviewer — reviews diffs, checks edge cases
|
|
31
|
+
- **You**: Tech lead — architecture, scope, tiebreaking
|
|
150
32
|
|
|
151
|
-
|
|
152
|
-
Lisa reads task.md before every review and checks for direction drift. Catching misalignment early is prioritized over code-level review.
|
|
33
|
+
## Key Features
|
|
153
34
|
|
|
154
|
-
|
|
155
|
-
- **
|
|
156
|
-
- **
|
|
157
|
-
- **
|
|
158
|
-
- **Auto-
|
|
159
|
-
- **
|
|
160
|
-
- **
|
|
35
|
+
- **Turn Control** — Only one agent works at a time; submissions pass the turn automatically
|
|
36
|
+
- **Tag System** — `[PLAN]`, `[CODE]`, `[FIX]`, `[PASS]`, `[NEEDS_WORK]`, `[CHALLENGE]`, `[CONSENSUS]`
|
|
37
|
+
- **Consensus Protocol** — Both agents must agree before proceeding; advisory verdicts, not commands
|
|
38
|
+
- **Policy Layer** — Configurable `warn`/`block` mode for submission quality checks
|
|
39
|
+
- **Auto Mode** — tmux-based automation with file watcher for hands-off operation
|
|
40
|
+
- **Round 1 Mandatory Plan** — Ralph must submit `[PLAN]` first for Lisa to verify understanding
|
|
41
|
+
- **Goal Guardian** — Lisa checks for direction drift before every review
|
|
42
|
+
- **Mid-Session Task Update** — Change direction without restarting
|
|
43
|
+
- **Deadlock Detection** — After 8 consecutive `[NEEDS_WORK]` rounds, watcher auto-pauses for user intervention
|
|
44
|
+
- **Minimal Init** — Zero-intrusion mode with plugin/global config architecture
|
|
161
45
|
|
|
162
|
-
|
|
163
|
-
After 5 rounds without consensus: `[OVERRIDE]` (proceed anyway) or `[HANDOFF]` (escalate to human).
|
|
164
|
-
|
|
165
|
-
## Commands
|
|
46
|
+
## Essential Commands
|
|
166
47
|
|
|
167
48
|
```bash
|
|
168
|
-
#
|
|
169
|
-
ralph-lisa init [dir] # Initialize project
|
|
170
|
-
ralph-lisa init --minimal [dir] # Minimal init (session only, no project files)
|
|
171
|
-
ralph-lisa uninit # Remove from project
|
|
49
|
+
# Setup
|
|
50
|
+
ralph-lisa init [dir] # Initialize project
|
|
172
51
|
ralph-lisa start "task" # Launch both agents
|
|
173
|
-
ralph-lisa start --full-auto "task" # Launch without permission prompts
|
|
174
52
|
ralph-lisa auto "task" # Auto mode (tmux)
|
|
175
|
-
ralph-lisa auto --full-auto "task" # Auto mode without permission prompts
|
|
176
53
|
|
|
177
54
|
# Turn control
|
|
178
55
|
ralph-lisa whose-turn # Check whose turn
|
|
179
|
-
ralph-lisa
|
|
180
|
-
ralph-lisa submit-
|
|
181
|
-
ralph-lisa submit-lisa --file f.md # Lisa submits (recommended)
|
|
182
|
-
ralph-lisa submit-ralph --stdin # Submit via stdin pipe
|
|
183
|
-
ralph-lisa submit-lisa --stdin # Lisa submit via stdin pipe
|
|
184
|
-
ralph-lisa submit-ralph "[TAG] ..." # Inline (deprecated)
|
|
56
|
+
ralph-lisa submit-ralph --file f.md # Ralph submits
|
|
57
|
+
ralph-lisa submit-lisa --file f.md # Lisa submits
|
|
185
58
|
|
|
186
59
|
# Information
|
|
187
60
|
ralph-lisa status # Current status
|
|
188
61
|
ralph-lisa read work.md # Ralph's latest
|
|
189
62
|
ralph-lisa read review.md # Lisa's latest
|
|
190
|
-
ralph-lisa read-review # Alias for read review.md
|
|
191
|
-
ralph-lisa read review --round N # Read review from round N
|
|
192
63
|
ralph-lisa history # Full history
|
|
193
|
-
ralph-lisa recap # Context recovery summary
|
|
194
|
-
ralph-lisa logs # List transcript logs
|
|
195
|
-
ralph-lisa logs cat [name] # View a specific log
|
|
196
64
|
|
|
197
65
|
# Flow control
|
|
198
|
-
ralph-lisa step "phase-name" # Enter new
|
|
199
|
-
ralph-lisa
|
|
200
|
-
ralph-lisa update-task "new direction" # Update task direction mid-session
|
|
201
|
-
ralph-lisa archive [name] # Archive session
|
|
202
|
-
ralph-lisa clean # Clean session
|
|
203
|
-
|
|
204
|
-
# Policy
|
|
205
|
-
ralph-lisa policy check <ralph|lisa> # Check submission (hard gate)
|
|
206
|
-
ralph-lisa policy check-consensus # Check if both [CONSENSUS]
|
|
207
|
-
ralph-lisa policy check-next-step # Comprehensive pre-step check
|
|
66
|
+
ralph-lisa step "phase-name" # Enter new step
|
|
67
|
+
ralph-lisa update-task "new direction" # Change task mid-session
|
|
208
68
|
|
|
209
69
|
# Diagnostics
|
|
210
|
-
ralph-lisa doctor # Check
|
|
211
|
-
ralph-lisa doctor --strict # Exit 1 if any missing (for CI)
|
|
212
|
-
```
|
|
213
|
-
|
|
214
|
-
## Project Structure After Init
|
|
215
|
-
|
|
216
|
-
**Full init** (`ralph-lisa init`):
|
|
217
|
-
```
|
|
218
|
-
your-project/
|
|
219
|
-
├── CLAUDE.md # Ralph's role (auto-loaded by Claude Code)
|
|
220
|
-
├── CODEX.md # Lisa's role (loaded via .codex/config.toml)
|
|
221
|
-
├── .claude/
|
|
222
|
-
│ └── commands/ # Claude slash commands
|
|
223
|
-
├── .codex/
|
|
224
|
-
│ ├── config.toml # Codex configuration
|
|
225
|
-
│ └── skills/ # Codex skills
|
|
226
|
-
└── .dual-agent/ # Session state
|
|
227
|
-
├── turn.txt # Current turn
|
|
228
|
-
├── task.md # Task goal (updated via update-task)
|
|
229
|
-
├── work.md # Ralph's submissions
|
|
230
|
-
├── review.md # Lisa's submissions
|
|
231
|
-
└── history.md # Full history
|
|
232
|
-
```
|
|
233
|
-
|
|
234
|
-
**Minimal init** (`ralph-lisa init --minimal`):
|
|
235
|
-
```
|
|
236
|
-
your-project/
|
|
237
|
-
└── .dual-agent/ # Session state only (zero project files)
|
|
70
|
+
ralph-lisa doctor # Check dependencies
|
|
238
71
|
```
|
|
239
72
|
|
|
240
73
|
## Requirements
|
|
241
74
|
|
|
242
75
|
- [Node.js](https://nodejs.org/) >= 18
|
|
243
|
-
- [Claude Code](https://claude.ai/code)
|
|
244
|
-
- [Codex CLI](https://github.com/openai/codex)
|
|
245
|
-
|
|
246
|
-
For auto mode:
|
|
247
|
-
- tmux (required)
|
|
248
|
-
- fswatch (macOS) or inotify-tools (Linux) — optional, speeds up turn detection; falls back to polling without them
|
|
249
|
-
|
|
250
|
-
## Environment Variables
|
|
251
|
-
|
|
252
|
-
| Variable | Default | Description |
|
|
253
|
-
|----------|---------|-------------|
|
|
254
|
-
| `RL_POLICY_MODE` | `warn` | Policy check mode: `off`, `warn`, `block` |
|
|
255
|
-
| `RL_CHECKPOINT_ROUNDS` | `0` (disabled) | Pause for human review every N rounds |
|
|
256
|
-
| `RL_LOG_MAX_MB` | `5` | Pane log truncation threshold in MB (min 1) |
|
|
76
|
+
- [Claude Code](https://claude.ai/code) — for Ralph
|
|
77
|
+
- [Codex CLI](https://github.com/openai/codex) — for Lisa
|
|
78
|
+
- tmux — for auto mode (`brew install tmux` / `apt install tmux`)
|
|
257
79
|
|
|
258
|
-
##
|
|
80
|
+
## Documentation
|
|
259
81
|
|
|
260
|
-
|
|
82
|
+
Full documentation on GitHub:
|
|
261
83
|
|
|
262
|
-
|
|
84
|
+
- **[User Guide](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/docs/en/guide.md)** — Setup, workflows, configuration
|
|
85
|
+
- **[Command Reference](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/docs/en/reference.md)** — All CLI commands
|
|
86
|
+
- **[FAQ](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/docs/en/faq.md)** — Common questions and troubleshooting
|
|
87
|
+
- **[Changelog](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/docs/en/changelog.md)** — Version history
|
|
88
|
+
- **[Design Philosophy](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/CONCEPT.md)** — Why dual-agent works
|
|
263
89
|
|
|
264
|
-
|
|
90
|
+
Other languages: [日本語](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/docs/ja/guide.md) | [中文](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/docs/zh-CN/guide.md)
|
|
265
91
|
|
|
266
92
|
## License
|
|
267
93
|
|
|
268
|
-
[MIT](LICENSE)
|
|
94
|
+
[MIT](https://github.com/YW1975/Ralph-Lisa-Loop/blob/main/LICENSE)
|
package/dist/cli.js
CHANGED
|
@@ -70,9 +70,34 @@ switch (cmd) {
|
|
|
70
70
|
case "logs":
|
|
71
71
|
(0, commands_js_1.cmdLogs)(rest);
|
|
72
72
|
break;
|
|
73
|
+
case "scope-update":
|
|
73
74
|
case "update-task":
|
|
74
75
|
(0, commands_js_1.cmdUpdateTask)(rest);
|
|
75
76
|
break;
|
|
77
|
+
case "force-turn":
|
|
78
|
+
(0, commands_js_1.cmdForceTurn)(rest);
|
|
79
|
+
break;
|
|
80
|
+
case "remote":
|
|
81
|
+
(0, commands_js_1.cmdRemote)(rest);
|
|
82
|
+
break;
|
|
83
|
+
case "state-dir":
|
|
84
|
+
(0, commands_js_1.cmdStateDir)(rest);
|
|
85
|
+
break;
|
|
86
|
+
case "subtask":
|
|
87
|
+
(0, commands_js_1.cmdSubtask)(rest);
|
|
88
|
+
break;
|
|
89
|
+
case "add-context":
|
|
90
|
+
(0, commands_js_1.cmdAddContext)(rest);
|
|
91
|
+
break;
|
|
92
|
+
case "stop":
|
|
93
|
+
(0, commands_js_1.cmdStop)(rest);
|
|
94
|
+
break;
|
|
95
|
+
case "emergency-msg":
|
|
96
|
+
(0, commands_js_1.cmdEmergencyMsg)(rest);
|
|
97
|
+
break;
|
|
98
|
+
case "notify":
|
|
99
|
+
(0, commands_js_1.cmdNotify)(rest);
|
|
100
|
+
break;
|
|
76
101
|
case "help":
|
|
77
102
|
case "--help":
|
|
78
103
|
case "-h":
|
|
@@ -99,6 +124,9 @@ function showHelp() {
|
|
|
99
124
|
console.log(' ralph-lisa start --full-auto "task" Launch without permission prompts');
|
|
100
125
|
console.log(' ralph-lisa auto "task" Auto mode (tmux)');
|
|
101
126
|
console.log(' ralph-lisa auto --full-auto "task" Auto mode without permission prompts');
|
|
127
|
+
console.log(" ralph-lisa stop Graceful stop (archive + cleanup)");
|
|
128
|
+
console.log(" ralph-lisa stop --force Force stop (SIGKILL)");
|
|
129
|
+
console.log(" ralph-lisa stop --no-archive Stop without archiving");
|
|
102
130
|
console.log("");
|
|
103
131
|
console.log("Turn Control:");
|
|
104
132
|
console.log(" ralph-lisa check-turn Check whose turn (alias: whose-turn)");
|
|
@@ -121,10 +149,16 @@ function showHelp() {
|
|
|
121
149
|
console.log(" ralph-lisa history Show full history");
|
|
122
150
|
console.log("");
|
|
123
151
|
console.log("Flow Control:");
|
|
124
|
-
console.log(' ralph-lisa next-step "name"
|
|
125
|
-
console.log(' ralph-lisa
|
|
126
|
-
console.log(
|
|
127
|
-
console.log(
|
|
152
|
+
console.log(' ralph-lisa next-step "name" Enter new step (alias: step)');
|
|
153
|
+
console.log(' ralph-lisa next-step "name" --task "t" Enter step with first subtask');
|
|
154
|
+
console.log(' ralph-lisa scope-update "desc" Update task scope (alias: update-task)');
|
|
155
|
+
console.log(' ralph-lisa subtask add "desc" Add subtask to current step');
|
|
156
|
+
console.log(" ralph-lisa subtask done <N> Mark subtask N as complete");
|
|
157
|
+
console.log(" ralph-lisa subtask list List all subtasks");
|
|
158
|
+
console.log(' ralph-lisa add-context "note" Add context note (visible to Lisa)');
|
|
159
|
+
console.log(" ralph-lisa force-turn <agent> Manual turn override (disabled in auto mode)");
|
|
160
|
+
console.log(" ralph-lisa archive [name] Archive session");
|
|
161
|
+
console.log(" ralph-lisa clean Clean session");
|
|
128
162
|
console.log("");
|
|
129
163
|
console.log("Policy:");
|
|
130
164
|
console.log(" ralph-lisa policy check <ralph|lisa> Check submission (hard gate)");
|
|
@@ -139,7 +173,19 @@ function showHelp() {
|
|
|
139
173
|
console.log(" ralph-lisa logs cat View live pane logs");
|
|
140
174
|
console.log(" ralph-lisa logs cat <file> View specific log file");
|
|
141
175
|
console.log("");
|
|
176
|
+
console.log("Remote Access:");
|
|
177
|
+
console.log(" ralph-lisa remote Start ttyd server (default port 7681)");
|
|
178
|
+
console.log(" ralph-lisa remote --port 8080 Custom port");
|
|
179
|
+
console.log(" ralph-lisa remote --auth user:pass Enable basic auth");
|
|
180
|
+
console.log(" ralph-lisa remote --stop Stop ttyd server");
|
|
181
|
+
console.log("");
|
|
182
|
+
console.log("Emergency & Notifications:");
|
|
183
|
+
console.log(' ralph-lisa emergency-msg <agent> "msg" Send emergency message to agent pane');
|
|
184
|
+
console.log(' ralph-lisa notify "message" Send notification via RL_NOTIFY_CMD');
|
|
185
|
+
console.log("");
|
|
142
186
|
console.log("Diagnostics:");
|
|
187
|
+
console.log(" ralph-lisa state-dir Show state directory resolution");
|
|
188
|
+
console.log(" ralph-lisa state-dir /path Set state directory (tmux env)");
|
|
143
189
|
console.log(" ralph-lisa doctor Check all dependencies");
|
|
144
190
|
console.log(" ralph-lisa doctor --strict Exit 1 if any missing (for CI)");
|
|
145
191
|
}
|
package/dist/commands.d.ts
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
* CLI commands for Ralph-Lisa Loop.
|
|
3
3
|
* Direct port of io.sh logic to Node/TS.
|
|
4
4
|
*/
|
|
5
|
+
/**
|
|
6
|
+
* Send a notification to the user via RL_NOTIFY_CMD.
|
|
7
|
+
* Notification failure must not block main flow.
|
|
8
|
+
*/
|
|
9
|
+
export declare function notifyUser(message: string): void;
|
|
5
10
|
/**
|
|
6
11
|
* Generate a project-specific tmux session name to avoid conflicts
|
|
7
12
|
* when running multiple projects simultaneously.
|
|
@@ -9,6 +14,15 @@
|
|
|
9
14
|
* tmux session names cannot contain '.' or ':'.
|
|
10
15
|
*/
|
|
11
16
|
export declare function generateSessionName(projectDir: string): string;
|
|
17
|
+
/**
|
|
18
|
+
* V4-01: Ralph Auto Gate — run test/lint commands before CODE/FIX submission.
|
|
19
|
+
* Config via env vars only (config file deferred to future version):
|
|
20
|
+
* RL_RALPH_GATE=true — enable gate (default: false)
|
|
21
|
+
* RL_GATE_COMMANDS=cmd1|cmd2 — pipe-separated commands
|
|
22
|
+
* RL_GATE_MODE=warn|block — warn (default) or block on failure
|
|
23
|
+
* Gate results are NOT written to work.md (prevents Lisa anchoring).
|
|
24
|
+
*/
|
|
25
|
+
export declare function runGate(tag: string): void;
|
|
12
26
|
export declare function cmdInit(args: string[]): void;
|
|
13
27
|
export declare function cmdWhoseTurn(): void;
|
|
14
28
|
export declare function cmdSubmitRalph(args: string[]): void;
|
|
@@ -17,14 +31,31 @@ export declare function cmdStatus(): void;
|
|
|
17
31
|
export declare function cmdRead(args: string[]): void;
|
|
18
32
|
export declare function cmdRecap(): void;
|
|
19
33
|
export declare function cmdStep(args: string[]): void;
|
|
34
|
+
interface Subtask {
|
|
35
|
+
index: number;
|
|
36
|
+
text: string;
|
|
37
|
+
done: boolean;
|
|
38
|
+
line: string;
|
|
39
|
+
}
|
|
40
|
+
export declare function parseSubtasks(taskContent: string): Subtask[];
|
|
41
|
+
export declare function cmdSubtask(args: string[]): void;
|
|
20
42
|
export declare function cmdHistory(): void;
|
|
21
43
|
export declare function cmdArchive(args: string[]): void;
|
|
22
44
|
export declare function cmdClean(): void;
|
|
45
|
+
export declare function cmdStop(args: string[]): void;
|
|
23
46
|
export declare function cmdUpdateTask(args: string[]): void;
|
|
47
|
+
export declare function cmdForceTurn(args: string[], confirmed?: boolean): void;
|
|
48
|
+
export declare function executeForceTurn(agent: string, dir: string): void;
|
|
24
49
|
export declare function cmdUninit(): void;
|
|
25
50
|
export declare function cmdInitProject(args: string[]): void;
|
|
26
51
|
export declare function cmdStart(args: string[]): void;
|
|
27
52
|
export declare function cmdAuto(args: string[]): void;
|
|
28
53
|
export declare function cmdPolicy(args: string[]): void;
|
|
29
54
|
export declare function cmdLogs(args: string[]): void;
|
|
55
|
+
export declare function cmdRemote(args: string[]): void;
|
|
56
|
+
export declare function cmdStateDir(args: string[]): void;
|
|
57
|
+
export declare function cmdAddContext(args: string[]): void;
|
|
30
58
|
export declare function cmdDoctor(args: string[]): void;
|
|
59
|
+
export declare function cmdEmergencyMsg(args: string[]): void;
|
|
60
|
+
export declare function cmdNotify(args: string[]): void;
|
|
61
|
+
export {};
|