Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -46,16 +46,17 @@ def textGPT(text):
|
|
| 46 |
return chats
|
| 47 |
|
| 48 |
|
| 49 |
-
def
|
| 50 |
-
|
|
|
|
| 51 |
|
| 52 |
|
| 53 |
with gr.Blocks() as test:
|
| 54 |
-
with gr.Row():
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
btn = gr.Button("
|
| 58 |
-
btn.click(fn=
|
| 59 |
|
| 60 |
|
| 61 |
text = gr.Interface(fn=textGPT, inputs="text", outputs="text")
|
|
|
|
| 46 |
return chats
|
| 47 |
|
| 48 |
|
| 49 |
+
def clear():
|
| 50 |
+
messages = [{"role": "system", "content": 'You are a helpful technology assistant.'}]
|
| 51 |
+
return
|
| 52 |
|
| 53 |
|
| 54 |
with gr.Blocks() as test:
|
| 55 |
+
#with gr.Row():
|
| 56 |
+
# inp = gr.Textbox(placeholder="What is your name?")
|
| 57 |
+
# out = gr.Textbox()
|
| 58 |
+
btn = gr.Button("clear history")
|
| 59 |
+
btn.click(fn=clear)
|
| 60 |
|
| 61 |
|
| 62 |
text = gr.Interface(fn=textGPT, inputs="text", outputs="text")
|