Metal3d commited on
Commit
103b4b8
·
unverified ·
1 Parent(s): 73839bd

Better presentation

Browse files
Files changed (1) hide show
  1. main.py +19 -5
main.py CHANGED
@@ -128,26 +128,40 @@ with gr.Blocks(js=JS) as demo:
128
  show_label=True,
129
  container=True,
130
  elem_classes="auto-scroll",
131
- max_height="90vh",
132
  render=False,
 
133
  )
134
- with gr.Row(equal_height=True, height="90vh"):
135
  with gr.Column(scale=3):
136
  gr.ChatInterface(
137
  chat,
138
  type="messages",
139
  chatbot=chat_bot,
140
- title=str(model_name),
141
  description=(
142
- f"*{model_name}* is a large language model "
143
  "trained on a mixture of instruction and "
144
- "conversational data."
 
 
 
145
  ),
146
  additional_outputs=[reasoning],
147
  )
148
 
149
  with gr.Column():
150
  reasoning.render()
 
 
 
 
 
 
 
 
 
 
 
151
 
152
 
153
  if __name__ == "__main__":
 
128
  show_label=True,
129
  container=True,
130
  elem_classes="auto-scroll",
 
131
  render=False,
132
+ height="80vh",
133
  )
134
+ with gr.Row(equal_height=True):
135
  with gr.Column(scale=3):
136
  gr.ChatInterface(
137
  chat,
138
  type="messages",
139
  chatbot=chat_bot,
140
+ title="Simple conversational AI with reasoning",
141
  description=(
142
+ f"We're using the **{model_name}**. It is a large language model "
143
  "trained on a mixture of instruction and "
144
+ "conversational data. It has the capability to reason about the "
145
+ "prompt (the user question). "
146
+ "When you ask a question, you can see its thoughts "
147
+ "on the left block."
148
  ),
149
  additional_outputs=[reasoning],
150
  )
151
 
152
  with gr.Column():
153
  reasoning.render()
154
+ gr.Markdown(
155
+ "\n\n"
156
+ "Note that we are deliberately using a small model with 1.5B parameters. "
157
+ "In spite of this, the model's reasoning capability offers highly relevant "
158
+ "answer generation. This interface can run on a personal computer if you have 6GB of GPU memory."
159
+ "\n\n"
160
+ "See [The model page](https://huggingface.co/deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B) "
161
+ "for more information.",
162
+ container=True,
163
+ max_height="20vh",
164
+ )
165
 
166
 
167
  if __name__ == "__main__":