You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
print(res.text) # "The mayor of Toronto, the capital of Ontario is Olivia Chow"
48
+
49
+
50
+
# tool descriptions that the model has access to
51
+
tools= [
52
+
{
53
+
"name": "query_daily_sales_report",
54
+
"description": "Connects to a database to retrieve overall sales volumes and sales information for a given day.",
55
+
"parameter_definitions": {"day": {"description": "Retrieves sales data for this day, formatted as YYYY-MM-DD.", "type": "str", "required": True}},
56
+
},
57
+
{
58
+
"name": "query_product_catalog",
59
+
"description": "Connects to a a product catalog with information about all the products being sold, including categories, prices, and stock levels.",
60
+
"parameter_definitions": {"category": {"description": "Retrieves product information data for all products in this category.", "type": "str", "required": True}},
61
+
},
62
+
]
63
+
64
+
# preamble containing instructions about the task and the desired style for the output.
65
+
preamble="""
66
+
## Task & Context
67
+
You help people answer their questions and other requests interactively. You will be asked a very wide array of requests on all kinds of topics. You will be equipped with a wide range of search engines or similar tools to help you, which you use to research your answer. You should focus on serving the user's needs as best you can, which will be wide-ranging.
68
+
69
+
## Style Guide
70
+
Unless the user asks for a different style of answer, you should answer in full sentences, using proper grammar and spelling.
71
+
"""
72
+
73
+
# user request
74
+
message="Can you provide a sales summary for 29th September 2023, and also give me some details about the products in the 'Electronics' category, for example their prices and stock levels?"
0 commit comments