KvrParaskevi
commited on
Commit
•
67b7de3
1
Parent(s):
e31c867
Update app.py
Browse files
app.py
CHANGED
@@ -3,11 +3,13 @@
|
|
3 |
#gr.load("models/KvrParaskevi/Llama-2-7b-Hotel-Booking-Model-8Bit").launch()
|
4 |
|
5 |
import gradio as gr
|
|
|
6 |
|
7 |
from transformers import pipeline
|
8 |
|
9 |
pipe = pipeline("text-generation", model="KvrParaskevi/Llama-2-7b-Hotel-Booking-Model")
|
10 |
|
|
|
11 |
def predict(text):
|
12 |
answer = pipe(text)[0]
|
13 |
print(answer)
|
|
|
3 |
#gr.load("models/KvrParaskevi/Llama-2-7b-Hotel-Booking-Model-8Bit").launch()
|
4 |
|
5 |
import gradio as gr
|
6 |
+
import spaces
|
7 |
|
8 |
from transformers import pipeline
|
9 |
|
10 |
pipe = pipeline("text-generation", model="KvrParaskevi/Llama-2-7b-Hotel-Booking-Model")
|
11 |
|
12 |
+
@spaces.GPU
|
13 |
def predict(text):
|
14 |
answer = pipe(text)[0]
|
15 |
print(answer)
|