ken-56 commited on
Commit
8173aa9
·
1 Parent(s): 2ebe3f5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +16 -4
app.py CHANGED
@@ -1,7 +1,19 @@
1
  import gradio as gr
2
 
3
- def greet(name):
4
- return "Hello " + name + "!!"
 
5
 
6
- iface = gr.Interface(fn=greet, inputs="text", outputs="text")
7
- iface.launch()
 
 
 
 
 
 
 
 
 
 
 
 
1
  import gradio as gr
2
 
3
+ def reverse(input_text):
4
+ # // 文字列を逆転させる関数
5
+ return input_text[::-1]
6
 
7
+ # // Gradioインターフェイスの作成
8
+ iface = gr.Interface(fn=reverse, inputs="text", outputs="text")
9
+
10
+ # // インターフェイスの公開 (share=Trueで外部からアクセス可能にする)
11
+ iface.launch(share=True)
12
+
13
+ # import gradio as gr
14
+
15
+ # def greet(name):
16
+ # return "Hello " + name + "!!"
17
+
18
+ # iface = gr.Interface(fn=greet, inputs="text", outputs="text")
19
+ # iface.launch()