LennyHood commited on
Commit
e086b8b
·
verified ·
1 Parent(s): 408dc6e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -6
app.py CHANGED
@@ -81,10 +81,22 @@ additional_inputs=[
81
  )
82
  ]
83
 
 
 
 
 
 
 
 
84
 
85
- gr.ChatInterface(
86
- fn=generate,
87
- chatbot=gr.Chatbot(show_label=False, show_share_button=False, show_copy_button=True, likeable=True, layout="panel"),
88
- additional_inputs=additional_inputs,
89
- title="""Mistral 7B"""
90
- ).launch(show_api=False)
 
 
 
 
 
 
81
  )
82
  ]
83
 
84
+ css = """
85
+ #mkd {
86
+ height: 500px;
87
+ overflow: auto;
88
+ border: 1px solid #ccc;
89
+ }
90
+ """
91
 
92
+ with gr.Blocks(css=css) as demo:
93
+ gr.HTML("<h1><center>Mistral 7B Instruct<h1><center>")
94
+ gr.HTML("<h3><center>In this demo, you can chat with <a href='https://huggingface.co/mistralai/Mistral-7B-Instruct-v0.1'>Mistral-7B-Instruct</a> model. 💬<h3><center>")
95
+ gr.HTML("<h3><center>Learn more about the model <a href='https://huggingface.co/docs/transformers/main/model_doc/mistral'>here</a>. 📚<h3><center>")
96
+ gr.ChatInterface(
97
+ generate,
98
+ additional_inputs=additional_inputs,
99
+ examples=[["What is the secret to life?"], ["Write me a recipe for pancakes."]]
100
+ )
101
+
102
+ demo.queue(concurrency_count=75, max_size=100).launch(debug=True)