File size: 1,045 Bytes
a4fcc7e
 
e77f816
9df72f4
 
bcaf4b9
 
cb9b710
 
 
34349aa
 
2682122
 
 
9df72f4
2682122
 
 
55f0c34
cb9b710
 
6caaed0
 
 
 
 
 
cb9b710
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
import gradio as gr


def sentence_builder(quantity, animal, , activity_list):
    return f"""The {quantity} {animal}s from  went to the where they {" and ".join(activity_list)} until the """


demo = gr.Interface(
    sentence_builder,
    [
        gr.Slider(2009, 2023, value=2009, label="Count", info="Choose a year between 2009 and 2023"),
        gr.Slider(0, 120167, value=0, label="Count", info="Enter mileage between 0 and 120167"),
        gr.Dropdown(
            ["cat", "dog", "bird"], label="Animal", info="Will add more animals later!"
        ),
       
        gr.Dropdown(
            ["cat", "dog", "bird"], label="Animal", info="Will add more animals later!"
        ),

    ],
    "text",
    #examples=[
    #    [2, "cat", ["Japan", "Pakistan"], "park", ["ate", "swam"], True],
    #    [4, "dog", ["Japan"], "zoo", ["ate", "swam"], False],
    #    [10, "bird", ["USA", "Pakistan"], "road", ["ran"], False],
    #    [8, "cat", ["Pakistan"], "zoo", ["ate"], True],
    #]
)

if __name__ == "__main__":
    demo.launch()