#pragma once #include "binres/openings.hpp" #include "pgnp.hpp" /** * @brief Guess the opening using the Lichess Opening Database * See: https://github.com/lichess-org/chess-openings */ class Openings { typedef std::vector MoveList; typedef std::vector> Volume; Volume A,B,C,D,E; void SearchOpening(const pgnp::HalfMove *moves,std::string &name, std::string &eco); void LoadVolume(const std::string &tsv, Volume *vol); public: void GuessOpening(const std::string &SANMoves, std::string &name, std::string &eco); void GuessOpening(const pgnp::HalfMove *moves, std::string &name, std::string &eco); Openings(); };