Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -375,10 +375,7 @@ def get_beam_search_html(input_text, number_steps, number_beams, length_penalty)
|
|
375 |
markdown = "Output sequences:"
|
376 |
decoded_sequences = tokenizer.batch_decode(outputs.sequences)
|
377 |
for i, sequence in enumerate(decoded_sequences):
|
378 |
-
markdown += f"\n- {sequence} (score {outputs.sequences_scores[i]:.2f})"
|
379 |
-
print("Markdown output")
|
380 |
-
print(markdown)
|
381 |
-
print(input_text, decoded_sequences)
|
382 |
|
383 |
original_tree = generate_beams(
|
384 |
input_text,
|
|
|
375 |
markdown = "Output sequences:"
|
376 |
decoded_sequences = tokenizer.batch_decode(outputs.sequences)
|
377 |
for i, sequence in enumerate(decoded_sequences):
|
378 |
+
markdown += f"\n- {sequence.replace('<s> ', '')} (score {outputs.sequences_scores[i]:.2f})"
|
|
|
|
|
|
|
379 |
|
380 |
original_tree = generate_beams(
|
381 |
input_text,
|