File size: 950 Bytes
837f010
 
d0b1bf3
837f010
d0b1bf3
193a7b5
3898232
837f010
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import gradio as gr
from transformers import pipeline
title = "📗❤️-Story Generator❤️📗- 🦄Myths and Legends🦸"
examples = [
    ["Tengu in Japanese folklore, a type of mischievous supernatural being, sometimes considered the reincarnated spirit of one who was proud and arrogant in life. "],
    ["Tengu are renowned swordsmen and are said to have taught the military arts to the Minamoto hero Yoshitsune. They live in trees in mountainous areas."]
    ]
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)