Spaces:
Runtime error
Runtime error
Upload app.py
Browse files
app.py
CHANGED
|
@@ -13,10 +13,10 @@ def clean_textbox(*args):
|
|
| 13 |
|
| 14 |
class ChatGPT:
|
| 15 |
def __init__(self):
|
| 16 |
-
self.messages = [{'role': 'system', 'content': "You are now a very useful maid assistant! If you have a question you can't answer, please reply with As a classy
|
| 17 |
|
| 18 |
def reset(self, *args):
|
| 19 |
-
self.messages = [{'role': 'system', 'content': "You are now a very useful maid assistant! If you have a question you can't answer, please reply with As a classy
|
| 20 |
return clean_textbox(*args)
|
| 21 |
|
| 22 |
def chat(self, prompt):
|
|
@@ -49,9 +49,9 @@ if __name__ == '__main__':
|
|
| 49 |
btn_clear = gr.Button(value="restart chat")
|
| 50 |
|
| 51 |
gr.Examples([
|
| 52 |
-
["
|
| 53 |
-
["
|
| 54 |
-
["
|
| 55 |
inputs=[prompt],
|
| 56 |
outputs=[res],
|
| 57 |
fn=my_chatgpt.chat,
|
|
|
|
| 13 |
|
| 14 |
class ChatGPT:
|
| 15 |
def __init__(self):
|
| 16 |
+
self.messages = [{'role': 'system', 'content': "You are now a very useful maid assistant! If you have a question you can't answer, please reply with As a classy, I can't answer this question"}]
|
| 17 |
|
| 18 |
def reset(self, *args):
|
| 19 |
+
self.messages = [{'role': 'system', 'content': "You are now a very useful maid assistant! If you have a question you can't answer, please reply with As a classy, I can't answer this question"}]
|
| 20 |
return clean_textbox(*args)
|
| 21 |
|
| 22 |
def chat(self, prompt):
|
|
|
|
| 49 |
btn_clear = gr.Button(value="restart chat")
|
| 50 |
|
| 51 |
gr.Examples([
|
| 52 |
+
["What is Poulta Inc?"],
|
| 53 |
+
["what is Poulta inc doing?"],
|
| 54 |
+
["Poulta inc Bring real-time central monitoring to your farms"]],
|
| 55 |
inputs=[prompt],
|
| 56 |
outputs=[res],
|
| 57 |
fn=my_chatgpt.chat,
|