Spaces:
Running
Running
injilashah
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -23,7 +23,7 @@ def Sentence_Commpletion(model_name, input):
|
|
23 |
tokenizer, model = g_tokenizer, g_model
|
24 |
inputs= tokenizer(input, return_tensors="pt")
|
25 |
outputs = model.generate(inputs.input_ids, max_new_tokens=32)
|
26 |
-
return tokenizer.decode(outputs[0])
|
27 |
|
28 |
|
29 |
interface = gr.Interface(
|
|
|
23 |
tokenizer, model = g_tokenizer, g_model
|
24 |
inputs= tokenizer(input, return_tensors="pt")
|
25 |
outputs = model.generate(inputs.input_ids, max_new_tokens=32)
|
26 |
+
return tokenizer.decode(outputs[0],skip_special_tokens=True)
|
27 |
|
28 |
|
29 |
interface = gr.Interface(
|