Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "packages/senpi"]
path = packages/senpi
url = https://github.com/code-yeongyu/senpi
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Command: bun run build:native
Started: 2026-06-20T10:43:16Z
$ bun run --cwd packages/omo-native build
$ node build.mjs
Completed: 2026-06-20T10:43:16Z
Exit: 0
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
omo-native CI install fix verification v2
UTC 2026-06-20T10:32:05Z

## stale link scan
no install-time senpi package links remain

## frozen install
bun install v1.3.14 (0d9b296a)

+ @types/js-yaml@4.0.9
+ @types/picomatch@4.0.3
+ @typescript/native-preview@7.0.0-dev.20260518.1
+ bun-types@1.3.14
+ typescript@6.0.3
+ @clack/prompts@1.5.0
+ @code-yeongyu/comment-checker@0.8.0
+ @modelcontextprotocol/sdk@1.29.0
+ @opencode-ai/plugin@1.15.13
+ @opencode-ai/sdk@1.15.13
+ @opentui/core@0.2.16
+ @opentui/keymap@0.2.16
+ @opentui/solid@0.2.16
+ commander@14.0.3
+ detect-libc@2.1.2
+ diff@9.0.0
+ js-yaml@4.2.0
+ jsonc-parser@3.3.1
+ picocolors@1.1.1
+ picomatch@4.0.4
+ posthog-node@5.35.12
+ vscode-jsonrpc@8.2.1
+ zod@4.4.3

576 packages installed [319.00ms]

## root direct build

## build:native
$ bun run --cwd packages/omo-native build
$ node build.mjs

## dynamic import
function

## typecheck
$ tsgo --noEmit -p tsconfig.json

## intentional seam audit red
$ vitest run

RUN v4.1.8 /Users/yeongyu/local-workspaces/omo-wt/code-yeongyu/omo-native-wave0/packages/omo-native

❯ src/__tests__/seam-boundary-audit.test.ts (2 tests | 1 failed) 4ms
× requires the senpi seam to own at least one real senpi type-layer import 2ms

⎯⎯⎯⎯⎯⎯⎯ Failed Tests 1 ⎯⎯⎯⎯⎯⎯⎯

FAIL src/__tests__/seam-boundary-audit.test.ts > omo-native seam boundary audit > requires the senpi seam to own at least one real senpi type-layer import
AssertionError: Expected src/senpi/** to contain at least one `import type` or `export type` from the real senpi/pi type layer. This Wave 0 RED proves the seam is still a stub.: expected 0 to be greater than 0
❯ src/__tests__/seam-boundary-audit.test.ts:142:7
140| typeLayerImports.length,
141| "Expected src/senpi/** to contain at least one `import type` or …
142| ).toBeGreaterThan(0)
| ^
143| })
144| })

⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯


Test Files 1 failed (1)
Tests 1 failed | 1 passed (2)
Start at 19:32:07
Duration 111ms (transform 11ms, setup 0ms, import 15ms, tests 4ms, environment 0ms)

error: script "test" exited with code 1
seam audit exit: 1 (expected non-zero until Wave 1 real senpi type import)

## cleanup/status
dist cleaned
M bun.lock
M package.json
M packages/omo-native/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
CI-like no-submodule install repro from pushed fix
UTC 2026-06-20T10:32:35Z
e59250899
-4ce93bcfbc7c681a709f2579f664b1bbf92fbc1b packages/senpi
no install-time senpi package links remain
bun install v1.3.14 (0d9b296a)

+ @types/js-yaml@4.0.9
+ @types/picomatch@4.0.3
+ @typescript/native-preview@7.0.0-dev.20260518.1
+ bun-types@1.3.14
+ typescript@6.0.3
+ @clack/prompts@1.5.0
+ @code-yeongyu/comment-checker@0.8.0
+ @modelcontextprotocol/sdk@1.29.0
+ @opencode-ai/plugin@1.15.13
+ @opencode-ai/sdk@1.15.13
+ @opentui/core@0.2.16
+ @opentui/keymap@0.2.16
+ @opentui/solid@0.2.16
+ commander@14.0.3
+ detect-libc@2.1.2
+ diff@9.0.0
+ js-yaml@4.2.0
+ jsonc-parser@3.3.1
+ picocolors@1.1.1
+ picomatch@4.0.4
+ posthog-node@5.35.12
+ vscode-jsonrpc@8.2.1
+ zod@4.4.3

576 packages installed [354.00ms]
$ tsgo --noEmit -p tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
omo-native Wave 0 final convention-fix verification
UTC 2026-06-20T10:26:06Z

## package convention
packages/omo-native/package.json:21: "bun-types": "1.3.14",
packages/omo-native/tsconfig.json:19: "types": [
packages/omo-native/tsconfig.json:20: "bun-types"

## no package-local @types/node declaration
no package-local @types/node declaration

## frozen install
bun install v1.3.14 (0d9b296a)

4 packages installed [92.00ms]

## root direct build

## root build:native
$ bun run --cwd packages/omo-native build
$ node build.mjs

## dynamic import
function

## typecheck
$ tsgo --noEmit -p tsconfig.json

## intentional seam audit red
$ vitest run

RUN v4.1.8 /Users/yeongyu/local-workspaces/omo-wt/code-yeongyu/omo-native-wave0/packages/omo-native

❯ src/__tests__/seam-boundary-audit.test.ts (2 tests | 1 failed) 4ms
× requires the senpi seam to own at least one real senpi type-layer import 1ms

⎯⎯⎯⎯⎯⎯⎯ Failed Tests 1 ⎯⎯⎯⎯⎯⎯⎯

FAIL src/__tests__/seam-boundary-audit.test.ts > omo-native seam boundary audit > requires the senpi seam to own at least one real senpi type-layer import
AssertionError: Expected src/senpi/** to contain at least one `import type` or `export type` from the real senpi/pi type layer. This Wave 0 RED proves the seam is still a stub.: expected 0 to be greater than 0
❯ src/__tests__/seam-boundary-audit.test.ts:142:7
140| typeLayerImports.length,
141| "Expected src/senpi/** to contain at least one `import type` or …
142| ).toBeGreaterThan(0)
| ^
143| })
144| })

⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯


Test Files 1 failed (1)
Tests 1 failed | 1 passed (2)
Start at 19:26:07
Duration 102ms (transform 11ms, setup 0ms, import 15ms, tests 4ms, environment 0ms)

error: script "test" exited with code 1
seam audit exit: 1 (expected non-zero until Wave 1 real senpi type import)

## cleanup/status
dist cleaned
tmux cleanup confirmed: no ulw-qa-omo-native-wave0-terminal
A .gitmodules
M bun.lock
M bunfig.toml
M package.json
A packages/senpi
?? packages/omo-native/
102 changes: 102 additions & 0 deletions .omo/evidence/20260620-omo-native-wave-0/final-gate-review.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
# omo-native Wave 0 Final Gate Review

reviewedAt: 2026-06-20T10:25:00Z
worktree: `/Users/yeongyu/local-workspaces/omo-wt/code-yeongyu/omo-native-wave0`
scope: Wave 0 todos 1-3 only
recommendation: APPROVE
AdversarialVerify verdict: confirmed

## originalIntent

Implement and verify only Wave 0 todos 1-3 from `.omo/plans/omo-native.md`: add the Senpi submodule and `packages/omo-native` workspace wiring, add the native package build/typecheck/test scaffold plus pi manifest, and add a RED seam-boundary audit that proves the future Senpi seam is still a stub while preventing raw Senpi/pi imports outside `src/senpi/**`.

## desiredOutcome

The user should be able to treat Wave 0 as a confirmed foundation: frozen install works with the updated lockfile, root and package build commands work, the built extension default-imports as a function, package typecheck works, the seam audit fails only for the intentional positive seam import assertion, terminal screenshot/cleanup evidence exists, and no later-wave implementation has slipped into the diff.

## blockers

None.

## userOutcomeReview

Confirmed. The current worktree satisfies the user-listed verification checks after the lockfile, root-build, and screenshot fixes.

The old `code-review.md`, `qa-matrix.md`, and `remove-ai-slops-review.md` record earlier blockers. They are superseded where later named PASS artifacts and my direct reruns prove the fixes: `final-local-verification.txt`, `qa-matrix-final.md`, `bun-install-fixed.txt`, `review-blocker-fix-stop-hook-verify-3.txt`, and `terminal-tui-screenshot-receipt.txt`.

The changed file set remains scoped to the expected Wave 0 files: `.gitmodules`, `bun.lock`, `bunfig.toml`, `package.json`, `packages/senpi` gitlink, and new `packages/omo-native/**`. I found no team mode, MCP bridge, hashline, background subagent, OpenClaw, boulder, prompt, ultrawork, config bridge, or real Senpi runtime implementation in `packages/omo-native`.

## directVerification

- `bun install --frozen-lockfile --ignore-scripts`: PASS, exit 0, `4 packages installed`.
- `node packages/omo-native/build.mjs`: PASS, exit 0.
- `bun run build:native`: PASS, runs `bun run --cwd packages/omo-native build` then `node build.mjs`.
- `node -e "import('./packages/omo-native/dist/index.js').then((m) => console.log(typeof m.default))"`: PASS, prints `function`.
- `bun run --cwd packages/omo-native typecheck`: PASS, `tsgo --noEmit -p tsconfig.json`.
- `bun run --cwd packages/omo-native test`: INTENTIONAL RED, exit 1 with exactly 1 failed / 1 passed. Failed test is `requires the senpi seam to own at least one real senpi type-layer import`; assertion is `expected 0 to be greater than 0`.
- Core-only `Bun.` audit across the 18 Core packages: PASS, no production hits.
- Lockfile grep: PASS, `bun.lock` contains `packages/omo-native`, `@oh-my-opencode/omo-native`, local `@earendil-works/pi-agent-core`, local `@earendil-works/pi-ai`, and local `file:packages/senpi/packages/ai` / `file:packages/senpi/packages/agent` entries.
- Screenshot artifact check: PASS, `terminal-tui.png` is PNG image data, 1600 x 1118, non-empty; transcript and cleanup receipts exist.
- TypeScript no-excuse check: PASS, `No violations in 5 file(s).`
- `git diff --check` and `git diff --cached --check`: PASS.

## slopAndProgrammingReview

Loaded and applied `remove-ai-slops` and `programming`, including the TypeScript reference. Codegraph was attempted first for source review, but the worktree has no `.codegraph/` index, so direct file inspection was used.

Direct slop pass: PASS. The seam test is not deletion-only, not tautological, and not merely checking that a requested removal happened. It enforces an architectural boundary plus an intentional future-positive condition. I did not find needless production extraction, speculative parser/normalizer code, hollow wrappers beyond the explicit Wave 0 stub, or maintenance-burden scope creep.

Direct programming pass: PASS. New TypeScript files avoid `any`, `as any`, `as unknown`, `@ts-ignore`, `@ts-expect-error`, non-null assertions, empty catches, and broad catch swallowing. Pure LOC is below the 250 ceiling; largest reviewed file is the seam audit test at 112 pure LOC. `tsconfig.json` includes strict flags beyond `strict`.

Report coverage check: PASS with caveat. `code-review.md` and `remove-ai-slops-review.md` explicitly include the required skill-perspective and overfit/slop coverage, but their verdicts are stale because they predate the lockfile/root-build/screenshot fixes. Current PASS artifacts plus direct reruns supersede those specific blockers.

## checkedArtifactPaths

- `.omo/plans/omo-native.md`
- `.omo/ulw-loop/omo-native-wave0/brief.md`
- `.omo/ulw-loop/omo-native-wave0/goals.json`
- `.gitmodules`
- `bun.lock`
- `bunfig.toml`
- `package.json`
- `packages/senpi`
- `packages/omo-native/package.json`
- `packages/omo-native/build.mjs`
- `packages/omo-native/tsconfig.json`
- `packages/omo-native/vitest.config.ts`
- `packages/omo-native/src/index.ts`
- `packages/omo-native/src/create-extension.ts`
- `packages/omo-native/src/senpi/types.ts`
- `packages/omo-native/src/__tests__/seam-boundary-audit.test.ts`
- `.omo/evidence/20260620-omo-native-wave-0/final-local-verification.txt`
- `.omo/evidence/20260620-omo-native-wave-0/qa-matrix-final.md`
- `.omo/evidence/20260620-omo-native-wave-0/bun-install-fixed.txt`
- `.omo/evidence/20260620-omo-native-wave-0/review-blocker-fix.txt`
- `.omo/evidence/20260620-omo-native-wave-0/review-blocker-fix-stop-hook-verify-3.txt`
- `.omo/evidence/20260620-omo-native-wave-0/build-pipeline.txt`
- `.omo/evidence/20260620-omo-native-wave-0/seam-audit-red.txt`
- `.omo/evidence/20260620-omo-native-wave-0/seam-audit-red-repeat.txt`
- `.omo/evidence/20260620-omo-native-wave-0/seam-audit-static.txt`
- `.omo/evidence/20260620-omo-native-wave-0/workspace-wiring.txt`
- `.omo/evidence/20260620-omo-native-wave-0/todo1-gate-fix.txt`
- `.omo/evidence/20260620-omo-native-wave-0/terminal-tui-screenshot-receipt.txt`
- `.omo/evidence/20260620-omo-native-wave-0/terminal-tui-transcript.txt`
- `.omo/evidence/20260620-omo-native-wave-0/terminal-tui.png`
- `.omo/evidence/20260620-omo-native-wave-0/cleanup-receipt.txt`
- `.omo/evidence/20260620-omo-native-wave-0/cleanup-receipt-build-skeleton.txt`
- `.omo/evidence/20260620-omo-native-wave-0/code-review.md`
- `.omo/evidence/20260620-omo-native-wave-0/qa-matrix.md`
- `.omo/evidence/20260620-omo-native-wave-0/remove-ai-slops-review.md`

## exactEvidenceGaps

No blocking evidence gaps against the user-listed final gate checks.

Notepad path: no Wave 0-specific notepad file was found under `.omo/notepads/` or `.omo/evidence/20260620-omo-native-wave-0/`. Intent and success criteria were instead reconstructed from `.omo/ulw-loop/omo-native-wave0/brief.md`, `.omo/ulw-loop/omo-native-wave0/goals.json`, and `.omo/plans/omo-native.md`.

## residualRisks

- `packages/omo-native/src/senpi/types.ts` is intentionally still a local stub. Wave 1 must replace it with real Senpi/pi type-layer imports and turn the positive seam audit green.
- No real Senpi runtime load QA is expected or proven in Wave 0; this is scheduled for Wave 1.
- `packages/omo-native/build.mjs` includes a few future-facing externals (`@code-yeongyu/senpi`, `@earendil-works/pi-ai`, `typebox`) that are not exercised by the current stub. They do not implement later-wave behavior, but should be revisited when the real seam lands.
- The worktree is intentionally dirty/uncommitted for the Wave 0 draft state; generated `packages/omo-native/dist/index.js` is ignored by root `.gitignore`.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Command: bun run --cwd packages/omo-native typecheck
Started: 2026-06-20T10:43:16Z
$ tsgo --noEmit -p tsconfig.json
Completed: 2026-06-20T10:43:16Z
Exit: 0
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Command: bun test script/package-registration-audit.test.ts
Started: 2026-06-20T10:43:16Z
bun test v1.3.14 (0d9b296a)

script/package-registration-audit.test.ts:
(pass) package registration audit > #given managed packages #when root registration is audited #then workspaces typecheck and dev deps stay aligned [1.75ms]
(pass) package registration audit > #given shared extraction guard #when audited #then every core package is covered [0.30ms]
(pass) package registration audit > #given package test scripts #when nested tests exist #then recursive globs are registered [4.39ms]
(pass) package registration audit > #given package dependencies #when ROADMAP layers are checked #then reverse edges stay at zero [1.23ms]
(pass) package registration audit > #given exact re-export shim scan #when inventory docs are checked #then total targets and every path are present [90.64ms]

5 pass
0 fail
10 expect() calls
Ran 5 tests across 1 file. [158.00ms]
Completed: 2026-06-20T10:43:16Z
Exit: 0
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Package Registration CI Fix Evidence

Date: 2026-06-20
Branch: code-yeongyu/omo-native-wave0
PR: #5454

## Root Cause

GitHub Actions `test` failed on ubuntu, macOS, and Windows because `packages/omo-native` was added to the root workspace and `typecheck:packages` script, but `script/package-registration-audit.test.ts` still did not classify it as a managed package.

The CI failure was reproduced locally by `bun test` before the fix:

- `1 tests failed`
- failing test: `package registration audit > #given managed packages #when root registration is audited #then workspaces typecheck and dev deps stay aligned`
- diff showed `packages/omo-native` present in actual typecheck paths but absent from expected managed paths

## Fix

Updated the registration audit so `packages/omo-native` is treated as a managed native package. The audit still excludes native packages from the root `workspace:*` devDependency expectation, preserving the Wave 0 constraint that the native package is registered for workspace/typecheck coverage without introducing install-time Senpi coupling.

## Verification

Focused audit:

```text
Command: bun test script/package-registration-audit.test.ts
Result: 5 pass, 0 fail
Exit: 0
Artifact: .omo/evidence/20260620-omo-native-wave-0/package-registration-audit-fix-verification.txt
```

Root suite:

```text
Command: bun test
Result: 10072 pass, 2 skip, 0 fail
Exit: 0
Artifact: .omo/evidence/20260620-omo-native-wave-0/root-bun-test-after-package-registration-fix.txt
```

Native adapter smoke checks:

```text
Command: bun run build:native
Exit: 0
Artifact: .omo/evidence/20260620-omo-native-wave-0/build-native-after-registration-fix.txt

Command: bun run --cwd packages/omo-native typecheck
Exit: 0
Artifact: .omo/evidence/20260620-omo-native-wave-0/native-typecheck-after-registration-fix.txt
```

Manual QA / cleanup:

- Terminal TUI screenshot remains attached in the PR from the earlier Wave 0 manual QA: `.omo/evidence/20260620-omo-native-wave-0/terminal-tui.png`.
- No `ulw-qa-omo-native-wave0-terminal` or `omo-native` tmux QA session remained after cleanup check.
Loading