GMM-based GA warm-starting from battle history #125

Closed
opened 2026-08-29 19:05:26 +02:00 by SirStone · 1 comment
Owner

What to build

Store historical enemy movement patterns across battles and use them to initialize the GA population, so that the GA converges faster and reaches higher peak fitness.

Currently initPopulationSeeded uses 75% random vectors on every battle start, wasting generations rediscovering patterns the bot has already seen.

Acceptance criteria

  • Historical EnemyState snapshots are persisted across battles
  • On battle start, if history exists, initPopulationSeeded initializes PopSize/4 seeds as centroid + N(0, 0.1 * covariance) perturbations
  • Remaining seeds are initialized randomly (fallback when no history)
  • Cold start (no history) behaves identically to current implementation
  • Fitness improvement visible within first 10 generations vs cold start
  • Existing when isMainModule self-checks still pass

Blocked by

None - can start immediately

Parent

Closes part of #118

## What to build Store historical enemy movement patterns across battles and use them to initialize the GA population, so that the GA converges faster and reaches higher peak fitness. Currently initPopulationSeeded uses 75% random vectors on every battle start, wasting generations rediscovering patterns the bot has already seen. ## Acceptance criteria - Historical EnemyState snapshots are persisted across battles - On battle start, if history exists, initPopulationSeeded initializes PopSize/4 seeds as centroid + N(0, 0.1 * covariance) perturbations - Remaining seeds are initialized randomly (fallback when no history) - Cold start (no history) behaves identically to current implementation - Fitness improvement visible within first 10 generations vs cold start - Existing when isMainModule self-checks still pass ## Blocked by None - can start immediately ## Parent Closes part of #118
SirStone added the ready-for-agent label 2026-08-29 19:05:49 +02:00
Author
Owner

Implemented in commit a730a9e

Summary: Added GMM-based GA warm-starting from battle history. initPopulationSeeded now seeds PopSize/4 individuals from historical enemy movement patterns (centroid + covariance-based perturbations). Remaining seeds are random. Cold start (no history) behaves identically to prior implementation.

Files:

  • vapourbot_garage/src/vapourbot/ga.nim - initPopulationSeeded(), history persistence logic
Implemented in commit a730a9e **Summary:** Added GMM-based GA warm-starting from battle history. initPopulationSeeded now seeds PopSize/4 individuals from historical enemy movement patterns (centroid + covariance-based perturbations). Remaining seeds are random. Cold start (no history) behaves identically to prior implementation. **Files:** - `vapourbot_garage/src/vapourbot/ga.nim` - initPopulationSeeded(), history persistence logic
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SirStone/SirRoboGarage#125