Spaces:
Sleeping
Sleeping
Download scenario_compiler.py from Humanlearning/Cyber_analyst-round1: direct link, hf CLI and curl.
- Browser
- Download file 680 Bytes
-
https://huggingface.co/spaces/Humanlearning/Cyber_analyst-round1/resolve/main/scenario_compiler.py
- Command line
-
hf download hf://spaces/Humanlearning/Cyber_analyst-round1/scenario_compiler.py
-
curl -L -o scenario_compiler.py https://huggingface.co/spaces/Humanlearning/Cyber_analyst-round1/resolve/main/scenario_compiler.py
680 Bytes
| """Compatibility facade for deterministic scenario compilation.""" | |
| from __future__ import annotations | |
| from typing import Any | |
| try: | |
| from .server.scenario_factory import ScenarioFactory | |
| except ImportError: # pragma: no cover | |
| from server.scenario_factory import ScenarioFactory | |
| def compile_scenario( | |
| seed: int, | |
| split: str = "train", | |
| difficulty: int = 0, | |
| curriculum_profile: dict[str, Any] | None = None, | |
| ) -> dict[str, Any]: | |
| """Compile one isolated authorization-repair scenario.""" | |
| return ScenarioFactory().compile_scenario( | |
| seed, | |
| split=split, | |
| difficulty=difficulty, | |
| curriculum_profile=curriculum_profile, | |
| ) | |