Skip to content

Commit 14f9914

Browse files
committed
Refactor Obs class to adjust webpage usage settings and add TODO for mouse pointer integration
1 parent cb585a8 commit 14f9914

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/agentlab/agents/tool_use_agent/multi_tool_agent.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ class Obs(Block):
7878
use_som: bool = False
7979
use_tabs: bool = False
8080
add_mouse_pointer: bool = True
81-
use_zoomed_webpage: bool = False
81+
use_zoomed_webpage: bool = False
8282

8383
def apply(
8484
self, llm, messages: list[MessageBuilder], obs: dict, last_llm_output: LLMOutput
@@ -102,6 +102,7 @@ def apply(
102102
screenshot = obs["screenshot"]
103103

104104
if self.add_mouse_pointer:
105+
# TODO this mouse pointer should be added at the browsergym level
105106
screenshot = np.array(
106107
agent_utils.add_mouse_pointer_from_action(
107108
Image.fromarray(obs["screenshot"]), obs["last_action"]
@@ -346,8 +347,8 @@ def get_action(self, obs: Any) -> float:
346347
obs=Obs(
347348
use_last_error=True,
348349
use_screenshot=True,
349-
use_axtree=True,
350-
use_dom=False,
350+
use_axtree=False,
351+
use_dom=True,
351352
use_som=False,
352353
use_tabs=False,
353354
),

0 commit comments

Comments
 (0)