Skip to content

Passed seed through to word selection #100

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

shannonsands
Copy link

Description

Updating the Hangman env to deterministically set the word for an episode

Motivation and Context

Makes testing easier since you can use a consistent seed with a know result
Useful for trainers with multiple rollouts since you can reset envs consistently

Types of changes

What types of changes does your code introduce? Put an x in all the boxes that apply:

  • Bug fix (non-breaking change which fixes an issue)
  • New game (adds a new game to TextArena)
  • Game enhancement (improves an existing game)
  • New feature (non-breaking change which adds core functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (update in the documentation)
  • Refactoring (code improvement without changing functionality)

Game-specific changes

If your PR adds or modifies a game, please specify:

  • Game affected: Hangman
  • Changes to game mechanics: No
  • Changes to game UI/rendering: No
  • Changes to game judging/rules: No

Implementation Details

  • Subtask 1 - updated _generate_board to optionally accept the seed and use it in word selection
  • Subtask 2
  • Subtask 3

Testing

Loaded the env in a local script, passed the seed. No extensive testing really required, it's a simple change

Checklist

Go over all the following points, and put an x in all the boxes that apply.
If you are unsure about any of these, don't hesitate to ask. We are here to help!

  • I have read the contribution guidelines. (required)
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes. (required for bug fixes or new features) (didn't see any for Hangman)
  • All new and existing tests passed.
  • For game changes, I have verified that the game still runs correctly end-to-end.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant