Repository navigation
perf(resolve): precompute symmetric blocking keys, and read only the candidates' rows (#1505) - #1506
Merged
Merged
Conversation
…candidates' rows (#1505) er-dev on 28b33aa: prefilter 632 ms of a 945 ms resolve. Locally, on the detached path at 520k (1 thread), about 225 ms of that re-evaluated every blocking rule, in both orientations, over all cached keys per call, and about 150 ms read every corpus file for the candidates' rows. - A rule written f(l) = f(r) (symmetric_key: one top-level =, the right side the exact l/r mirror of a left side that reads only l.) holds exactly when f(corpus) = f(probe). The key table stores f(corpus) per row as __k<i>, computed once per refresh, and a call compares it with the probe's f(probe). Any other rule keeps its both-orientation condition. A one-off call still filters the corpus directly in one scan. - A detached key table also records each row's filename and file_row_number, and a call reads only those rows: the same union_by_name file set, filtered per hit file on file_row_number. resolve_latency_at_scale now times er-dev's shape: the expected answer through the lake, then a lake-free session that refreshes itself and resolves from the files, asserting each answer equals the lake's. At 519,984 records, 1 thread: p50 505 to 148 ms, p95 520 to 169 ms. Unit tests pin symmetric_key. Resolve (8), acct_ (12), er-cli lib (23), a_detached_resolve_matches_the_lake_resolve and pg_launch_proof pass. Co-Authored-By: Claude Opus 5.5 <[email protected]>
athvin
temporarily deployed
to
marketing-preview
November 30, 2026 11:16 — with
GitHub Actions
Inactive
This was referenced Nov 30, 2026
Closed
This branch was previously deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #1505
Part of #1429. #1429 stays open until er-dev measures p95 under 300 ms.
What
f(l) = f(r)holds exactly whenf(corpus) = f(probe).symmetric_keyrecognises it: one top-level=, and the right side is the exactl/rmirror of a left side that reads onlyl.. The key table storesf(corpus)per row as__k<i>, computed once per refresh, and each call compares it with the probe'sf(probe). Other rules keep their both-orientation condition. A one-off call still filters the corpus directly in one scan.filenameandfile_row_number, and a call reads only those rows: the sameunion_by_namefile set, filtered per hit file onfile_row_number.resolve_latency_at_scaletakes the expected answer through the lake, then times a lake-free session that refreshes itself and resolves from the files, asserting every answer equals the lake's.Why
On er-dev
28b33aa0(#1503), the prefilter took 632 ms of a 945 ms resolve, with p50 1164 / p95 1447 ms. Locally, on the detached path at 520k records, single-threaded:Proof
resolve_latency_at_scale, detached, 519,984 records, 1 thread (all answers equal the lake resolve):symmetric_key: mirrored, range, two equalities, and=inside a literal.acct_(12), er-cli lib (23),a_detached_resolve_matches_the_lake_resolve, andpg_launch_proof.make check: exit 0.Risk & rollback
git revert <merge-sha>.Post-merge ledger
Closed by: unclosed
mainis green with this change on it — the merge SHA, and the runthat proves it. A later head SHA with this commit as an ancestor counts;
a cancelled run with zero jobs does not:
imagesbuilt, or correctly never ran because nothing that goes intoan image changed:
deployconverged — proved by a line the running process emitted, notby the image digest and not by the workflow conclusion:
deploy,drift,kind's nightly leg) is green, or knowingly red for a reason that is notthis change:
Donethrough the automation rather than byhand, and the issue closed:
(a skill, a reference, memory) — or nothing new was learned:
Specific to this change
resolve timingsmedians:🤖 Generated with Claude Code