feat: PROVING GROUND — dogfood validation milestone#192
Conversation
New imperative view that identifies crate/module/pkg nodes lacking implements edges to spec/adr targets. Returns meta.linked, meta.unlinked, and meta.coveragePct for PROVING GROUND Q3.
56 nodes (5 milestones, 5 specs, 5 ADRs, 5 docs, 15 crates, 11 tasks, 10 issues) and 70 edges with deterministic ground truth for 5 dogfood questions in PROVING GROUND.
Imports Echo seed YAML (55 nodes, 70 edges) and validates ground truth for milestone blockers, ADR gaps, crate coverage, onboarding order, and low-confidence edge detection. All 5 queries complete in <1s.
CLI-style walkthrough of all 5 dogfood questions with answers, timing, and commentary. All queries complete in <1ms on a 55-node graph.
Coverage view, Echo seed fixture, integration tests for 5 dogfood questions, and session transcript. 162 tests across 9 files.
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📝 WalkthroughWalkthroughAdds PROVING GROUND dogfood artifacts: a new built-in Changes
Sequence Diagram(s)mermaid Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches🧪 Generate unit tests (beta)
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: 4
🤖 Fix all issues with AI agents
In `@test/fixtures/echo-seed.yaml`:
- Around line 1-228: YAML linter flags are due to flow mappings with spaces
inside braces used across node property blocks like the milestone nodes
("milestone:M1", "milestone:M2", ...), ADRs ("adr:003-encryption-at-rest"), docs
("doc:getting-started"), crates ("crate:echo-core"), tasks ("task:E-005"), and
issues ("issue:E-001"); fix by converting those flow mappings to block-style
mappings (e.g., replace { title: "...", status: "..." } with newline indented
key: value pairs) or, if you prefer to keep flow style, update the yamllint
configuration to relax the braces rule so these mappings no longer produce "too
many spaces inside braces" warnings.
In `@test/proving-ground.test.js`:
- Around line 173-186: The timing test in the describe('timing') / it('all 5
queries complete in under 60s total') block uses an overly large 60_000ms
threshold; tighten this to a realistic CI-safe bound (e.g. 2_000ms) to increase
regression signal. Locate the test that calls renderView(graph, ...) five times
and replace the expect(elapsed).toBeLessThan(60_000) assertion with a stricter
assertion like expect(elapsed).toBeLessThan(2_000), keeping the same
performance.now measurement and variable names.
- Around line 162-168: The test "low-confidence edges have expected confidence
values" collects confidences via renderView and then calls .sort() which uses
lexicographic ordering; change the sort to use a numeric comparator (e.g., in
the confidences assignment that maps e => e.props?.confidence, call .sort((a, b)
=> a - b) or otherwise convert to numbers before sorting) so the array is
ordered numerically; update the confidences variable in this test to use the
numeric comparator to avoid future lexicographic ordering bugs.
- Around line 39-57: The test file creates an implicit ordering dependency by
running importFile(graph, SEED_PATH) inside a test case so subsequent describes
rely on that side-effect; move the actual import into a beforeAll hook so the
seed is loaded once before any tests run, then keep the existing "seed import"
describe for assertions only by replacing the import call there with checks that
rely on the already-imported state (references: importFile, SEED_PATH, graph,
and the "seed import" describe block).
- Convert YAML node properties to block-style (yamllint) - Move seed import into beforeAll (ordering dependency) - Use numeric comparator for confidence sort - Replace wall-clock timing test with O(N+E) complexity verification
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@test/proving-ground.test.js`:
- Around line 255-281: Wrap each per-size iteration so the temp dir returned by
generateGraph is always removed even if renderView throws: after calling
generateGraph(...) and before renderView calls in the loop, ensure you use
try/finally (or collect dirs and clean in afterAll) and call rm(dir, {
recursive: true, force: true }) in the finally block to avoid leaking
directories; additionally, when computing growthFactor from the timings array,
guard the denominator to avoid tiny/zero division by using something like
Math.max(timings[i - 1], 1) when calculating growthFactor = timings[i] /
Math.max(timings[i - 1], 1) so spurious huge ratios cannot occur.
- Wrap view rendering in try/finally for temp dir cleanup - Guard growth factor denominator with Math.max(..., 1)
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@test/proving-ground.test.js`:
- Around line 176-177: The comment above the synthetic graph generator is
inaccurate: it says "~2N edges" but the edge-creation loops actually produce
about 0.7N edges (expression N/5 + N/5 + (N/5−1) + (N/10−1) + 4). Update that
comment near the graph generator (referencing nodeCount and the edge-creation
loops in this test) to state the correct approximate edge count (≈0.7N or give
the explicit expression) so the docstring matches the implemented logic.
Summary
coverageview — code-to-spec gap analysis identifyingcrate:/module:/pkg:nodes lackingimplementsedges to specs/ADRsAll 5 questions answered correctly from graph views alone. 162 tests passing across 9 files.
Closes #191
Test plan
npx vitest run— 162 tests pass (143 existing + 4 coverage view + 15 proving ground)issue:E-003,issue:E-004as M2 blockersadr:003-encryption-at-rest,adr:004-rest-vs-grpcas gapsdoc:getting-startedbeforedoc:architecture-overviewSummary by CodeRabbit
New Features
Documentation
Tests