stable-baselines3 icon indicating copy to clipboard operation
stable-baselines3 copied to clipboard

[Feature Request] Add support for gymnasium.spaces.Text

Open jvasso opened this issue 2 years ago • 1 comments

🚀 Feature

Unless I'm mistaken, stable-baselines3 only supports Box, Discrete, MultiDiscrete, MultiBinary and Dict spaces from gymnasium. It seems like a new fundamental space has been introduced in Gymnasium ( gymnasium.spaces.Text ), which seems to be a more natural way to deal with text data.

Motivation

This new support would ease the training of LLMs with RL.

Pitch

No response

Alternatives

One alternative is to use gymnasium.spaces.Box(low=0, high=vocab_size-1, dtype=np.int). However this requires padding to support smaller texts.

Additional context

No response

Checklist

  • [X] I have checked that there is no similar issue in the repo
  • [X] If I'm requesting a new feature, I have proposed alternatives

jvasso avatar Oct 02 '23 17:10 jvasso

If I'm requesting a new feature, I have proposed alternatives

araffin avatar Oct 02 '23 17:10 araffin