mirror of
https://github.com/OpenHands/OpenHands.git
synced 2025-12-26 05:48:36 +08:00
* docs(docs): start implementing docs website * update video url * add autogenerated codebase docs for backend * precommit * update links * fix config and video * gh actions * rename * workdirs * path * path * fix doc1 * redo markdown * docs * change main folder name * simplify readme * add back architecture * Fix lint errors * lint * update poetry lock --------- Co-authored-by: Jim Su <jimsu@protonmail.com>
50 lines
713 B
Markdown
50 lines
713 B
Markdown
---
|
|
sidebar_label: base
|
|
title: opendevin.observation.base
|
|
---
|
|
|
|
## Observation Objects
|
|
|
|
```python
|
|
@dataclass
|
|
class Observation()
|
|
```
|
|
|
|
This data class represents an observation of the environment.
|
|
|
|
#### to\_dict
|
|
|
|
```python
|
|
def to_dict() -> dict
|
|
```
|
|
|
|
Converts the observation to a dictionary and adds user message.
|
|
|
|
#### to\_memory
|
|
|
|
```python
|
|
def to_memory() -> dict
|
|
```
|
|
|
|
Converts the observation to a dictionary.
|
|
|
|
#### message
|
|
|
|
```python
|
|
@property
|
|
def message() -> str
|
|
```
|
|
|
|
Returns a message describing the observation.
|
|
|
|
## NullObservation Objects
|
|
|
|
```python
|
|
@dataclass
|
|
class NullObservation(Observation)
|
|
```
|
|
|
|
This data class represents a null observation.
|
|
This is used when the produced action is NOT executable.
|
|
|