Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
import gradio as gr
|
| 2 |
from transformers import pipeline
|
| 3 |
|
| 4 |
-
# Load
|
| 5 |
generator = pipeline("text-generation", model="tiiuae/falcon-7b-instruct", device_map="auto", max_new_tokens=200)
|
| 6 |
|
| 7 |
def respond(message, chat_history):
|
|
@@ -11,7 +11,7 @@ def respond(message, chat_history):
|
|
| 11 |
chat_history.append((message, response))
|
| 12 |
return "", chat_history
|
| 13 |
|
| 14 |
-
#
|
| 15 |
with gr.Blocks() as demo:
|
| 16 |
chatbot = gr.Chatbot()
|
| 17 |
with gr.Row():
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
from transformers import pipeline
|
| 3 |
|
| 4 |
+
# Load the text generation model
|
| 5 |
generator = pipeline("text-generation", model="tiiuae/falcon-7b-instruct", device_map="auto", max_new_tokens=200)
|
| 6 |
|
| 7 |
def respond(message, chat_history):
|
|
|
|
| 11 |
chat_history.append((message, response))
|
| 12 |
return "", chat_history
|
| 13 |
|
| 14 |
+
# Interface: PromptVerse
|
| 15 |
with gr.Blocks() as demo:
|
| 16 |
chatbot = gr.Chatbot()
|
| 17 |
with gr.Row():
|