.omo/evidence/codegraph-tmpdir-defaults-gate-review.md
recommendation: APPROVE
blockers:
originalIntent: CodeGraph should exclude OS temp roots by default on every supported platform, allow tmpdir injection for deterministic tests, preserve the existing exclude-only configuration shape without adding an include override, update docs and bundled dist artifacts, and provide complete QA/review evidence.
desiredOutcome:
Users running LazyCodex/OMO from temp or OMO state locations should not get CodeGraph bootstrap workers or a live CodeGraph MCP for those roots. Normal project roots should still bootstrap. Documentation should explain defaults, codegraph.excluded_roots, managed CodeGraph environment flags, and dead-store pruning. Evidence should prove the behavior through unit, component, live hook, Codex QA, typecheck, and hygiene gates.
userOutcomeReview:
The shipped diff satisfies the requested outcome. packages/utils/src/codegraph/exclusion.ts adds a typed tmpdir injection option and includes os.tmpdir() in the default excluded roots, while preserving POSIX /tmp and /private/tmp, .omo state exclusion, custom excludedRoots, and normal-project inclusion. The hook and serve call sites continue to use the shared exclusion seam and add no config/include override. packages/omo-codex/README.md documents the default exclusions, exclude-only custom roots, no include override, managed CodeGraph env flags, and dead-store GC. The generated dist/cli.js and dist/serve.js contain the same exclusion logic and keep their original file modes.
checked artifact paths:
verification performed:
remove-ai-slops and programming criteria, including the TypeScript reference and code-smell rules.git diff --check origin/dev..HEAD: exit 0.git diff origin/dev..HEAD, git diff --name-status, git diff --stat, git diff --summary, source/docs/dist diffs, committed evidence, and review artifacts./Users/yeongyu/.bun/bin/bun test packages/utils/src/codegraph-exclusion.test.ts: 3 pass, 0 fail.bun test test in packages/omo-codex/plugin/components/codegraph: 53 pass, 0 fail.PATH="/Users/yeongyu/.bun/bin:$PATH" /Users/yeongyu/.bun/bin/bun run typecheck: exit 0.exclusion.ts 75, codegraph-exclusion.test.ts 97, codegraph-workspace.test.ts 177.green-codegraph-hook-serve-tests.txt artifact is absent, failed diagnostic artifacts are explicitly documented as superseded by clean reruns, and .omo/evidence/codegraph-tmpdir-defaults-code-review.md now records post-fix programming plus remove-ai-slops/overfit coverage.remove-ai-slops and programming review:
No unresolved slop or programming blocker found. The production change is at the existing shared exclusion seam, adds no speculative abstraction, no broad catch, no new config parser/normalizer, no include override, no any, no assertions, no non-null assertion, and no oversized touched source/test file. The tests are not deletion-only, tautological, or implementation-mirroring: they assert observable exclusion decisions for Linux/POSIX defaults, Darwin injected temp root, Windows injected temp root, custom excluded roots, .omo state paths, sibling non-exclusion, and normal project inclusion. The test split removes unrelated workspace-helper coupling while preserving and extending behavior coverage.
exact evidence gaps: