Repository navigation
[Integration] Position search — maintainer acceptance of PR #11 - #12
Merged
Merged
Conversation
- query::PositionQuery on GameDataQuery::position: "Look for", "Or" and "Exclude" boards of men (a piece of a colour, or a joker for any man of a colour), horizontal and vertical mirrors (colours swapped), and First, Length, Last with the dialog's defaults. "Sacrifice" is refused as unsupported. - The fragment compiles to bitboards per orientation; the replay stage tests it on each main-line position in the same single replay as the endings, and stops once the answer is known. Ending-only queries keep their own sink. - parse_fragment and the cbvault search options --look-for, --or, --exclude, --mirror, --first-move, --length, --last-move, --sacrifice. - Tests on classic and 2CBH fixtures, CLI tests, fixture and whole-database benchmarks, docs/search.md and the OpenSpec change search-position. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ovenance and measurements Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…eview tests - Tracker::passed: after a main-line move, a next move past Last settles the answer, so the move after Last is never decoded (a corrupt one no longer fails a valid 1..=Last search). - MainLine::resume ends the main line, so no variation move is decoded. - Tests: a 2CBH variation, both mirrors together, a set-up start (Black to move on move 10), Length up to Last, the same man in Look for and Exclude, a corrupt move right after Last, and an exhaustive square-by-square gigachess reference over every man on every square plus 2,000 pseudo-random combinations of boards, mirrors and windows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
"Vertical" reflects across the vertical axis (files a<->h); "Horizontal" across the horizontal axis (ranks 1<->8) with the colours swapped. Checked against ChessBase on Mega Database 2026 (white bishop on h7): Horizontal 344,642 (cbvault 342,106), Vertical 395,103 (cbvault 389,913); the dialog draws the axis as a red line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Mirror axes, "Or" and the start position agree with ChessBase on Mega Database 2026; ChessBase reads past move Last by a rule not yet established, recorded with the counts in docs/search.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Measured on Mega Database 2026: ChessBase looks at every position from the start through move max(Last, First + 1), plus the position after White's following move; First does not cut the positions before it. Eleven searches agree within 0.03% (docs/search.md). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…cope, MoveNumbering, variations, and Gates A/B
…-009, and validation report
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.
Scope
Integrates Tulio Vianna's PR #11 with its original commits preserved. CBVault provides canonical, independently validated partial-position search across classic CBH and native 2CBH. Supports bounded First/Last, persistence, mirrors, jokers, record scope, FEN/relative numbering and optional branch-local variations. Does not reproduce the observed ChessBase window defects.
See ADR-009, search guide, validation report and acceptance runbook.
Verification
Integration
Latest branch changes after beff433 enable automatic functional and native CI on each integration push. Do not disclose licensed data or private membership fingerprints. Preserve contributor attribution and merge history. Final native benchmark and upstream npm release retry status will be recorded before release.