mirror of
https://github.com/All-Hands-AI/OpenHands.git
synced 2026-01-10 07:18:10 -05:00
* refactor actions and events * remove type_key * remove stream * move import * move import * fix NullObs * reorder imports * fix lint * fix dataclasses * remove blank fields * fix nullobs * fix sidebar labels * fix test compilation * switch to asdict * lint * fix whitespace * fix executable * delint * fix run * remove NotImplementeds * fix path prefix * remove null files * add debug * add more debug info * fix dataclass on null * remove debug * revert sandbox * fix merge issues * fix tyeps * Update opendevin/events/action/browse.py
27 lines
801 B
Python
27 lines
801 B
Python
from dataclasses import dataclass, field
|
|
from typing import Dict, List, Tuple
|
|
|
|
from opendevin.events.action import (
|
|
Action,
|
|
)
|
|
from opendevin.events.observation import (
|
|
CmdOutputObservation,
|
|
Observation,
|
|
)
|
|
from opendevin.plan import Plan
|
|
|
|
|
|
@dataclass
|
|
class State:
|
|
plan: Plan
|
|
iteration: int = 0
|
|
# number of characters we have sent to and received from LLM so far for current task
|
|
num_of_chars: int = 0
|
|
background_commands_obs: List[CmdOutputObservation] = field(
|
|
default_factory=list)
|
|
history: List[Tuple[Action, Observation]] = field(default_factory=list)
|
|
updated_info: List[Tuple[Action, Observation]
|
|
] = field(default_factory=list)
|
|
inputs: Dict = field(default_factory=dict)
|
|
outputs: Dict = field(default_factory=dict)
|