T.Masuda commited on
Commit
9bc1856
·
1 Parent(s): 0c7d0be

update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -30,7 +30,7 @@ def generate(input_text, maxlen):
30
  generated_text = output[0]['generated_text']
31
  return generated_text
32
 
33
- with gr.Blocks(title='text generation ja') as chatbox:
34
  gr.Markdown('# Text Generation JA')
35
 
36
  chatbot = gr.Chatbot(label='generated text')
@@ -47,4 +47,5 @@ with gr.Blocks(title='text generation ja') as chatbox:
47
 
48
  msg.submit(respond, [msg, maxlen, chatbot], [msg, chatbot])
49
 
50
- chatbox.launch()
 
 
30
  generated_text = output[0]['generated_text']
31
  return generated_text
32
 
33
+ with gr.Blocks(title='text generation ja') as app:
34
  gr.Markdown('# Text Generation JA')
35
 
36
  chatbot = gr.Chatbot(label='generated text')
 
47
 
48
  msg.submit(respond, [msg, maxlen, chatbot], [msg, chatbot])
49
 
50
+ app.queue(concurrency_count=20)
51
+ app.launch()