MCPcopy Index your code
hub / github.com/browser-use/macOS-use / get_context

Method get_context

examples/basic_agent.py:55–61  ·  view source on GitHub ↗
(self, ui_tree_string: str)

Source from the content-addressed store, hash-verified

53 self.last_action = None
54
55 def get_context(self, ui_tree_string: str) -> str:
56 if not self.new_folder_clicked:
57 return "Find and click the 'New Folder' button."
58 elif not self.folder_name_entered:
59 return "The 'New Folder' button has been clicked. Look for the newly appeared text field to type the folder name."
60 else:
61 return 'Folder name has been entered.'
62
63 def update(self, action_name: str, success: bool = True, element_info: str = '') -> None:
64 if not success:

Callers 1

mainFunction · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected