BenBot 1.7.5
A chess engine
Loading...
Searching...
No Matches
ben_bot::search::Options Struct Referencefinal

#include <libbenbot/search/Options.hpp>

Static Public Member Functions

static auto from_libchess (const chess::uci::GoCommandOptions &goOptions, bool isWhiteToMove) -> Options

Public Attributes

size_t depth { std::numeric_limits<size_t>::max() }
bool infinite { false }
std::optional< size_t > mateIn
size_t maxNodes { std::numeric_limits<size_t>::max() }
std::chrono::milliseconds moveOverhead { 0uz }
chess::moves::MoveList movesToSearch
std::optional< std::chrono::milliseconds > searchTime

Detailed Description

This struct encapsulates the parameters to the search algorithm.

See also
Context

Definition at line 52 of file Options.hpp.

Member Function Documentation

◆ from_libchess()

auto ben_bot::search::Options::from_libchess ( const chess::uci::GoCommandOptions & goOptions,
bool isWhiteToMove ) -> Options
staticnodiscard

Translates the raw UCI "go" command options into this struct's fields.

Member Data Documentation

◆ depth

size_t ben_bot::search::Options::depth { std::numeric_limits<size_t>::max() }

The maximum search depth (in plies).

Definition at line 54 of file Options.hpp.

◆ infinite

bool ben_bot::search::Options::infinite { false }

If true, the search should not exit until a stop or exit command is received.

Definition at line 75 of file Options.hpp.

◆ mateIn

std::optional<size_t> ben_bot::search::Options::mateIn

Search for mate in this many moves.

Definition at line 78 of file Options.hpp.

◆ maxNodes

size_t ben_bot::search::Options::maxNodes { std::numeric_limits<size_t>::max() }

Search only this many nodes. Setting this value too low can really emphasize the effects of our move ordering algorithm.

Definition at line 65 of file Options.hpp.

◆ moveOverhead

std::chrono::milliseconds ben_bot::search::Options::moveOverhead { 0uz }

Move overhead time subtracted from maximum search time.

Definition at line 60 of file Options.hpp.

◆ movesToSearch

chess::moves::MoveList ben_bot::search::Options::movesToSearch

Restrict the search to only these moves. If this is empty, all legal moves in the position will be searched.

Definition at line 70 of file Options.hpp.

◆ searchTime

std::optional<std::chrono::milliseconds> ben_bot::search::Options::searchTime

The maximum search time.

Definition at line 57 of file Options.hpp.


The documentation for this struct was generated from the following file: