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
description:"Connects to a database to retrieve overall sales volumes and sales information for a given day.",
74
-
parameter_definitions: {
75
-
day: {
76
-
description:"Retrieves sales data for this day, formatted as YYYY-MM-DD.",
77
-
type:"str",
78
-
required:true
79
-
}
80
-
}
81
-
}
75
+
{
76
+
name:"query_daily_sales_report",
77
+
description:"Connects to a database to retrieve overall sales volumes and sales information for a given day.",
78
+
parameter_definitions: {
79
+
day: {
80
+
description:"Retrieves sales data for this day, formatted as YYYY-MM-DD.",
81
+
type:"str",
82
+
required:true
83
+
}
84
+
}
85
+
}
82
86
]
83
87
84
88
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?"
# This endpoint returns text embeddings. An embedding is a list of floating point numbers that captures semantic information about the text that it represents.
107
102
defembed(
108
-
texts:,
109
-
model: nil,
110
-
input_type: nil,
103
+
model:,
104
+
input_type:,
105
+
embedding_types:,
106
+
texts: nil,
107
+
images: nil,
111
108
truncate: nil
112
109
)
113
-
response=connection.post("embed")do |req|
114
-
req.body={texts: texts}
115
-
req.body[:model]=modelifmodel
116
-
req.body[:input_type]=input_typeifinput_type
110
+
response=v2_connection.post("embed")do |req|
111
+
req.body={
112
+
model: model,
113
+
input_type: input_type,
114
+
embedding_types: embedding_types
115
+
}
116
+
req.body[:texts]=textsiftexts
117
+
req.body[:images]=imagesifimages
117
118
req.body[:truncate]=truncateiftruncate
118
119
end
119
120
response.body
120
121
end
121
122
123
+
# This endpoint takes in a query and a list of texts and produces an ordered array with each text assigned a relevance score.
0 commit comments