Skip to content

Latest commit

 

History

History
39 lines (30 loc) · 1.5 KB

File metadata and controls

39 lines (30 loc) · 1.5 KB

AGENTS.md

This repository contains training data stats collection script for the Leela Chess Zero project.

  • Python code is located in the src/ directory.
  • C++ code is located in the csrc/ directory.

The build system for C++ code is meson. During development, the project is built in the builddir/.

Testing and Building

  • Build: meson compile -C builddir/ from build directory for debug build or just build for release build (located in build/release).
  • Format code: just format
  • We use Google C++ style guide.
    • That means 80 columns.
    • That means comments should be in full sentences with periods in the end.
    • When conditional or loop fits one line, it must be written as one line without braces, for example: if (condition) return value;
    • Prefer absl to std (e.g. absl::c_ algorithms, absl::Mutex, absl::StrCat, etc.). Prefer absl::flat_hash_map (or absl::btree_map if we need ordered keys) to std::unordered_map or std::map.
  • We use uv for Python package and venv management, and to running the application.
  • To test it, build using just build run build/release/trainingdata-stats --input_tar=/home/crem/tmp/2025-11/training-run2-test91-20251108-1317.tar --run=t90

IMPORTANT

  • NEVER add # type: ignore or other ways to mask/silence errors instead of fixing them.
  • Rely on protobuf default values. DO NOT write code like config.has_foo() ? config.foo() : default_value;

Documentation

  • Documentation is in the spec/ directory.