OpenEnv: Agentic Execution Environments#
A unified framework for building, deploying, and interacting with isolated execution environments for agentic reinforcement learning—powered by simple, Gymnasium-style APIs.
Training RL agents—especially in agentic settings like code generation, web browsing, or game playing—requires environments that are:
Familiar step(), reset(), and state() interface for seamless integration with existing RL frameworks.
Package environments as containers for consistent, reproducible deployments across any infrastructure.
Deploy environments as HTTP services for distributed training and remote execution.
Run untrusted agent code safely with sandboxed execution environments.
Pre-built environments for games, coding, web browsing, and more.
Powerful command-line interface for environment management and deployment.
Getting Started#
New to OpenEnv? Follow our recommended learning path:
Getting Started Series — A 5-part series covering what OpenEnv is, how to use and build environments, and how to contribute. No GPU required.
Build Your Own Environment — The complete reference guide for creating, packaging, and deploying custom environments with Docker and Hugging Face Hub.
Simulation vs Production Mode — Understand when to use the training loop, when to expose MCP directly, and how tools behave in each mode.
MCP Environment Lifecycle — Understand how MCP tools fit into the OpenEnv step loop, when
step_async()is used, and when to usecall_tool()versusstep(...).Explore Environments — Browse pre-built environments for games, coding, web browsing, and more.
How Can I Contribute?#
We welcome contributions from the community! If you find a bug, have a feature request, or want to contribute a new environment, please open an issue or submit a pull request. The repository is hosted on GitHub at meta-pytorch/OpenEnv.
Warning
OpenEnv is currently in an experimental stage. You should expect bugs, incomplete features, and APIs that may change in future versions. The project welcomes bug fixes, but to ensure coordination, please discuss significant changes before starting work. Signal your intention to contribute in the issue tracker by filing a new issue or claiming an existing one.