facebookresearch / facebookresearch/MLGym
Decouple containerization logic from environment
- Dominant language
- Python
- Stars
- 622
- Forks
- 59
- PR merge metrics
- No merged PRs in 30d
Description
### Describe the feature
In the current codebase, `communicate` and `read` methods are part of the environment submodule. This increases the complexity of the environment codebase and limits extensibility when supporting different types of containers.
The proposal is to move the containerization logic to a new module and provide abstract implementations for new container types. It is also worth exploring the use of [SWE-Rex](https://github.com/SWE-agent/SWE-ReX), although it is unclear whether they support GPU passthrough.
### Potential Solutions
One potential solution:
1. Create a `containers` module in `mlgym` package.
2. Move `communicate`, `communicate_with_handling`, `read_with_timeout`, `interrupt`, and other communication-related functions to the new `containers` module.
3. If possible, create an abstraction for adding new containers.
Contributor guide
Research direction
Locate the mlgym environment submodule and inspect communicate, communicate_with_handling, read_with_timeout, interrupt, read, and related communication functions. Review the existing environment tests or callers before deciding the container boundary. Done means the communication logic is owned by a new containers module and the proposed container abstraction is validated without breaking current behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- infrastructure
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100