gym-http-api-0.1.0.1: REST client to the gym-http-api project

LicenseMIT
Stabilityexperimental
Portabilitynon-portable
Safe HaskellNone
LanguageHaskell2010

OpenAI.Gym.Data

Description

Aeson-based data types to be returned by OpenAI.Gym.API

Synopsis

Documentation

data GymEnv #

Classic Control Environments

Constructors

CartPoleV0

Balance a pole on a cart (for a short time).

CartPoleV1

Balance a pole on a cart.

AcrobotV1

Swing up a two-link robot.

MountainCarV0

Drive up a big hill.

MountainCarContinuousV0

Drive up a big hill with continuous control.

PendulumV0

Swing up a pendulum.

FrozenLakeV0

Swing up a pendulum.

PongRamV0

Maximize score in the game Pong, with RAM as input

PongV0

Maximize score in the game Pong

Instances
Enum GymEnv # 
Instance details

Defined in OpenAI.Gym.Data

Eq GymEnv # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: GymEnv -> GymEnv -> Bool #

(/=) :: GymEnv -> GymEnv -> Bool #

Ord GymEnv # 
Instance details

Defined in OpenAI.Gym.Data

Show GymEnv # 
Instance details

Defined in OpenAI.Gym.Data

ToJSON GymEnv # 
Instance details

Defined in OpenAI.Gym.Data

newtype InstID #

a short identifier (such as '3c657dbc') for the created environment instance. The instance_id is used in future API calls to identify the environment to be manipulated.

Constructors

InstID 

Fields

Instances
Eq InstID # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: InstID -> InstID -> Bool #

(/=) :: InstID -> InstID -> Bool #

Show InstID # 
Instance details

Defined in OpenAI.Gym.Data

Generic InstID # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep InstID :: * -> * #

Methods

from :: InstID -> Rep InstID x #

to :: Rep InstID x -> InstID #

ToJSON InstID # 
Instance details

Defined in OpenAI.Gym.Data

FromJSON InstID # 
Instance details

Defined in OpenAI.Gym.Data

ToHttpApiData InstID # 
Instance details

Defined in OpenAI.Gym.Data

type Rep InstID # 
Instance details

Defined in OpenAI.Gym.Data

type Rep InstID = D1 (MetaData "InstID" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" True) (C1 (MetaCons "InstID" PrefixI True) (S1 (MetaSel (Just "getInstID") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text)))

newtype Environment #

a mapping of instance_id to env_id (e.g. {'3c657dbc': 'CartPole-v0'}) for every env on the server

Constructors

Environment 
Instances
Eq Environment # 
Instance details

Defined in OpenAI.Gym.Data

Show Environment # 
Instance details

Defined in OpenAI.Gym.Data

Generic Environment # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Environment :: * -> * #

ToJSON Environment # 
Instance details

Defined in OpenAI.Gym.Data

FromJSON Environment # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Environment # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Environment = D1 (MetaData "Environment" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" True) (C1 (MetaCons "Environment" PrefixI True) (S1 (MetaSel (Just "all_envs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (HashMap Text Text))))

newtype Observation #

The agent's observation of the current environment

Constructors

Observation 
Instances
Eq Observation # 
Instance details

Defined in OpenAI.Gym.Data

Show Observation # 
Instance details

Defined in OpenAI.Gym.Data

Generic Observation # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Observation :: * -> * #

ToJSON Observation # 
Instance details

Defined in OpenAI.Gym.Data

FromJSON Observation # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Observation # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Observation = D1 (MetaData "Observation" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" True) (C1 (MetaCons "Observation" PrefixI True) (S1 (MetaSel (Just "getObservation") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Value)))

data Step #

An action to take in the environment and whether or not to render that change

Constructors

Step 

Fields

Instances
Eq Step # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: Step -> Step -> Bool #

(/=) :: Step -> Step -> Bool #

Show Step # 
Instance details

Defined in OpenAI.Gym.Data

Methods

showsPrec :: Int -> Step -> ShowS #

show :: Step -> String #

showList :: [Step] -> ShowS #

Generic Step # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Step :: * -> * #

Methods

from :: Step -> Rep Step x #

to :: Rep Step x -> Step #

ToJSON Step # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Step # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Step = D1 (MetaData "Step" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" False) (C1 (MetaCons "Step" PrefixI True) (S1 (MetaSel (Just "action") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Value) :*: S1 (MetaSel (Just "render") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Bool)))

data Outcome #

The result of taking a step in an environment

Constructors

Outcome 

Fields

  • observation :: !Value

    agent's observation of the current environment

  • reward :: !Double

    amount of reward returned after previous action

  • done :: !Bool

    whether the episode has ended

  • info :: !Object

    a dict containing auxiliary diagnostic information

Instances
Eq Outcome # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: Outcome -> Outcome -> Bool #

(/=) :: Outcome -> Outcome -> Bool #

Show Outcome # 
Instance details

Defined in OpenAI.Gym.Data

Generic Outcome # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Outcome :: * -> * #

Methods

from :: Outcome -> Rep Outcome x #

to :: Rep Outcome x -> Outcome #

ToJSON Outcome # 
Instance details

Defined in OpenAI.Gym.Data

FromJSON Outcome # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Outcome # 
Instance details

Defined in OpenAI.Gym.Data

newtype Info #

A dict containing auxiliary diagnostic information

Constructors

Info 

Fields

Instances
Eq Info # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: Info -> Info -> Bool #

(/=) :: Info -> Info -> Bool #

Show Info # 
Instance details

Defined in OpenAI.Gym.Data

Methods

showsPrec :: Int -> Info -> ShowS #

show :: Info -> String #

showList :: [Info] -> ShowS #

Generic Info # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Info :: * -> * #

Methods

from :: Info -> Rep Info x #

to :: Rep Info x -> Info #

ToJSON Info # 
Instance details

Defined in OpenAI.Gym.Data

FromJSON Info # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Info # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Info = D1 (MetaData "Info" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" True) (C1 (MetaCons "Info" PrefixI True) (S1 (MetaSel (Just "getInfo") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Object)))

newtype Action #

An action to take in the environment

Constructors

Action 

Fields

Instances
Eq Action # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: Action -> Action -> Bool #

(/=) :: Action -> Action -> Bool #

Show Action # 
Instance details

Defined in OpenAI.Gym.Data

Generic Action # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Action :: * -> * #

Methods

from :: Action -> Rep Action x #

to :: Rep Action x -> Action #

ToJSON Action # 
Instance details

Defined in OpenAI.Gym.Data

FromJSON Action # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Action # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Action = D1 (MetaData "Action" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" True) (C1 (MetaCons "Action" PrefixI True) (S1 (MetaSel (Just "getAction") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Value)))

data Monitor #

Parameters used to start a monitoring session.

Constructors

Monitor 

Fields

  • directory :: !Text

    directory to use for monitoring

  • force :: !Bool

    Clear out existing training data from this directory (by deleting every file prefixed with "openaigym.") (default=False)

  • resume :: !Bool

    Retain the training data already in this directory, which will be merged with our new data. (default=False)

  • video_callable :: !Bool

    video_callable parameter from the native env.monitor.start function

Instances
Eq Monitor # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: Monitor -> Monitor -> Bool #

(/=) :: Monitor -> Monitor -> Bool #

Show Monitor # 
Instance details

Defined in OpenAI.Gym.Data

Generic Monitor # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Monitor :: * -> * #

Methods

from :: Monitor -> Rep Monitor x #

to :: Rep Monitor x -> Monitor #

ToJSON Monitor # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Monitor # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Monitor = D1 (MetaData "Monitor" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" False) (C1 (MetaCons "Monitor" PrefixI True) ((S1 (MetaSel (Just "directory") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: S1 (MetaSel (Just "force") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Bool)) :*: (S1 (MetaSel (Just "resume") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Bool) :*: S1 (MetaSel (Just "video_callable") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Bool))))

data Config #

Parameters used to upload a monitored session to OpenAI's servers

Constructors

Config 

Fields

  • training_dir :: !Text

    A directory containing the results of a training run.

  • algorithm_id :: !Text

    An arbitrary string indicating the paricular version of the algorithm (including choices of parameters) you are running. (default=None)

  • api_key :: !Text

    Your OpenAI API key

Instances
Eq Config # 
Instance details

Defined in OpenAI.Gym.Data

Methods

(==) :: Config -> Config -> Bool #

(/=) :: Config -> Config -> Bool #

Show Config # 
Instance details

Defined in OpenAI.Gym.Data

Generic Config # 
Instance details

Defined in OpenAI.Gym.Data

Associated Types

type Rep Config :: * -> * #

Methods

from :: Config -> Rep Config x #

to :: Rep Config x -> Config #

ToJSON Config # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Config # 
Instance details

Defined in OpenAI.Gym.Data

type Rep Config = D1 (MetaData "Config" "OpenAI.Gym.Data" "gym-http-api-0.1.0.1-GBHZzBvJwr3LixGOqfeVcJ" False) (C1 (MetaCons "Config" PrefixI True) (S1 (MetaSel (Just "training_dir") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: (S1 (MetaSel (Just "algorithm_id") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text) :*: S1 (MetaSel (Just "api_key") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text))))