lichess.org
Donate
Jja: Jin, Jîyan, Azadî

Can Ferman Gülmez

Exploring the New Features of jja 0.6.0

Software DevelopmentChess botChess engineAnalysis
Discover the Power of jja 0.6.0: A New Era of Improved Performance and Features

In the ever-evolving world of technology, it's crucial to stay ahead of the curve. That's why we're delighted to announce the release of jja 0.6.0, which comes packed with new features, bug fixes, and performance improvements.

Download

To install from source, use cargo install jja.

New Features

  1. Enhanced Operators: jja::pgnfilt::Operator and jja::pgnfilt::LogicalOperator now implement Eq as well as PartialEq, enhancing the efficiency and reliability of comparisons.
  2. The Restore Command: To complement the dump command, a new restore command has been added. This command allows JSON serialized PolyGlot or BrainLearn file entries to be restored into the specified output file.
  3. SIGPIPE Handling: On UNIX systems, SIGPIPE handling has been fixed to prevent jja from panicking when the output is piped to another program like a pager.
  4. Find Learned Hash: The -z <HASH>, --hash=<HASH> option has been added to query PolyGlot opening books and BrainLearn experience files by Zobrist hash.
  5. BrainLearn Experience File Support: Read-only support for the BrainLearn experience file format has been added, with the subcommands info, dump, and find now able to handle files in this format.
  6. PolyGlot Key Lookup: The PolyGlot key lookup has been improved to enhance efficiency. The newly introduced public function polyglotbook::PolyGlotBook::read_book_key is used for this purpose.
  7. Binary File I/O Utilities: A new module jja::file has been introduced, which exports utilities for binary file i/o.

Improvements and Bug Fixes

  1. PolyGlot Compatible Zobrist Hashes: A critical fix has been implemented to calculate PolyGlot compatible Zobrist hashes with respect to en-passant legality.
  2. PolyGlot and CTG Book Handling: Significant improvements have been made in the management of PolyGlot and CTG books, resulting in breaking changes. This includes changes to functions, types, and member elements.
  3. Dependency Management: Several updates and changes have been made to dependencies. Some dependencies, such as chrono, have been dropped due to their unmaintained and insecure status, while others have been upgraded to their latest versions.
  4. En-Passant Mode Selection: The hash command now supports -e=<MODE>, --enpassant-mode=<MODE> to select the en-passant mode for Zobrist hash calculation.

Performance Optimizations

  1. Buffered Read/Write: Buffered read/write operations have been introduced when interacting with PolyGlot books, which greatly reduces the number of read/write system calls, thereby improving performance.
  2. Random Number Generator: The XorShift random number generator is now used to pick moves during book matches using the match command. Though this algorithm is not cryptographically secure, it is remarkably fast.
  3. CTG to PolyGlot Conversions: Most CTG to PolyGlot conversions have been made almost twice as fast due to performant implementation that uses less memory.

Breaking Changes

This new version brings several breaking changes. The adjustments to function names, member types, and the argument nature in several modules are intended to streamline the codebase and improve functionality. A few examples include changes to the polyglotbook::PolyglotBook::lookup_moves and jja::polyglot::entry_{from,to}_file functions, and alterations to the CtgBook::extract_all function's return type.
In conclusion, the new version 0.6.0 of jja brings many exciting features, performance improvements, and vital bug fixes to the table. Be sure to check out the full changelog for a detailed overview of all the changes.
As always, we appreciate the community's feedback and contributions, which help make jja a powerful tool for the community. Please feel free to explore this new version and share your experiences with us. Your feedback is invaluable to our continued improvement.