-
Couldn't load subscription status.
- Fork 50
Rename models.py to types.py across all environments #43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Hi @Copilot! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
Co-authored-by: Darktex <890615+Darktex@users.noreply.github.com>
Co-authored-by: Darktex <890615+Darktex@users.noreply.github.com>
|
lets avoid using types.py in general because of conflicting imports that might happen with python std types. Like: |
|
@copilot Propose 5 names to use instead of |
Here are 5 alternative names to replace
My recommendation: |
Problem
The file name
models.pyin environment directories was causing confusion, as readers typically expect "models" to refer to machine learning models (neural networks, transformers, etc.). However, these files actually contain data type definitions - dataclasses forAction,Observation, andStatetypes used by each environment.Solution
Renamed all
models.pyfiles totypes.pyacross all environments to better reflect their actual purpose. The name "types" clearly indicates these files contain type definitions and is understood by both AI/ML and infrastructure engineers.Changes
Files Renamed
src/envs/atari_env/models.py→types.pysrc/envs/coding_env/models.py→types.pysrc/envs/echo_env/models.py→types.pysrc/envs/chat_env/models.py→types.pysrc/envs/openspiel_env/models.py→types.pyUpdated References
.modelsto.types(34 files total)Why "types"?
The name
types.pywas chosen because:core/types.py)Testing
Example Usage (unchanged)
The API remains exactly the same for users:
Users import from the environment package (
envs.echo_env), so the internal file rename is transparent to them.Original prompt
Fixes #42
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.