Logged

class coba.environments.Logged

Transform simulated interactions to logged interactions.

Constructors

__init__(learner: Learner, seed: float | None = 1.23) None

Instantiate a Logged filter.

Parameters:
  • learners – The learners that will be used as the logging policy. An environment will be created for every learner provided.

  • seed – The seed for used for all random number generation.

Remarks:

Adds ‘action’, ‘reward’, and ‘probability’ to interactions with ‘context’, ‘actions’, and ‘rewards’.

Methods

filter(interactions: Iterable[Interaction]) Iterable[Interaction]

Apply filter to an Environment’s interactions.

Attributes

params