Add OMP sessions to AI Vault#7255
Conversation
📝 WalkthroughWalkthroughThis PR adds "omp" support to AI Vault session handling across shared types, session directory normalization, discovery, parsing, and scanner tests. It also updates resume-command generation so omp resumes use 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (2)
src/shared/ai-vault-resume-command.test.ts (1)
43-57: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueConsider covering the omp fallback path.
Only the "resumeFilePath provided" case is tested for
omp. A test forresumeFilePathomitted/empty (falling back tosessionId) would close the coverage gap for theresumeTargetbranch inbuildAiVaultResumeCommand.src/main/ai-vault/session-scanner-accumulator.ts (1)
73-80: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueConsider a short comment on why
resumeFilePathis threaded through.The reasoning (OMP's CLI resumes via an explicit
.jsonlpath rather than Orca's internal session ID) isn't evident from this function alone.As per coding guidelines, "When writing or modifying code driven by a design doc or non-obvious constraint, add a comment explaining why the code behaves the way it does."📝 Proposed comment
resumeCommand: buildAiVaultResumeCommand({ agent: accumulator.agent, sessionId, + // Why: omp's CLI resumes via an explicit .jsonl path, not Orca's + // internal session id; other agents ignore this field. resumeFilePath: accumulator.filePath, cwd: accumulator.cwd, platform, codexHome: options.codexHome })Source: Coding guidelines
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 9503ac87-7a17-4220-bd58-312157e6df6f
📒 Files selected for processing (17)
src/main/ai-vault/session-scanner-accumulator.tssrc/main/ai-vault/session-scanner-agent-parser.tssrc/main/ai-vault/session-scanner-codex-workers.test.tssrc/main/ai-vault/session-scanner-graph-parsers.tssrc/main/ai-vault/session-scanner-opencode-sqlite-coexistence.test.tssrc/main/ai-vault/session-scanner-source-discovery.tssrc/main/ai-vault/session-scanner-types.tssrc/main/ai-vault/session-scanner.test.tssrc/renderer/src/components/right-sidebar/AiVaultSessionRow.tsxsrc/renderer/src/components/right-sidebar/AiVaultSessionVirtualList.tsxsrc/renderer/src/i18n/locales/en.jsonsrc/renderer/src/i18n/locales/es.jsonsrc/renderer/src/i18n/locales/ja.jsonsrc/renderer/src/i18n/locales/ko.jsonsrc/renderer/src/i18n/locales/zh.jsonsrc/shared/ai-vault-resume-command.test.tssrc/shared/ai-vault-types.ts
|
Fixed CodeRabbit's OMP root normalization note in 3f72448. OMP now uses the shared agent-session root normalizer with '.omp', so OMP_CODING_AGENT_DIR=/path/to/.omp expands to /path/to/.omp/agent/sessions. Added regression coverage in session-scanner-values.test.ts and reran lint, typecheck, and targeted scanner tests. |
|
@coderabbitai review |
✅ Action performedReview finished.
|
Summary
OMPto the AI Vault/Agents session catalog so historical.omp/agent/sessions/**/*.jsonltranscripts can be discovered from the right-sidebar session browser.omp --resume <absolute-jsonl-path>because OMP's CLI rejects Orca's internal JSON session ids for these records.Screenshot
Verification
Run with Node 24.18.0 via
fnm execand a sanitized test environment that clears live Orca hook vars fromWSLENV/SSH_ASKPASS:pnpm lintpnpm typecheckpnpm testpnpm buildTargeted checks also passed:
pnpm exec vitest run --config config/vitest.config.ts src/main/ai-vault/session-scanner.test.ts src/main/ai-vault/session-scanner-codex-workers.test.ts src/main/ai-vault/session-scanner-opencode-sqlite-coexistence.test.ts src/shared/ai-vault-resume-command.test.tspnpm exec vitest run --config config/vitest.config.ts src/renderer/src/components/right-sidebar/ai-vault-session-display.test.ts src/renderer/src/components/right-sidebar/ai-vault-session-projects.test.ts src/renderer/src/components/right-sidebar/ai-vault-session-worktree.test.tsAI-agent review summary