Spaces:
Runtime error
Runtime error
mertbozkurt
commited on
Commit
•
0e3c396
1
Parent(s):
640b5d3
Update app.py
Browse files
app.py
CHANGED
@@ -17,15 +17,15 @@ pipeline = transformers.pipeline(
|
|
17 |
device_map="auto",
|
18 |
offload_folder="offload"
|
19 |
)
|
20 |
-
|
21 |
-
sequences = pipeline(
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
)
|
29 |
-
for seq in sequences:
|
30 |
-
|
31 |
|
|
|
17 |
device_map="auto",
|
18 |
offload_folder="offload"
|
19 |
)
|
20 |
+
if st.button('Process'):
|
21 |
+
sequences = pipeline(
|
22 |
+
f'<s>[INST] {prompt} [/INST]',
|
23 |
+
do_sample=True,
|
24 |
+
top_k=10,
|
25 |
+
num_return_sequences=1,
|
26 |
+
eos_token_id=tokenizer.eos_token_id,
|
27 |
+
max_length=100,
|
28 |
)
|
29 |
+
for seq in sequences:
|
30 |
+
st.write(seq)
|
31 |
|