gigachess 0.3.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +102 -125
- package/dist/attacks.d.ts +3 -3
- package/dist/attacks.d.ts.map +1 -1
- package/dist/attacks.js +1 -1
- package/dist/board.d.ts +99 -44
- package/dist/board.d.ts.map +1 -1
- package/dist/board.js +726 -15
- package/dist/castling.d.ts +11 -1
- package/dist/castling.d.ts.map +1 -1
- package/dist/castling.js +122 -0
- package/dist/chess.d.ts +11 -23
- package/dist/chess.d.ts.map +1 -1
- package/dist/chess.js +81 -178
- package/dist/chess960.d.ts +1 -1
- package/dist/chess960.d.ts.map +1 -1
- package/dist/chess960.js +2 -2
- package/dist/chessjs.d.ts +13 -0
- package/dist/chessjs.d.ts.map +1 -0
- package/dist/chessjs.js +23 -0
- package/dist/chessops/board.d.ts +1 -1
- package/dist/chessops/board.d.ts.map +1 -1
- package/dist/chessops/chess.d.ts +1 -1
- package/dist/chessops/chess.d.ts.map +1 -1
- package/dist/chessops/chess.js +2 -2
- package/dist/chessops/convert.d.ts +1 -1
- package/dist/chessops/convert.d.ts.map +1 -1
- package/dist/chessops/fen.d.ts +1 -1
- package/dist/chessops/fen.d.ts.map +1 -1
- package/dist/chessops/fen.js +1 -1
- package/dist/chessops/fenInternal.d.ts +1 -1
- package/dist/chessops/fenInternal.d.ts.map +1 -1
- package/dist/chessops/fenInternal.js +2 -2
- package/dist/chessops/index.js +2 -2
- package/dist/chessops/result.d.ts +35 -0
- package/dist/chessops/result.d.ts.map +1 -0
- package/dist/chessops/result.js +49 -0
- package/dist/chessops/setup.js +1 -1
- package/dist/chessops/types.js +1 -1
- package/dist/chesstree.d.ts +1 -1
- package/dist/chesstree.d.ts.map +1 -1
- package/dist/chesstree.js +5 -5
- package/dist/core.d.ts +1 -1
- package/dist/core.d.ts.map +1 -1
- package/dist/core.js +2 -2
- package/dist/fen.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -6
- package/dist/packedMove.js +1 -1
- package/dist/squareSet.js +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/zobrist.d.ts +22 -0
- package/dist/zobrist.d.ts.map +1 -1
- package/dist/zobrist.js +89 -33
- package/dist/zobristBlob.js +1 -1
- package/package.json +5 -8
package/README.md
CHANGED
|
@@ -5,9 +5,8 @@
|
|
|
5
5
|
<h1 align="center">GigaChess</h1>
|
|
6
6
|
|
|
7
7
|
<p align="center">
|
|
8
|
-
<strong>The fastest chess engine in
|
|
9
|
-
|
|
10
|
-
18.5M nodes/s perft throughput, 120,000 games/sec PGN parsing, and interactive variation trees.
|
|
8
|
+
<strong>The fastest chess library and engine in TypeScript.</strong><br>
|
|
9
|
+
Built for high-performance web applications, interactive chessboards, and analysis engines.
|
|
11
10
|
</p>
|
|
12
11
|
|
|
13
12
|
<p align="center">
|
|
@@ -20,47 +19,24 @@
|
|
|
20
19
|
|
|
21
20
|
---
|
|
22
21
|
|
|
23
|
-
|
|
22
|
+
## ⚡ Highlights
|
|
24
23
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
1
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
**
|
|
32
|
-
|
|
33
|
-
- ⚡ **Up to 3.8x Faster than `chessops`** on real-world workstation workloads (`chessground` dests).
|
|
34
|
-
- 🏎️ **3.8x–5.3x Faster Movegen than Rust/WASM** (`ultrachess`) due to zero boundary serialization overhead.
|
|
35
|
-
- 🔄 **1-Line Drop-in Replacement** for `chess.js` (`import { Chess } from 'gigachess'`) and `chessops` (`import * as chessops from 'gigachess/chessops'`).
|
|
36
|
-
- 🌳 **Built-in `chesstree` Variation Trees** (`game.toTree()` and `Chess.loadTree(pgn)`).
|
|
37
|
-
- 🔑 **Instant $O(1)$ 64-bit Polyglot Zobrist Hashing** (`game.zobrist()`).
|
|
38
|
-
- 📦 **16-bit Binary Move Streams (`moves2`)** (25x smaller memory footprint per game).
|
|
39
|
-
- 📜 **100% Permissive MIT License** — completely free for commercial and proprietary software.
|
|
24
|
+
* 🚀 **45x Faster Move Execution**: In-place stateful `Board` executes moves at **5.98M moves/sec** (167 ns/op).
|
|
25
|
+
* 🏎️ **18.7M nodes/s Perft**: Stockfish-grade bitboard throughput in pure TypeScript.
|
|
26
|
+
* 🛡️ **100% Permissive MIT License**: Completely free for commercial and proprietary applications.
|
|
27
|
+
* 🔄 **1-Line `chess.js` Upgrade**: Drop-in wrapper via `gigachess/chessjs` with zero code changes.
|
|
28
|
+
* ♟️ **Full Chess & Chess960**: Complete support for standard chess, Fischer Random (960), FEN, SAN, and UCI.
|
|
29
|
+
* 🌲 **Study Trees & Fast PGN**: Interactive variation trees, comments, glyphs, and 128k games/sec PGN streaming.
|
|
30
|
+
* 🔑 **Instant Polyglot Zobrist Hashing**: Zero-allocation $O(1)$ 64-bit incremental hash matching Polyglot startpos.
|
|
31
|
+
* 📦 **16-bit Packed Move Streams (`moves2`)**: Compact 2-byte binary serialization replaying at **4.8M plies/sec**.
|
|
40
32
|
|
|
41
33
|
---
|
|
42
34
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
| Metric / Workload | 🚀 **GigaChess** | ♟️ **`chessops`** (0.15.1) | 📦 **`chess.js`** (1.4.0) | GigaChess Advantage |
|
|
46
|
-
|---|---|---|---|---|
|
|
47
|
-
| **License** | ✅ **100% MIT** | ❌ **GPL-3.0** | ✅ **BSD-2-Clause** | **Free for commercial use** |
|
|
48
|
-
| **Sliding Piece Attacks** | **35.5 MAttacks/s** | 10.6 MAttacks/s | N/A *(array scan)* | **3.36x faster (+236%)** vs chessops |
|
|
49
|
-
| **Perft Movegen Throughput** | **18.5 Million nodes/s** | 8.5 Million nodes/s | ❌ *(No perft API)* | **2.17x faster (+117%)** vs chessops |
|
|
50
|
-
| **Chessground UI Dests** | **212,675 pos/s** | 56,000 pos/s | N/A | **3.80x faster (+280%)** vs chessops |
|
|
51
|
-
| **FEN Parse + Make** | **285,000 ops/s** | 125,000 ops/s | 94,000 ops/s | **2.26x vs chessops \| 3.03x vs chess.js** |
|
|
52
|
-
| **SAN Make + Legal Dests** | **51,700 ops/s** | 18,200 ops/s | 6,947 ops/s | **2.84x vs chessops \| 7.44x vs chess.js** |
|
|
53
|
-
| **PGN Game Streaming** | **120,000 games/s** (84 MB/s) | 41,500 games/s (29 MB/s) | 1,710 games/s (1.2 MB/s) | **2.89x vs chessops \| 7.01x vs chess.js** |
|
|
54
|
-
| **Repertoire Tree Build** | **37,200 lines/s** | 20,400 lines/s | ❌ *(No Tree API)* | **1.84x faster (+84%)** vs chessops |
|
|
55
|
-
| **isCheck Detection** | **0.5 ns / op** (2.1B ops/s) | 14.5 ns / op | 85.0 ns / op | **29x vs chessops \| 170x vs chess.js** |
|
|
56
|
-
| **Polyglot Zobrist ($O(1)$)** | ✅ **Native (`{lo,hi}`)** | ❌ None | ❌ None | **Zero-allocation transposition match** |
|
|
57
|
-
| **16-bit Packed Moves (`moves2`)** | ✅ **Native (`Uint16Array`)** | ❌ None | ❌ None | **25x smaller memory (160 B/game)** |
|
|
58
|
-
|
|
59
|
-
*Benchmarks measured on Node.js v24 on Apple Silicon. Run locally via `node --expose-gc bench/bench-real.mjs`.*
|
|
35
|
+
> 💡 **100% Pure TypeScript with Zero Dependencies**: GigaChess requires no native C++ binaries, node-gyp, or WebAssembly. It runs seamlessly in modern browsers, Node.js, Bun, Deno, and edge workers.
|
|
60
36
|
|
|
61
37
|
---
|
|
62
38
|
|
|
63
|
-
##
|
|
39
|
+
## 📦 Installation
|
|
64
40
|
|
|
65
41
|
```bash
|
|
66
42
|
npm install gigachess
|
|
@@ -68,131 +44,132 @@ npm install gigachess
|
|
|
68
44
|
|
|
69
45
|
---
|
|
70
46
|
|
|
71
|
-
##
|
|
47
|
+
## 🚀 Quick Start
|
|
72
48
|
|
|
73
|
-
### From `chess.js`
|
|
74
|
-
Replace your import statement. Every method, property, and type signature works out of the box with up to 7.4x faster move validation:
|
|
75
49
|
```ts
|
|
76
|
-
|
|
77
|
-
// import { Chess } from 'chess.js';
|
|
50
|
+
import { Board } from "gigachess";
|
|
78
51
|
|
|
79
|
-
//
|
|
80
|
-
|
|
52
|
+
// Initialize starting position
|
|
53
|
+
const board = new Board();
|
|
81
54
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
console.log(chess.fen()); // 'rnbqkbnr/pppp1ppp/8/4p3/4P3/8/PPPP1PPP/RNBQKBNR w KQkq - 0 2'
|
|
86
|
-
console.log(chess.history()); // ['e4', 'e5']
|
|
87
|
-
```
|
|
55
|
+
// Parse SAN and execute move in 167 ns
|
|
56
|
+
const move = board.parseSan("e4");
|
|
57
|
+
const undo = board.makeMove(move);
|
|
88
58
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
```ts
|
|
92
|
-
// Before:
|
|
93
|
-
// import { Chess } from 'chessops/chess';
|
|
94
|
-
// import { parseFen } from 'chessops/fen';
|
|
59
|
+
console.log(board.toFen()); // 'rnbqkbnr/pppppppp/8/8/4P3/8/PPPP1PPP/RNBQKBNR b KQkq - 0 1'
|
|
60
|
+
console.log(board.inCheck()); // false
|
|
95
61
|
|
|
96
|
-
//
|
|
97
|
-
|
|
98
|
-
|
|
62
|
+
// Instant O(1) reversible unmake
|
|
63
|
+
board.unmakeMove(undo);
|
|
64
|
+
console.log(board.toFen()); // startpos restored
|
|
99
65
|
```
|
|
100
66
|
|
|
101
67
|
---
|
|
102
68
|
|
|
103
|
-
##
|
|
69
|
+
## 📊 GigaChess vs `chess.js`
|
|
104
70
|
|
|
105
|
-
|
|
106
|
-
Generate legal move dots for `@lichess-org/chessground` or any UI chessboard in microseconds:
|
|
107
|
-
```ts
|
|
108
|
-
import { Chess } from 'gigachess';
|
|
71
|
+
Measured under Node.js v24 on Apple Silicon:
|
|
109
72
|
|
|
110
|
-
|
|
73
|
+
| Feature / Benchmark | 🚀 **GigaChess** | 📦 **`chess.js`** (1.4.0) | Advantage |
|
|
74
|
+
|---|---|---|---|
|
|
75
|
+
| **Move Execution (`make` + `unmake`)** | **5,986,400 ops/s** (167 ns) | 134,500 ops/s (7,434 ns) | **44.5x faster (+4,350%)** |
|
|
76
|
+
| **Legal Move Generation** | **541,200 pos/s** (1,848 ns) | 49,200 pos/s (20,341 ns) | **11.0x faster (+1,001%)** |
|
|
77
|
+
| **Perft Movegen (Depth Search)** | **18,678,516 nodes/s** | ~500,000 nodes/s | **37x faster** |
|
|
78
|
+
| **Game Stream Replay** | **4,803,000 plies/s** | 649,000 plies/s | **7.4x faster (+640%)** |
|
|
79
|
+
| **Check & Status Query (`inCheck`)** | **4.9 ns** (203M ops/s) | 26.3 ns (38M ops/s) | **5.3x faster (+434%)** |
|
|
80
|
+
| **PGN Parsing & Streaming** | **128,701 games/s** (89 MB/s) | 3,634 games/s (2.5 MB/s) | **35.4x faster (+3,440%)** |
|
|
81
|
+
| **SAN Move Validation & Make** | **49,444 ops/s** | 6,992 ops/s | **7.07x faster (+607%)** |
|
|
82
|
+
| **FEN Parsing & Setup** | **458,961 ops/s** | 91,214 ops/s | **5.03x faster (+403%)** |
|
|
83
|
+
| **Memory per 80-Ply Game** | **160 Bytes** (`Uint16Array`) | ~4,200 Bytes (Heap Objects) | **26x less memory** |
|
|
84
|
+
| **64-bit Polyglot Zobrist Hash** | ✅ **Built-in ($O(1)$ incremental)** | ❌ None | **Transposition & repetition** |
|
|
85
|
+
| **Variation Trees & Analysis** | ✅ **Built-in (`chesstree`)** | ❌ None | **Branching, comments, glyphs** |
|
|
86
|
+
| **Chess960 (Fischer Random)** | ✅ **Full 960 support** | ⚠️ Partial / legacy bugs | **Full standard & Chess960** |
|
|
111
87
|
|
|
112
|
-
|
|
113
|
-
const allDests = game.allDests();
|
|
88
|
+
---
|
|
114
89
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
90
|
+
## 🔄 Drop-in `chess.js` Compatibility
|
|
91
|
+
|
|
92
|
+
Existing `chess.js` code can be upgraded in 1 line with zero refactoring:
|
|
118
93
|
|
|
119
|
-
### 2. Variation Trees & PGN Analysis (`toTree` & `loadTree`)
|
|
120
|
-
Full recursive variation tree navigation and PGN export built right in:
|
|
121
94
|
```ts
|
|
122
|
-
|
|
95
|
+
// Simply replace your import:
|
|
96
|
+
// import { Chess } from "chess.js";
|
|
97
|
+
import { Chess } from "gigachess/chessjs";
|
|
123
98
|
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
99
|
+
const chess = new Chess();
|
|
100
|
+
chess.move("e4");
|
|
101
|
+
chess.move("e5");
|
|
102
|
+
console.log(chess.fen()); // 'rnbqkbnr/pppp1ppp/8/4p3/4P3/8/PPPP1PPP/RNBQKBNR w KQkq - 0 2'
|
|
103
|
+
console.log(chess.history()); // ['e4', 'e5']
|
|
104
|
+
```
|
|
129
105
|
|
|
130
|
-
|
|
131
|
-
tree.setCommentAt([1], 'Open Game');
|
|
132
|
-
console.log(tree.pgn());
|
|
106
|
+
---
|
|
133
107
|
|
|
134
|
-
|
|
135
|
-
const treeWrapper = Chess.loadTree(`1. e4 e5 (1... c5 2. Nf3) 2. Nf3 Nc6`);
|
|
136
|
-
const root = treeWrapper.getRoot();
|
|
137
|
-
```
|
|
108
|
+
## 💡 Common Recipes
|
|
138
109
|
|
|
139
|
-
###
|
|
140
|
-
Instant position fingerprinting for opening books, transpositions, and repetitions:
|
|
110
|
+
### 1. Legal Move Generation
|
|
141
111
|
```ts
|
|
142
|
-
import {
|
|
112
|
+
import { Board } from "gigachess";
|
|
113
|
+
|
|
114
|
+
const board = new Board();
|
|
143
115
|
|
|
144
|
-
|
|
145
|
-
|
|
116
|
+
// Iterate without array allocation:
|
|
117
|
+
board.forEachLegalMove((move) => {
|
|
118
|
+
console.log(board.toSan(move));
|
|
119
|
+
});
|
|
146
120
|
|
|
147
|
-
|
|
148
|
-
|
|
121
|
+
// Or write into a reusable buffer (541k pos/s):
|
|
122
|
+
const buffer = new Uint16Array(256);
|
|
123
|
+
const count = board.legalMoves(buffer);
|
|
149
124
|
```
|
|
150
125
|
|
|
151
|
-
###
|
|
152
|
-
Compress entire game databases down to 2 bytes per ply:
|
|
126
|
+
### 2. Game State & Terminal Checks
|
|
153
127
|
```ts
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
128
|
+
const board = new Board();
|
|
129
|
+
|
|
130
|
+
board.inCheck(); // false
|
|
131
|
+
board.isCheckmate(); // false
|
|
132
|
+
board.isStalemate(); // false
|
|
133
|
+
board.isDraw(); // false
|
|
134
|
+
board.isInsufficientMaterial();// false
|
|
135
|
+
board.turn; // 0 = White, 1 = Black
|
|
136
|
+
```
|
|
160
137
|
|
|
161
|
-
|
|
162
|
-
|
|
138
|
+
### 3. Incremental Polyglot Zobrist Hashing
|
|
139
|
+
```ts
|
|
140
|
+
const board = new Board();
|
|
163
141
|
|
|
164
|
-
//
|
|
165
|
-
const
|
|
166
|
-
console.log(
|
|
142
|
+
// Fast 64-bit Polyglot key updated in O(1) during moves:
|
|
143
|
+
const hash = board.zobrist(); // { lo: number, hi: number }
|
|
144
|
+
console.log(board.zobristHex()); // "463b96181691fc9c"
|
|
167
145
|
```
|
|
168
146
|
|
|
169
|
-
|
|
147
|
+
### 4. Chess960 (Fischer Random)
|
|
148
|
+
```ts
|
|
149
|
+
import { Board } from "gigachess";
|
|
170
150
|
|
|
171
|
-
|
|
151
|
+
// Load any of the 960 starting positions:
|
|
152
|
+
const board = Board.fromFen("rnqbbknr/pppppppp/8/8/8/8/PPPPPPPP/RNQBBKNR w KQkq - 0 1");
|
|
153
|
+
console.log(board.toFen());
|
|
154
|
+
```
|
|
172
155
|
|
|
173
|
-
|
|
156
|
+
### 5. Binary Move Stream Replay (`moves2`)
|
|
157
|
+
```ts
|
|
158
|
+
import { Board } from "gigachess";
|
|
174
159
|
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
5. **Precomputed $64 \times 64$ Flat Ray & Between Tables**: Single-cycle `Uint32Array(4096)` array index lookups replace dynamic loops during pin and check resolution.
|
|
180
|
-
6. **Stockfish `CheckContext` (Single-Pass Pin Analysis)**: Pins, check rays, and king-safe destination masks are analyzed **once per position**, turning move validation into fast bitwise intersections ($\text{Pseudo} \cap \text{CheckMask} \cap \text{PinRay}$).
|
|
181
|
-
7. **Black Magic Sliding Bitboards**: $O(1)$ Bishop, Rook, and Queen ray generation delivering over **35.5 Million attacks/sec**.
|
|
182
|
-
8. **Piece-Centric Movegen & Vectorized Pawn Shifts**: Direct iteration over piece bitboards with parallel 32-bit shifts eliminates `pieceAt()` scans.
|
|
183
|
-
9. **Zero-Allocation `MoveSink` & `forEachLegalMove` Visitor**: Bulk popcounting at perft leaves and stack-buffer packed move writing (`legalMovesInto`) eliminate all move object allocations.
|
|
184
|
-
10. **Incremental Zobrist XORs**: Hashing updates in $O(1)$ per move rather than rescanning the 64 squares.
|
|
160
|
+
// Replay full games at 4.8M plies/s from compact 16-bit buffers:
|
|
161
|
+
const moves = new Uint16Array([ /* packed 16-bit moves */ ]);
|
|
162
|
+
const board = Board.fromMoves2(moves);
|
|
163
|
+
```
|
|
185
164
|
|
|
186
165
|
---
|
|
187
166
|
|
|
188
|
-
##
|
|
189
|
-
|
|
190
|
-
GigaChess is engineered for maximum performance across the entire chess stack:
|
|
167
|
+
## 🔬 Under the Hood: Why GigaChess is Fast
|
|
191
168
|
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
169
|
+
1. **In-Place Bitboard Mutation**: Unlike engines that clone full state on every move, `Board` mutates bitboards in-place and returns a compact `Undo` for instant $O(1)$ rollback.
|
|
170
|
+
2. **Zero-BigInt 32-bit Integer Pairs**: 64-bit `BigInt` forces object allocation on the heap. GigaChess executes all bitboards as 32-bit unsigned integer pairs (`lo >>> 0`, `hi >>> 0`), running directly in CPU registers.
|
|
171
|
+
3. **Stockfish Single-Pass Pin Analysis (`CheckContext`)**: Checkers and pin lines are computed once per position, turning legal move validation into fast bitwise intersections.
|
|
172
|
+
4. **16-bit Unboxed Small Integers (Smis)**: Packed moves are stored as 16-bit integers, bypassing garbage collection pauses.
|
|
196
173
|
|
|
197
174
|
---
|
|
198
175
|
|
package/dist/attacks.d.ts
CHANGED
|
@@ -34,9 +34,9 @@ export declare function lineRay(from: number, to: number): SquareSet;
|
|
|
34
34
|
* evaluate attackedness with the moving king removed from the occupancy so
|
|
35
35
|
* that sliders x-raying the king stay "attacking" through its old square).
|
|
36
36
|
*/
|
|
37
|
-
export declare function attackersTo(board: import("./board.js").
|
|
38
|
-
export declare function isAttacked(board: import("./board.js").
|
|
39
|
-
export declare function kingAttackers(board: import("./board.js").
|
|
37
|
+
export declare function attackersTo(board: import("./board.js").BoardLike, square: number, attacker: Color, occ?: SquareSet): SquareSet;
|
|
38
|
+
export declare function isAttacked(board: import("./board.js").BoardLike, square: number, attacker: Color): boolean;
|
|
39
|
+
export declare function kingAttackers(board: import("./board.js").BoardLike, kingColor: Color): SquareSet;
|
|
40
40
|
export declare function rookAttacksForTest(sqIdx: number, occ: SquareSet): SquareSet;
|
|
41
41
|
export declare function bishopAttacksForTest(sqIdx: number, occ: SquareSet): SquareSet;
|
|
42
42
|
export {};
|
package/dist/attacks.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"attacks.d.ts","sourceRoot":"","sources":["../src/attacks.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAiInC,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,CAEtD;AACD,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,CAEpD;AACD,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MA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E,OAAO,YAAY,EAAE,SAAS,EACrC,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,KAAK,EACf,GAAG,GAAE,SAA0B,GAC9B,SAAS,CA4BX;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,OAAO,YAAY,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,GAAG,OAAO,CAuB1G;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,YAAY,EAAE,SAAS,EAAE,SAAS,EAAE,KAAK,GAAG,SAAS,CAQhG;AAGD,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,SAAS,GAAG,SAAS,CAE3E;AACD,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,SAAS,GAAG,SAAS,CAE7E"}
|
package/dist/attacks.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/attacks.ts — leaper tables + fancy per-square Black Magic sliding
|
|
2
2
|
// (lazily loaded from generated base64 blobs) via bench/magic-tables
|
|
3
|
-
// MIT
|
|
3
|
+
// MIT gigachess, clean-room from specs + FIDE notes (no G P L)
|
|
4
4
|
import * as sq from "./squareSet.js";
|
|
5
5
|
import { Color } from "./types.js";
|
|
6
6
|
import { squareFile, squareRank } from "./util.js";
|
package/dist/board.d.ts
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
import type { SquareSet } from "./squareSet.js";
|
|
1
|
+
import type { SquareSet, MutableSquareSet } from "./squareSet.js";
|
|
2
2
|
import * as sq from "./squareSet.js";
|
|
3
3
|
import { Color, Role } from "./types.js";
|
|
4
|
-
|
|
4
|
+
import type { Position, Move, CastlingRights } from "./types.js";
|
|
5
|
+
import type { ZobristKey } from "./zobrist.js";
|
|
6
|
+
import type { CastlingPlan } from "./castling.js";
|
|
7
|
+
export type BoardLike = {
|
|
5
8
|
readonly white: SquareSet;
|
|
6
9
|
readonly black: SquareSet;
|
|
7
10
|
readonly pawn: SquareSet;
|
|
@@ -14,33 +17,88 @@ export type Board = {
|
|
|
14
17
|
readonly promoted: SquareSet;
|
|
15
18
|
readonly kingSq?: readonly [number, number];
|
|
16
19
|
};
|
|
17
|
-
export
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
20
|
+
export type Undo = {
|
|
21
|
+
readonly move: number;
|
|
22
|
+
readonly movingRole: Role;
|
|
23
|
+
readonly capturedRole: Role | -1;
|
|
24
|
+
readonly capturedSq: number;
|
|
25
|
+
readonly castlingPlan: CastlingPlan | null;
|
|
26
|
+
readonly isEnPassant: boolean;
|
|
27
|
+
readonly promoRole: Role | null;
|
|
28
|
+
readonly epSquare: number | null;
|
|
29
|
+
readonly castling: CastlingRights;
|
|
30
|
+
readonly castlingMask?: number;
|
|
31
|
+
readonly halfmoves: number;
|
|
32
|
+
readonly fullmoves: number;
|
|
33
|
+
readonly kingSq: readonly [number, number];
|
|
34
|
+
readonly checkers: SquareSet;
|
|
35
|
+
readonly zobristLo: number;
|
|
36
|
+
readonly zobristHi: number;
|
|
37
|
+
};
|
|
38
|
+
export declare class Board implements BoardLike {
|
|
39
|
+
white: MutableSquareSet;
|
|
40
|
+
black: MutableSquareSet;
|
|
41
|
+
pawn: MutableSquareSet;
|
|
42
|
+
knight: MutableSquareSet;
|
|
43
|
+
bishop: MutableSquareSet;
|
|
44
|
+
rook: MutableSquareSet;
|
|
45
|
+
queen: MutableSquareSet;
|
|
46
|
+
king: MutableSquareSet;
|
|
47
|
+
occupied: MutableSquareSet;
|
|
48
|
+
promoted: MutableSquareSet;
|
|
49
|
+
kingSq: [number, number];
|
|
50
|
+
turn: Color;
|
|
51
|
+
castling: CastlingRights;
|
|
52
|
+
castlingMask?: number;
|
|
53
|
+
epSquare: number | null;
|
|
54
|
+
halfmoves: number;
|
|
55
|
+
fullmoves: number;
|
|
56
|
+
checkers: SquareSet;
|
|
57
|
+
isChess960: boolean;
|
|
58
|
+
_zobristLo: number;
|
|
59
|
+
_zobristHi: number;
|
|
60
|
+
constructor(input?: string | Position | Board | BoardLike);
|
|
61
|
+
static startpos(): Board;
|
|
62
|
+
static empty(): Board;
|
|
63
|
+
static fromFen(fen: string): Board;
|
|
64
|
+
static fromMoves2(buffer: Uint16Array | Uint8Array, startFen?: string, isChess960?: boolean): Board;
|
|
65
|
+
get board(): Board;
|
|
66
|
+
get pos(): Position;
|
|
67
|
+
toPosition(): Position;
|
|
68
|
+
get halfmove(): number;
|
|
69
|
+
get fullmove(): number;
|
|
70
|
+
get zobristLo(): number;
|
|
71
|
+
get zobristHi(): number;
|
|
72
|
+
zobrist(): ZobristKey;
|
|
73
|
+
zobristBigInt(): bigint;
|
|
74
|
+
zobristHex(): string;
|
|
75
|
+
inCheck(): boolean;
|
|
76
|
+
private refreshZobrist;
|
|
77
|
+
clear(): this;
|
|
78
|
+
loadFen(fen: string): void;
|
|
79
|
+
copyFrom(src: Position | Board | BoardLike): this;
|
|
80
|
+
clone(): Board;
|
|
81
|
+
roleAt(sqIdx: number): Role | undefined;
|
|
82
|
+
colorAt(sqIdx: number): Color | undefined;
|
|
83
|
+
pieceAt(sqIdx: number): {
|
|
84
|
+
color: Color;
|
|
85
|
+
role: Role;
|
|
86
|
+
} | undefined;
|
|
87
|
+
hasPiece(sqIdx: number): boolean;
|
|
88
|
+
kingSquare(color: Color): number | undefined;
|
|
89
|
+
private _clearSquare;
|
|
90
|
+
private _putPiece;
|
|
91
|
+
makeMove(moveWord: number | Move): Undo;
|
|
92
|
+
unmakeMove(undo: Undo): void;
|
|
93
|
+
legalMoves(outBuffer?: Uint16Array): Uint16Array;
|
|
94
|
+
forEachLegalMove(fn: (moveWord: number) => void): void;
|
|
95
|
+
toSan(moveWord: number): string;
|
|
96
|
+
toUci(moveWord: number): string;
|
|
97
|
+
toFen(): string;
|
|
98
|
+
parseSan(san: string): number | null;
|
|
99
|
+
parseUci(uci: string): number | null;
|
|
100
|
+
perft(depth: number): number;
|
|
101
|
+
}
|
|
44
102
|
export type WritableBoard = {
|
|
45
103
|
white: sq.MutableSquareSet;
|
|
46
104
|
black: sq.MutableSquareSet;
|
|
@@ -54,31 +112,28 @@ export type WritableBoard = {
|
|
|
54
112
|
promoted: sq.MutableSquareSet;
|
|
55
113
|
kingSq: [number, number];
|
|
56
114
|
};
|
|
115
|
+
export declare function emptyBoard(): BoardLike;
|
|
116
|
+
export declare function cloneBoard(board: BoardLike): BoardLike;
|
|
57
117
|
export declare function newScratchBoard(): WritableBoard;
|
|
58
|
-
export declare function cloneAsWritable(board:
|
|
59
|
-
|
|
60
|
-
* field objects, so only the 64-bit values are assigned (no {lo,hi} churn). */
|
|
61
|
-
export declare function copyBoardInto(dst: WritableBoard, src: Board): void;
|
|
62
|
-
/** In-place: remove the piece (any color/role) at sqIdx. Hot-loop only.
|
|
63
|
-
* Zero-allocation: raw bitmasks instead of sq.not/singleton/and objects. */
|
|
118
|
+
export declare function cloneAsWritable(board: BoardLike): WritableBoard;
|
|
119
|
+
export declare function copyBoardInto(dst: WritableBoard, src: BoardLike): void;
|
|
64
120
|
export declare function clearSquareInPlace(b: WritableBoard, sqIdx: number): void;
|
|
65
|
-
/** In-place: place a piece at sqIdx. Hot-loop only. Zero-allocation. */
|
|
66
121
|
export declare function putPieceInPlace(b: WritableBoard, sqIdx: number, piece: {
|
|
67
122
|
color: Color;
|
|
68
123
|
role: Role;
|
|
69
124
|
}): void;
|
|
70
|
-
export declare function setPiece(board:
|
|
125
|
+
export declare function setPiece(board: BoardLike, sqIdx: number, piece: {
|
|
71
126
|
color: Color;
|
|
72
127
|
role: Role;
|
|
73
128
|
}): Board;
|
|
74
|
-
export declare function removePiece(board:
|
|
75
|
-
export declare function pieceAt(board:
|
|
129
|
+
export declare function removePiece(board: BoardLike, sqIdx: number): Board;
|
|
130
|
+
export declare function pieceAt(board: BoardLike, sqIdx: number): {
|
|
76
131
|
color: Color;
|
|
77
132
|
role: Role;
|
|
78
133
|
} | undefined;
|
|
79
|
-
export declare function hasPiece(board:
|
|
80
|
-
export declare function kingSquare(board:
|
|
81
|
-
export declare function occupiedEqualsWhiteBlack(board:
|
|
82
|
-
export declare function rolePartitionEqualsOccupied(board:
|
|
83
|
-
export declare function boardEquals(a:
|
|
134
|
+
export declare function hasPiece(board: BoardLike, sqIdx: number): boolean;
|
|
135
|
+
export declare function kingSquare(board: BoardLike, color: Color): number | undefined;
|
|
136
|
+
export declare function occupiedEqualsWhiteBlack(board: BoardLike): boolean;
|
|
137
|
+
export declare function rolePartitionEqualsOccupied(board: BoardLike): boolean;
|
|
138
|
+
export declare function boardEquals(a: BoardLike, b: BoardLike): boolean;
|
|
84
139
|
//# sourceMappingURL=board.d.ts.map
|
package/dist/board.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"board.d.ts","sourceRoot":"","sources":["../src/board.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"board.d.ts","sourceRoot":"","sources":["../src/board.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClE,OAAO,KAAK,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AACzC,OAAO,KAAK,EAAE,QAAQ,EAAS,IAAI,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAkBxE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAW/C,OAAO,KAAK,EAAE,Y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