Skip to content

Clarify what is ObsType: is it the type for a single observation, or a list of observations? #198

@etnbrd

Description

@etnbrd

When reading the Env implementation and the documentation, it's unclear if ObsType should be a single observation or a list of observations.

The EnvStepOutput type have a field observations (plural) typed ObsType:

observations: ObsType

At the same time, the step method documents that it returns observation (singular):
observation (ObsType): The resulting observation after executing the action.

In the BaseTextEnv implementation Env is initialised with ObsType being a str:

class BaseTextEnv(Env[str, str]):

But the step methods return List[Dict[str, str]] in the observations field:
observations: List[Dict[str, str]] # OpenAI API Messages Format

I'd be happy to provide a PR to unify these types and documentation, but I'm not sure what ObsType should contain.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions