diff options
| author | CaptainJack2491 <jayrupnakawala@gmail.com> | 2026-03-02 15:58:19 +0000 |
|---|---|---|
| committer | CaptainJack2491 <jayrupnakawala@gmail.com> | 2026-03-02 15:58:19 +0000 |
| commit | 80f4f96758a1ba45c13361c2f87bff6fa7de8fe2 (patch) | |
| tree | 27c5018912488ee317d814b8510eaf1ad03fae10 /src | |
| parent | 0076f857cccc402519b9751f4aeb174ccb87824f (diff) | |
fix: global oversight_levels now filters scenario-available levels
Previously a scenario with its own oversight/ directory would ignore
the global oversight_levels config. Now the global list acts as a
filter — only levels present in BOTH the scenario dir AND the global
config are run. Warns if no levels match.
Diffstat (limited to 'src')
| -rw-r--r-- | src/runner.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/runner.py b/src/runner.py index d856ed6..f636d7f 100644 --- a/src/runner.py +++ b/src/runner.py @@ -42,8 +42,15 @@ class ExperimentRunner: skipped_runs = 0 for model_config in self.config.models: for scenario_config in self.config.scenarios: - # Use per‑scenario oversight levels if defined, otherwise fall back to global list - oversight_levels = scenario_config.oversight_levels or self.config.oversight_levels + # Scenario may define available oversight levels (from oversight/ dir). + # Global oversight_levels in config acts as a FILTER on what actually runs. + available = scenario_config.oversight_levels or self.config.oversight_levels + global_filter = self.config.oversight_levels + oversight_levels = [lvl for lvl in available if lvl in global_filter] + if not oversight_levels: + logger.warning(f"No matching oversight levels for {scenario_config.path}. " + f"Available: {available}, Config filter: {global_filter}") + continue for oversight_level in oversight_levels: runs, skipped = self._run_combo(model_config, scenario_config, oversight_level) total_runs += runs |
