Skip to content

Commit

Permalink
fixed type errors
Browse files Browse the repository at this point in the history
  • Loading branch information
dillonalaird committed Oct 16, 2024
1 parent 802c7e2 commit b58e48d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
10 changes: 10 additions & 0 deletions vision_agent/agent/vision_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,8 @@ def __init__(
verbosity (int): The verbosity level of the agent.
local_artifacts_path (Optional[Union[str, Path]]): The path to the local
artifacts file.
remote_artifacts_path (Optional[Union[str, Path]]): The path to the remote
artifacts file.
callback_message (Optional[Callable[[Dict[str, Any]], None]]): Callback
function to send intermediate update messages.
code_interpreter (Optional[Union[str, CodeInterpreter]]): For string values
Expand Down Expand Up @@ -643,6 +645,7 @@ def __init__(
agent: Optional[LMM] = None,
verbosity: int = 0,
local_artifacts_path: Optional[Union[str, Path]] = None,
remote_artifacts_path: Optional[Union[str, Path]] = None,
callback_message: Optional[Callable[[Dict[str, Any]], None]] = None,
code_interpreter: Optional[Union[str, CodeInterpreter]] = None,
) -> None:
Expand All @@ -654,6 +657,8 @@ def __init__(
verbosity (int): The verbosity level of the agent.
local_artifacts_path (Optional[Union[str, Path]]): The path to the local
artifacts file.
remote_artifacts_path (Optional[Union[str, Path]]): The path to the remote
artifacts file.
callback_message (Optional[Callable[[Dict[str, Any]], None]]): Callback
function to send intermediate update messages.
code_interpreter (Optional[Union[str, CodeInterpreter]]): For string values
Expand All @@ -667,6 +672,7 @@ def __init__(
agent,
verbosity,
local_artifacts_path,
remote_artifacts_path,
callback_message,
code_interpreter,
)
Expand All @@ -678,6 +684,7 @@ def __init__(
agent: Optional[LMM] = None,
verbosity: int = 0,
local_artifacts_path: Optional[Union[str, Path]] = None,
remote_artifacts_path: Optional[Union[str, Path]] = None,
callback_message: Optional[Callable[[Dict[str, Any]], None]] = None,
code_interpreter: Optional[Union[str, CodeInterpreter]] = None,
) -> None:
Expand All @@ -689,6 +696,8 @@ def __init__(
verbosity (int): The verbosity level of the agent.
local_artifacts_path (Optional[Union[str, Path]]): The path to the local
artifacts file.
remote_artifacts_path (Optional[Union[str, Path]]): The path to the remote
artifacts file.
callback_message (Optional[Callable[[Dict[str, Any]], None]]): Callback
function to send intermediate update messages.
code_interpreter (Optional[Union[str, CodeInterpreter]]): For string values
Expand All @@ -702,6 +711,7 @@ def __init__(
agent,
verbosity,
local_artifacts_path,
remote_artifacts_path,
callback_message,
code_interpreter,
)
2 changes: 1 addition & 1 deletion vision_agent/tools/meta_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -835,7 +835,7 @@ def extract_and_save_files_to_artifacts(
files = {}
for res in result.results:
for format in res.formats():
if format in ["png", "jpeg", "mp4"]: # type: ignore
if format in ["png", "jpeg", "mp4"]:
if format == "png":
data = base64.b64decode(res.png) if res.png is not None else None
elif format == "jpeg":
Expand Down

0 comments on commit b58e48d

Please sign in to comment.