Spaces:
Build error
Build error
autonomous019
commited on
Commit
•
04c6deb
1
Parent(s):
3a579df
Update app.py
Browse files
app.py
CHANGED
@@ -73,6 +73,8 @@ def inference(input_sentence, max_length, sample_or_greedy, seed=42):
|
|
73 |
return (None, None, f"<span style='color:red'>ERROR: {data['error']} </span>")
|
74 |
|
75 |
generation = data[0]["generated_text"].split(input_sentence, 1)[1]
|
|
|
|
|
76 |
return (
|
77 |
input_sentence
|
78 |
+ prompt_to_generation
|
@@ -81,6 +83,8 @@ def inference(input_sentence, max_length, sample_or_greedy, seed=42):
|
|
81 |
data[0]["generated_text"],
|
82 |
"",
|
83 |
)
|
|
|
|
|
84 |
|
85 |
|
86 |
|
|
|
73 |
return (None, None, f"<span style='color:red'>ERROR: {data['error']} </span>")
|
74 |
|
75 |
generation = data[0]["generated_text"].split(input_sentence, 1)[1]
|
76 |
+
print(generation)
|
77 |
+
'''
|
78 |
return (
|
79 |
input_sentence
|
80 |
+ prompt_to_generation
|
|
|
83 |
data[0]["generated_text"],
|
84 |
"",
|
85 |
)
|
86 |
+
'''
|
87 |
+
return generation
|
88 |
|
89 |
|
90 |
|