Rahatara commited on
Commit
f87bbb4
·
verified ·
1 Parent(s): 9695bf8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -1
app.py CHANGED
@@ -15,6 +15,7 @@ def respond(
15
  temperature,
16
  top_p,
17
  ):
 
18
  messages = [{"role": "system", "content": system_message}]
19
 
20
  for val in history:
@@ -45,7 +46,7 @@ For information on how to customize the ChatInterface, peruse the gradio docs: h
45
  demo = gr.ChatInterface(
46
  respond,
47
  additional_inputs=[
48
- gr.Textbox(value="You are a friendly Chatbot.", label="System message"),
49
  gr.Slider(minimum=1, maximum=2048, value=512, step=1, label="Max new tokens"),
50
  gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature"),
51
  gr.Slider(
@@ -56,6 +57,13 @@ demo = gr.ChatInterface(
56
  label="Top-p (nucleus sampling)",
57
  ),
58
  ],
 
 
 
 
 
 
 
59
  )
60
 
61
 
 
15
  temperature,
16
  top_p,
17
  ):
18
+ system_message = "You are a good listener. You advise quick relaxation exercises step-bye-step, suggest avoiding negative thoughts, and guide through manage stress."
19
  messages = [{"role": "system", "content": system_message}]
20
 
21
  for val in history:
 
46
  demo = gr.ChatInterface(
47
  respond,
48
  additional_inputs=[
49
+ gr.Textbox(value="You are a good listener. You advise quick relaxation exercises step-bye-step, suggest avoiding negative thoughts, and guide through manage stress.", label="System message"),
50
  gr.Slider(minimum=1, maximum=2048, value=512, step=1, label="Max new tokens"),
51
  gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature"),
52
  gr.Slider(
 
57
  label="Top-p (nucleus sampling)",
58
  ),
59
  ],
60
+ examples = [
61
+ ["I am feeling overwhelming"],
62
+ ["I am tired"],
63
+ ["It was a long day"]
64
+ ],
65
+
66
+ title = "Calm Mate :)"
67
  )
68
 
69