test chatbot
Browse files- chatbot/chat_main.py +0 -10
chatbot/chat_main.py
CHANGED
|
@@ -2102,16 +2102,6 @@ def validate_url(url):
|
|
| 2102 |
print(f"URL validation error for {url}: {str(e)}")
|
| 2103 |
return False
|
| 2104 |
|
| 2105 |
-
|
| 2106 |
-
def respond(message, history, system_message, max_new_tokens, temperature, top_p, session_url):
|
| 2107 |
-
"""
|
| 2108 |
-
你的实际响应逻辑(调用 LLM 等)
|
| 2109 |
-
注意:必须接受所有 additional_inputs 的值作为参数
|
| 2110 |
-
"""
|
| 2111 |
-
# 示例:简单回显(替换成你的真实逻辑)
|
| 2112 |
-
response = f"[System: {system_message[:30]}...] You said: {message}"
|
| 2113 |
-
return response
|
| 2114 |
-
|
| 2115 |
def create_financial_chatbot():
|
| 2116 |
"""
|
| 2117 |
返回一个可嵌入的 ChatInterface 组件
|
|
|
|
| 2102 |
print(f"URL validation error for {url}: {str(e)}")
|
| 2103 |
return False
|
| 2104 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2105 |
def create_financial_chatbot():
|
| 2106 |
"""
|
| 2107 |
返回一个可嵌入的 ChatInterface 组件
|