mirror of
https://github.com/RYDE-WORK/Langchain-Chatchat.git
synced 2026-01-29 18:29:44 +08:00
fix bug, add dependencies: strsimpy, markdownify
This commit is contained in:
parent
03e55e11c4
commit
27418ba9fa
@ -27,7 +27,11 @@ pathlib
|
||||
pytest
|
||||
scikit-learn
|
||||
numexpr
|
||||
strsimpy
|
||||
markdownify
|
||||
|
||||
vllm>=0.2.0; sys_platform == "linux"
|
||||
|
||||
# online api libs
|
||||
# zhipuai
|
||||
# dashscope>=1.10.0 # qwen
|
||||
|
||||
@ -26,6 +26,8 @@ pathlib
|
||||
pytest
|
||||
scikit-learn
|
||||
numexpr
|
||||
strsimpy
|
||||
markdownify
|
||||
|
||||
vllm>=0.2.0; sys_platform == "linux"
|
||||
|
||||
|
||||
@ -93,8 +93,8 @@ def test_knowledge_chat(api="/chat/knowledge_base_chat"):
|
||||
data = json.loads(line)
|
||||
if "answer" in data:
|
||||
print(data["answer"], end="", flush=True)
|
||||
pprint(data)
|
||||
assert "docs" in data and len(data["docs"]) > 0
|
||||
pprint(data["docs"])
|
||||
assert response.status_code == 200
|
||||
|
||||
|
||||
|
||||
@ -50,7 +50,7 @@ def file_exists(kb: str, selected_rows: List) -> Tuple[str, str]:
|
||||
return "", ""
|
||||
|
||||
|
||||
def knowledge_base_page(api: ApiRequest):
|
||||
def knowledge_base_page(api: ApiRequest, is_lite: bool = None):
|
||||
try:
|
||||
kb_list = {x["kb_name"]: x for x in get_kb_details()}
|
||||
except Exception as e:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user