Skip to content

Commit 4fb4621

Browse files
committed
Stash last commit
1 parent af93036 commit 4fb4621

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/agentlab/agents/tool_use_agent/tool_use_agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ class ToolUseAgentArgs(AgentArgs):
354354

355355
def __post_init__(self):
356356
try:
357-
self.agent_name = f"MultiToolUse-{self.model_args.model_name}".replace("/", "_")
357+
self.agent_name = f"ToolUse-{self.model_args.model_name}".replace("/", "_")
358358
except AttributeError:
359359
pass
360360

src/agentlab/llm/llm_utils.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
from typing import TYPE_CHECKING, Any, Union
1212
from warnings import warn
1313

14+
import anthropic
1415
import numpy as np
1516
import openai
16-
import anthropic
1717
import tiktoken
1818
import yaml
1919
from langchain.schema import BaseMessage
@@ -99,9 +99,9 @@ def generic_call_api_with_retries(
9999
rate_limit_exceptions,
100100
api_error_exceptions,
101101
get_status_code_fn=None,
102-
max_retries=5,
103-
initial_retry_delay_seconds=1,
104-
max_retry_delay_seconds=60,
102+
max_retries=10,
103+
initial_retry_delay_seconds=20,
104+
max_retry_delay_seconds=60 * 5,
105105
):
106106
"""
107107
Makes an API call with retries for transient failures, rate limiting,
@@ -226,7 +226,7 @@ def _handle_api_error(e, attempt):
226226
raise RuntimeError(f"API call failed after {max_retries} retries.")
227227

228228

229-
def call_openai_api_with_retries(client_function, api_params, max_retries=5):
229+
def call_openai_api_with_retries(client_function, api_params, max_retries=10):
230230
"""
231231
Makes an OpenAI API call with retries for transient failures,
232232
rate limiting, and invalid or error-containing responses.
@@ -261,7 +261,7 @@ def get_openai_status_code(exception):
261261
)
262262

263263

264-
def call_anthropic_api_with_retries(client_function, api_params, max_retries=5):
264+
def call_anthropic_api_with_retries(client_function, api_params, max_retries=10):
265265
"""
266266
Makes an Anthropic API call with retries for transient failures,
267267
rate limiting, and invalid responses.

0 commit comments

Comments
 (0)