Wave-32 C08: expand cross-language parity coverage - #267
Conversation
Add a thin OKF structural-invariant harness that compares shared v1.0 core shape across Python/TypeScript/Go matrix fixtures; extend SSOT docs and SelfCheck. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Warning Review limit reached
Next review available in: 59 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (5)
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
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 |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
| } | ||
|
|
||
| # Fingerprint = sorted intersection of present types with the shared required core. | ||
| $corePresent = @($requiredSharedEntityTypes | Where-Object { $typeSet.Contains($_) } | Sort-Object) |
There was a problem hiding this comment.
SUGGESTION: Cross-language fingerprint is redundant with the per-fixture required-type checks.
The fingerprint is the sorted intersection of the 6 required shared types, and Assert-OkfStructuralInvariants already forces every fixture to contain all 6 (lines 147-151). So the uniqueness assertion at lines 265-268 can only fail when a per-fixture check has already thrown. The documented guarantee "Sorted shared-core type set is identical across Python / TypeScript / Go" is therefore effectively vacuous — it cannot catch a real cross-language divergence (e.g. a language dropping a shared core type would be caught per-fixture, not cross-language).
To make this a genuine cross-language invariant, fingerprint the actual entity-type set per language (or at least the present shared-core types joined in fixture order rather than a fixed constant set) and compare those, or narrow the doc claim to state the check only confirms the shared core is present in each. As written, the "cross-language" portion adds no independent assurance.
| if ($null -eq $rel.type -or ($allowedRelationTypes -notcontains [string]$rel.type)) { | ||
| throw "$Language fixture: relation type '$($rel.type)' not in OKF v1.0 set." | ||
| } | ||
| if ($null -eq $rel.provenance -or [string]$rel.provenance.source_id -ne $Stem) { |
There was a problem hiding this comment.
SUGGESTION: Relation provenance is mandatory here, but the SSOT table only says "relation provenance.source_id matches".
This throws if any relation lacks a provenance block (or has provenance without source_id), which is stricter than the doc implies. If relation provenance is genuinely required by OKF v1.0, the docs/ops/cross-language-parity.md "Relations" row should say so explicitly (e.g. "provenance present and source_id matches") so the harness contract and the SSOT agree. Otherwise, relax this to only validate source_id when provenance exists.
Reply with @kilocode-bot fix it to have Kilo Code address this issue.
Code Review SummaryStatus: 2 Issues Found | Recommendation: Address before merge (non-blocking) Overview
Issue Details (click to expand)SUGGESTION
Files Reviewed (5 files)
NotesThe structural-invariant harness is hermetic, well-structured, and matches the fixtures in the corpus (all three matrix fixtures carry okf=1.0, the shared core entity types, resolvable relation endpoints, and aligned provenance). No compilation, clippy, test, or security violations. Both findings are design/strictness observations, not blocking defects. Fix these issues in Kilo Cloud Reviewed by hy3:free · Input: 77.6K · Output: 7.2K · Cached: 180.3K |
Summary
scripts/cross-language-parity-check.ps1that compares shared v1.0 core shape (entity types, relation endpoints, provenance) across Python / TypeScript / Go matrix fixtures.docs/ops/cross-language-parity.md+ EVAL_SCOPE note; keep Harbor N/A; SelfCheck/CI still hermetic and blocking.Test plan
pwsh ./scripts/cross-language-parity-check.ps1 -SelfCheckcargo test --test cross_language_paritycross-language parity SelfCheckjob green on PR