Spaces:
Runtime error
Runtime error
this
Browse files
app.py
CHANGED
|
@@ -41,8 +41,14 @@ def responsenew(data):
|
|
| 41 |
- You can view your shared notes\n
|
| 42 |
- You can start a timer or a stopwatch\n\n
|
| 43 |
|
| 44 |
-
|
|
|
|
|
|
|
|
|
|
| 45 |
|
|
|
|
|
|
|
|
|
|
| 46 |
Return the intent as one-word string representing the user's intent, one of:
|
| 47 |
* if intent = purchasing coins return = "purchase_coins"
|
| 48 |
* if intent = viewing friends return = "view_friends"
|
|
@@ -72,13 +78,7 @@ def responsenew(data):
|
|
| 72 |
* if intent = sharing a todo list return = "share_todo_list"
|
| 73 |
* if intent = sharing a note return = "share_note"
|
| 74 |
* if intent = knowing your name or who you are or what is your name return = "cosmo_name"
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
"""
|
| 79 |
-
|
| 80 |
-
response = palm.chat( messages=data)
|
| 81 |
-
intent = palm.chat(context = contxxt, messages=data)
|
| 82 |
print(intent)
|
| 83 |
# respo = {
|
| 84 |
# "message": intent.last,
|
|
|
|
| 41 |
- You can view your shared notes\n
|
| 42 |
- You can start a timer or a stopwatch\n\n
|
| 43 |
|
| 44 |
+
|
| 45 |
+
|
| 46 |
+
|
| 47 |
+
"""
|
| 48 |
|
| 49 |
+
response = palm.chat( messages=data)
|
| 50 |
+
intent = palm.chat(context = contxxt, messages="""Identify the user's intent from text_data below:\n
|
| 51 |
+
text_data = {data}\n\n
|
| 52 |
Return the intent as one-word string representing the user's intent, one of:
|
| 53 |
* if intent = purchasing coins return = "purchase_coins"
|
| 54 |
* if intent = viewing friends return = "view_friends"
|
|
|
|
| 78 |
* if intent = sharing a todo list return = "share_todo_list"
|
| 79 |
* if intent = sharing a note return = "share_note"
|
| 80 |
* if intent = knowing your name or who you are or what is your name return = "cosmo_name"
|
| 81 |
+
""")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 82 |
print(intent)
|
| 83 |
# respo = {
|
| 84 |
# "message": intent.last,
|