oh-my-codex 0.8.7 → 0.8.9

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 (65) hide show
  1. package/README.md +3 -1
  2. package/dist/catalog/__tests__/generator.test.js +1 -0
  3. package/dist/catalog/__tests__/generator.test.js.map +1 -1
  4. package/dist/catalog/__tests__/schema.test.js +6 -0
  5. package/dist/catalog/__tests__/schema.test.js.map +1 -1
  6. package/dist/cli/__tests__/package-bin-contract.test.js +1 -1
  7. package/dist/cli/__tests__/package-bin-contract.test.js.map +1 -1
  8. package/dist/hooks/__tests__/anti-slop-workflow.test.d.ts +2 -0
  9. package/dist/hooks/__tests__/anti-slop-workflow.test.d.ts.map +1 -0
  10. package/dist/hooks/__tests__/anti-slop-workflow.test.js +52 -0
  11. package/dist/hooks/__tests__/anti-slop-workflow.test.js.map +1 -0
  12. package/dist/hooks/__tests__/keyword-detector.test.js +47 -1
  13. package/dist/hooks/__tests__/keyword-detector.test.js.map +1 -1
  14. package/dist/hooks/__tests__/notify-hook-auto-nudge.test.js +160 -75
  15. package/dist/hooks/__tests__/notify-hook-auto-nudge.test.js.map +1 -1
  16. package/dist/hooks/__tests__/notify-hook-modules.test.js +43 -0
  17. package/dist/hooks/__tests__/notify-hook-modules.test.js.map +1 -1
  18. package/dist/hooks/__tests__/prompt-team-routing.test.d.ts +2 -0
  19. package/dist/hooks/__tests__/prompt-team-routing.test.d.ts.map +1 -0
  20. package/dist/hooks/__tests__/prompt-team-routing.test.js +15 -0
  21. package/dist/hooks/__tests__/prompt-team-routing.test.js.map +1 -0
  22. package/dist/hooks/keyword-detector.d.ts +12 -0
  23. package/dist/hooks/keyword-detector.d.ts.map +1 -1
  24. package/dist/hooks/keyword-detector.js +51 -0
  25. package/dist/hooks/keyword-detector.js.map +1 -1
  26. package/dist/hooks/prompt-guidance-contract.d.ts.map +1 -1
  27. package/dist/hooks/prompt-guidance-contract.js +2 -0
  28. package/dist/hooks/prompt-guidance-contract.js.map +1 -1
  29. package/dist/team/__tests__/model-contract.test.js +18 -4
  30. package/dist/team/__tests__/model-contract.test.js.map +1 -1
  31. package/dist/team/__tests__/runtime.test.js +143 -0
  32. package/dist/team/__tests__/runtime.test.js.map +1 -1
  33. package/dist/team/__tests__/scaling.test.js +83 -2
  34. package/dist/team/__tests__/scaling.test.js.map +1 -1
  35. package/dist/team/__tests__/tmux-session.test.js +47 -0
  36. package/dist/team/__tests__/tmux-session.test.js.map +1 -1
  37. package/dist/team/__tests__/worker-bootstrap.test.js +17 -1
  38. package/dist/team/__tests__/worker-bootstrap.test.js.map +1 -1
  39. package/dist/team/model-contract.d.ts +4 -1
  40. package/dist/team/model-contract.d.ts.map +1 -1
  41. package/dist/team/model-contract.js +23 -4
  42. package/dist/team/model-contract.js.map +1 -1
  43. package/dist/team/runtime.d.ts +4 -2
  44. package/dist/team/runtime.d.ts.map +1 -1
  45. package/dist/team/runtime.js +32 -12
  46. package/dist/team/runtime.js.map +1 -1
  47. package/dist/team/scaling.d.ts.map +1 -1
  48. package/dist/team/scaling.js +48 -32
  49. package/dist/team/scaling.js.map +1 -1
  50. package/dist/team/tmux-session.d.ts +2 -0
  51. package/dist/team/tmux-session.d.ts.map +1 -1
  52. package/dist/team/tmux-session.js +9 -4
  53. package/dist/team/tmux-session.js.map +1 -1
  54. package/dist/team/worker-bootstrap.d.ts +5 -0
  55. package/dist/team/worker-bootstrap.d.ts.map +1 -1
  56. package/dist/team/worker-bootstrap.js +25 -0
  57. package/dist/team/worker-bootstrap.js.map +1 -1
  58. package/package.json +2 -2
  59. package/scripts/notify-hook/auto-nudge.js +185 -75
  60. package/skills/ai-slop-cleaner/SKILL.md +107 -0
  61. package/skills/plan/SKILL.md +4 -1
  62. package/skills/review/SKILL.md +14 -6
  63. package/skills/team/SKILL.md +3 -3
  64. package/templates/AGENTS.md +24 -0
  65. package/templates/catalog-manifest.json +7 -0
@@ -1 +1 @@
1
- {"version":3,"file":"worker-bootstrap.js","sourceR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;;;;;;;;;CAS3D,CAAC;AACF,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,sBAAsB,CAAC,UAAkB,EAAE,QAAgB;IACzE,OAAO,uDAAuD,QAAQ,YAAY,UAAU,WAAW,CAAC;AAC1G,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,6BAA6B,CAAC,UAAkB,EAAE,QAAgB,EAAE,KAAa;IAC/F,MAAM,CAAC,GAAG,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACtE,OAAO,YAAY,CAAC,0CAA0C,QAAQ,YAAY,UAAU,OAAO,CAAC;AACtG,CAAC"}
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "oh-my-codex",
3
- "version": "0.8.7",
3
+ "version": "0.8.9",
4
4
  "description": "Multi-agent orchestration layer for OpenAI Codex CLI",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "bin": {
8
- "omx": "./bin/omx.js"
8
+ "omx": "bin/omx.js"
9
9
  },
10
10
  "scripts": {
11
11
  "build": "tsc",
@@ -13,6 +13,11 @@ import { logTmuxHookEvent } from './log.js';
13
13
  import { DEFAULT_MARKER } from '../tmux-hook-engine.js';
14
14
 
15
15
  export const SKILL_ACTIVE_STATE_FILE = 'skill-active-state.json';
16
+ export const DEEP_INTERVIEW_BLOCKED_APPROVAL_INPUTS = ['yes', 'y', 'proceed', 'continue', 'ok', 'sure', 'go ahead'];
17
+ export const DEEP_INTERVIEW_INPUT_LOCK_MESSAGE = 'Deep interview is active; auto-approval shortcuts are blocked until the interview finishes.';
18
+ const DEEP_INTERVIEW_ERROR_PATTERNS = [' error', ' failed', ' failure', ' exception', 'unable to continue', 'cannot continue', 'could not continue'];
19
+ const DEEP_INTERVIEW_ABORT_PATTERNS = ['aborted', 'cancelled', 'canceled'];
20
+ const DEEP_INTERVIEW_ABORT_INPUTS = new Set(['abort', 'cancel', 'stop']);
16
21
  const SKILL_PHASES = new Set(['planning', 'executing', 'reviewing', 'completing']);
17
22
 
18
23
  function normalizeSkillPhase(phase) {
@@ -20,6 +25,92 @@ function normalizeSkillPhase(phase) {
20
25
  return SKILL_PHASES.has(normalized) ? normalized : 'planning';
21
26
  }
22
27
 
28
+ function normalizeInputLock(raw) {
29
+ if (!raw || typeof raw !== 'object') return null;
30
+ return {
31
+ active: raw.active !== false,
32
+ scope: safeString(raw.scope),
33
+ acquired_at: safeString(raw.acquired_at),
34
+ released_at: safeString(raw.released_at),
35
+ blocked_inputs: Array.isArray(raw.blocked_inputs)
36
+ ? raw.blocked_inputs.map((value) => safeString(value).toLowerCase()).filter(Boolean)
37
+ : [...DEEP_INTERVIEW_BLOCKED_APPROVAL_INPUTS],
38
+ message: safeString(raw.message) || DEEP_INTERVIEW_INPUT_LOCK_MESSAGE,
39
+ exit_reason: safeString(raw.exit_reason),
40
+ };
41
+ }
42
+
43
+ export function normalizeBlockedAutoApprovalInput(text) {
44
+ return safeString(text)
45
+ .toLowerCase()
46
+ .replace(/\[omx_tmux_inject\]/gi, '')
47
+ .replace(/[^a-z]+/g, ' ')
48
+ .trim();
49
+ }
50
+
51
+ export function isBlockedAutoApprovalInput(text, blockedInputs = DEEP_INTERVIEW_BLOCKED_APPROVAL_INPUTS) {
52
+ const normalized = normalizeBlockedAutoApprovalInput(text);
53
+ if (!normalized) return false;
54
+ if (blockedInputs.some((entry) => normalizeBlockedAutoApprovalInput(entry) === normalized)) return true;
55
+
56
+ const tokens = normalized.split(/\s+/).filter(Boolean);
57
+ if (tokens.length === 0) return false;
58
+
59
+ const blockedTokenSet = new Set(
60
+ blockedInputs.flatMap((entry) => normalizeBlockedAutoApprovalInput(entry).split(/\s+/).filter(Boolean)),
61
+ );
62
+ return tokens.every((token) => blockedTokenSet.has(token));
63
+ }
64
+
65
+ function isDeepInterviewAbortInput(text) {
66
+ return DEEP_INTERVIEW_ABORT_INPUTS.has(normalizeBlockedAutoApprovalInput(text));
67
+ }
68
+
69
+ function hasAnySubstring(text, patterns) {
70
+ const lower = safeString(text).toLowerCase();
71
+ return patterns.some((pattern) => lower.includes(pattern));
72
+ }
73
+
74
+ export function isDeepInterviewAutoApprovalLocked(skillState) {
75
+ return Boolean(
76
+ skillState
77
+ && skillState.skill === 'deep-interview'
78
+ && skillState.input_lock
79
+ && (safeString(skillState.input_lock.scope) === '' || skillState.input_lock.scope === 'deep-interview-auto-approval')
80
+ && skillState.input_lock.active === true,
81
+ );
82
+ }
83
+
84
+ export function inferDeepInterviewReleaseReason({ skillState, latestUserInput = '', lastMessage = '' }) {
85
+ if (!isDeepInterviewAutoApprovalLocked(skillState)) {
86
+ return null;
87
+ }
88
+ if (isDeepInterviewAbortInput(latestUserInput) || hasAnySubstring(lastMessage, DEEP_INTERVIEW_ABORT_PATTERNS)) {
89
+ return 'abort';
90
+ }
91
+ if (hasAnySubstring(` ${safeString(lastMessage).toLowerCase()}`, DEEP_INTERVIEW_ERROR_PATTERNS)) {
92
+ return 'error';
93
+ }
94
+ if (skillState.phase === 'completing') {
95
+ return 'success';
96
+ }
97
+ return null;
98
+ }
99
+
100
+ function releaseDeepInterviewInputLock(skillState, reason, nowIso) {
101
+ if (!skillState?.input_lock) return skillState;
102
+ skillState.input_lock = {
103
+ ...skillState.input_lock,
104
+ active: false,
105
+ released_at: nowIso,
106
+ exit_reason: reason,
107
+ };
108
+ skillState.phase = 'completing';
109
+ skillState.active = false;
110
+ skillState.updated_at = nowIso;
111
+ return skillState;
112
+ }
113
+
23
114
  export function normalizeSkillActiveState(raw) {
24
115
  if (!raw || typeof raw !== 'object') {
25
116
  return null;
@@ -35,6 +126,7 @@ export function normalizeSkillActiveState(raw) {
35
126
  activated_at: safeString(raw.activated_at),
36
127
  updated_at: safeString(raw.updated_at),
37
128
  source: safeString(raw.source),
129
+ input_lock: normalizeInputLock(raw.input_lock),
38
130
  };
39
131
  }
40
132
 
@@ -68,6 +160,12 @@ async function persistSkillActiveState(stateDir, state) {
68
160
  await writeFile(join(stateDir, SKILL_ACTIVE_STATE_FILE), JSON.stringify(state, null, 2)).catch(() => {});
69
161
  }
70
162
 
163
+ function latestUserInputFromPayload(payload) {
164
+ const inputMessages = payload['input-messages'] || payload.input_messages || [];
165
+ if (!Array.isArray(inputMessages) || inputMessages.length === 0) return '';
166
+ return safeString(inputMessages[inputMessages.length - 1]);
167
+ }
168
+
71
169
  export const DEFAULT_STALL_PATTERNS = [
72
170
  'if you want',
73
171
  'would you like',
@@ -134,15 +232,11 @@ export async function loadAutoNudgeConfig() {
134
232
 
135
233
  export function detectStallPattern(text, patterns) {
136
234
  if (!text || typeof text !== 'string') return false;
137
- // Broader tail window (~800 chars / ~15-20 lines) for context
138
235
  const tail = text.slice(-800).toLowerCase();
139
236
  const lowerPatterns = patterns.map(p => p.toLowerCase());
140
- // Focus on last few lines where stall prompts typically appear
141
237
  const lines = tail.split('\n').filter(l => l.trim());
142
238
  const hotZone = lines.slice(-3).join('\n');
143
- // Primary: check last few lines (highest signal)
144
239
  if (lowerPatterns.some(p => hotZone.includes(p))) return true;
145
- // Secondary: check broader tail window
146
240
  return lowerPatterns.some(p => tail.includes(p));
147
241
  }
148
242
 
@@ -158,11 +252,9 @@ export async function capturePane(paneId, lines = 10) {
158
252
  }
159
253
 
160
254
  export async function resolveNudgePaneTarget(stateDir) {
161
- // 1. Try TMUX_PANE env var (inherited from the Codex process)
162
255
  const envPane = safeString(process.env.TMUX_PANE || '');
163
256
  if (envPane) return envPane;
164
257
 
165
- // 2. Fallback: check active mode states for tmux_pane_id
166
258
  try {
167
259
  const scopedDirs = await getScopedStateDirsForCurrentSession(stateDir);
168
260
  for (const dir of scopedDirs) {
@@ -187,93 +279,111 @@ export async function resolveNudgePaneTarget(stateDir) {
187
279
  return '';
188
280
  }
189
281
 
282
+ async function emitInjectionMessage(paneId, message) {
283
+ const markedResponse = `${message} ${DEFAULT_MARKER}`;
284
+ await runProcess('tmux', ['send-keys', '-t', paneId, '-l', markedResponse], 3000);
285
+ await new Promise(r => setTimeout(r, 100));
286
+ await runProcess('tmux', ['send-keys', '-t', paneId, 'C-m'], 3000);
287
+ await new Promise(r => setTimeout(r, 100));
288
+ await runProcess('tmux', ['send-keys', '-t', paneId, 'C-m'], 3000);
289
+ }
290
+
190
291
  export async function maybeAutoNudge({ cwd, stateDir, logsDir, payload }) {
191
292
  const config = await loadAutoNudgeConfig();
192
293
  if (!config.enabled) return;
193
294
 
194
- const skillState = await loadSkillActiveState(stateDir);
195
295
  const lastMessage = safeString(payload['last-assistant-message'] || payload.last_assistant_message || '');
196
- if (skillState) {
197
- const inferredPhase = inferSkillPhaseFromText(lastMessage, skillState.phase);
198
- if (inferredPhase !== skillState.phase || skillState.active !== (inferredPhase !== 'completing')) {
296
+ const latestUserInput = latestUserInputFromPayload(payload);
297
+ let skillState = await loadSkillActiveState(stateDir);
298
+ let releaseReason = null;
299
+
300
+ try {
301
+ if (skillState) {
302
+ const inferredPhase = inferSkillPhaseFromText(lastMessage, skillState.phase);
199
303
  skillState.phase = inferredPhase;
200
304
  skillState.active = inferredPhase !== 'completing';
201
305
  skillState.updated_at = new Date().toISOString();
306
+ releaseReason = inferDeepInterviewReleaseReason({ skillState, latestUserInput, lastMessage });
202
307
  await persistSkillActiveState(stateDir, skillState);
203
308
  }
204
- }
205
309
 
206
- // Check nudge count against session limit
207
- const nudgeStatePath = join(stateDir, 'auto-nudge-state.json');
208
- let nudgeState = await readJsonIfExists(nudgeStatePath, null);
209
- if (!nudgeState || typeof nudgeState !== 'object') {
210
- nudgeState = { nudgeCount: 0, lastNudgeAt: '' };
211
- }
212
- const nudgeCount = asNumber(nudgeState.nudgeCount) ?? 0;
213
- if (Number.isFinite(config.maxNudgesPerSession) && nudgeCount >= config.maxNudgesPerSession) return;
310
+ const nudgeStatePath = join(stateDir, 'auto-nudge-state.json');
311
+ let nudgeState = await readJsonIfExists(nudgeStatePath, null);
312
+ if (!nudgeState || typeof nudgeState !== 'object') {
313
+ nudgeState = { nudgeCount: 0, lastNudgeAt: '' };
314
+ }
315
+ const nudgeCount = asNumber(nudgeState.nudgeCount) ?? 0;
316
+ if (Number.isFinite(config.maxNudgesPerSession) && nudgeCount >= config.maxNudgesPerSession) return;
214
317
 
215
- // Resolve pane target early (needed for both capture-pane check and sending)
216
- const paneId = await resolveNudgePaneTarget(stateDir);
318
+ const paneId = await resolveNudgePaneTarget(stateDir);
217
319
 
218
- // Check last assistant message for stall patterns (fast path)
219
- let detected = detectStallPattern(lastMessage, config.patterns);
220
- let source = 'payload';
320
+ let detected = detectStallPattern(lastMessage, config.patterns);
321
+ let source = 'payload';
221
322
 
222
- // Fallback: capture the last 10 lines of tmux pane output
223
- if (!detected && paneId) {
224
- const captured = await capturePane(paneId);
225
- detected = detectStallPattern(captured, config.patterns);
226
- source = 'capture-pane';
227
- }
228
-
229
- // Preserve completion quietness unless we explicitly see a stall phrase.
230
- // This handles stale skill-state files that remain in "completing" while
231
- // the assistant still asks for permission ("if you want", etc.).
232
- if (skillState?.phase === 'completing' && !detected) return;
323
+ if (!detected && paneId) {
324
+ const captured = await capturePane(paneId);
325
+ detected = detectStallPattern(captured, config.patterns);
326
+ source = 'capture-pane';
327
+ }
233
328
 
234
- if (!detected || !paneId) return;
329
+ if (skillState?.phase === 'completing' && !detected) return;
330
+ if (!detected || !paneId) return;
235
331
 
236
- // Short delay to let the agent settle before nudging
237
- if (config.delaySec > 0) {
238
- await new Promise(r => setTimeout(r, config.delaySec * 1000));
239
- }
332
+ const deepInterviewLockActive = isDeepInterviewAutoApprovalLocked(skillState) && !releaseReason;
333
+ if (deepInterviewLockActive && isBlockedAutoApprovalInput(config.response, skillState.input_lock?.blocked_inputs)) {
334
+ const blockedMessage = skillState.input_lock?.message || DEEP_INTERVIEW_INPUT_LOCK_MESSAGE;
335
+ await emitInjectionMessage(paneId, blockedMessage);
336
+ await logTmuxHookEvent(logsDir, {
337
+ timestamp: new Date().toISOString(),
338
+ type: 'auto_nudge_blocked',
339
+ pane_id: paneId,
340
+ response: config.response,
341
+ source,
342
+ blocked_by: 'deep-interview-lock',
343
+ message: blockedMessage,
344
+ }).catch(() => {});
345
+ return;
346
+ }
240
347
 
241
- const nowIso = new Date().toISOString();
242
- try {
243
- // Send the response text as literal bytes, then submit with double C-m
244
- // Codex CLI needs C-m sent twice with a short delay for reliable prompt submission
245
- const markedResponse = `${config.response} ${DEFAULT_MARKER}`;
246
- await runProcess('tmux', ['send-keys', '-t', paneId, '-l', markedResponse], 3000);
247
- await new Promise(r => setTimeout(r, 100));
248
- await runProcess('tmux', ['send-keys', '-t', paneId, 'C-m'], 3000);
249
- await new Promise(r => setTimeout(r, 100));
250
- await runProcess('tmux', ['send-keys', '-t', paneId, 'C-m'], 3000);
251
-
252
- nudgeState.nudgeCount = nudgeCount + 1;
253
- nudgeState.lastNudgeAt = nowIso;
254
- await writeFile(nudgeStatePath, JSON.stringify(nudgeState, null, 2)).catch(() => {});
255
-
256
- if (skillState && skillState.phase === 'planning') {
257
- skillState.phase = 'executing';
258
- skillState.active = true;
259
- skillState.updated_at = nowIso;
260
- await persistSkillActiveState(stateDir, skillState);
348
+ if (config.delaySec > 0) {
349
+ await new Promise(r => setTimeout(r, config.delaySec * 1000));
261
350
  }
262
351
 
263
- await logTmuxHookEvent(logsDir, {
264
- timestamp: nowIso,
265
- type: 'auto_nudge',
266
- pane_id: paneId,
267
- response: config.response,
268
- source,
269
- nudge_count: nudgeState.nudgeCount,
270
- });
271
- } catch (err) {
272
- await logTmuxHookEvent(logsDir, {
273
- timestamp: nowIso,
274
- type: 'auto_nudge',
275
- pane_id: paneId,
276
- error: err instanceof Error ? err.message : safeString(err),
277
- }).catch(() => {});
352
+ const nowIso = new Date().toISOString();
353
+ try {
354
+ await emitInjectionMessage(paneId, config.response);
355
+
356
+ nudgeState.nudgeCount = nudgeCount + 1;
357
+ nudgeState.lastNudgeAt = nowIso;
358
+ await writeFile(nudgeStatePath, JSON.stringify(nudgeState, null, 2)).catch(() => {});
359
+
360
+ if (skillState && skillState.phase === 'planning') {
361
+ skillState.phase = 'executing';
362
+ skillState.active = true;
363
+ skillState.updated_at = nowIso;
364
+ await persistSkillActiveState(stateDir, skillState);
365
+ }
366
+
367
+ await logTmuxHookEvent(logsDir, {
368
+ timestamp: nowIso,
369
+ type: 'auto_nudge',
370
+ pane_id: paneId,
371
+ response: config.response,
372
+ source,
373
+ nudge_count: nudgeState.nudgeCount,
374
+ });
375
+ } catch (err) {
376
+ await logTmuxHookEvent(logsDir, {
377
+ timestamp: nowIso,
378
+ type: 'auto_nudge',
379
+ pane_id: paneId,
380
+ error: err instanceof Error ? err.message : safeString(err),
381
+ }).catch(() => {});
382
+ }
383
+ } finally {
384
+ if (releaseReason && skillState && isDeepInterviewAutoApprovalLocked(skillState)) {
385
+ releaseDeepInterviewInputLock(skillState, releaseReason, new Date().toISOString());
386
+ await persistSkillActiveState(stateDir, skillState).catch(() => {});
387
+ }
278
388
  }
279
389
  }
@@ -0,0 +1,107 @@
1
+ ---
2
+ name: ai-slop-cleaner
3
+ description: Run an anti-slop cleanup/refactor/deslop workflow
4
+ ---
5
+
6
+ # AI Slop Cleaner Skill
7
+
8
+ Reduce AI-generated slop with a regression-tests-first, smell-by-smell cleanup workflow that preserves behavior and raises signal quality.
9
+
10
+ ## When to Use
11
+
12
+ Use this skill when:
13
+ - A code path works but feels bloated, noisy, repetitive, or over-abstracted
14
+ - A user asks to “cleanup”, “refactor”, or “deslop” AI-generated output
15
+ - Follow-up implementation left duplicate code, dead code, weak boundaries, missing tests, or unnecessary wrapper layers
16
+ - You need a disciplined cleanup workflow without broad rewrites
17
+
18
+ ## GPT-5.4 Guidance Alignment
19
+
20
+ - Keep outputs concise and evidence-dense unless risk or the user requests more detail.
21
+ - Treat newer user instructions as local workflow updates without discarding earlier non-conflicting constraints.
22
+ - Keep using inspection, tests, diagnostics, and verification until the cleanup is grounded.
23
+ - Proceed automatically through clear, reversible cleanup steps; ask only when a choice materially changes scope or behavior.
24
+
25
+ ## Procedure
26
+
27
+ 1. **Lock behavior with regression tests first**
28
+ - Identify the behavior that must not change
29
+ - Add or run targeted regression tests before editing cleanup candidates
30
+ - If behavior is currently untested, create the narrowest test coverage needed first
31
+
32
+ 2. **Create a cleanup plan before code**
33
+ - List the specific smells to remove
34
+ - Bound the pass to the requested files/scope
35
+ - Order fixes from safest/highest-signal to riskiest
36
+ - Do not start coding until the cleanup plan is explicit
37
+
38
+ 3. **Categorize issues before editing**
39
+ - **Duplication** — repeated logic, copy-paste branches, redundant helpers
40
+ - **Dead code** — unused code, unreachable branches, stale flags, debug leftovers
41
+ - **Needless abstraction** — pass-through wrappers, speculative indirection, single-use helper layers
42
+ - **Boundary violations** — hidden coupling, leaky responsibilities, wrong-layer imports or side effects
43
+ - **Missing tests** — behavior not locked, weak regression coverage, gaps around edge cases
44
+
45
+ 4. **Execute passes one smell at a time**
46
+ - **Pass 1: Dead code deletion**
47
+ - **Pass 2: Duplicate removal**
48
+ - **Pass 3: Naming/error handling cleanup**
49
+ - **Pass 4: Test reinforcement**
50
+ - Re-run targeted verification after each pass
51
+ - Avoid bundling unrelated refactors into the same edit set
52
+
53
+ 5. **Run quality gates**
54
+ - Regression tests stay green
55
+ - Lint passes
56
+ - Typecheck passes
57
+ - Relevant unit/integration tests pass
58
+ - Static/security scan passes when available
59
+ - Diff stays minimal and scoped
60
+ - No new abstractions or dependencies unless explicitly required
61
+
62
+ 6. **Finish with an evidence-dense report**
63
+ - Changed files
64
+ - Simplifications made
65
+ - Tests/diagnostics/build checks run
66
+ - Remaining risks
67
+ - Residual follow-ups or consciously deferred cleanup
68
+
69
+ ## Output Format
70
+
71
+ ```text
72
+ AI SLOP CLEANUP REPORT
73
+ ======================
74
+
75
+ Scope: [files or feature area]
76
+ Behavior Lock: [targeted regression tests added/run]
77
+ Cleanup Plan: [bounded smells and order]
78
+
79
+ Passes Completed:
80
+ 1. Pass 1: Dead code deletion - [concise fix]
81
+ 2. Pass 2: Duplicate removal - [concise fix]
82
+ 3. Pass 3: Naming/error handling cleanup - [concise fix]
83
+ 4. Pass 4: Test reinforcement - [concise fix]
84
+
85
+ Quality Gates:
86
+ - Regression tests: PASS/FAIL
87
+ - Lint: PASS/FAIL
88
+ - Typecheck: PASS/FAIL
89
+ - Tests: PASS/FAIL
90
+ - Static/security scan: PASS/FAIL or N/A
91
+
92
+ Changed Files:
93
+ - [path] - [simplification]
94
+
95
+ Remaining Risks:
96
+ - [none or short deferred item]
97
+ ```
98
+
99
+ ## Scenario Examples
100
+
101
+ **Good:** The user says `continue` after tests already lock behavior and the next smell pass is clear. Continue with the next bounded cleanup pass.
102
+
103
+ **Good:** The user narrows the scope to a specific file after planning. Keep the regression-tests-first workflow, but apply the new scope locally.
104
+
105
+ **Bad:** Start rewriting architecture before protecting behavior with tests.
106
+
107
+ **Bad:** Collapse multiple smell categories into one large refactor with no intermediate verification.
@@ -108,9 +108,12 @@ Jumping into code without understanding requirements leads to rework, scope cree
108
108
 
109
109
  ### Review Mode (`--review`)
110
110
 
111
+ 0. Treat review as a reviewer-only pass. The context that wrote the plan, cleanup proposal, or diff MUST NOT be the context that approves it.
111
112
  1. Read plan file from `.omx/plans/`
112
113
  2. Evaluate via Critic using `ask_codex` with `agent_role: "critic"`
113
- 3. Return verdict: APPROVED, REVISE (with specific feedback), or REJECT (replanning required)
114
+ 3. For cleanup/refactor/anti-slop work, verify that the artifact includes a cleanup plan, regression tests or an explicit test gap, smell-by-smell passes, and quality gates.
115
+ 4. Return verdict: APPROVED, REVISE (with specific feedback), or REJECT (replanning required)
116
+ 5. If the current context authored the artifact, hand the review to `/review`, `critic`, `quality-reviewer`, `security-reviewer`, or `verifier` as appropriate.
114
117
 
115
118
  ### Plan Output Format
116
119
 
@@ -1,11 +1,11 @@
1
1
  ---
2
2
  name: review
3
- description: Alias for /plan --review
3
+ description: Reviewer-only pass for /plan --review and cleanup artifact review
4
4
  ---
5
5
 
6
- # Review (Plan Review Alias)
6
+ # Review (Reviewer-Only Pass)
7
7
 
8
- Review is a shorthand alias for `/plan --review`. It triggers Critic evaluation of an existing plan.
8
+ Review is a shorthand alias for `/plan --review`. It triggers Critic evaluation of an existing plan and is intended to preserve writer/reviewer separation.
9
9
 
10
10
  ## Usage
11
11
 
@@ -23,8 +23,16 @@ This skill invokes the Plan skill in review mode:
23
23
  ```
24
24
 
25
25
  The review workflow:
26
- 1. Read plan file from `.omx/plans/` (or specified path)
27
- 2. Evaluate via Critic agent
28
- 3. Return verdict: APPROVED, REVISE (with specific feedback), or REJECT (replanning required)
26
+ 1. Treat review as a reviewer-only pass. The authoring context may write the plan or cleanup proposal, but a separate reviewer context must issue the verdict.
27
+ 2. Read plan file from `.omx/plans/` (or specified path)
28
+ 3. Evaluate via Critic agent
29
+ 4. For cleanup/refactor/anti-slop work, confirm the artifact includes a cleanup plan, regression-test coverage or an explicit test gap, bounded smell-by-smell passes, and quality gates.
30
+ 5. Return verdict: APPROVED, REVISE (with specific feedback), or REJECT (replanning required)
31
+
32
+ ## Guardrails
33
+
34
+ - Never write and approve in the same context.
35
+ - If the current context authored the artifact, hand review to Critic or another reviewer role.
36
+ - Approval must cite concrete evidence, not author claims.
29
37
 
30
38
  Follow the Plan skill's full documentation for review mode details.
@@ -147,15 +147,15 @@ Model precedence (highest to lowest):
147
147
  Thinking-level rule (critical):
148
148
  - **No model-name heuristic mapping.**
149
149
  - Team runtime must **not** infer `model_reasoning_effort` from model-name substrings (e.g., `spark`, `high-capability`, `mini`).
150
- - Worker thinking level is applied **only when explicitly provided** (leader/user launch args or explicit config).
151
- - If no explicit thinking value is provided, runtime leaves `model_reasoning_effort` unset.
150
+ - When the leader assigns teammate roles/tasks, OMX allocates **per-worker reasoning effort dynamically** from the resolved worker role (`low`, `medium`, `high`).
151
+ - Explicit launch args still win: if `OMX_TEAM_WORKER_LAUNCH_ARGS` already includes `-c model_reasoning_effort=...`, that explicit value overrides dynamic allocation for every worker.
152
152
 
153
153
  Normalization requirements:
154
154
  - Parse both `--model <value>` and `--model=<value>`
155
155
  - Remove duplicate/conflicting model flags
156
156
  - Emit exactly one final canonical flag: `--model <value>`
157
157
  - Preserve unrelated args in worker launch config
158
- - If explicit reasoning exists, preserve canonical `-c model_reasoning_effort="<level>"`; otherwise do not inject one
158
+ - If explicit reasoning exists, preserve canonical `-c model_reasoning_effort="<level>"`; otherwise inject the worker role's default reasoning level
159
159
 
160
160
  ## Required Lifecycle (Operator Contract)
161
161
 
@@ -36,6 +36,16 @@ Keep runtime marker contracts stable and non-destructive when overlays are appli
36
36
  <!-- OMX:GUIDANCE:OPERATING:END -->
37
37
  </operating_principles>
38
38
 
39
+ ## Working agreements
40
+ - Write a cleanup plan before modifying code for cleanup/refactor/deslop work.
41
+ - Lock existing behavior with regression tests before cleanup edits when behavior is not already protected.
42
+ - Prefer deletion over addition.
43
+ - Reuse existing utils and patterns before introducing new abstractions.
44
+ - No new dependencies without explicit request.
45
+ - Keep diffs small, reviewable, and reversible.
46
+ - Run lint, typecheck, tests, and static analysis after changes.
47
+ - Final reports must include changed files, simplifications made, and remaining risks.
48
+
39
49
  ---
40
50
 
41
51
  <delegation_rules>
@@ -48,6 +58,8 @@ Work directly only for trivial operations where delegation adds disproportionate
48
58
  - Small clarifications, quick status checks, or single-command sequential operations.
49
59
 
50
60
  For substantive code changes, delegate to `executor` (default for both standard and complex implementation work).
61
+ Outside active `team`/`swarm` mode, use `executor` (or another standard role prompt) for implementation work; do not invoke `worker` or spawn Worker-labeled helpers in non-team mode.
62
+ Reserve `worker` strictly for active `team`/`swarm` sessions and team-runtime bootstrap flows.
51
63
  For non-trivial SDK/API/framework usage, delegate to `dependency-expert` to check official docs first.
52
64
  </delegation_rules>
53
65
 
@@ -80,6 +92,7 @@ Key constraints:
80
92
  - Each child has its own context window (not shared with parent)
81
93
  - Parent must read prompt file BEFORE calling spawn_agent
82
94
  - Child agents can access skills ($name) but should focus on their assigned role
95
+ - `worker` is a team-runtime surface, not a general-purpose child role; outside active `team`/`swarm` mode, never substitute `worker` for `executor`
83
96
  - Child role prompts should report recommended handoffs upward instead of recursively orchestrating unless the parent explicitly authorizes recursion
84
97
  </child_agent_protocol>
85
98
 
@@ -160,6 +173,7 @@ Do not ask for confirmation — just read the skill file and follow its instruct
160
173
  | "autopilot", "build me", "I want a" | `$autopilot` | Read `~/.agents/skills/autopilot/SKILL.md`, execute autonomous pipeline |
161
174
  | "ultrawork", "ulw", "parallel" | `$ultrawork` | Read `~/.agents/skills/ultrawork/SKILL.md`, execute parallel agents |
162
175
  | "ultraqa" | `$ultraqa` | Read `~/.agents/skills/ultraqa/SKILL.md`, run QA cycling workflow |
176
+ | "anti-slop", "cleanup", "refactor", "deslop" | `$ai-slop-cleaner` | Read `~/.agents/skills/ai-slop-cleaner/SKILL.md`, run the tests-first anti-slop cleanup workflow |
163
177
  | "analyze", "investigate" | `$analyze` | Read `~/.agents/skills/analyze/SKILL.md`, run deep analysis |
164
178
  | "plan this", "plan the", "let's plan" | `$plan` | Read `~/.agents/skills/plan/SKILL.md`, start planning workflow |
165
179
  | "interview", "deep interview", "gather requirements", "interview me", "don't assume", "ouroboros" | `$deep-interview` | Read `~/.agents/skills/deep-interview/SKILL.md`, run Ouroboros-inspired Socratic ambiguity-gated interview workflow |
@@ -202,6 +216,7 @@ Workflow Skills:
202
216
  - `team`: N coordinated agents on shared task list
203
217
  - `swarm`: N coordinated agents on shared task list (compatibility facade over team)
204
218
  - `ultraqa`: QA cycling -- test, verify, fix, repeat
219
+ - `ai-slop-cleaner`: Tests-first anti-slop cleanup workflow with cleanup planning, smell-by-smell passes, and reviewer separation
205
220
  - `plan`: Strategic planning with optional RALPLAN-DR consensus mode
206
221
  - `deep-interview`: Socratic deep interview with Ouroboros-inspired mathematical ambiguity gating before execution
207
222
  - `ralplan`: Iterative consensus planning with RALPLAN-DR structured deliberation (planner + architect + critic); supports `--deliberate` for high-risk work
@@ -217,6 +232,7 @@ Agent Shortcuts:
217
232
  - `git-master` -> git-master: Git commit and history management
218
233
 
219
234
  Utilities:
235
+ - `review`: Reviewer-only pass for existing plans or cleanup artifacts; use a separate reviewer context and never self-approve
220
236
  - `cancel`: Cancel active execution modes
221
237
  - `note`: Save notes for session persistence
222
238
  - `doctor`: Diagnose installation issues
@@ -312,6 +328,14 @@ Parallelization:
312
328
  - If a task update changes only the current branch of work, apply it locally and continue without reinterpreting unrelated standing instructions.
313
329
  - When correctness depends on retrieval, diagnostics, tests, or other tools, continue using them until the task is grounded and verified.
314
330
 
331
+ Anti-slop workflow:
332
+ - For cleanup/refactor/deslop requests, route through `$ai-slop-cleaner` unless the user explicitly requests a different workflow.
333
+ - Lock behavior with regression tests first, then write a cleanup plan before code changes.
334
+ - Categorize issues (duplication, dead code, needless abstraction, boundary violations, missing tests) and execute one smell-focused pass at a time.
335
+ - Prefer deletion, reuse, and boundary repair over new layers or dependencies.
336
+ - Minimum cleanup quality gates: lint -> typecheck -> relevant unit/integration tests -> static/security scan when available.
337
+ - Use writer/reviewer pass separation for plans, cleanup proposals, and approval: the context/agent that writes the change or plan must not be the final reviewer or approver.
338
+
315
339
  Visual iteration gate:
316
340
  - For visual tasks (reference image(s) + generated screenshot), run `$visual-verdict` every iteration before the next edit.
317
341
  - Persist visual verdict JSON in `.omx/state/{scope}/ralph-progress.json` with both numeric (`score`, threshold pass/fail) and qualitative (`reasoning`, `differences`, `suggestions`, `next_actions`) feedback.
@@ -108,6 +108,13 @@
108
108
  "core": false,
109
109
  "internalRequired": false
110
110
  },
111
+ {
112
+ "name": "ai-slop-cleaner",
113
+ "category": "shortcut",
114
+ "status": "active",
115
+ "core": false,
116
+ "internalRequired": false
117
+ },
111
118
  {
112
119
  "name": "code-review",
113
120
  "category": "shortcut",