Spaces:
Build error
Build error
jcarbonnell
commited on
Commit
•
ffca0f8
1
Parent(s):
69ebead
Update app.py
Browse files
app.py
CHANGED
@@ -23,12 +23,12 @@ if choice == 'NFT':
|
|
23 |
generated = torch.tensor(tokenizer.encode(prompt)).unsqueeze(0)
|
24 |
output = model.generate(generated, do_sample=True, top_k=50, max_length = 512, top_p=0.95, num_return_sequences=1)
|
25 |
generated_text = tokenizer.decode(output, skip_special_tokens=True)
|
26 |
-
summary = summarize(generated_text, num_sentences=1)
|
27 |
|
28 |
#st.text("Keywords: {}\n".format(keywords))
|
29 |
#st.text("Length in number of words: {}\n".format(length))
|
30 |
st.text("This is your tailored blog article:", generated_text)
|
31 |
-
st.text("This is a tweet-sized summary of your article: ", summary)
|
32 |
else:
|
33 |
st.write("Topic not available yet")
|
34 |
|
|
|
23 |
generated = torch.tensor(tokenizer.encode(prompt)).unsqueeze(0)
|
24 |
output = model.generate(generated, do_sample=True, top_k=50, max_length = 512, top_p=0.95, num_return_sequences=1)
|
25 |
generated_text = tokenizer.decode(output, skip_special_tokens=True)
|
26 |
+
#summary = summarize(generated_text, num_sentences=1)
|
27 |
|
28 |
#st.text("Keywords: {}\n".format(keywords))
|
29 |
#st.text("Length in number of words: {}\n".format(length))
|
30 |
st.text("This is your tailored blog article:", generated_text)
|
31 |
+
#st.text("This is a tweet-sized summary of your article: ", summary)
|
32 |
else:
|
33 |
st.write("Topic not available yet")
|
34 |
|