gyx v0.1.1 Gyx.Core.Env behaviour
This behaviour is intended to be followed for any Environment
implementation
The most critical function to be exposed is step/1
, which serves as a direct bridge
between the environment and any agent.
Here, an important design question to address is the fundamental difference between the environment state (its internal representation) and an observation of such state.
In principle, the environment returns an observation as part of step/1 response.
Should it be a way to obtain an evironment state abstraction as suposed to be shown to an agent? i.e. an indirect observation.
Link to this section Summary
Callbacks
Gets an environment representation usable by the agent
Sets the state of the environment to its default
Recieves an agent's action
and responds to it,
informing the agent back with a reward, a modified environment
and a termination signal
Link to this section Types
action()
action() :: any()
action() :: any()
environment()
environment() :: any()
environment() :: any()
initial_state()
initial_state() :: Gyx.Core.Exp.t()
initial_state() :: Gyx.Core.Exp.t()
observation()
observation() :: any()
observation() :: any()
Link to this section Callbacks
observe(environment)
observe(environment()) :: observation()
observe(environment()) :: observation()
Gets an environment representation usable by the agent
reset(environment)
reset(environment()) :: initial_state()
reset(environment()) :: initial_state()
Sets the state of the environment to its default
step(environment, action)
step(environment(), action()) ::
Gyx.Core.Exp.t() | {:error, reason :: String.t()}
step(environment(), action()) :: Gyx.Core.Exp.t() | {:error, reason :: String.t()}
Recieves an agent's action
and responds to it,
informing the agent back with a reward, a modified environment
and a termination signal