Cran-May commited on
Commit
b17374e
1 Parent(s): c9716b3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -28,7 +28,6 @@ ROLE_TOKENS = {
28
  "system": SYSTEM_TOKEN
29
  }
30
 
31
- system_prompt = SYSTEM_PROMPT
32
 
33
  def get_message_tokens(model, role, content):
34
  message_tokens = model.tokenize(content.encode("utf-8"))
@@ -112,8 +111,9 @@ with gr.Blocks(
112
  """
113
  )
114
  with gr.Row():
115
- with gr.Column(scale=5):
116
  chatbot = gr.Chatbot(label="兮辞如是说").style(height=400)
 
117
  with gr.Column(min_width=80, scale=1):
118
  with gr.Tab(label="设置参数"):
119
  top_p = gr.Slider(
 
28
  "system": SYSTEM_TOKEN
29
  }
30
 
 
31
 
32
  def get_message_tokens(model, role, content):
33
  message_tokens = model.tokenize(content.encode("utf-8"))
 
111
  """
112
  )
113
  with gr.Row():
114
+ with gr.Column(scale=1):
115
  chatbot = gr.Chatbot(label="兮辞如是说").style(height=400)
116
+ system_prompt = gr.Textbox(label="系统提示词", placeholder="", value=SYSTEM_PROMPT, interactive=False)
117
  with gr.Column(min_width=80, scale=1):
118
  with gr.Tab(label="设置参数"):
119
  top_p = gr.Slider(