YKajima commited on
Commit
b61760d
·
1 Parent(s): 78d5f9d

construct the location of the components

Browse files
Files changed (1) hide show
  1. app.py +7 -5
app.py CHANGED
@@ -19,7 +19,7 @@ async def summarize(input_text: str, input_url: str):
19
  {url_content}
20
  """
21
  else:
22
- _prompt = "文章が入力されていないことを主張してください。"
23
 
24
  config = FilmConfig(
25
  "gpt-3.5-turbo",
@@ -45,10 +45,12 @@ async def chat(input_text, input_url):
45
 
46
  with gr.Blocks() as iface:
47
  # UI
48
- input_text = gr.Textbox(label="テキスト")
49
- input_url = gr.Textbox(label="URL")
50
- output_text = gr.Textbox(label="要約")
51
- chat_btn = gr.Button("Chat")
 
 
52
 
53
  # Event handler
54
  chat_btn.click(fn=chat, inputs=[input_text, input_url], outputs=output_text)
 
19
  {url_content}
20
  """
21
  else:
22
+ _prompt = "文章が入力するように促してください。"
23
 
24
  config = FilmConfig(
25
  "gpt-3.5-turbo",
 
45
 
46
  with gr.Blocks() as iface:
47
  # UI
48
+ with gr.Row:
49
+ with gr.Column:
50
+ input_text = gr.Textbox(label="")
51
+ input_url = gr.Textbox(label="")
52
+ chat_btn = gr.Button("Chat")
53
+ output_text = gr.Textbox(label="")
54
 
55
  # Event handler
56
  chat_btn.click(fn=chat, inputs=[input_text, input_url], outputs=output_text)