# Classic Lost Cities: three rounds, self-play.
#
# rollout_steps is deliberately shorter than a match. Early self-play stalls
# rounds badly (untrained matches run ~900 plies), and the env carries across
# updates, so a long match simply spans several rollouts -- the GAE truncation
# bootstrap keeps that unbiased. Sizing the scan to the worst-case match instead
# would blow up the rollout tensors, which are already doubled by training both
# seats and widened by the critic's 681-dim privileged view.
run:
  experiment_name: match-selfplay
  seed: 20260715
  learner_seat: 0
  total_updates: 300
  log_every: 10
  checkpoint_every: 50
  artifact_root: runs/jax-ppo-match

opponent:
  name: discard_only # unused: self-play

network:
  hidden_size: 512
  num_layers: 3

ppo:
  batch_games: 512
  rollout_steps: 256
  gamma: 1.0
  gae_lambda: 0.97 # a match is ~3x a round; 0.95 reaches too little of it
  clip_epsilon: 0.2
  entropy_coef: 0.01
  value_coef: 0.5
  max_grad_norm: 0.5
  learning_rate: 0.0003
  epochs: 4
  minibatches: 32

reward:
  terminal_scale: 50.0
  # Counted in learner actions now, not padded scan steps. Held slightly above
  # zero: the match-terminal signal alone is one bounded number per ~160 plies.
  potential_shaping_initial: 1.0
  potential_shaping_final: 0.05
  potential_shaping_anneal_steps: 20000000

evaluation:
  games: 2000
  duplicate: true
  shuffle_bank_seed: 20260715
  batch_games: 512
