oh-my-codex 0.7.4 → 0.7.6

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 (140) hide show
  1. package/README.md +14 -0
  2. package/dist/cli/__tests__/index.test.js +25 -1
  3. package/dist/cli/__tests__/index.test.js.map +1 -1
  4. package/dist/cli/__tests__/ralph.test.d.ts +2 -0
  5. package/dist/cli/__tests__/ralph.test.d.ts.map +1 -0
  6. package/dist/cli/__tests__/ralph.test.js +64 -0
  7. package/dist/cli/__tests__/ralph.test.js.map +1 -0
  8. package/dist/cli/__tests__/team-decompose.test.d.ts +2 -0
  9. package/dist/cli/__tests__/team-decompose.test.d.ts.map +1 -0
  10. package/dist/cli/__tests__/team-decompose.test.js +67 -0
  11. package/dist/cli/__tests__/team-decompose.test.js.map +1 -0
  12. package/dist/cli/index.d.ts +6 -0
  13. package/dist/cli/index.d.ts.map +1 -1
  14. package/dist/cli/index.js +25 -3
  15. package/dist/cli/index.js.map +1 -1
  16. package/dist/cli/ralph.d.ts +12 -0
  17. package/dist/cli/ralph.d.ts.map +1 -1
  18. package/dist/cli/ralph.js +58 -1
  19. package/dist/cli/ralph.js.map +1 -1
  20. package/dist/cli/team.d.ts +18 -0
  21. package/dist/cli/team.d.ts.map +1 -1
  22. package/dist/cli/team.js +108 -16
  23. package/dist/cli/team.js.map +1 -1
  24. package/dist/config/generator.d.ts.map +1 -1
  25. package/dist/config/generator.js +8 -0
  26. package/dist/config/generator.js.map +1 -1
  27. package/dist/hooks/__tests__/notify-fallback-watcher.test.js +10 -7
  28. package/dist/hooks/__tests__/notify-fallback-watcher.test.js.map +1 -1
  29. package/dist/hooks/__tests__/notify-hook-team-dispatch.test.js +11 -7
  30. package/dist/hooks/__tests__/notify-hook-team-dispatch.test.js.map +1 -1
  31. package/dist/hooks/__tests__/notify-hook-tmux-heal.test.js +199 -0
  32. package/dist/hooks/__tests__/notify-hook-tmux-heal.test.js.map +1 -1
  33. package/dist/hooks/__tests__/notify-hook-visual-verdict.test.d.ts +11 -0
  34. package/dist/hooks/__tests__/notify-hook-visual-verdict.test.d.ts.map +1 -0
  35. package/dist/hooks/__tests__/notify-hook-visual-verdict.test.js +266 -0
  36. package/dist/hooks/__tests__/notify-hook-visual-verdict.test.js.map +1 -0
  37. package/dist/hooks/__tests__/notify-hook-worker-idle.test.js +4 -5
  38. package/dist/hooks/__tests__/notify-hook-worker-idle.test.js.map +1 -1
  39. package/dist/hooks/__tests__/tmux-hook-engine.test.js +36 -1
  40. package/dist/hooks/__tests__/tmux-hook-engine.test.js.map +1 -1
  41. package/dist/mcp/__tests__/team-server-cleanup.test.d.ts +2 -0
  42. package/dist/mcp/__tests__/team-server-cleanup.test.d.ts.map +1 -0
  43. package/dist/mcp/__tests__/team-server-cleanup.test.js +219 -0
  44. package/dist/mcp/__tests__/team-server-cleanup.test.js.map +1 -0
  45. package/dist/mcp/bootstrap.d.ts +1 -1
  46. package/dist/mcp/bootstrap.d.ts.map +1 -1
  47. package/dist/mcp/bootstrap.js +1 -0
  48. package/dist/mcp/bootstrap.js.map +1 -1
  49. package/dist/mcp/state-server.d.ts.map +1 -1
  50. package/dist/mcp/state-server.js +11 -2
  51. package/dist/mcp/state-server.js.map +1 -1
  52. package/dist/mcp/team-server.d.ts +24 -0
  53. package/dist/mcp/team-server.d.ts.map +1 -0
  54. package/dist/mcp/team-server.js +419 -0
  55. package/dist/mcp/team-server.js.map +1 -0
  56. package/dist/notifications/__tests__/verbosity.test.js +35 -0
  57. package/dist/notifications/__tests__/verbosity.test.js.map +1 -1
  58. package/dist/notifications/config.d.ts.map +1 -1
  59. package/dist/notifications/config.js +4 -2
  60. package/dist/notifications/config.js.map +1 -1
  61. package/dist/notifications/tmux.d.ts.map +1 -1
  62. package/dist/notifications/tmux.js +11 -2
  63. package/dist/notifications/tmux.js.map +1 -1
  64. package/dist/notifications/types.d.ts +4 -0
  65. package/dist/notifications/types.d.ts.map +1 -1
  66. package/dist/openclaw/__tests__/index.test.js +40 -0
  67. package/dist/openclaw/__tests__/index.test.js.map +1 -1
  68. package/dist/openclaw/index.d.ts.map +1 -1
  69. package/dist/openclaw/index.js +1 -0
  70. package/dist/openclaw/index.js.map +1 -1
  71. package/dist/openclaw/types.d.ts +2 -0
  72. package/dist/openclaw/types.d.ts.map +1 -1
  73. package/dist/team/__tests__/role-router.test.d.ts +2 -0
  74. package/dist/team/__tests__/role-router.test.d.ts.map +1 -0
  75. package/dist/team/__tests__/role-router.test.js +204 -0
  76. package/dist/team/__tests__/role-router.test.js.map +1 -0
  77. package/dist/team/__tests__/runtime-cli.test.d.ts +2 -0
  78. package/dist/team/__tests__/runtime-cli.test.d.ts.map +1 -0
  79. package/dist/team/__tests__/runtime-cli.test.js +72 -0
  80. package/dist/team/__tests__/runtime-cli.test.js.map +1 -0
  81. package/dist/team/__tests__/runtime.test.js +194 -5
  82. package/dist/team/__tests__/runtime.test.js.map +1 -1
  83. package/dist/team/__tests__/scaling.test.js +132 -2
  84. package/dist/team/__tests__/scaling.test.js.map +1 -1
  85. package/dist/team/__tests__/tmux-session.test.js +86 -7
  86. package/dist/team/__tests__/tmux-session.test.js.map +1 -1
  87. package/dist/team/__tests__/worker-bootstrap.test.js +38 -0
  88. package/dist/team/__tests__/worker-bootstrap.test.js.map +1 -1
  89. package/dist/team/__tests__/worktree.test.js +27 -1
  90. package/dist/team/__tests__/worktree.test.js.map +1 -1
  91. package/dist/team/idle-nudge.d.ts +53 -0
  92. package/dist/team/idle-nudge.d.ts.map +1 -0
  93. package/dist/team/idle-nudge.js +140 -0
  94. package/dist/team/idle-nudge.js.map +1 -0
  95. package/dist/team/mcp-comm.d.ts +1 -1
  96. package/dist/team/mcp-comm.d.ts.map +1 -1
  97. package/dist/team/role-router.d.ts +32 -0
  98. package/dist/team/role-router.d.ts.map +1 -0
  99. package/dist/team/role-router.js +137 -0
  100. package/dist/team/role-router.js.map +1 -0
  101. package/dist/team/runtime-cli.d.ts +18 -0
  102. package/dist/team/runtime-cli.d.ts.map +1 -0
  103. package/dist/team/runtime-cli.js +238 -0
  104. package/dist/team/runtime-cli.js.map +1 -0
  105. package/dist/team/runtime.d.ts +4 -0
  106. package/dist/team/runtime.d.ts.map +1 -1
  107. package/dist/team/runtime.js +108 -42
  108. package/dist/team/runtime.js.map +1 -1
  109. package/dist/team/scaling.d.ts +1 -0
  110. package/dist/team/scaling.d.ts.map +1 -1
  111. package/dist/team/scaling.js +41 -20
  112. package/dist/team/scaling.js.map +1 -1
  113. package/dist/team/state.d.ts +2 -1
  114. package/dist/team/state.d.ts.map +1 -1
  115. package/dist/team/state.js.map +1 -1
  116. package/dist/team/tmux-session.d.ts +42 -2
  117. package/dist/team/tmux-session.d.ts.map +1 -1
  118. package/dist/team/tmux-session.js +219 -65
  119. package/dist/team/tmux-session.js.map +1 -1
  120. package/dist/team/worker-bootstrap.d.ts +2 -0
  121. package/dist/team/worker-bootstrap.d.ts.map +1 -1
  122. package/dist/team/worker-bootstrap.js +29 -5
  123. package/dist/team/worker-bootstrap.js.map +1 -1
  124. package/dist/team/worktree.d.ts +5 -1
  125. package/dist/team/worktree.d.ts.map +1 -1
  126. package/dist/team/worktree.js +28 -16
  127. package/dist/team/worktree.js.map +1 -1
  128. package/package.json +1 -1
  129. package/scripts/notify-hook/log.js +5 -0
  130. package/scripts/notify-hook/team-dispatch.js +44 -8
  131. package/scripts/notify-hook/team-worker.js +26 -4
  132. package/scripts/notify-hook/tmux-injection.js +45 -4
  133. package/scripts/notify-hook/visual-verdict.js +109 -0
  134. package/scripts/notify-hook.js +26 -0
  135. package/scripts/tmux-hook-engine.js +24 -0
  136. package/skills/autopilot/SKILL.md +2 -2
  137. package/skills/doctor/SKILL.md +1 -1
  138. package/skills/help/SKILL.md +3 -3
  139. package/skills/skill/SKILL.md +32 -32
  140. package/skills/team/SKILL.md +43 -0
@@ -404,6 +404,32 @@ async function main() {
404
404
  // Non-critical
405
405
  }
406
406
 
407
+ // 10.5. Visual verdict persistence (non-fatal, observable – issue #421)
408
+ if (!isTeamWorker) {
409
+ try {
410
+ const { maybePersistVisualVerdict } = await import('./notify-hook/visual-verdict.js');
411
+ await maybePersistVisualVerdict({
412
+ payload,
413
+ stateDir,
414
+ logsDir,
415
+ sessionId: payloadSessionId,
416
+ turnId: safeString(payload['turn-id'] || payload.turn_id || ''),
417
+ });
418
+ } catch (err) {
419
+ // Structured warning for module import failure (issue #421)
420
+ const warnEntry = JSON.stringify({
421
+ timestamp: new Date().toISOString(),
422
+ level: 'warn',
423
+ type: 'visual_verdict_import_failure',
424
+ error: err?.message || String(err),
425
+ session_id: payloadSessionId,
426
+ turn_id: safeString(payload['turn-id'] || payload.turn_id || ''),
427
+ });
428
+ const warnFile = join(logsDir, `notify-hook-${new Date().toISOString().split('T')[0]}.jsonl`);
429
+ await appendFile(warnFile, warnEntry + '\n').catch(() => {});
430
+ }
431
+ }
432
+
407
433
  // 10. Code simplifier: delegate recently modified files for simplification.
408
434
  // Opt-in via ~/.omx/config.json: { "codeSimplifier": { "enabled": true } }
409
435
  if (!isTeamWorker) {
@@ -154,6 +154,30 @@ export function buildPaneInModeArgv(paneTarget) {
154
154
  return ['display-message', '-p', '-t', paneTarget, '#{pane_in_mode}'];
155
155
  }
156
156
 
157
+ /**
158
+ * Returns the tmux argv to query the current foreground command of a pane.
159
+ * Used to detect when the agent process has exited and the pane has returned
160
+ * to a shell (zsh, bash, fish, etc.).
161
+ */
162
+ export function buildPaneCurrentCommandArgv(paneTarget) {
163
+ return ['display-message', '-p', '-t', paneTarget, '#{pane_current_command}'];
164
+ }
165
+
166
+ const SHELL_COMMANDS = new Set(['zsh', 'bash', 'fish', 'sh', 'dash', 'ksh', 'csh', 'tcsh', 'login']);
167
+
168
+ /**
169
+ * Returns true when the pane's foreground process is an interactive shell,
170
+ * meaning the agent has exited and injection would land on a bare prompt.
171
+ */
172
+ export function isPaneRunningShell(paneCurrentCommand) {
173
+ if (typeof paneCurrentCommand !== 'string') return false;
174
+ const cmd = paneCurrentCommand.trim().toLowerCase();
175
+ if (cmd === '') return false;
176
+ // Handle paths like /bin/zsh -> zsh, and flags like -zsh -> zsh
177
+ const base = cmd.split('/').pop().replace(/^-/, '');
178
+ return SHELL_COMMANDS.has(base);
179
+ }
180
+
157
181
  export function buildCapturePaneArgv(paneTarget, tailLines = 80) {
158
182
  return ['capture-pane', '-t', paneTarget, '-p', '-S', `-${tailLines}`];
159
183
  }
@@ -139,7 +139,7 @@ Why bad: This is an exploration/brainstorming request. Respond conversationally
139
139
  Optional settings in `~/.codex/config.toml`:
140
140
 
141
141
  ```toml
142
- [omc.autopilot]
142
+ [omx.autopilot]
143
143
  maxIterations = 10
144
144
  maxQaCycles = 5
145
145
  maxValidationRounds = 3
@@ -172,7 +172,7 @@ RALPLAN (consensus planning) -> team-exec (Codex CLI workers) -> ralph-verify (a
172
172
  Pipeline configuration options:
173
173
 
174
174
  ```toml
175
- [omc.autopilot.pipeline]
175
+ [omx.autopilot.pipeline]
176
176
  maxRalphIterations = 10 # Ralph verification iteration ceiling
177
177
  workerCount = 2 # Number of Codex CLI team workers
178
178
  agentType = "executor" # Agent type for team workers
@@ -152,7 +152,7 @@ rm -f ~/.codex/hooks/stop-continuation.sh
152
152
 
153
153
  ### Fix: Outdated Plugin
154
154
  ```bash
155
- rm -rf ~/.codex/plugins/cache/oh-my-codex
155
+ rm -rf ~/.codex/plugins/cache/omc/oh-my-codex
156
156
  echo "Plugin cache cleared. Restart Codex CLI to fetch latest version."
157
157
  ```
158
158
 
@@ -44,7 +44,7 @@ I'll figure out what to stop based on context.
44
44
  If you haven't configured OMX yet:
45
45
 
46
46
  ```
47
- /omc-setup
47
+ /omx-setup
48
48
  ```
49
49
 
50
50
  This is the **only command** you need to know. It downloads the configuration and you're done.
@@ -134,7 +134,7 @@ Based on patterns found, output recommendations:
134
134
  - "Use security-reviewer after auth/API changes"
135
135
 
136
136
  **If defaultExecutionMode not set:**
137
- - "Set defaultExecutionMode in /omc-setup for consistent behavior"
137
+ - "Set defaultExecutionMode in /omx-setup for consistent behavior"
138
138
 
139
139
  ### Step 4: Output Report
140
140
 
@@ -179,7 +179,7 @@ No token tracking found. To enable tracking:
179
179
  1. Ensure ~/.omx/state/ directory exists
180
180
  2. Run any OMX command to start tracking
181
181
 
182
- Tip: Run /omc-setup to configure OMX properly.
182
+ Tip: Run /omx-setup to configure OMX properly.
183
183
  ```
184
184
 
185
185
  ## Need More Help?
@@ -15,19 +15,19 @@ Meta-skill for managing oh-my-codex skills via CLI-like commands.
15
15
  Show all local skills organized by scope.
16
16
 
17
17
  **Behavior:**
18
- 1. Scan user skills at `~/.codex/skills/omc-learned/`
19
- 2. Scan project skills at `.omx/skills/`
18
+ 1. Scan user skills at `~/.agents/skills/`
19
+ 2. Scan project skills at `.agents/skills/`
20
20
  3. Parse YAML frontmatter for metadata
21
21
  4. Display in organized table format:
22
22
 
23
23
  ```
24
- USER SKILLS (~/.codex/skills/omc-learned/):
24
+ USER SKILLS (~/.agents/skills/):
25
25
  | Name | Triggers | Quality | Usage | Scope |
26
26
  |-------------------|--------------------|---------|-------|-------|
27
27
  | error-handler | fix, error | 95% | 42 | user |
28
28
  | api-builder | api, endpoint | 88% | 23 | user |
29
29
 
30
- PROJECT SKILLS (.omx/skills/):
30
+ PROJECT SKILLS (.agents/skills/):
31
31
  | Name | Triggers | Quality | Usage | Scope |
32
32
  |-------------------|--------------------|---------|-------|---------|
33
33
  | test-runner | test, run | 92% | 15 | project |
@@ -51,8 +51,8 @@ Interactive wizard for creating a new skill.
51
51
  4. **Ask for argument hint** (optional)
52
52
  - Example: "<file> [options]"
53
53
  5. **Ask for scope:**
54
- - `user` → `~/.codex/skills/omc-learned/<name>/SKILL.md`
55
- - `project` → `.omx/skills/<name>/SKILL.md`
54
+ - `user` → `~/.agents/skills/<name>/SKILL.md`
55
+ - `project` → `.agents/skills/<name>/SKILL.md`
56
56
  6. **Create skill file** with template:
57
57
 
58
58
  ```yaml
@@ -105,7 +105,7 @@ Triggers (comma-separated): log, logger, logging
105
105
  Argument hint (optional): <level> [message]
106
106
  Scope (user/project): user
107
107
 
108
- ✓ Created skill at ~/.codex/skills/omc-learned/custom-logger/SKILL.md
108
+ ✓ Created skill at ~/.agents/skills/custom-logger/SKILL.md
109
109
  → Edit with: /skill edit custom-logger
110
110
  ```
111
111
 
@@ -117,13 +117,13 @@ Remove a skill by name.
117
117
 
118
118
  **Behavior:**
119
119
  1. **Search for skill** in both scopes:
120
- - `~/.codex/skills/omc-learned/<name>/SKILL.md`
121
- - `.omx/skills/<name>/SKILL.md`
120
+ - `~/.agents/skills/<name>/SKILL.md`
121
+ - `.agents/skills/<name>/SKILL.md`
122
122
  2. **If found:**
123
123
  - Display skill info (name, description, scope)
124
124
  - **Ask for confirmation:** "Delete '<name>' skill from <scope>? (yes/no)"
125
125
  3. **If confirmed:**
126
- - Delete entire skill directory (e.g., `~/.codex/skills/omc-learned/<name>/`)
126
+ - Delete entire skill directory (e.g., `~/.agents/skills/<name>/`)
127
127
  - Report: "✓ Removed skill '<name>' from <scope>"
128
128
  4. **If not found:**
129
129
  - Report: "✗ Skill '<name>' not found in user or project scope"
@@ -135,7 +135,7 @@ Remove a skill by name.
135
135
  User: /skill remove old-logger
136
136
  Assistant: Found skill 'old-logger' in user scope:
137
137
  Description: Legacy logging utility
138
- Scope: user (~/.codex/skills/omc-learned/)
138
+ Scope: user (~/.agents/skills/)
139
139
 
140
140
  Delete 'old-logger' skill? (yes/no)
141
141
 
@@ -251,13 +251,13 @@ Show detailed information about a skill.
251
251
 
252
252
  ```
253
253
  Skill: custom-logger
254
- Scope: user (~/.codex/skills/omc-learned/custom-logger/)
254
+ Scope: user (~/.agents/skills/custom-logger/)
255
255
  Description: Enhanced logging with structured output
256
256
  Triggers: log, logger, logging
257
257
  Argument Hint: <level> [message]
258
258
  Quality: 95% (if available)
259
259
  Usage Count: 42 times (if available)
260
- File Path: /home/user/.codex/skills/omc-learned/custom-logger/SKILL.md
260
+ File Path: /home/user/.agents/skills/custom-logger/SKILL.md
261
261
 
262
262
  --- FULL CONTENT ---
263
263
  [entire markdown content]
@@ -272,7 +272,7 @@ Assistant: Skill: custom-logger
272
272
  Scope: user
273
273
  Description: Enhanced logging with structured output
274
274
  Triggers: log, logger, logging
275
- File: ~/.codex/skills/omc-learned/custom-logger/SKILL.md
275
+ File: ~/.agents/skills/custom-logger/SKILL.md
276
276
 
277
277
  --- CONTENT ---
278
278
  # Custom Logger Skill
@@ -290,8 +290,8 @@ Sync skills between user and project scopes.
290
290
 
291
291
  **Behavior:**
292
292
  1. **Scan both scopes:**
293
- - User skills: `~/.codex/skills/omc-learned/`
294
- - Project skills: `.omx/skills/`
293
+ - User skills: `~/.agents/skills/`
294
+ - Project skills: `.agents/skills/`
295
295
  2. **Compare and categorize:**
296
296
  - User-only skills (not in project)
297
297
  - Project-only skills (not in user)
@@ -339,7 +339,7 @@ Assistant: Found 5 user-only skills and 2 project-only skills.
339
339
 
340
340
  Copy 'error-handler' from user to project? (yes/no/skip)
341
341
  User: yes
342
- Assistant: ✓ Copied 'error-handler' to .omx/skills/
342
+ Assistant: ✓ Copied 'error-handler' to .agents/skills/
343
343
 
344
344
  Copy 'api-builder' from user to project? (yes/no/skip)
345
345
  User: skip
@@ -360,7 +360,7 @@ First, check if skill directories exist and create them if needed:
360
360
 
361
361
  ```bash
362
362
  # Check and create user-level skills directory
363
- USER_SKILLS_DIR="$HOME/.codex/skills/omc-learned"
363
+ USER_SKILLS_DIR="$HOME/.agents/skills"
364
364
  if [ -d "$USER_SKILLS_DIR" ]; then
365
365
  echo "User skills directory exists: $USER_SKILLS_DIR"
366
366
  else
@@ -369,7 +369,7 @@ else
369
369
  fi
370
370
 
371
371
  # Check and create project-level skills directory
372
- PROJECT_SKILLS_DIR=".omx/skills"
372
+ PROJECT_SKILLS_DIR=".agents/skills"
373
373
  if [ -d "$PROJECT_SKILLS_DIR" ]; then
374
374
  echo "Project skills directory exists: $PROJECT_SKILLS_DIR"
375
375
  else
@@ -384,15 +384,15 @@ Scan both directories and show a comprehensive inventory:
384
384
 
385
385
  ```bash
386
386
  # Scan user-level skills
387
- echo "=== USER-LEVEL SKILLS (~/.codex/skills/omc-learned/) ==="
388
- if [ -d "$HOME/.codex/skills/omc-learned" ]; then
389
- USER_COUNT=$(find "$HOME/.codex/skills/omc-learned" -name "*.md" 2>/dev/null | wc -l)
387
+ echo "=== USER-LEVEL SKILLS (~/.agents/skills/) ==="
388
+ if [ -d "$HOME/.agents/skills" ]; then
389
+ USER_COUNT=$(find "$HOME/.agents/skills" -name "*.md" 2>/dev/null | wc -l)
390
390
  echo "Total skills: $USER_COUNT"
391
391
 
392
392
  if [ $USER_COUNT -gt 0 ]; then
393
393
  echo ""
394
394
  echo "Skills found:"
395
- find "$HOME/.codex/skills/omc-learned" -name "*.md" -type f -exec sh -c '
395
+ find "$HOME/.agents/skills" -name "*.md" -type f -exec sh -c '
396
396
  FILE="$1"
397
397
  NAME=$(grep -m1 "^name:" "$FILE" 2>/dev/null | sed "s/name: //")
398
398
  DESC=$(grep -m1 "^description:" "$FILE" 2>/dev/null | sed "s/description: //")
@@ -408,15 +408,15 @@ else
408
408
  fi
409
409
 
410
410
  echo ""
411
- echo "=== PROJECT-LEVEL SKILLS (.omx/skills/) ==="
412
- if [ -d ".omx/skills" ]; then
413
- PROJECT_COUNT=$(find ".omx/skills" -name "*.md" 2>/dev/null | wc -l)
411
+ echo "=== PROJECT-LEVEL SKILLS (.agents/skills/) ==="
412
+ if [ -d ".agents/skills" ]; then
413
+ PROJECT_COUNT=$(find ".agents/skills" -name "*.md" 2>/dev/null | wc -l)
414
414
  echo "Total skills: $PROJECT_COUNT"
415
415
 
416
416
  if [ $PROJECT_COUNT -gt 0 ]; then
417
417
  echo ""
418
418
  echo "Skills found:"
419
- find ".omx/skills" -name "*.md" -type f -exec sh -c '
419
+ find ".agents/skills" -name "*.md" -type f -exec sh -c '
420
420
  FILE="$1"
421
421
  NAME=$(grep -m1 "^name:" "$FILE" 2>/dev/null | sed "s/name: //")
422
422
  DESC=$(grep -m1 "^description:" "$FILE" 2>/dev/null | sed "s/description: //")
@@ -467,8 +467,8 @@ Ask user to provide either:
467
467
  - **Paste content**: Paste skill markdown content directly
468
468
 
469
469
  Then ask for scope:
470
- - **User-level** (~/.codex/skills/omc-learned/) - Available across all projects
471
- - **Project-level** (.omx/skills/) - Only for this project
470
+ - **User-level** (~/.agents/skills/) - Available across all projects
471
+ - **Project-level** (.agents/skills/) - Only for this project
472
472
 
473
473
  Validate the skill format and save to the chosen location.
474
474
 
@@ -715,7 +715,7 @@ When invoked without arguments, run the full guided wizard.
715
715
 
716
716
  **Automatic Application**: Codex detects triggers and applies skills automatically - no need to remember or search for solutions.
717
717
 
718
- **Version Control**: Project-level skills (.omx/skills/) are committed with your code, so the whole team benefits.
718
+ **Version Control**: Project-level skills (.agents/skills/) are committed with your code, so the whole team benefits.
719
719
 
720
720
  **Evolving Knowledge**: Skills improve over time as you discover better approaches and refine triggers.
721
721
 
@@ -760,8 +760,8 @@ Good skills are:
760
760
  > /skill list
761
761
 
762
762
  Checking skill directories...
763
- ✓ User skills directory exists: ~/.codex/skills/omc-learned/
764
- ✓ Project skills directory exists: .omx/skills/
763
+ ✓ User skills directory exists: ~/.agents/skills/
764
+ ✓ Project skills directory exists: .agents/skills/
765
765
 
766
766
  Scanning for skills...
767
767
 
@@ -343,6 +343,49 @@ When operating this skill, provide concrete progress evidence:
343
343
  Do not claim success without file/pane evidence.
344
344
  Do not claim clean completion if shutdown occurred with `in_progress>0`.
345
345
 
346
+ ## MCP Job Lifecycle Tools
347
+
348
+ For programmatic or agent-driven team spawning (as opposed to interactive CLI use), OMX exposes four MCP tools via the `team-server`:
349
+
350
+ | Tool | Description |
351
+ |------|-------------|
352
+ | `omx_run_team_start` | Spawn tmux CLI workers in the background; returns a `jobId` immediately |
353
+ | `omx_run_team_status` | Non-blocking status check for a running job |
354
+ | `omx_run_team_wait` | Block until the job completes, with automatic idle-pane nudging |
355
+ | `omx_run_team_cleanup` | Kill worker tmux panes for a job (early stop only) |
356
+
357
+ ### CLI vs MCP Tools
358
+
359
+ - **`omx team ...` CLI** — Primary method for interactive team orchestration. Use this when you are operating inside a live tmux session and want direct pane visibility.
360
+ - **`omx_run_team_*` MCP tools** — For programmatic or agent-driven team spawning (analogous to OMC's `omc_run_team_*` tools). Use these when an agent needs to launch workers, poll status, and collect results without manual intervention.
361
+
362
+ ### Naming Distinction
363
+
364
+ Two cleanup tools exist and must not be confused:
365
+
366
+ - `team_cleanup` (**state-server**): Deletes team state **files** on disk (`.omx/state/team/<team>/`). Use after a team run is fully complete.
367
+ - `omx_run_team_cleanup` (**team-server**): Kills tmux worker **panes** for a job. Use only when stopping workers early; otherwise `omx_run_team_wait` handles natural termination.
368
+
369
+ ### Basic Usage Example
370
+
371
+ ```
372
+ 1. omx_run_team_start({
373
+ teamName: "fix-bugs",
374
+ agentTypes: ["codex"],
375
+ tasks: [{ subject: "Fix bug", description: "..." }],
376
+ cwd: "/path/to/project"
377
+ })
378
+ → Returns { jobId: "omx-abc123" }
379
+
380
+ 2. omx_run_team_wait({ job_id: "omx-abc123", timeout_ms: 300000 })
381
+ → Blocks until done, auto-nudges idle panes
382
+
383
+ 3. omx_run_team_cleanup({ job_id: "omx-abc123" })
384
+ → Only needed if stopping workers early
385
+ ```
386
+
387
+ `omx_run_team_status` can be called between steps 1 and 2 for a non-blocking poll if you need to interleave other work while workers run.
388
+
346
389
  ## Limitations
347
390
 
348
391
  - Worktree provisioning requires a git repository and can fail on branch/path collisions