ocmm 0.5.0 → 0.5.2

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 (157) hide show
  1. package/.codex/agents/dw-builder.toml +1 -1
  2. package/.codex/agents/dw-clarifier.toml +1 -1
  3. package/.codex/agents/dw-code-search.toml +1 -1
  4. package/.codex/agents/dw-coding.toml +1 -1
  5. package/.codex/agents/dw-complex.toml +1 -1
  6. package/.codex/agents/dw-creative.toml +1 -1
  7. package/.codex/agents/dw-deep.toml +1 -1
  8. package/.codex/agents/dw-doc-search.toml +1 -1
  9. package/.codex/agents/dw-documenting.toml +1 -1
  10. package/.codex/agents/dw-explore.toml +1 -1
  11. package/.codex/agents/dw-frontend.toml +1 -1
  12. package/.codex/agents/dw-hard-reasoning.toml +1 -1
  13. package/.codex/agents/dw-media-reader.toml +1 -1
  14. package/.codex/agents/dw-normal-task.toml +1 -1
  15. package/.codex/agents/dw-oracle.toml +2 -2
  16. package/.codex/agents/dw-orchestrator.toml +1 -1
  17. package/.codex/agents/dw-plan-critic.toml +1 -1
  18. package/.codex/agents/dw-planner.toml +1 -1
  19. package/.codex/agents/dw-quick.toml +1 -1
  20. package/.codex/agents/dw-research.toml +1 -1
  21. package/.codex/agents/dw-reviewer.toml +2 -2
  22. package/README.md +7 -2
  23. package/dist/codex/plugin-generator.js +40 -26
  24. package/dist/codex/plugin-generator.js.map +1 -1
  25. package/dist/config/normalize.d.ts +2 -0
  26. package/dist/config/normalize.js +17 -0
  27. package/dist/config/normalize.js.map +1 -1
  28. package/dist/config/schema.d.ts +17 -1
  29. package/dist/config/schema.js +17 -0
  30. package/dist/config/schema.js.map +1 -1
  31. package/dist/data/agents.js +2 -2
  32. package/dist/data/agents.js.map +1 -1
  33. package/dist/hooks/chat-params.js +18 -0
  34. package/dist/hooks/chat-params.js.map +1 -1
  35. package/dist/hooks/config.d.ts +1 -0
  36. package/dist/hooks/config.js +82 -25
  37. package/dist/hooks/config.js.map +1 -1
  38. package/dist/hooks/event.d.ts +1 -0
  39. package/dist/hooks/event.js +1 -0
  40. package/dist/hooks/event.js.map +1 -1
  41. package/dist/index.js +5 -1
  42. package/dist/index.js.map +1 -1
  43. package/dist/intent/prompt-loader.d.ts +4 -2
  44. package/dist/intent/prompt-loader.js +8 -2
  45. package/dist/intent/prompt-loader.js.map +1 -1
  46. package/dist/permissions/index.d.ts +1 -0
  47. package/dist/permissions/index.js +58 -0
  48. package/dist/permissions/index.js.map +1 -1
  49. package/dist/routing/model-upgrades.d.ts +3 -0
  50. package/dist/routing/model-upgrades.js +123 -0
  51. package/dist/routing/model-upgrades.js.map +1 -0
  52. package/dist/routing/resolver.d.ts +11 -1
  53. package/dist/routing/resolver.js +63 -69
  54. package/dist/routing/resolver.js.map +1 -1
  55. package/dist/runtime-fallback/event-handler.d.ts +1 -0
  56. package/dist/runtime-fallback/event-handler.js +37 -26
  57. package/dist/runtime-fallback/event-handler.js.map +1 -1
  58. package/package.json +1 -1
  59. package/plugins/deepwork/.codex-plugin/plugin.json +1 -1
  60. package/plugins/deepwork/agents/dw-builder.toml +1 -1
  61. package/plugins/deepwork/agents/dw-clarifier.toml +1 -1
  62. package/plugins/deepwork/agents/dw-code-search.toml +1 -1
  63. package/plugins/deepwork/agents/dw-coding.toml +1 -1
  64. package/plugins/deepwork/agents/dw-complex.toml +1 -1
  65. package/plugins/deepwork/agents/dw-creative.toml +1 -1
  66. package/plugins/deepwork/agents/dw-deep.toml +1 -1
  67. package/plugins/deepwork/agents/dw-doc-search.toml +1 -1
  68. package/plugins/deepwork/agents/dw-documenting.toml +1 -1
  69. package/plugins/deepwork/agents/dw-explore.toml +1 -1
  70. package/plugins/deepwork/agents/dw-frontend.toml +1 -1
  71. package/plugins/deepwork/agents/dw-hard-reasoning.toml +1 -1
  72. package/plugins/deepwork/agents/dw-media-reader.toml +1 -1
  73. package/plugins/deepwork/agents/dw-normal-task.toml +1 -1
  74. package/plugins/deepwork/agents/dw-oracle.toml +2 -2
  75. package/plugins/deepwork/agents/dw-orchestrator.toml +1 -1
  76. package/plugins/deepwork/agents/dw-plan-critic.toml +1 -1
  77. package/plugins/deepwork/agents/dw-planner.toml +1 -1
  78. package/plugins/deepwork/agents/dw-quick.toml +1 -1
  79. package/plugins/deepwork/agents/dw-research.toml +1 -1
  80. package/plugins/deepwork/agents/dw-reviewer.toml +2 -2
  81. package/plugins/deepwork/package.json +1 -1
  82. package/plugins/deepwork/skills/ast-grep/SKILL.md +2 -1
  83. package/plugins/deepwork/skills/debugging/SKILL.md +2 -1
  84. package/plugins/deepwork/skills/deepwork/SKILL.md +32 -11
  85. package/plugins/deepwork/skills/deepwork-brainstorming/SKILL.md +2 -1
  86. package/plugins/deepwork/skills/deepwork-dispatching-parallel-agents/SKILL.md +2 -1
  87. package/plugins/deepwork/skills/deepwork-receiving-code-review/SKILL.md +2 -1
  88. package/plugins/deepwork/skills/deepwork-requesting-code-review/SKILL.md +6 -1
  89. package/plugins/deepwork/skills/deepwork-subagent-driven-development/SKILL.md +2 -1
  90. package/plugins/deepwork/skills/deepwork-writing-plans/SKILL.md +13 -8
  91. package/plugins/deepwork/skills/frontend/SKILL.md +3 -2
  92. package/plugins/deepwork/skills/frontend/references/design/README.md +9 -3
  93. package/plugins/deepwork/skills/frontend/references/design/design-system-architecture.md +44 -13
  94. package/plugins/deepwork/skills/git-master/SKILL.md +2 -1
  95. package/plugins/deepwork/skills/init-deep/SKILL.md +2 -1
  96. package/plugins/deepwork/skills/remove-ai-slops/SKILL.md +2 -1
  97. package/plugins/deepwork/skills/using-git-worktrees/SKILL.md +2 -1
  98. package/prompts/codex/agents/plan-critic.md +6 -0
  99. package/prompts/codex/agents/planner.md +3 -1
  100. package/prompts/codex/category/coding.md +4 -0
  101. package/prompts/codex/category/complex.md +4 -0
  102. package/prompts/codex/category/creative.md +4 -0
  103. package/prompts/codex/category/deep.md +4 -0
  104. package/prompts/codex/category/documenting.md +4 -0
  105. package/prompts/codex/category/frontend.md +4 -0
  106. package/prompts/codex/category/hard-reasoning.md +4 -0
  107. package/prompts/codex/category/normal-task.md +4 -0
  108. package/prompts/codex/category/quick.md +4 -0
  109. package/prompts/codex/category/research.md +4 -0
  110. package/prompts/codex/deepwork/codex.md +10 -4
  111. package/prompts/codex/deepwork/default.md +6 -0
  112. package/prompts/codex/deepwork/gemini.md +7 -0
  113. package/prompts/codex/deepwork/glm.md +6 -0
  114. package/prompts/codex/deepwork/gpt-5.6.md +35 -0
  115. package/prompts/codex/deepwork/gpt.md +6 -0
  116. package/prompts/codex/deepwork/planner.md +6 -0
  117. package/prompts/omo/category/coding.md +4 -0
  118. package/prompts/omo/category/complex.md +4 -0
  119. package/prompts/omo/category/creative.md +4 -0
  120. package/prompts/omo/category/deep.md +4 -0
  121. package/prompts/omo/category/documenting.md +4 -0
  122. package/prompts/omo/category/frontend.md +4 -0
  123. package/prompts/omo/category/hard-reasoning.md +4 -0
  124. package/prompts/omo/category/normal-task.md +4 -0
  125. package/prompts/omo/category/quick.md +4 -0
  126. package/prompts/omo/category/research.md +4 -0
  127. package/prompts/omo/deepwork/codex.md +10 -4
  128. package/prompts/omo/deepwork/default.md +8 -2
  129. package/prompts/omo/deepwork/gemini.md +8 -2
  130. package/prompts/omo/deepwork/glm.md +6 -0
  131. package/prompts/omo/deepwork/gpt-5.6.md +31 -0
  132. package/prompts/omo/deepwork/gpt.md +7 -1
  133. package/prompts/omo/deepwork/planner.md +6 -0
  134. package/prompts/v1/agents/plan-critic.md +6 -0
  135. package/prompts/v1/agents/planner.md +3 -1
  136. package/prompts/v1/category/coding.md +4 -0
  137. package/prompts/v1/category/complex.md +4 -0
  138. package/prompts/v1/category/creative.md +4 -0
  139. package/prompts/v1/category/deep.md +4 -0
  140. package/prompts/v1/category/documenting.md +4 -0
  141. package/prompts/v1/category/frontend.md +4 -0
  142. package/prompts/v1/category/hard-reasoning.md +4 -0
  143. package/prompts/v1/category/normal-task.md +4 -0
  144. package/prompts/v1/category/quick.md +4 -0
  145. package/prompts/v1/category/research.md +4 -0
  146. package/prompts/v1/deepwork/codex.md +10 -4
  147. package/prompts/v1/deepwork/default.md +6 -0
  148. package/prompts/v1/deepwork/gemini.md +9 -2
  149. package/prompts/v1/deepwork/glm.md +6 -0
  150. package/prompts/v1/deepwork/gpt-5.6.md +35 -0
  151. package/prompts/v1/deepwork/gpt.md +6 -0
  152. package/prompts/v1/deepwork/planner.md +6 -0
  153. package/skills/frontend/SKILL.md +1 -1
  154. package/skills/frontend/references/design/README.md +9 -3
  155. package/skills/frontend/references/design/design-system-architecture.md +44 -13
  156. package/skills/v1/requesting-code-review/SKILL.md +4 -0
  157. package/skills/v1/writing-plans/SKILL.md +11 -7
@@ -15,11 +15,19 @@ Every frontend project MUST have a `DESIGN.md` at its root. This file is the sin
15
15
 
16
16
  ## DESIGN.md Structure
17
17
 
18
- The file has 7 sections. Every section is mandatory. Skip nothing.
18
+ The file has nine sections, numbered 0 through 8. Every section is mandatory. Skip nothing. Section 0 applies to greenfield UI; existing-project extraction may state that historical research is unavailable instead of inventing it.
19
19
 
20
20
  ```markdown
21
21
  # [Project Name] Design System
22
22
 
23
+ ## 0. Research Log
24
+
25
+ For greenfield UI, record the design decision before writing product screens.
26
+
27
+ - **Candidates considered**: 2-3 relevant local Layer B/design references, with a short reason each fits or does not fit.
28
+ - **Selection**: the chosen Layer A execution skill and Layer B/design reference, with rationale tied to the product and audience.
29
+ - **Evidence (optional)**: a local `ui-ux-db` lookup, user-provided image, or local mockup. If a tool/source is unavailable or not relevant, record the reason instead of forcing network research.
30
+
23
31
  ## 1. Atmosphere & Identity
24
32
 
25
33
  One paragraph. What this product FEELS like. Not what it does — how it feels to use.
@@ -112,18 +120,23 @@ All spacing derives from a base of **4px**.
112
120
 
113
121
  ## 5. Components
114
122
 
115
- Document reusable patterns as they emerge. Format:
123
+ ### Planned Showcase Primitives
124
+
125
+ This is a pre-implementation verification checklist, not reusable component documentation. Before composing a greenfield product screen, list each intended primitive and check its applicable default, hover, focus, disabled, loading, empty, and error states in a component showcase or equivalent state page.
126
+
127
+ ### Implemented Reusable Patterns
128
+
129
+ Document only implemented reusable patterns used 2+ times. Format:
116
130
 
117
131
  ### [Component Name]
118
132
  - **Structure**: HTML/JSX outline
119
133
  - **Variants**: list
120
134
  - **Spacing**: which tokens
121
- - **States**: default, hover, active, focus, disabled, loading, error
135
+ - **States**: default, hover, active, focus, disabled, loading, empty, error
122
136
  - **Accessibility**: keyboard, ARIA, contrast
123
137
  - **Motion**: entry/exit animations
124
138
 
125
- Start with components used 2+ times. Do not pre-document components
126
- that don't exist yet.
139
+ Do not promote planned primitives or one-off implementations into reusable component documentation.
127
140
 
128
141
  ## 6. Motion & Interaction
129
142
 
@@ -162,6 +175,20 @@ If borders:
162
175
 
163
176
  If tonal-shift:
164
177
  Surfaces use progressively lighter/darker shades. No borders, no shadows.
178
+
179
+ ## 8. Accessibility Constraints & Accepted Debt
180
+
181
+ ### Constraints
182
+
183
+ - **WCAG goal**: state the target level and the testable scope.
184
+ - **Contrast**: document text, control, and focus-indicator contrast requirements.
185
+ - **Keyboard and focus**: every interactive primitive has a keyboard path and visible focus treatment.
186
+ - **ARIA**: semantic HTML first; document required names, roles, and live-region behavior for custom controls.
187
+ - **Reduced motion**: respect `prefers-reduced-motion` and identify any essential motion.
188
+
189
+ ### Accepted Debt
190
+
191
+ Each exception records its location, reason, owner, and exit criteria. An agent may not accept accessibility debt or a constraint exception silently: it requires explicit user authorization.
165
192
  ```
166
193
 
167
194
  ## Creation Workflow
@@ -169,13 +196,15 @@ Surfaces use progressively lighter/darker shades. No borders, no shadows.
169
196
  ### For New Projects
170
197
 
171
198
  1. **Ask or infer the product domain** — SaaS dashboard? Marketing site? Dev tool?
172
- 2. **Write the Atmosphere paragraph** — one chance to establish identity.
173
- 3. **Define palette** — derive from atmosphere. Not random. Not generic.
174
- 4. **Set typography** — match the atmosphere. Editorial = serif. Technical = mono-heavy. Clean = geometric sans.
175
- 5. **Lock spacing** — base-4 system. Customize only the section-level values.
176
- 6. **Document initial components** — only those you are about to build.
177
- 7. **Choose depth strategy** — one. Not "a mix."
178
- 8. **Write it to `DESIGN.md`** at project root.
199
+ 2. **Write the Research Log** — consider 2-3 relevant local design candidates, select Layer A + Layer B, and record optional local evidence or why it was unavailable.
200
+ 3. **Write the Atmosphere paragraph** — one chance to establish identity.
201
+ 4. **Define palette** — derive from atmosphere. Not random. Not generic.
202
+ 5. **Set typography** — match the atmosphere. Editorial = serif. Technical = mono-heavy. Clean = geometric sans.
203
+ 6. **Lock spacing** — base-4 system. Customize only the section-level values.
204
+ 7. **Fill in Planned Showcase Primitives** — use the pre-implementation verification checklist to cover intended primitives and states before composing a product screen; do not treat it as reusable component documentation.
205
+ 8. **Choose depth strategy** — one. Not "a mix."
206
+ 9. **Set accessibility constraints and record no debt without user authorization.**
207
+ 10. **Write it to `DESIGN.md`** at project root.
179
208
 
180
209
  ### For Existing Projects (Extraction)
181
210
 
@@ -194,8 +223,10 @@ After every component implementation, check:
194
223
  - [ ] All spacing values are multiples of `--space-1` (4px). No magic numbers.
195
224
  - [ ] Interactive elements have all required states from Section 6.
196
225
  - [ ] Depth treatment matches the chosen strategy from Section 7.
197
- - [ ] Component reused 2+ times? Documented in Section 5.
226
+ - [ ] Implemented reusable pattern used 2+ times? Documented in Section 5.
198
227
  - [ ] Motion follows the timing table. No arbitrary durations.
228
+ - [ ] `Planned Showcase Primitives` is complete for greenfield UI, with a showcase (or equivalent state page) covering default, hover, focus, disabled, loading, empty, and error before product-screen composition.
229
+ - [ ] Section 8 constraints were checked; any accepted debt has location, reason, owner, exit criteria, and explicit user authorization.
199
230
 
200
231
  ## Memory Management
201
232
 
@@ -77,6 +77,10 @@ Two reviewer agents are available, with distinct semantics:
77
77
 
78
78
  **Default:** `oracle` for simple tasks. Upgrade to both when the orchestrator judges the task complex or large.
79
79
 
80
+ `oracle` can also be an optional independent consultation for a high-risk implementation plan. It does not replace the `plan-critic` receipt, does not make dual plan review mandatory, and a timeout or partial response is not a conclusion.
81
+
82
+ **GPT/Codex reasoning policy:** `reviewer` and `oracle` use `xhigh` minimum. For complex or high-risk review or verification, request local `max`; the adapter maps it to the target's maximum supported effort (currently `xhigh` for GPT/Codex). `plan-critic` remains `xhigh`.
83
+
80
84
  ## Example
81
85
 
82
86
  ```
@@ -154,24 +154,26 @@ If you find issues, fix them inline. No need to re-review — just fix and move
154
154
 
155
155
  ## plan-critic Review Loop
156
156
 
157
- After self-review passes, submit the plan to the `plan-critic` agent for a mandatory review loop. The plan-critic agent reads the plan path or inline plan and returns a three-state verdict.
157
+ After self-review passes, submit the plan to the `plan-critic` agent for a mandatory review loop. A review round covers exactly one saved, complete, current plan revision. A current receipt is valid only when that round returns an explicit `[OKAY]` or `[OKAY-UNAMBIGUOUS]`; any plan edit invalidates every earlier receipt.
158
+
159
+ Timeouts, `WORKING`, acknowledgements, partial output, a missing verdict, or a review of an older/incomplete plan are not approval. Wait for a complete verdict, follow up, or re-dispatch the critic for the current full plan. Dispatch success is not a receipt.
158
160
 
159
161
  **Loop procedure:**
160
162
 
161
- 1. Submit the plan to the `plan-critic` agent (pass the plan file path, or the inline plan if not yet saved).
162
- 2. Dispatch the plan-critic agent and wait for its verdict.
163
+ 1. Save the complete plan, then submit that exact plan path to the `plan-critic` agent.
164
+ 2. Dispatch the plan-critic agent and wait for one explicit verdict for the current revision.
163
165
  3. Branch on the verdict:
164
166
 
165
167
  | Verdict | Meaning | Action |
166
168
  |---|---|---|
167
- | `[REJECT]` | Critical blockers exist; plan not executable as-is | Apply the blocker fixes (max 3), re-run self-review, resubmit. Loop. |
169
+ | `[REJECT]` | Critical blockers exist; plan not executable as-is | Apply the blocker fixes (max 3), re-run self-review, save the updated complete plan, then begin a fresh critic round. |
168
170
  | `[OKAY]` | Plan is executable; residual uncertainty/ambiguity remains | Exit the loop. Proceed to user approval (unless delegation applies). |
169
171
  | `[OKAY-UNAMBIGUOUS]` | Plan is executable AND logically clear with no ambiguity | Exit the loop. Skip user approval. Proceed to Execution Handoff. |
170
172
 
171
173
  **Loop cap (user delegation "review N 次就下一步"):**
172
174
 
173
175
  If the user has delegated with "review N 次就下一步" / "review N times then proceed", cap the loop at N iterations. After N iterations:
174
- - If still `[REJECT]`: record the unresolved blockers in the plan (as a "Known Unresolved Blockers" section) and proceed anyway. Do not block the workflow.
176
+ - If still `[REJECT]`, or no current receipt exists: record unresolved blockers in the plan (as a "Known Unresolved Blockers" section) and proceed only under the explicit status `delegated-without-plan-approval`. Do not call this approved, passed, or receipted.
175
177
  - If `[OKAY]` or `[OKAY-UNAMBIGUOUS]` reached before N: exit early.
176
178
 
177
179
  **Plan approval conditionality:**
@@ -185,11 +187,13 @@ After the loop exits, determine whether user approval is required:
185
187
 
186
188
  > "Plan written to `<path>`. plan-critic verdict: `[OKAY]` (executable, residual uncertainty). Please review and approve before execution, or delegate with '你自己决定' / '无需批准自行继续' to proceed."
187
189
 
188
- Wait for the user's response. If they request changes, make them, re-run self-review, and re-run the plan-critic loop. Only proceed once the user approves or delegates.
190
+ Wait for the user's response. If they request changes, make them, re-run self-review, and re-run the plan-critic loop for the changed plan. Only proceed once the user approves or delegates.
191
+
192
+ `oracle` may provide an optional, independent consultation for a high-risk plan, but it never replaces the current `plan-critic` receipt and does not create a mandatory dual-review gate.
189
193
 
190
194
  ## Execution Handoff
191
195
 
192
- After saving the plan, proceed to the subagent-driven-development skill to execute it.
196
+ Proceed to the subagent-driven-development skill only with a current plan-critic receipt, user approval where required, or an explicitly labeled `delegated-without-plan-approval` exception. Report the current receipt verdict or `waiting for receipt`; never treat a dispatch timeout or acknowledgement as pass.
193
197
 
194
198
  **Execution:**
195
199
  - Fresh subagent per task + completion/integration check after each returned agent + final acceptance review once after all tasks