Spaces:
Runtime error
Runtime error
Commit ·
aee2b02
1
Parent(s): 34129c0
Update space
Browse files- app.py +6 -3
- requirements.txt +2 -1
app.py
CHANGED
|
@@ -31,9 +31,12 @@ def predict(input, history = []):
|
|
| 31 |
return chat_history, history
|
| 32 |
|
| 33 |
existing_chat=[
|
| 34 |
-
{'role': 'system', 'content': 'You are an expert code completionist.'},
|
| 35 |
-
{'role': 'user', 'content': 'huu'},
|
| 36 |
-
{'role': 'assistant', 'content': 'Wow wow'}
|
|
|
|
|
|
|
|
|
|
| 37 |
]
|
| 38 |
|
| 39 |
def initialize(input, history = []):
|
|
|
|
| 31 |
return chat_history, history
|
| 32 |
|
| 33 |
existing_chat=[
|
| 34 |
+
#{'role': 'system', 'content': 'You are an expert code completionist.'},
|
| 35 |
+
#{'role': 'user', 'content': 'huu'},
|
| 36 |
+
#{'role': 'assistant', 'content': 'Wow wow'},
|
| 37 |
+
gr.ChatMessage(role="system",content="You are an expert code completionist."),
|
| 38 |
+
gr.ChatMessage(role="user",content="huu"),
|
| 39 |
+
gr.ChatMessage(role="assistant",content="Wow wow"),
|
| 40 |
]
|
| 41 |
|
| 42 |
def initialize(input, history = []):
|
requirements.txt
CHANGED
|
@@ -3,4 +3,5 @@ torch
|
|
| 3 |
transformers
|
| 4 |
accelerate>=0.26.0
|
| 5 |
pymongo
|
| 6 |
-
|
|
|
|
|
|
| 3 |
transformers
|
| 4 |
accelerate>=0.26.0
|
| 5 |
pymongo
|
| 6 |
+
|
| 7 |
+
gradio==4.44.0
|