Spaces:
Runtime error
Runtime error
Commit
•
a4e1535
1
Parent(s):
6f40744
Update app.py
Browse files
app.py
CHANGED
@@ -20,15 +20,15 @@ function_descriptions = [
|
|
20 |
},
|
21 |
"product": {
|
22 |
"type": "string",
|
23 |
-
"description": "Try to identify which product the client is interested in, if any"
|
24 |
},
|
25 |
"amount":{
|
26 |
"type": "string",
|
27 |
-
"description": "Try to identify the amount of products the client wants to purchase, if any"
|
28 |
},
|
29 |
"category": {
|
30 |
"type": "string",
|
31 |
-
"description": "Try to categorise this email into categories like those: 1. Sales 2. customer support; 3. consulting; 4. partnership; etc."
|
32 |
},
|
33 |
"nextStep":{
|
34 |
"type": "string",
|
@@ -64,7 +64,7 @@ def extract_data(email,function_descriptions):
|
|
64 |
message = [{"role": "user", "content": prompt}]
|
65 |
|
66 |
response = openai.ChatCompletion.create(
|
67 |
-
model="gpt-
|
68 |
messages=message,
|
69 |
functions = function_descriptions,
|
70 |
function_call="auto"
|
|
|
20 |
},
|
21 |
"product": {
|
22 |
"type": "string",
|
23 |
+
"description": "Try to identify which product the client is interested in selling or buying, if any"
|
24 |
},
|
25 |
"amount":{
|
26 |
"type": "string",
|
27 |
+
"description": "Try to identify the amount of products the client wants to purchase or sell, if any"
|
28 |
},
|
29 |
"category": {
|
30 |
"type": "string",
|
31 |
+
"description": "Try to categorise this email into categories like those: 1. Sales; 2. customer support; 3. consulting; 4. partnership; 5. Marketing; etc."
|
32 |
},
|
33 |
"nextStep":{
|
34 |
"type": "string",
|
|
|
64 |
message = [{"role": "user", "content": prompt}]
|
65 |
|
66 |
response = openai.ChatCompletion.create(
|
67 |
+
model="gpt-4-0613",
|
68 |
messages=message,
|
69 |
functions = function_descriptions,
|
70 |
function_call="auto"
|