@@ -535,7 +535,9 @@ def wrapper(*args, **kwargs):
535535def update_screenshot (som_or_not : str ):
536536 global info
537537 action = info .exp_result .steps_info [info .step ].action
538- return agent_utils .tag_screenshot_with_action (get_screenshot (info , som_or_not = som_or_not ), action )
538+ return agent_utils .tag_screenshot_with_action (
539+ get_screenshot (info , som_or_not = som_or_not ), action
540+ )
539541
540542
541543def get_screenshot (info : Info , step : int = None , som_or_not : str = "Raw Screenshots" ):
@@ -554,7 +556,9 @@ def update_screenshot_pair(som_or_not: str):
554556 s2 = get_screenshot (info , info .step + 1 , som_or_not )
555557
556558 if s1 is not None :
557- s1 = agent_utils .tag_screenshot_with_action (s1 , info .exp_result .steps_info [info .step ].action )
559+ s1 = agent_utils .tag_screenshot_with_action (
560+ s1 , info .exp_result .steps_info [info .step ].action
561+ )
558562 return s1 , s2
559563
560564
@@ -596,7 +600,12 @@ def dict_to_markdown(d: dict):
596600 """
597601 Convert a dictionary to a clean markdown representation, recursively.
598602
599- dict: type = dict[str, str | list[dict[...]]]
603+ Args:
604+ d (dict): A dictionary where keys are strings and values can be strings,
605+ lists of dictionaries, or nested dictionaries.
606+
607+ Returns:
608+ str: A markdown-formatted string representation of the dictionary.
600609 """
601610 if not isinstance (d , dict ):
602611 warning (f"Expected dict, got { type (d )} " )
0 commit comments