Prompthumanizer commited on
Commit
8376b0b
·
verified ·
1 Parent(s): 4e237cf

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -1247,7 +1247,7 @@ def create_jain_interface():
1247
 
1248
  def submit_message(message, history):
1249
  """메시지 전송 처리"""
1250
- return chat_function(message, history)
1251
 
1252
  # 이벤트 연결
1253
  send_btn.click(
@@ -1264,16 +1264,19 @@ def create_jain_interface():
1264
 
1265
  refresh_btn.click(
1266
  fn=get_system_status,
 
1267
  outputs=system_status
1268
  )
1269
 
1270
  clear_btn.click(
1271
- fn=clear_memory,
 
1272
  outputs=[chatbot, msg_input]
1273
  )
1274
 
1275
  example_btn.click(
1276
  fn=set_example,
 
1277
  outputs=msg_input
1278
  )
1279
 
 
1247
 
1248
  def submit_message(message, history):
1249
  """메시지 전송 처리"""
1250
+ return chat_function(message, history), "" # 챗봇 출력 후 입력창 초기화
1251
 
1252
  # 이벤트 연결
1253
  send_btn.click(
 
1264
 
1265
  refresh_btn.click(
1266
  fn=get_system_status,
1267
+ inputs=None,
1268
  outputs=system_status
1269
  )
1270
 
1271
  clear_btn.click(
1272
+ fn=lambda: ([], ""), # 메모리 및 입력창 초기화
1273
+ inputs=None,
1274
  outputs=[chatbot, msg_input]
1275
  )
1276
 
1277
  example_btn.click(
1278
  fn=set_example,
1279
+ inputs=None,
1280
  outputs=msg_input
1281
  )
1282