bstraehle commited on
Commit
988c224
ยท
verified ยท
1 Parent(s): f645072

Update agents/tools/ai_tools.py

Browse files
Files changed (1) hide show
  1. agents/tools/ai_tools.py +10 -10
agents/tools/ai_tools.py CHANGED
@@ -64,7 +64,7 @@ class AITools():
64
  print(f"๐Ÿ› ๏ธ AITools: {tool_name}: result={result}")
65
  return result
66
  except Exception as e:
67
- print(f"๐Ÿค– AITools: {tool_name}: exception={str(e)}")
68
  raise RuntimeError(f"Processing failed: {str(e)}")
69
 
70
  def _extract_execution_result(response):
@@ -107,7 +107,7 @@ class AITools():
107
  print(f"๐Ÿ› ๏ธ AITools: web_search_tool: result={result}")
108
  return result
109
  except Exception as e:
110
- print(f"๐Ÿค– AITools: web_search_tool: exception={str(e)}")
111
  raise RuntimeError(f"Processing failed: {str(e)}")
112
 
113
  @tool("Web Browser Tool")
@@ -152,7 +152,7 @@ class AITools():
152
  print(f"๐Ÿ› ๏ธ AITools: web_browser_tool: result={result}")
153
  return result
154
  except Exception as e:
155
- print(f"๐Ÿค– AITools: web_browser_tool: exception={str(e)}")
156
  raise RuntimeError(f"Processing failed: {str(e)}")
157
 
158
  @tool("Image Analysis Tool")
@@ -238,7 +238,7 @@ class AITools():
238
  print(f"๐Ÿ› ๏ธ AITools: youtube_analysis_tool: result={result}")
239
  return result
240
  except Exception as e:
241
- print(f"๐Ÿค– AITools: youtube_analysis_tool: exception={str(e)}")
242
  raise RuntimeError(f"Processing failed: {str(e)}")
243
 
244
  @tool("Document Analysis Tool")
@@ -288,7 +288,7 @@ class AITools():
288
  print(f"๐Ÿ› ๏ธ AITools: document_analysis_tool: result={result}")
289
  return result
290
  except Exception as e:
291
- print(f"๐Ÿค– AITools: document_analysis_tool: exception={str(e)}")
292
  raise RuntimeError(f"Processing failed: {str(e)}")
293
 
294
  @tool("Code Generation and Execution Tool")
@@ -325,7 +325,7 @@ class AITools():
325
  print(f"๐Ÿ› ๏ธ AITools: code_generation_and_execution_tool: result={result}")
326
  return result
327
  except Exception as e:
328
- print(f"๐Ÿค– AITools: code_generation_and_execution_tool: exception={str(e)}")
329
  raise RuntimeError(f"Processing failed: {str(e)}")
330
 
331
  @tool("Code Execution Tool")
@@ -365,7 +365,7 @@ class AITools():
365
  print(f"๐Ÿ› ๏ธ AITools: code_execution_tool: result={result}")
366
  return result
367
  except Exception as e:
368
- print(f"๐Ÿค– AITools: code_execution_tool: exception={str(e)}")
369
  raise RuntimeError(f"Processing failed: {str(e)}")
370
 
371
  @tool("Image to FEN Tool")
@@ -428,7 +428,7 @@ class AITools():
428
  print(f"๐Ÿ› ๏ธ AITools: img_to_fen_tool: result={result}")
429
  return result
430
  except Exception as e:
431
- print(f"๐Ÿค– AITools: img_to_fen_tool: exception={str(e)}")
432
  raise RuntimeError(f"Processing failed: {str(e)}")
433
 
434
  @tool("Algebraic Notation Tool")
@@ -489,7 +489,7 @@ class AITools():
489
  print(f"๐Ÿ› ๏ธ AITools: algebraic_notation_tool: result={result}")
490
  return result
491
  except Exception as e:
492
- print(f"๐Ÿค– AITools: algebraic_notation_tool: exception={str(e)}")
493
  raise RuntimeError(f"Processing failed: {str(e)}")
494
 
495
  def final_answer_tool(question: str, answer: str) -> str:
@@ -526,5 +526,5 @@ class AITools():
526
  print(f"๐Ÿ› ๏ธ AITools: final_answer_tool: result={result}")
527
  return result
528
  except Exception as e:
529
- print(f"๐Ÿค– AITools: final_answer_tool: exception={str(e)}")
530
  raise RuntimeError(f"Processing failed: {str(e)}")
 
64
  print(f"๐Ÿ› ๏ธ AITools: {tool_name}: result={result}")
65
  return result
66
  except Exception as e:
67
+ print(f"โš ๏ธ AITools: {tool_name}: exception={str(e)}")
68
  raise RuntimeError(f"Processing failed: {str(e)}")
69
 
70
  def _extract_execution_result(response):
 
107
  print(f"๐Ÿ› ๏ธ AITools: web_search_tool: result={result}")
108
  return result
109
  except Exception as e:
110
+ print(f"โš ๏ธ AITools: web_search_tool: exception={str(e)}")
111
  raise RuntimeError(f"Processing failed: {str(e)}")
112
 
113
  @tool("Web Browser Tool")
 
152
  print(f"๐Ÿ› ๏ธ AITools: web_browser_tool: result={result}")
153
  return result
154
  except Exception as e:
155
+ print(f"โš ๏ธ AITools: web_browser_tool: exception={str(e)}")
156
  raise RuntimeError(f"Processing failed: {str(e)}")
157
 
158
  @tool("Image Analysis Tool")
 
238
  print(f"๐Ÿ› ๏ธ AITools: youtube_analysis_tool: result={result}")
239
  return result
240
  except Exception as e:
241
+ print(f"โš ๏ธ AITools: youtube_analysis_tool: exception={str(e)}")
242
  raise RuntimeError(f"Processing failed: {str(e)}")
243
 
244
  @tool("Document Analysis Tool")
 
288
  print(f"๐Ÿ› ๏ธ AITools: document_analysis_tool: result={result}")
289
  return result
290
  except Exception as e:
291
+ print(f"โš ๏ธ AITools: document_analysis_tool: exception={str(e)}")
292
  raise RuntimeError(f"Processing failed: {str(e)}")
293
 
294
  @tool("Code Generation and Execution Tool")
 
325
  print(f"๐Ÿ› ๏ธ AITools: code_generation_and_execution_tool: result={result}")
326
  return result
327
  except Exception as e:
328
+ print(f"โš ๏ธ AITools: code_generation_and_execution_tool: exception={str(e)}")
329
  raise RuntimeError(f"Processing failed: {str(e)}")
330
 
331
  @tool("Code Execution Tool")
 
365
  print(f"๐Ÿ› ๏ธ AITools: code_execution_tool: result={result}")
366
  return result
367
  except Exception as e:
368
+ print(f"โš ๏ธ AITools: code_execution_tool: exception={str(e)}")
369
  raise RuntimeError(f"Processing failed: {str(e)}")
370
 
371
  @tool("Image to FEN Tool")
 
428
  print(f"๐Ÿ› ๏ธ AITools: img_to_fen_tool: result={result}")
429
  return result
430
  except Exception as e:
431
+ print(f"โš ๏ธ AITools: img_to_fen_tool: exception={str(e)}")
432
  raise RuntimeError(f"Processing failed: {str(e)}")
433
 
434
  @tool("Algebraic Notation Tool")
 
489
  print(f"๐Ÿ› ๏ธ AITools: algebraic_notation_tool: result={result}")
490
  return result
491
  except Exception as e:
492
+ print(f"โš ๏ธ AITools: algebraic_notation_tool: exception={str(e)}")
493
  raise RuntimeError(f"Processing failed: {str(e)}")
494
 
495
  def final_answer_tool(question: str, answer: str) -> str:
 
526
  print(f"๐Ÿ› ๏ธ AITools: final_answer_tool: result={result}")
527
  return result
528
  except Exception as e:
529
+ print(f"โš ๏ธ AITools: final_answer_tool: exception={str(e)}")
530
  raise RuntimeError(f"Processing failed: {str(e)}")