2796 Commits

Author SHA1 Message Date
Codex Review
478093b631 chore(release): bump version to v4.13.0
Includes the autoresearch-as-a-skill migration (#2727) and the
company-context MCP contract scaffolding. Both ship as opt-in
experimental surfaces; minor bump reflects the new functionality
even though the features are not yet GA.

Constraint: autoresearch migration touches shared skill-state and persistent-mode plumbing — minor bump signals upgrade caution despite the experimental label
Confidence: high
Scope-risk: moderate
v4.13.0
2026-04-19 08:08:23 +00:00
Bellman
dd92b0b86c Merge pull request #2727 from Yeachan-Heo/feat/autoresearch-as-a-skill-v2
Reland: autoresearch-as-a-skill migration (fixes conflicts vs #2716)
2026-04-19 13:55:30 +09:00
Bellman
681101c137 Merge pull request #2728 from Gujiassh/fix/hooks-lib-sync-dev-clean-20260419
fix(installer): Copy hooks lib modules during update
2026-04-19 13:36:03 +09:00
Codex Review
59ee7dbc2d test(skills): sync autoresearch skill expectations 2026-04-19 04:34:46 +00:00
gujishh
1f6fee3478 build(installer): refresh hooks lib artifacts 2026-04-19 12:14:08 +09:00
Gujiassh
d0582516d5 fix(installer): copy hooks lib modules during update
Copy templates/hooks/lib into ~/.claude/hooks/lib for standalone installs and update reconciliation so .mjs hooks keep resolving stdin and atomic-write helpers after omc update.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-19 12:11:56 +09:00
Codex Review
d7f8d3d2bd chore(build): regenerate bridge/ and dist/ for autoresearch skill migration
Regenerate CLI and runtime bundles plus compiled TypeScript artifacts so
dist/ matches the skill-first autoresearch sources introduced in the two
preceding commits. Also captures incidental rebuilds for plugin-patterns
and other modules whose dist/ on dev was stale relative to its src/.

Constraint: dist/ is tracked-but-gitignored and must stay in sync with src/
Confidence: high
Scope-risk: narrow
Directive: Do not hand-edit dist/ or bridge/*.cjs; always run npm run build
2026-04-19 02:39:32 +00:00
Codex Review
4ff20e5655 Keep autoresearch enforcement visible across session state
Autoresearch still writes active mode state through the legacy shared path while stop hooks and exclusivity checks have moved toward session-aware enforcement. This commit adds a narrow compatibility bridge for autoresearch stop-hook checks and routes startup exclusivity through the registry's cross-session active-mode detection.

Constraint: Existing autoresearch lifecycle APIs do not yet thread session identifiers end-to-end.

Rejected: Full session-scoped autoresearch normalization now | broader runtime migration than the reviewed defects require.

Rejected: Generic readModeState session fallback | would weaken the session isolation contract for unrelated modes.

Confidence: high

Scope-risk: narrow

Directive: Keep the legacy bridge autoresearch-specific until a dedicated session-normalization migration retires shared autoresearch state.

Tested: npm test -- --run src/hooks/persistent-mode/stop-hook-blocking.test.ts src/autoresearch/__tests__/runtime.test.ts

Tested: npm run build

Tested: lsp_diagnostics_directory totalErrors=0

Not-tested: Full repository test suite
2026-04-19 02:37:26 +00:00
Codex Review
5c5835a26b Preserve the autoresearch skill migration for coordinated review
The team runtime requires a clean leader workspace before it can launch
review workers in dedicated worktrees. This checkpoint captures the
stateful autoresearch migration exactly as verified so the requested
team review can run against a stable branch tip.

Constraint: omx team refuses to launch from a dirty leader workspace
Rejected: Stash local changes temporarily | workers would review an outdated tree
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep omc autoresearch as a hard-deprecated shim; do not restore CLI runtime ownership without revisiting the skill-first contract
Tested: npm run build; targeted vitest suites; project diagnostics via lsp_diagnostics_directory
Not-tested: Full repository test suite; live cron/native scheduling integration
2026-04-19 02:36:57 +00:00
Bellman
68d304a9d7 Merge pull request #2724 from Yeachan-Heo/fix/issue-2723-deep-interview-threshold
Fix deep-interview threshold on native skill path
2026-04-19 01:55:35 +09:00
Codex Review
b3b4dd964a Align deep-interview threshold tests with raw-skill contract
CI exercises both the rendered skill template and the raw shipped SKILL.md.
The previous PR update changed the contract from an injected
ambiguityThreshold sentence to a placeholder/resolved-threshold step, so the
tests need to assert that contract directly. The static skill prose also needs
the portable config-dir notation required by the skill config-dir guard.

Constraint: Keep the static native-loader threshold fix intact
Rejected: Restore the old ambiguityThreshold = ... renderer sentence | would re-couple tests to renderer-only wording
Confidence: high
Scope-risk: narrow
Reversibility: clean
Tested: npx vitest run src/__tests__/skills.test.ts -t "loads deep-interview ambiguityThreshold from settings before state init and updates the announcement copy|refreshes cached deep-interview output when the configured threshold changes without requiring manual cache clearing|replaces all hardcoded 20%/0.2 threshold references in deep-interview template \(issue #2545\)|ships a config-aware deep-interview SKILL.md for native skill-loader paths \(issue #2723\)"
Tested: npx vitest run src/__tests__/auto-slash-aliases.test.ts src/__tests__/skills.test.ts src/skills/__tests__/skill-config-dir.test.ts -t "applies deep-interview threshold runtime injection in slash/materialized output|loads deep-interview ambiguityThreshold from settings before state init and updates the announcement copy|refreshes cached deep-interview output when the configured threshold changes without requiring manual cache clearing|replaces all hardcoded 20%/0.2 threshold references in deep-interview template \(issue #2545\)|ships a config-aware deep-interview SKILL.md for native skill-loader paths \(issue #2723\)|CLAUDE_CONFIG_DIR|total baseline should not increase"
Not-tested: Full test suite
Related: #2723
2026-04-18 16:43:54 +00:00
Codex Review
d3d47a7e7a Make deep-interview threshold explicit in shipped skill text
Claude Code native plugin skill loading can consume the bundled SKILL.md without passing through OMC renderBundledSkillBody. That left the shipped deep-interview skill with hardcoded 20%/0.2 guidance on qualified slash and Skill() paths even though OMC-rendered paths were fixed.

This change makes the bundled deep-interview SKILL.md self-describing for threshold resolution, replacing static 20%/0.2 guidance with runtime placeholders the model must resolve from settings before state init. The existing renderer still resolves those placeholders for OMC-owned paths, so current slash and materialized behavior stays intact.

Constraint: Native Claude plugin skill loading may bypass OMC render hooks
Rejected: Fix this only in renderBundledSkillBody | does not reach raw SKILL.md consumers
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep deep-interview threshold guidance config-aware in raw SKILL.md, not only in JS render transforms
Tested: npx vitest run src/__tests__/auto-slash-aliases.test.ts src/__tests__/skills.test.ts -t "applies deep-interview threshold runtime injection in slash/materialized output|replaces all hardcoded 20%/0.2 threshold references in deep-interview template \(issue #2545\)|ships a config-aware deep-interview SKILL.md for native skill-loader paths \(issue #2723\)"
Not-tested: End-to-end Claude Code native marketplace loader invocation outside repo tests
Related: #2723
2026-04-18 16:33:23 +00:00
Bellman
46da35e719 Merge pull request #2722 from 50sotero/fix/plugin-patterns-spawn-einval-windows
fix(hooks, windows): pass shell:true to plugin-patterns npm/npx spawns (#2721)
2026-04-19 00:25:27 +09:00
Victor de Andrade
a5def5f4e9 test(plugin-patterns): scope win32 shell-flag regex per call site
Codex review on #2722 correctly flagged that [\s\S]*? could cross call
boundaries — dropping the shell flag from runTypeCheck could still pass
if runTests or runLint kept theirs, because the lazy match would just
continue past the end of the target call until it found the flag in a
sibling options object.

Replaced [\s\S]*? with [^}]*? and anchored the match to this call's own
options-object boundaries (\{ … \}\s*\);), so each assertion fails
independently when its target call loses the flag. Keep the option
objects flat — nested braces would terminate [^}]*? prematurely.

Confidence: high
Scope-risk: narrow
Directive: If future option objects nest braces (e.g. { env: { … } }),
  switch these to balanced-scan or per-call substring extraction —
  [^}]*? stops at the first inner }.
Not-tested: Mutation-test that synthetically removes each shell flag
  and asserts each test fails independently.
2026-04-18 12:19:15 +02:00
Victor de Andrade
bfec081caf fix(hooks, windows): pass shell:true to plugin-patterns npm/npx spawns
Three sibling instances of the CVE-2024-27980 EINVAL class fixed in
v4.12.1 for the HUD wrapper, all in src/hooks/plugin-patterns/index.ts:

  - runTypeCheck  spawnSync('npx',  ['tsc', '--noEmit'], …)   L280
  - runTests      execFileSync('npm',['test'],            …)  L301
  - runLint       execFileSync('npm',['run','lint'],      …)  L337

On Windows + Node 20.12+ / 18.20+ / 21.7+, spawning npm/npx (which
resolve to npm.cmd / npx.cmd) via spawnSync/execFileSync without
shell:true throws EINVAL. All three callers are exported, re-exported
through src/hooks/index.ts, and invoked unconditionally by
runPreCommitChecks() in the same file, so every Windows user hitting
the plugin pre-commit flow trips these.

Each call now opts in to shell:true only on win32 so POSIX spawn
behavior is byte-for-byte identical to before.

Added three static-content assertions to plugin-patterns.test.ts under
a new `win32 spawn hardening (#2721)` describe. Static assertions are
the only regression guard available: CI runs Ubuntu-only (see
.github/workflows/ci.yml — every runs-on is ubuntu-latest), so the
existing behavioral tests (runLint "exit 0" etc.) never exercise the
broken Windows spawn path.

Follow-up to #2715 / PR #2719 (v4.12.1). Fixes #2721.

Constraint: CI is Ubuntu-only; behavioral tests cannot detect win32
  spawn regressions. Static content assertions are required as the
  regression guard.
Constraint: The three regex assertions must remain tolerant of inline
  option-object reformatting ([\s\S]*? + anchored to the literal args
  and the shell flag) so future lint-driven reflows don't false-fail.
Rejected: Centralize via a spawnWithShellOnWindows() helper | out of
  scope for a point fix; maintainer can land that separately.
Rejected: Replace execFileSync/spawnSync with exec() on Windows |
  reintroduces shell-injection risk and changes error semantics.
Rejected: Gate on a Node-version check instead of platform | the
  project's engines.node is >=20.0.0 and pre-20.12 is out of support
  scope, so platform gating is simpler and covers every supported Node.
Confidence: high
Scope-risk: narrow
Directive: Do not remove `shell: process.platform === 'win32'` from
  these call sites without either dropping Windows support or replacing
  with a helper that encapsulates the same mitigation.
Not-tested: A behavioral Windows-runner test that asserts EINVAL pre-fix
  and absence-of-EINVAL post-fix. Requires adding a windows-latest
  matrix to .github/workflows/ci.yml, out of scope for this patch.
2026-04-18 12:11:26 +02:00
Bellman
c4db4a883b Merge pull request #2720 from Yeachan-Heo/dev
chore(release): v4.12.1
v4.12.1
2026-04-18 18:48:08 +09:00
Codex Review
7ce1643f33 chore(release): bump version to v4.12.1
Bumps all version files to 4.12.1. Includes 1 new feature, 2 bug fixes,
and 9 other changes across 14 user-facing PRs since v4.12.0.

Highlights:
- feat(hooks): derive subagent model from ANTHROPIC_DEFAULT_*_MODEL env vars (#2683)
- fix(planning): stop OMX ralplan/team follow-ups from re-entering planning (#2718)
- fix(hud): Windows npm.cmd EINVAL fallback (#2719)
- fix(cli): Windows tmux login-shell wrapping (#2713)
- fix(state): OMC state root resolution for nested working directories (#2712)
- fix(team): omc-teams multi-repo Codex handoff contract (#2709)
- fix(hooks): ScheduleWakeup persistent-mode self-cancel on stop (#2698)
- fix(hud): prefer stdin rate limits; suppress read-spike fallback inflation (#2699, #2703)
- fix(installer): cache-root canonicalization prevents escape writes (#2706)
- refactor(skill-state): harden stateful-skills keyword detection + state init (#2701)
- docs: narrow company-context MCP interface to prompt-level contract (#2694)

Constraint: dist/ must be committed for plugin-marketplace git-clone installs (new test dist files force-added per release protocol)
Scope-risk: broad
Confidence: high

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-18 09:39:33 +00:00
Bellman
05b7c04115 Merge pull request #2719 from Yeachan-Heo/fix/issue-2715-hud-npm-cmd-einval
Fix Windows HUD npm.cmd EINVAL fallback
2026-04-18 18:29:39 +09:00
Bellman
dba5633f91 Merge pull request #2718 from Yeachan-Heo/fix/issue-2714-plan-state-loop
fix: stop OMX ralplan/team follow-ups from re-entering planning
2026-04-18 18:25:36 +09:00
Codex Review
ebf2706aa0 Credit documentation stewardship in the project README
Add devswha to the top README as a Document Specialist directly below the ambassadors section so the contributor roster reflects current documentation ownership and links to the correct GitHub profile.\n\nConstraint: Keep this as a docs-only change limited to README.md\nRejected: Adding the entry under Ambassadors | requested role is Document Specialist\nConfidence: high\nScope-risk: narrow\nReversibility: clean\nDirective: Keep contributor role links pointed at canonical GitHub profile URLs\nTested: README.md diff inspection on dev\nNot-tested: Render preview on GitHub
2026-04-18 09:18:39 +00:00
Codex Review
360ca59bba Credit documentation stewardship in the project README
Add devswha to the top README as a Document Specialist directly below the ambassadors section so the contributor roster reflects current documentation ownership and links to the correct GitHub profile.\n\nConstraint: Keep this as a docs-only change limited to README.md\nRejected: Adding the entry under Ambassadors | requested role is Document Specialist\nConfidence: high\nScope-risk: narrow\nReversibility: clean\nDirective: Keep contributor role links pointed at canonical GitHub profile URLs\nTested: README.md diff inspection on dev\nNot-tested: Render preview on GitHub
2026-04-18 09:18:38 +00:00
Codex Review
56513f28a2 Fix Windows HUD npm root discovery
The HUD wrapper needs npm root discovery to keep global installs reachable when cache and marketplace paths are absent. Node 20.12+ rejects direct npm.cmd execFileSync calls on Windows unless shell execution is enabled, so limit shell:true to the Windows npm.cmd probe while preserving the existing non-Windows npm exec behavior.

Constraint: Node 20.12+ requires shell execution for Windows .cmd/.bat child_process calls.

Rejected: Use execSync('npm root -g') everywhere | broader behavior change for non-Windows wrapper runtime.

Confidence: high

Scope-risk: narrow

Tested: npm test -- --run src/installer/__tests__/hud-wrapper-env.test.ts src/__tests__/hud-windows.test.ts src/__tests__/hud-wrapper-template-sync.test.ts src/__tests__/hud-marketplace-resolution.test.ts

Tested: npx tsc
2026-04-18 09:12:30 +00:00
Codex Review
93b72258d7 Prevent post-ralplan team follow-ups from looping back into planning
OMX deep-interview and ralplan flows can write approved artifacts and state
under .omx, but the post-ralplan shortcut path only recognized .omc plan
artifacts, only parsed omc launch hints, and returned early before short
follow-up prompts like "team" could reach the approved execution gate.

This narrows the fix to the state-transition detection path: planning artifact
resolution now reads both .omc and .omx plan roots, launch hints accept OMX
commands, and keyword-detector checks approved follow-ups before the no-match
fast path while recognizing OMX ralplan state files.

Constraint: Team keyword auto-detection remains disabled to avoid worker respawn loops
Rejected: Re-enable generic team keyword detection | would broaden behavior beyond the broken post-ralplan transition
Rejected: Rewrite ralplan state storage globally to .omx only | wider migration than needed for issue #2714
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep approved follow-up detection aligned with both OMC and OMX artifact/state namespaces unless runtime ownership is fully unified
Tested: npx vitest run src/planning/__tests__/artifacts.test.ts src/team/__tests__/followup-planner.test.ts src/__tests__/keyword-detector-script.test.ts
Not-tested: Full repository test suite
Related: #2714
2026-04-18 09:01:49 +00:00
Bellman
43f8cc3505 Merge pull request #2713 from Yeachan-Heo/fix/issue-2711-windows-login-shell
Fix Windows tmux login-shell wrapping for issue #2711
2026-04-18 17:58:18 +09:00
Codex Review
4975462039 Preserve POSIX tmux preflight on MSYS2 Windows shells
The first #2711 fix correctly stopped native Windows shells from receiving
Unix-only exec wrapping, but the preflight path in runClaudeOutsideTmux
still keyed off process.platform alone. That caused MSYS2/Git Bash sessions
on Windows to skip the existing POSIX sleep/tcflush preflight even though
they still use login-shell wrapping.

Constraint: Keep native Windows COMSPEC handling intact
Constraint: Preserve existing POSIX/MSYS2 login-shell behavior without broad launch refactors
Rejected: Revert the Windows-specific path entirely | would reintroduce the original PowerShell failure
Rejected: Add separate MSYS2-specific launch branches everywhere | broader drift than needed
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: When branching shell launch behavior, key off native-Windows-vs-POSIX shell semantics, not process.platform by itself
Tested: npm test -- --run src/cli/__tests__/tmux-utils.test.ts src/cli/__tests__/launch.test.ts src/cli/__tests__/autoresearch-guided.test.ts
Tested: npm run build:cli
Not-tested: Live tmux launch on a real MSYS2/Git Bash Windows host
Related: #2711
Related: #2713
2026-04-18 08:47:00 +00:00
Codex Review
8eabb2be16 Prevent Windows tmux launches from emitting Unix-only exec wrappers
Native Windows shells were receiving Unix login-shell syntax from
wrapWithLoginShell and related tmux launch paths, causing PowerShell/cmd
sessions to fail before Claude or autoresearch setup could start. This
change keeps the existing POSIX/MSYS2 login-shell behavior, but routes
native Windows paths through COMSPEC-compatible command building and
Windows-safe env injection.

Constraint: Preserve existing POSIX login-shell + rc-sourcing behavior
Constraint: Keep the fix narrow to wrapWithLoginShell and directly related launch/setup paths
Rejected: Disable login-shell wrapping everywhere on win32 | would regress MSYS2/Git Bash support
Rejected: Broad tmux contract rewrite | unnecessary drift beyond issue #2711
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: If future tmux launch paths add inline env prefixes, use the platform-aware tmux command builders instead of raw Unix shell syntax
Tested: npm test -- --run src/cli/__tests__/tmux-utils.test.ts src/cli/__tests__/launch.test.ts src/cli/__tests__/autoresearch-guided.test.ts
Tested: npm run build:cli
Not-tested: Live tmux launch on a real Windows host
Related: #2711
2026-04-18 08:24:45 +00:00
Bellman
c90aadab90 Merge pull request #2712 from Yeachan-Heo/fix/issue-2710-omc-state-root
Fix OMC state root resolution for nested working directories
2026-04-18 17:15:31 +09:00
Codex Review
8bcfb1d4ec Preserve temp-directory state while fixing nested git subdirs
The earlier root canonicalization reused validateWorkingDirectory, which is
correct for MCP tool entrypoints but too strict for direct mode-state I/O
callers used by tests and temp workspaces. Narrow the fix so mode-state-io
collapses only directories that are inside a git worktree back to that
worktree root, while leaving non-git temp directories untouched.

Constraint: Direct mode-state-io callers must continue to work in standalone temp directories outside the repo root
Rejected: Keep validateWorkingDirectory in mode-state-io | rejects legitimate temp workspaces and breaks session-state cleanup tests
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Use git-root canonicalization here only for nested worktree paths; keep stricter trusted-root enforcement at MCP/tool boundaries
Tested: npx vitest run src/lib/__tests__/mode-state-io.test.ts src/hooks/session-end/__tests__/mode-state-cleanup.test.ts src/hooks/session-end/__tests__/subdirectory-cwd.test.ts src/hooks/session-end/__tests__/team-cleanup.test.ts
Tested: npx vitest run src/hooks/persistent-mode/__tests__/ralph-verification-flow.test.ts src/hooks/persistent-mode/__tests__/rate-limit-stop.test.ts src/hooks/persistent-mode/__tests__/skill-state-stop.test.ts src/hooks/persistent-mode/__tests__/team-ralplan-stop.test.ts
Not-tested: Full repo test suite
2026-04-18 07:59:07 +00:00
Codex Review
d7508bcc5a Resolve OMC state paths from the real project root
Mode-state I/O was still resolving .omc state paths from the caller's raw
working directory, which let nested cwds create state under subdirectories
instead of the owning git worktree root. Canonicalize the root through
validateWorkingDirectory before resolving, scanning, reading, writing, or
clearing state paths, and add regression coverage for nested cwd calls.

Constraint: OMC MCP tools must keep honoring the trusted worktree-root policy used elsewhere
Rejected: Fix only state_write tool paths | would leave read/clear and direct mode-state-io callers inconsistent
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep mode-state-io path resolution aligned with validateWorkingDirectory so nested cwds cannot recreate local .omc state
Tested: npx vitest run src/lib/__tests__/mode-state-io.test.ts
Tested: npx tsc --noEmit
Not-tested: Full repo test suite
2026-04-18 07:53:30 +00:00
Bellman
1b2e60969c Merge pull request #2709 from Yeachan-Heo/issue-2708-omc-teams-multi-repo-cwd
Fix omc-teams multi-repo Codex handoff contract
2026-04-18 03:25:14 +09:00
Codex Review
d7d770e77a Preserve multi-repo workspace context for CLI team handoffs
`/omc-teams` already delegates to `omc team`, whose workers share one cwd. The compatibility skill only showed the current-repo launch form, so plans stored in one repo could spawn Codex workers in that repo while target repos lived in siblings. The skill now makes the workspace-root/absolute-plan-path contract explicit and uses the existing `--cwd` support instead of adding runtime heuristics.\n\nConstraint: `omc team` runtime remains single-working-directory\nRejected: Auto-infer workspace roots in runtime | brittle path heuristics and broad behavior drift\nConfidence: high\nScope-risk: narrow\nDirective: Keep multi-repo `/omc-teams` launches anchored to a shared workspace root unless the runtime grows explicit multi-workspace support\nTested: npm run test:run -- src/__tests__/skills.test.ts\nTested: npm run build:cli\nNot-tested: live tmux Codex launch across sibling repositories
2026-04-17 18:17:14 +00:00
Bellman
c74eddf348 Merge pull request #2696 from myro-june/docs/readme-discord-link
docs: add Discord link to navigation in all README translations
2026-04-18 01:11:26 +09:00
Bellman
bedf33ee76 Merge pull request #2706 from shaun0927/fix/issue-2705-cache-root-canonicalization
fix(installer): reject cache-repair roots that escape plugins/cache
2026-04-18 00:46:34 +09:00
Bellman
dc48557033 Merge pull request #2701 from Yeachan-Heo/refactor/stateful-skills-state-init
refactor(skill-state): harden stateful-skills keyword detection and state init
2026-04-18 00:38:00 +09:00
Yeachan-Heo
8cac6bde4d Keep PR #2701 focused on workflow-slot state changes
The original branch update bundled unrelated generated dist churn alongside the
intended workflow-slot/state-init source changes. This follow-up commit reverts
only the generated artifacts that do not correspond to the touched source areas,
so the PR diff stays aligned with the bridge, keyword-detector, persistent-mode,
mode-registry, skill-state, mode-names, and state-tools changes.

Constraint: GitHub PR #2701 must update via the real head branch instead of a local-only approval path
Constraint: Keep the follow-up diff limited to generated artifacts that shrink the existing PR scope
Rejected: Force-push a rewritten replacement commit | unnecessary history rewrite for a narrow cleanup-only fix
Rejected: Keep all dist outputs from 56718e05 | preserves unrelated churn that blocks review
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Regenerate and commit dist only for source areas that remain in the final PR diff
Tested: Branch diff review vs dev after cleanup; targeted verification pending on final commit SHA
Not-tested: Full project-wide build/lint suite for this cleanup-only dist follow-up
2026-04-17 15:33:50 +00:00
JunghwanNA
9afd81aec3 Prevent cache repair from writing outside the plugin cache root
The cache-repair path trusted raw installPath strings from installed_plugins.json, so an OMC entry containing ../ segments could still pass the existing prefix check and receive a full payload sync outside plugins/cache. This narrows the fix to canonical containment in the repair predicate and adds an issue-scoped regression test for the escape path.

Constraint: Keep the repair flow behavior unchanged for valid cache-installed OMC roots
Rejected: Broaden path hardening across unrelated installer flows in the same patch | would enlarge review scope beyond the verified repair bug
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Any future cache-root checks should compare canonical paths, not normalized raw strings
Tested: npm run build; ./node_modules/.bin/vitest run src/installer/__tests__/plugin-cache-sync.test.ts src/__tests__/auto-update.test.ts src/__tests__/installer-omc-reference.test.ts; ./node_modules/.bin/tsc --noEmit --pretty false; ./node_modules/.bin/eslint src/installer/index.ts src/installer/__tests__/plugin-cache-sync.test.ts; direct local reproduction of syncInstalledPluginPayload escape path before and after fix
Not-tested: Full repository vitest suite; src/__tests__/installer-plugin-agents.test.ts timed out in this environment during unrelated runs
2026-04-18 00:33:02 +09:00
Bellman
ada552f8ba Merge pull request #2694 from Yeachan-Heo/issue-2692-company-context-mcp-interface
Narrow company-context MCP interface to prompt-level contract
2026-04-17 23:40:34 +09:00
Codex Review
f6b3ff2bda Close the remaining PR #2694 documentation acceptance blockers
The original company-context interface change landed with the right code and
skill-surface updates, but review correctly held the PR until the missing
acceptance-doc pieces were explicit. This follow-up adds the settings-schema
page entry for companyContext and records the issue's requested ~5% prompt-
directive miss-rate / residual-risk language without widening runtime scope.

Constraint: Keep the follow-up documentation-only and avoid runtime behavior changes
Constraint: Satisfy issue #2692 acceptance criteria exactly enough for merge review
Rejected: Expand the fix into broader doc cross-linking or runtime wording cleanup | unnecessary scope growth for a blocked PR follow-up
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep future company-context changes aligned with the current .claude/omc.jsonc / ~/.config/claude-omc/config.jsonc config surface unless the runtime contract changes first
Tested: npx vitest run src/config/__tests__/loader.test.ts -t "company context configuration"
Tested: git diff --check -- docs/company-context-interface.md docs/settings-schema.md
Tested: local link existence check for docs/settings-schema.md -> ./company-context-interface.md
Tested: lsp_diagnostics on both changed docs files reported 0 errors
Tested: architect verification APPROVED
Not-tested: Full repo build/test suite (intentionally skipped for docs-only narrow follow-up)
2026-04-17 14:24:21 +00:00
Bellman
61e75987d5 Merge pull request #2698 from Yeachan-Heo/issue-2693-schedulewakeup-cancel-reentry
Fix ScheduleWakeup persistent-mode self-cancel on stop
2026-04-17 22:47:20 +09:00
Bellman
9a1d484f1f Merge pull request #2699 from Yeachan-Heo/issue-2695-hud-rate-limits-stdin
Prefer stdin rate limits over cold-start HUD API fetches
2026-04-17 22:25:47 +09:00
Bellman
29eafb8952 Merge pull request #2703 from Yeachan-Heo/issue-2697-dashboard-read-spikes
Prevent HUD read spikes from inflating fallback context
2026-04-17 21:44:19 +09:00
Codex Review
987443092a Prevent HUD read spikes from inflating fallback context
The HUD manual fallback treated cache-read telemetry as live context usage, which could drive large false spikes when native used_percentage was unavailable. This change keeps the fix local to stdin fallback math and adds focused regressions for fallback, native-percentage precedence, and stabilization behavior.

Constraint: Preserve transcript token rendering and MiniMax usage-api semantics\nRejected: Provider-specific MiniMax branching | The proven bug path is HUD-local fallback math, not provider quota parsing\nConfidence: high\nScope-risk: narrow\nReversibility: clean\nDirective: If another provider proves cache_read_input_tokens should count in fallback, capture failing evidence before reintroducing provider-specific logic\nTested: vitest run src/__tests__/hud/stdin.test.ts\nTested: vitest run src/__tests__/hud/token-usage.test.ts\nTested: vitest run src/__tests__/hud/usage-api.test.ts -t minimax\nTested: eslint src/hud/stdin.ts src/__tests__/hud/stdin.test.ts\nTested: npm run build\nNot-tested: Full repo test suite outside the targeted HUD and MiniMax coverage
2026-04-17 12:02:39 +00:00
Codex Review
56718e0502 refactor(skill-state): harden stateful-skills keyword detection and state init
Replace per-skill ad-hoc detectors with a unified workflow slot ledger that
tracks all 8 canonical workflow skills (autopilot, ralph, team, ultrawork,
ultraqa, deep-interview, ralplan, self-improve) with explicit dual-copy
writes (root + session), soft-tombstone semantics, and TTL pruning.

Key changes:
- Expand canonical mode registry: deep-interview and self-improve promoted
  to full ExecutionMode with MODE_CONFIGS entries (mode-names.ts,
  mode-registry/{types,index}.ts, state-tools.ts)
- New skill-active-state v2 mixed schema with active_skills + support_skill
  branches; 7 new helpers in skill-state/index.ts including
  writeSkillActiveStateCopies() as the single persistence path
- Unified parseExplicitWorkflowSlashInvocation() handles /name, /omc:name,
  /oh-my-claudecode:name prefixes across all workflow skills; PreToolUse
  confirms, PostToolUse tombstones
- Tombstone-aware completion gating in persistent-mode with authority-first
  ordering for nested autopilot -> ralph; env kill-switches (DISABLE_OMC,
  OMC_SKIP_HOOKS, OMC_TEAM_WORKER) bypass the detector cleanly
- +107 tests across 7 files covering dual-write invariant, TTL prune,
  diverged-copy reconciliation, nested lineage, prefix-detector unity,
  intent-pattern guards, kill switches, tombstone suppression

Verified via independent codex ralplan consensus (APPROVE verdict) and
lane-isolated verifier pass. Full suite: lint clean, tsc clean, targeted
tests green (181 passed on skill-state + bridge-routing).

Constraint: writeSkillActiveStateCopies() must be the only helper that
  persists workflow-slot state; divergence between root and session copies
  forces full rewrite on next mutation
Constraint: soft-tombstone semantics (completed_at set, slot retained)
  preserve nested parent/child relationships across session boundaries
Rejected: per-skill independent state files | would reintroduce divergence
Rejected: hard-delete on completion | breaks nested workflow authority
  resolution when autopilot spawns ralph
Confidence: high
Scope-risk: moderate
Directive: every workflow-slot write/confirm/tombstone/prune/clear MUST
  route through writeSkillActiveStateCopies(); direct writes to either
  copy violate the dual-write invariant
Not-tested: cross-session race where two Claude Code sessions mutate the
  same workflow slot concurrently (single-writer assumption holds today)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-17 11:28:52 +00:00
Codex Review
3621ec7edc Prefer stdin rate limits over cold-start HUD API fetches
Claude Code statusline stdin can already carry five-hour and weekly usage data. The HUD ignored that payload and always called getUsage(), which created avoidable 429 loops in cold ephemeral environments.

This change extends the stdin contract, converts those buckets into the existing RateLimits shape, and bypasses getUsage() only when stdin provides usable data. Focused tests cover stdin parsing and the watch-mode fallback path.

Constraint: Keep HUD behavior unchanged when stdin omits rate limits
Rejected: Broaden usage-api exports for shared clamp/parser logic | wider surface than needed for a local stdin contract fix
Rejected: Tune 429 backoff/cache only | does not consume already-available stdin data
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: If Claude Code adds more stdin quota buckets later, extend the stdin parser only when HUD rendering actually needs them
Tested: ./node_modules/.bin/vitest run src/__tests__/hud/stdin.test.ts src/__tests__/hud/watch-mode-init.test.ts
Tested: ./node_modules/.bin/eslint src/hud/index.ts src/hud/stdin.ts src/hud/types.ts src/__tests__/hud/stdin.test.ts src/__tests__/hud/watch-mode-init.test.ts
Tested: ./node_modules/.bin/tsc --noEmit --pretty false --project tsconfig.json
Not-tested: Live Claude Code session with a real stdin rate_limits payload
Related: #2695
2026-04-17 10:01:20 +00:00
Codex Review
c3eeb3f2d2 Restore portable repo links for PR #2694 docs blocker
PR #2694 shipped markdown links that pointed at a machine-local worktree path, which breaks portability outside the author environment. This follow-up keeps scope to the two reported cross-links and replaces them with file-relative repo links that resolve in the repository and on GitHub.

Constraint: Keep scope limited to the review blocker in the two reported docs
Rejected: Broader doc link cleanup | exceeds the blocker scope and broadens the PR
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep cross-doc markdown links repo-relative; never embed machine-local worktree paths in shipped docs
Tested: Focused diff review for the two docs; grep confirmed the absolute worktree path is removed from touched files; relative-link target resolution from each source directory; git diff --check
Not-tested: Full markdown renderer / external docs site rendering
Related: PR #2694
2026-04-17 09:41:45 +00:00
june
0660dc0a26 Merge branch 'Yeachan-Heo:main' into docs/readme-discord-link 2026-04-17 17:47:37 +09:00
june
b8a7261d1c docs: add Discord link to navigation in all README translations
The English README nav line links to the community Discord server,
but the 11 translated READMEs were missing that link. Append
`• [Discord](https://discord.gg/PUwSMR9XNk)` to the top navigation
line of each translation so non-English readers have the same
discovery path as English readers.
2026-04-17 17:36:19 +09:00
Codex Review
c26a334e40 Prevent scheduled wakeup resumes from self-cancelling persistent hooks
ScheduleWakeup-style resume events are not real persistence work, but the Stop hook treated them like ordinary idle stops and could inject continuation text that tells Claude to run /oh-my-claudecode:cancel. That let scheduled /loop turns cancel themselves before the scheduled task executed.

This change adds a narrow scheduled-wakeup bypass alongside the existing non-reinforceable stop guards and mirrors the same detector in the shipped script/template hook surfaces so installed runtime behavior stays aligned with the shared TypeScript path.

Constraint: Installed Stop hook behavior is shipped via script/template surfaces as well as shared TypeScript logic
Rejected: Tighten global persistent-mode freshness rules | broader behavioral change across legitimate long-running sessions
Confidence: medium
Scope-risk: narrow
Directive: Keep scheduled-resume stop marker detection aligned across shared logic and script/template mirrors if Claude Code changes its native wakeup payloads
Tested: ./node_modules/.bin/vitest run src/hooks/todo-continuation/__tests__/isRateLimitStop.test.ts src/hooks/persistent-mode/__tests__/rate-limit-stop.test.ts src/hooks/persistent-mode/stop-hook-blocking.test.ts
Tested: ./node_modules/.bin/eslint src/hooks/todo-continuation/index.ts src/hooks/persistent-mode/index.ts src/hooks/todo-continuation/__tests__/isRateLimitStop.test.ts src/hooks/persistent-mode/__tests__/rate-limit-stop.test.ts src/hooks/persistent-mode/stop-hook-blocking.test.ts
Tested: ./node_modules/.bin/tsc --noEmit --pretty false
Not-tested: Live Claude Code /loop ScheduleWakeup reproduction on macOS
2026-04-17 08:28:51 +00:00
Codex Review
f35b220520 Define a minimal company-context MCP contract for prompt workflows
The issue describes a broader deterministic interface, but the maintainable shape here is narrower: an explicit config/schema surface plus shared prompt wording for a small set of skills. This keeps the feature aligned with OMC's existing MCP model instead of inventing runtime enforcement or a new control plane.

The implementation adds a documented companyContext config block, minimal schema/tests, a small reference server, and skill/docs updates that treat returned vendor data as advisory quoted context only.

Constraint: Must stay prompt-level and avoid runtime hook enforcement
Constraint: Base configuration surface should match existing OMC config files rather than introducing a parallel settings path
Rejected: Blindly implement the issue's deterministic wording | the current architecture cannot guarantee tool invocation from prompt text alone
Rejected: Add runtime interception for every workflow | broader policy surface than justified by the issue
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep company-context semantics limited to one configured tool plus onError unless a separate runtime design is explicitly approved
Tested: node --check examples/vendor-mcp-server/server.mjs
Tested: ./node_modules/.bin/vitest run src/config/__tests__/loader.test.ts
Not-tested: End-to-end MCP invocation from live skill execution
Related: #2692
2026-04-17 06:47:56 +00:00
Bellman
e9856ebc2f Repair incomplete cached OMC plugin installs
Reviewed in OMX. Scope is appropriately narrow: it repairs incomplete cached/install plugin roots before setup trusts plugin-provided payloads, reuses the same sync logic in auto-update, and covers the #2689 HUD symptom as part of the broader #2688 cache-root contract bug. Source precedence (marketplace -> global npm -> runtime root) is sane for maintainer-controlled repair without overclaiming broader release-flow changes.
2026-04-17 11:59:03 +09:00