Download scripts/pier_adapters.py from OpenMOSS-Team/SWE-bench-Science: direct link, hf CLI and curl.
- Browser
- Download file 567 Bytes
-
https://huggingface.co/datasets/OpenMOSS-Team/SWE-bench-Science/resolve/main/scripts/pier_adapters.py
- Command line
-
hf download hf://datasets/OpenMOSS-Team/SWE-bench-Science/scripts/pier_adapters.py
-
curl -L -o pier_adapters.py https://huggingface.co/datasets/OpenMOSS-Team/SWE-bench-Science/resolve/main/scripts/pier_adapters.py
567 Bytes
| #!/usr/bin/env python3 | |
| """Small runtime-only Pier adapters shared by all task images.""" | |
| from __future__ import annotations | |
| from pier.agents.installed.codex import Codex | |
| class ScienceBenchCodex(Codex): | |
| """Use npm's optional platform package when Pier installs Codex.""" | |
| def install_spec(self): | |
| spec = super().install_spec() | |
| for step in spec.steps: | |
| step.run = step.run.replace( | |
| "npm install -g @openai/codex", | |
| "npm install -g --include=optional @openai/codex", | |
| ) | |
| return spec | |