Spaces:
Runtime error
Runtime error
nitinbhayana
commited on
Commit
•
bbd82c5
1
Parent(s):
271399f
Update app.py
Browse files
app.py
CHANGED
@@ -19,7 +19,7 @@ You are a helpful, respectful, and honest assistant for product feature mapping.
|
|
19 |
[INST]
|
20 |
For a given e-commerce product title.
|
21 |
[TITLE]
|
22 |
-
|
23 |
[/TITLE]
|
24 |
Create a new, easy-to-read, error-free title.
|
25 |
[/INST]
|
@@ -27,7 +27,7 @@ Create a new, easy-to-read, error-free title.
|
|
27 |
Suggested Title:
|
28 |
"""
|
29 |
predictions = pipeline(prompt)
|
30 |
-
output=(predictions[0]['generated_text']).split('Suggested Title:')[-1]
|
31 |
return (output)
|
32 |
|
33 |
gr.Interface(
|
|
|
19 |
[INST]
|
20 |
For a given e-commerce product title.
|
21 |
[TITLE]
|
22 |
+
{title}
|
23 |
[/TITLE]
|
24 |
Create a new, easy-to-read, error-free title.
|
25 |
[/INST]
|
|
|
27 |
Suggested Title:
|
28 |
"""
|
29 |
predictions = pipeline(prompt)
|
30 |
+
output=((predictions[0]['generated_text']).split('Suggested Title:')[-1]).strip()
|
31 |
return (output)
|
32 |
|
33 |
gr.Interface(
|