Kackle commited on
Commit
2d550de
·
verified ·
1 Parent(s): 9a34089
Files changed (1) hide show
  1. app.py +8 -7
app.py CHANGED
@@ -39,8 +39,8 @@ class SlpMultiAgent:
39
  model = OpenAIServerModel(
40
  model_id="gpt-3.5-turbo-16k",
41
  temperature=0.0,
42
- max_tokens=1000,
43
- request_timeout=60
44
  )
45
 
46
  # Here you can implement your agent logic, tools, and model calls
@@ -58,8 +58,8 @@ class SlpMultiAgent:
58
  model=OpenAIServerModel(
59
  model_id="gpt-3.5-turbo-16k",
60
  temperature=0.0,
61
- max_tokens=1000,
62
- request_timeout=60
63
  ),
64
  tools=[],
65
  managed_agents=[web_agent],
@@ -125,8 +125,8 @@ def check_reasoning(final_answer, agent_memory):
125
  try:
126
  multimodal_model = OpenAIServerModel(
127
  model_id="gpt-3.5-turbo",
128
- max_tokens=500,
129
- request_timeout=30
130
  )
131
 
132
  # Simplified prompt to reduce token usage
@@ -221,7 +221,8 @@ async def run_and_submit_all(profile):
221
  answers_payload = []
222
  print(f"Running agent on {len(questions_data)} questions...")
223
 
224
- semaphore = asyncio.Semaphore(3)
 
225
 
226
  async def process_question(item):
227
  task_id = item.get("task_id")
 
39
  model = OpenAIServerModel(
40
  model_id="gpt-3.5-turbo-16k",
41
  temperature=0.0,
42
+ max_tokens=1000
43
+ # Removed request_timeout parameter
44
  )
45
 
46
  # Here you can implement your agent logic, tools, and model calls
 
58
  model=OpenAIServerModel(
59
  model_id="gpt-3.5-turbo-16k",
60
  temperature=0.0,
61
+ max_tokens=1000
62
+ # Removed request_timeout parameter
63
  ),
64
  tools=[],
65
  managed_agents=[web_agent],
 
125
  try:
126
  multimodal_model = OpenAIServerModel(
127
  model_id="gpt-3.5-turbo",
128
+ max_tokens=500
129
+ # Removed request_timeout parameter
130
  )
131
 
132
  # Simplified prompt to reduce token usage
 
221
  answers_payload = []
222
  print(f"Running agent on {len(questions_data)} questions...")
223
 
224
+ # Process questions with lower concurrency to avoid rate limits
225
+ semaphore = asyncio.Semaphore(1) # Process one question at a time
226
 
227
  async def process_question(item):
228
  task_id = item.get("task_id")