You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This PR is a re-submission of #185 .
The previous PR was closed only to move the changes to a dedicated fix branch.
No functional changes compared to the original PR.
Description
Fixed a bug in WordleEnv.step where player actions were incorrectly attributed to the GAME_ID. This caused the observation logs to display [GAME] for player guesses instead of [Player].
Changes
Explicitly pass from_id=player_id in add_observation when recording PLAYER_ACTION.
Comparison
Before:
[GAME] [planets]
[GAME] You submitted [planets].
After:
[Player] [planets]
[GAME] You submitted [planets].
Ready to merge. Confirmed the PLAYER_ACTION observation was omitting from_id, so it defaulted to GAME_ID and the guess was logged as [GAME] instead of [Player]. Passing from_id=player_id fixes the attribution. It's a broadcast observation, so there's no gameplay change — logging/attribution only.
Minor nit (non-blocking): the explicit to_id=-1 just restates the existing default.
Verified. add_observation defaults from_id=GAME_ID (-1), so the player's own guess was being logged as coming from GAME rather than from the player; passing from_id=player_id attributes it correctly, and to_id=-1 matches the existing broadcast default. Correct one-line fix.
LGTM, recommend merge.
Heads-up on overlap: #169 also edits Wordle/env.py (an unrelated constructor redesign toward word_lengths). This attribution fix is orthogonal to that change, so whichever lands second may just need a trivial rebase.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is a re-submission of #185 .
The previous PR was closed only to move the changes to a dedicated fix branch.
No functional changes compared to the original PR.
Description
Fixed a bug in WordleEnv.step where player actions were incorrectly attributed to the
GAME_ID. This caused the observation logs to display[GAME]for player guesses instead of[Player].Changes
Explicitly pass
from_id=player_idinadd_observationwhen recording PLAYER_ACTION.Comparison
Before:
After: