Kirin v0.2.3-4-g1d04d94-dirty
Autonomous chess — engine and hardware API reference
Loading...
Searching...
No Matches
Chess engine (kirin_engine)

Pure chess — movegen, search, evaluation, UCI. No hardware dependencies. More...

Files

file  attacks.cpp
 Attack tables and magic bitboard lookups.
file  attacks.h
 Attack tables and magic bitboard lookups.
file  bitboard.cpp
 Bit manipulation and board representation.
file  bitboard.h
 Bit manipulation and board representation.
file  engine.h
 Main public interface.
file  evaluation.cpp
 Position evaluation.
file  evaluation.h
 Position evaluation.
file  movegen.cpp
 Move generation and encoding.
file  movegen.h
 Move generation and encoding.
file  nnue.cpp
 Efficiently updatable neural network evaluation scaffold.
file  nnue.h
 Efficiently updatable neural network evaluation scaffold.
file  position.cpp
 Position management and FEN parsing.
file  position.h
 Position management and FEN parsing.
file  san.cpp
 see san.h
file  san.h
 Standard Algebraic Notation for encoded moves.
file  search.cpp
 Search algorithms and transposition table.
file  search.h
 Search algorithms and transposition table.
file  types.cpp
 Implementation of global constants.
file  types.h
 Basic type definitions, constants, and enums.
file  uci.cpp
 UCI protocol implementation.
file  uci.h
 UCI protocol interface.
file  utils.cpp
 Time control, random numbers, and I/O utilities.
file  utils.h
 Time control, random numbers, and I/O utilities.
file  zobrist.cpp
 Zobrist hashing implementation.
file  zobrist.h
 Zobrist hashing for position identification.

Detailed Description

Pure chess — movegen, search, evaluation, UCI. No hardware dependencies.

Pure chess, no hardware dependencies. Bitboard move generation with magic bitboards, Zobrist hashing, alpha-beta search with iterative deepening and a transposition table, classical + NNUE evaluation, and the UCI protocol.

The invariant
This library must build and test standalone. Nothing here may include a hardware header, touch GPIO, or open a serial port. That boundary is what lets the same engine ship in the product, on the lichess bot, and in CI on a machine with no board attached.
Types, not identities
The engine reasons about piece types: it knows "a black knight is on d5", not "the b8-knight is on d5". Anything needing per-piece identity lives in Hardware layer (kirin_hardware) — see PieceTracker for where the two reconcile.

Design reference: docs/engine-docs/.