|
30 | 30 | from agentlab.utils.hinting import HintsSource |
31 | 31 |
|
32 | 32 |
|
33 | | - |
34 | 33 | logger = logging.getLogger(__name__) |
35 | 34 | logger.setLevel(logging.INFO) |
36 | 35 |
|
|
84 | 83 | def action_from_generalized_bgym_action_tool( |
85 | 84 | response: LLMOutput, tool_name: str = "perform_action" |
86 | 85 | ) -> tuple[str | None, str | None]: |
87 | | - |
88 | 86 | """Extract the action string from the tool call in the LLM response.""" |
89 | 87 | action, think = None, None |
90 | 88 | if response.tool_calls is not None: |
@@ -284,7 +282,6 @@ def apply( |
284 | 282 | discussion, obs["last_action"], self._last_observation |
285 | 283 | ) |
286 | 284 |
|
287 | | - |
288 | 285 | obs_msg.add_image(image_to_png_base64_url(screenshot)) |
289 | 286 | if self.use_axtree: |
290 | 287 | obs_msg.add_text(f"AXTree:\n{AXTREE_NOTE}\n{obs['axtree_txt']}") |
@@ -685,8 +682,8 @@ def get_action(self, obs: Any) -> float: |
685 | 682 | action_subsets=("coord",), |
686 | 683 | keep_last_n_obs=5, # max 20 no more than 20 screenshots for claude |
687 | 684 | multiaction=True, |
688 | | - use_noop_as_default_action = False, |
689 | | - use_generalized_bgym_action_tool = True |
| 685 | + use_noop_as_default_action=False, |
| 686 | + use_generalized_bgym_action_tool=True, |
690 | 687 | ) |
691 | 688 |
|
692 | 689 |
|
|
0 commit comments