Spaces:
Sleeping
Sleeping
File size: 957 Bytes
6bd5450 fae1572 6bd5450 35c7a98 6bd5450 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
import gradio as gr
from transformers import pipeline
title = "NLP Mindful Tip Generators"
examples = [
["Mindfulness tips include"],
["To expand your memory and remember anything"],
["To learn at an accelerated rate you can"],
["The most useful advice I have ever heard is"],
["My favorite quote is"],
["This joke was really funny and made me laugh"],
["You really make me smile because"],
["I can't tell you how thankful I am for your help"]
]
from gradio import inputs
from gradio.inputs import Textbox
from gradio import outputs
generator2 = gr.Interface.load("huggingface/EleutherAI/gpt-neo-2.7B")
generator3 = gr.Interface.load("huggingface/EleutherAI/gpt-j-6B")
generator1 = gr.Interface.load("huggingface/gpt2-large")
gr.Parallel(generator1, generator2, generator3, inputs=gr.inputs.Textbox(lines=5, label="Enter a sentence to get another sentence."),
title=title, examples=examples).launch(share=False) |