shrutikaP8497 commited on
Commit
82ec8dc
·
verified ·
1 Parent(s): 7fb4ff5

Update tools.py

Browse files
Files changed (1) hide show
  1. tools.py +9 -6
tools.py CHANGED
@@ -1,4 +1,3 @@
1
- # tools.py
2
 
3
  from smolagents import tool
4
 
@@ -22,11 +21,15 @@ def build_prompt(question: str, context: str) -> str:
22
  )
23
  return f"{system_instruction}Context:\n{context}\n\nQuestion: {question}\nAnswer:"
24
 
25
- # These tools are optional; remove or fix if using
26
- # @tool
27
- # def guest_info_tool(name: str) -> str:
28
- # return "Background info not available."
29
-
30
  @tool
31
  def greeting_tool(name: str) -> str:
 
 
 
 
 
 
 
 
 
32
  return f"Welcome to the gala, {name}! We're honored to have you with us."
 
 
1
 
2
  from smolagents import tool
3
 
 
21
  )
22
  return f"{system_instruction}Context:\n{context}\n\nQuestion: {question}\nAnswer:"
23
 
 
 
 
 
 
24
  @tool
25
  def greeting_tool(name: str) -> str:
26
+ """
27
+ Generates a custom greeting for the guest.
28
+
29
+ Args:
30
+ name: Name of the guest
31
+
32
+ Returns:
33
+ A friendly greeting message.
34
+ """
35
  return f"Welcome to the gala, {name}! We're honored to have you with us."