You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Validate aliased event fields before DiskGraph token batching - #517
When two selected fields read the same stored column, DiskGraph counts it once for the token budget. On main, validation accepted the request and the first batch failed. check() and prepare() now name both fields and the column before building the index. Batching by sample count still delivers both fields.
Reused the Parquet-anchor regression from #447. The one-field case passed on main and the two-field case reproduced #500. Both passed with the fix. The three affected package test modules passed all 104 tests.
CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.
Parsing warnings: 1
Validation error: Unrecognized key: "tone_instructions" at "reviews"
If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
No actionable comments were generated in the recent review.
Walkthrough
DiskGraph now reports DG-TOKEN-LENGTH-ALIAS during contract validation when token budgeting or length bucketing uses multiple fields that directly reference the same stored column in one event. Tests cover refusal and preparation behavior, as well as accepted inputs without the alias. The limitations table documents the condition and alternatives.
Severity of issue fixed: Medium
Merge Risk: Minimal · up to 69bfc
DiskGraph now rejects token-budget or length-bucketing inputs where two fields read the same stored column, with a clear error and workaround. Single-field and sample-count batching behavior is preserved. No merge-blocking risk was identified.
Security architecture risk: Minimal · up to 69bfc
The update rejects a configuration that could already fail during batching and reports the problem earlier. Sample-count-only batching still permits both fields, and the change adds no new access or privileges.
Retained concerns
No architecture-level concerns identified.
Security review details
Security Blast Radius
inferred — On the inspected path, a caller who controls the matching declarations can trigger a refusal of that preparation request. The added code creates no route to new data, credentials, or privileged operations.
Pre-merge checks: 2 · 1
Failed checks: 1 inconclusive
Check name
Status
Explanation
Resolution
Change Map Design Review
The check reviews the PR conversation comment that starts with <!-- kumo-pr-change-map -->. That comment is not in the supplied context. The review comments section lists no threads. The checkout co…
Provide the body of the PR conversation comment that starts with <!-- kumo-pr-change-map -->, for example by pasting its text or by making the comment reachable to this check. Then re-run the check. The review should confirm that the map:…
Passed checks: 2 passed
Check name
Status
Explanation
Pr Size
PR size check: the changed-file count is 4, which does not exceed the limit of 40. The reviewed range (refs/coderabbit/pre-merge-check/base..head) shows four modified files: packages/experimental/kumo…
Public Resource Access
The check applies only to external resource references whose text this PR adds or modifies. I listed the changed files with git diff --name-status against the review base. Four files changed: `docs/…
Full details: Pr Size
Explanation
PR size check: the changed-file count is 4, which does not exceed the limit of 40. The reviewed range (refs/coderabbit/pre-merge-check/base..head) shows four modified files: packages/experimental/kumo-pytorch/docs/limitations.md, packages/experimental/kumo-pytorch/src/kumo/pytorch/engines/diskgraph.py, packages/experimental/kumo-pytorch/src/kumo/pytorch/engines/unsupported.py, and packages/experimental/kumo-pytorch/tests/test_diskgraph_unsupported.py. Both git diff --name-status and --name-only agree on the count. Line counts were ignored, as the check requires.
Full details: Public Resource Access
Explanation
The check applies only to external resource references whose text this PR adds or modifies. I listed the changed files with git diff --name-status against the review base. Four files changed: docs/limitations.md, src/kumo/pytorch/engines/diskgraph.py, src/kumo/pytorch/engines/unsupported.py, and tests/test_diskgraph_unsupported.py. I searched every added line in that diff for URLs (http://, https://), git+, github.com, git@, pypi, npm, file://, and Markdown link syntax. No added line matched. The PR adds no package source location, repository location, or URL to the changed files. The links in the PR description and the linked issue #500 are not part of the repository diff, so they fall outside the check's scope. No changed reference requires an anonymous-access test, so the check passes.
Full details: Change Map Design Review
Explanation
The check reviews the PR conversation comment that starts with <!-- kumo-pr-change-map -->. That comment is not in the supplied context. The review comments section lists no threads. The checkout contains only a reference to the marker in docs/development/review.md. The PR description links the map at comment 7117861563, but this environment cannot fetch GitHub comments. Without the map text, I cannot check its necessity claims, observed failure, inspected behavior, verification, or stopping condition. I therefore cannot judge its design. Partial code evidence from the PR range (refs/coderabbit/pre-merge-check/base to head, 4 files, +106/-1): - diskgraph.py adds _token_budget_aliases, called from check_contract. It only checks Field references with no path, in history event inputs that use Fields with Tokens rows. Aliases through a path, derived fields, or other collections are not reported by this helper. Whether those cases matter for token planning is an open design question, not a proven defect. - Field is imported (line 53), so the isinstance(value, Field) check resolves. - unsupported.py adds the DG-TOKEN-LENGTH-ALIAS catalog entry. The limitations.md text matches it. - The PR description claims that batching by sample count still delivers both fields and that 104 tests pass. I did not verify either claim. The test file changes were not run. Result: the map's design quality is unverified. The concrete code changes do not show a proven defect.
Resolution
Provide the body of the PR conversation comment that starts with <!-- kumo-pr-change-map -->, for example by pasting its text or by making the comment reachable to this check. Then re-run the check. The review should confirm that the map: 1. States the observed failure from #500 (two fields reading kind pass check() and fail on the first batch). 2. Justifies the chosen layer (check_contract plus _token_budget_aliases) against the existing unsupported catalog path, and states why no change to token counting is needed. 3. Explains the scope limits of the helper: path-based and derived field aliases, and non-history collections. 4. Lists the verification (the two-field regression, the one-field baseline, and the 104-test run) and a stopping condition.
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 4 remain after this review.
The reason will be displayed to describe this comment to others. Learn more.
The targeted early refusal prevents silent alias undercount for native token budgets/bucketing while retaining sample-count-only behavior. All 32 unsupported-contract/regression tests passed. This is a documented limitation, not full alias-budget support.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #500.
When two selected fields read the same stored column, DiskGraph counts it once for the token budget. On main, validation accepted the request and the first batch failed.
check()andprepare()now name both fields and the column before building the index. Batching by sample count still delivers both fields.Change map
Reused the Parquet-anchor regression from #447. The one-field case passed on main and the two-field case reproduced #500. Both passed with the fix. The three affected package test modules passed all 104 tests.