Skip to content

feat: wire BUGGIFY_CONFIG into all DST subsystems for GEPA optimizer#16

Open
nerdsane wants to merge 1 commit intomainfrom
feat/gepa-multi-target-dst
Open

feat: wire BUGGIFY_CONFIG into all DST subsystems for GEPA optimizer#16
nerdsane wants to merge 1 commit intomainfrom
feat/gepa-multi-target-dst

Conversation

@nerdsane
Copy link
Owner

Summary

  • Wire BUGGIFY_CONFIG env var into all 4 DST subsystems so the GEPA optimizer can tune all 32 fault parameters with meaningful gradient signal
  • Previously only process.crash (1/32 knobs) had any effect on optimizer fitness — now all object store, disk, and replication fault knobs are exercised
  • Multi-target evaluator runs crash, streaming, WAL, and CRDT tests in sequence and aggregates fitness

Changes

Rust — 3 new from_env_or_default() methods

Config struct Fault keys Params
SimulatedStoreConfig object_store.* 8
SimulatedWalStoreConfig disk.* 5
CRDTDSTConfig replication.* 2

Rust — 3 new GEPA optimizer test entry points

Test file Test name Output
streaming_dst_test test_env_config_streaming GEPA_STREAMING_*
wal_dst_test test_env_config_wal GEPA_WAL_*
crdt_dst_test test_env_config_crdt GEPA_CRDT_*

Python — multi-target CargoDstEvaluator

Runs all 4 targets, aggregates fitness as equal-weight subscores.

Verification

With global_multiplier=2.0:

Metric Before After
Streaming PUT failures 2 18
WAL write failures 2 79
WAL sync/disk_full 0 38
CRDT message drops 67 914
Invariant violations 0 0

All 40 existing DST tests pass with zero regressions.

Test plan

  • cargo test --release --test streaming_dst_test (12 pass)
  • cargo test --release --test wal_dst_test (6 pass)
  • cargo test --release --test crdt_dst_test (16 pass)
  • cargo test --release --test dst_batch_verification (6 pass)
  • cargo clippy --release -p redis-sim -- -D warnings (0 warnings)
  • Verified with custom BUGGIFY_CONFIG env var across all 3 new tests

🤖 Generated with Claude Code

The DST optimizer previously only exercised process.crash (1 of 32
fault knobs) because each DST subsystem had its own isolated config.
This wires BUGGIFY_CONFIG env var into all 4 subsystems so the GA
can tune all 32 parameters with meaningful gradient signal.

Rust changes:
- SimulatedStoreConfig::from_env_or_default() reads object_store.* keys (8 params)
- SimulatedWalStoreConfig::from_env_or_default() reads disk.* keys (5 params)
- CRDTDSTConfig::from_env_or_default(seed) reads replication.* keys (2 params)
- FaultConfig::from_env_or_default() + parse_config_string() for env var parsing
- test_env_config_streaming/wal/crdt emit GEPA_* structured output

Python changes:
- CargoDstEvaluator runs all 4 test targets and aggregates fitness
- Per-subsystem result parsing (StreamingResult, WalResult, CrdtResult)
- Equal-weight fitness: 0.25 * crash + 0.25 * streaming + 0.25 * wal + 0.25 * crdt

Verified with global_multiplier=2.0:
- Streaming: PUT failures 2→18, GET failures 6→20
- WAL: write failures 2→79, sync failures 0→20, disk full 0→18
- CRDT: message drops 67→914
- All invariants hold (0 violations across all subsystems)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant