Aller directement au contenu principal

openhands.events.observation.commands

CmdOutputMetadata Objects

class CmdOutputMetadata(BaseModel)

Additional metadata captured from PS1

prefix

Prefix to add to command output

suffix

Suffix to add to command output

to_ps1_prompt

@classmethod
def to_ps1_prompt(cls) -> str

Convert the required metadata into a PS1 prompt.

from_ps1_match

@classmethod
def from_ps1_match(cls, match: re.Match[str]) -> Self

Extract the required metadata from a PS1 prompt.

CmdOutputObservation Objects

@dataclass
class CmdOutputObservation(Observation)

This data class represents the output of a command.

IPythonRunCellObservation Objects

@dataclass
class IPythonRunCellObservation(Observation)

This data class represents the output of a IPythonRunCellAction.