Skip to content

Commit d2d59bc

Browse files
more black
1 parent 532047a commit d2d59bc

File tree

3 files changed

+9
-11
lines changed

3 files changed

+9
-11
lines changed

experiments/run_osworld.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,9 @@
22
import logging
33
import os
44

5-
from tapeagents import agent
6-
7-
from agentlab.agents.tool_use_agent.tool_use_agent import OSWORLD_CLAUDE, OSWORLD_OAI
5+
from agentlab.agents.tool_use_agent.tool_use_agent import OSWORLD_CLAUDE
86
from agentlab.benchmarks.osworld import OsworldBenchmark
9-
from agentlab.experiments.study import make_study, Study
7+
from agentlab.experiments.study import Study, make_study
108

119
fmt = "%(asctime)s - %(levelname)s - %(name)s:%(lineno)d - %(funcName)s() - %(message)s"
1210
logging.basicConfig(level=logging.INFO, force=True, format=fmt, handlers=[logging.StreamHandler()])
@@ -20,6 +18,7 @@ def get_most_recent_incomplete_study() -> Study:
2018
study.find_incomplete(include_errors=True)
2119
return study
2220

21+
2322
def get_task_ids() -> set[str]:
2423
with open("experiments/osworld_debug_task_ids.json", "r") as f:
2524
task_ids = json.load(f)
@@ -32,13 +31,15 @@ def main():
3231
relaunch = True
3332
agent_args = [
3433
OSWORLD_CLAUDE,
35-
# OSWORLD_OAI # performs poorly.
36-
] # type: ignore
34+
# OSWORLD_OAI # performs poorly.
35+
] # type: ignore
3736
parallel_backend = "ray"
3837
os.environ["AGENTLAB_DEBUG"] = os.environ.get("AGENTLAB_DEBUG", "1")
3938

4039
study = make_study(
41-
benchmark=OsworldBenchmark(test_set_name="test_small.json"), # or test_all.json (Exper) # type: ignore
40+
benchmark=OsworldBenchmark(
41+
test_set_name="test_small.json"
42+
), # or test_all.json (Exper) # type: ignore
4243
agent_args=agent_args, # type: ignore
4344
comment="osworld debug 2",
4445
logging_level=logging.INFO,

src/agentlab/benchmarks/osworld.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -733,7 +733,7 @@ def model_post_init(self, __context: Any) -> None:
733733

734734
def fix_settings_file_path_in_config(self, task: dict) -> dict:
735735
"""Fix the settings file path in the task configuration.
736-
736+
737737
Args:
738738
task: Task configuration dictionary.
739739

tests/benchmarks/test_osworld.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
import tempfile
32
from pathlib import Path
43
from unittest.mock import patch
@@ -12,7 +11,6 @@
1211
)
1312

1413

15-
1614
def mock_task_config() -> dict:
1715
"""Mock task configuration for testing."""
1816
return {
@@ -282,4 +280,3 @@ def test_convert_agentlab_action_to_computer_13(self):
282280
result = gym.convert_agentlab_action_to_computer_13('typing(text="hello")')
283281
expected = {"action_type": "TYPING", "parameters": {"text": "hello"}}
284282
assert result == expected
285-

0 commit comments

Comments
 (0)