feat: update optimization defaults for viable CMA-ES convergence

- generations: 20 -> 200 (need at least 200 for high-dim search)
- population_size: 8 -> 64 (was far below CMA-ES recommendation)
- Add pca_dimensions: 128 for dimensionality reduction
- Add use_diagonal_cma: true for sep-CMA-ES variant
- Add cache_fitness: true to avoid redundant API calls

Previous defaults (popsize=8, gen=20) gave only 160 evaluations,
which is ~1% of the theoretical minimum needed for convergence.
This commit is contained in:
kigland
2026-03-08 15:06:46 +08:00
parent 689a85a3bd
commit 2208e255b8
+7 -3
View File
@@ -9,7 +9,11 @@ openai:
api_key: "env"
optimization:
surrogate_model: "microsoft/phi-2"
surrogate_model: "microsoft/phi-2" # keep for now, will be made configurable
trigger_length: 15
generations: 20
population_size: 8
generations: 200 # was 20, need at least 200 for any convergence
population_size: 64 # was 8, need at least 64 for high-dim search
sigma: 0.5
pca_dimensions: 128 # NEW: PCA reduction target dimensions
use_diagonal_cma: true # NEW: use sep-CMA-ES for high-dimensional efficiency
cache_fitness: true # NEW: cache token_ids -> fitness to avoid redundant API calls