Skip to content

Enhancement - Add config.yaml for hyperparameters & settings #9

@Codex-Crusader

Description

@Codex-Crusader

Summary

Move hardcoded hyperparameters and runtime settings into a config.yaml (or config/default.yaml) and add a loader to read configuration at startup.

Motivation

A config file makes experiments reproducible and tuning easier without editing source files.

Acceptance criteria / Definition of Done

  • Add configs/default.yaml with clearly documented sections (training, mcts, model, selfplay, io paths).
  • Implement a small config loader (e.g., config.py) that:
    • Loads defaults from configs/default.yaml.
    • Allows overriding via CLI flags or environment variables.
  • Update scripts (run_train.sh, run_selfplay.sh, run_play.sh) to accept or point to the config file.
  • Document usage in README and provide one example config file committed to the repo.
  • Add a unit test that loads the config and verifies required keys exist.

Implementation notes

  • Use PyYAML (yaml.safe_load) or toml/json if preferred. Keep dependency footprint small.
  • Ensure backward compatibility — if config missing, fallback to current defaults.

Complexity

Low to Medium — great starter task for contributors.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions