update UI, fix #212
Former-commit-id: ac92c2bd7c47353759474fad9412f21b38c65501
This commit is contained in:
@@ -73,6 +73,7 @@ class WebChatModel(ChatModel):
|
||||
chatbot: List[Tuple[str, str]],
|
||||
query: str,
|
||||
history: List[Tuple[str, str]],
|
||||
prefix: str,
|
||||
max_new_tokens: int,
|
||||
top_p: float,
|
||||
temperature: float
|
||||
@@ -80,7 +81,7 @@ class WebChatModel(ChatModel):
|
||||
chatbot.append([query, ""])
|
||||
response = ""
|
||||
for new_text in self.stream_chat(
|
||||
query, history, max_new_tokens=max_new_tokens, top_p=top_p, temperature=temperature
|
||||
query, history, prefix, max_new_tokens=max_new_tokens, top_p=top_p, temperature=temperature
|
||||
):
|
||||
response += new_text
|
||||
new_history = history + [(query, response)]
|
||||
|
||||
Reference in New Issue
Block a user