feat: add client password argument to multiple agents and scripts
- Introduced `--client_password` argument in `run_multienv_aguvis.py`, `run_multienv_claude.py`, and `run_multienv_gta1.py` for enhanced security and flexibility. - Updated agent classes (`PromptAgent`, `AguvisAgent`, `GTA1Agent`) to accept and utilize `client_password` for improved configuration. - Modified evaluation guidelines to reflect the new client password requirement. - Ensured existing logic remains intact while enhancing functionality for better user experience.
This commit is contained in:
@@ -360,6 +360,7 @@ class AguvisAgent:
|
||||
temperature=0.5,
|
||||
action_space="pyautogui",
|
||||
observation_type="screenshot",
|
||||
client_password="password"
|
||||
):
|
||||
self.platform = platform
|
||||
self.planner_model = planner_model
|
||||
@@ -372,6 +373,8 @@ class AguvisAgent:
|
||||
self.observation_type = observation_type
|
||||
assert action_space in ["pyautogui"], "Invalid action space"
|
||||
assert observation_type in ["screenshot"], "Invalid observation type"
|
||||
self.client_password = client_password
|
||||
|
||||
self.thoughts = []
|
||||
self.actions = []
|
||||
self.observations = []
|
||||
@@ -429,7 +432,7 @@ class AguvisAgent:
|
||||
# So we temporarily separate the planner prompt and aguvis prompt.
|
||||
|
||||
planner_messages = []
|
||||
planner_system_message = AGUVIS_PLANNER_SYS_PROMPT
|
||||
planner_system_message = AGUVIS_PLANNER_SYS_PROMPT.format(CLIENT_PASSWORD=self.client_password)
|
||||
planner_messages.append({
|
||||
"role": "system",
|
||||
"content": [{"type": "text", "text": planner_system_message}]
|
||||
|
||||
Reference in New Issue
Block a user