ElPlaguister commited on
Commit
7ffda7a
1 Parent(s): fa30541

Fix requirements.txt

Browse files
Files changed (3) hide show
  1. __pycache__/t5.cpython-39.pyc +0 -0
  2. app.py +12 -13
  3. requirements.txt +1 -1
__pycache__/t5.cpython-39.pyc ADDED
Binary file (1.58 kB). View file
 
app.py CHANGED
@@ -41,17 +41,16 @@ def chat(message, chat_history, model):
41
  chat_history.append((message, response))
42
  return "", chat_history
43
 
44
- if __name__=='__main__':
45
- theme = prepare_theme()
46
- model = T5()
47
-
48
- with gr.Blocks(theme=theme) as demo:
49
- with gr.Row():
50
- with gr.Column(scale=5): # 챗봇 부분
51
- chatbot = gr.Chatbot(label="T5", bubble_full_width=False)
52
- with gr.Row():
53
- txt = gr.Textbox(show_label=False, placeholder='Send a message...', container=False)
54
 
55
- txt.submit(chat, [txt, chatbot], [txt, chatbot])
56
-
57
- demo.launch(debug=True, share=True)
 
 
 
 
 
 
 
 
41
  chat_history.append((message, response))
42
  return "", chat_history
43
 
44
+ theme = prepare_theme()
45
+ model = T5()
 
 
 
 
 
 
 
 
46
 
47
+ with gr.Blocks(theme=theme) as demo:
48
+ with gr.Row():
49
+ with gr.Column(scale=5): # 챗봇 부분
50
+ chatbot = gr.Chatbot(label="T5", bubble_full_width=False)
51
+ with gr.Row():
52
+ txt = gr.Textbox(show_label=False, placeholder='Send a message...', container=False)
53
+
54
+ txt.submit(chat, [txt, chatbot], [txt, chatbot])
55
+
56
+ demo.launch(debug=True, share=True)
requirements.txt CHANGED
@@ -2,4 +2,4 @@ transformers==4.16.2
2
  gradio==4.1.1
3
  numpy==1.26.1
4
  pandas==2.1.2
5
- pytorch==2.0.1
 
2
  gradio==4.1.1
3
  numpy==1.26.1
4
  pandas==2.1.2
5
+ torch==2.0.1