This commit is contained in:
wangmeihua 2025-08-13 11:15:39 +08:00
parent 069e287bdd
commit d629f483dc

View File

@ -17,6 +17,7 @@ class APIService:
debug(f'{uapi=}, {type(uapi.call)}') debug(f'{uapi=}, {type(uapi.call)}')
params_kw = {"input": texts} params_kw = {"input": texts}
b = await uapi.call(upappid, apiname, user, params_kw) b = await uapi.call(upappid, apiname, user, params_kw)
debug(f'{b=}, {type(b)}')
d = json.loads(b.decode('utf-8')) d = json.loads(b.decode('utf-8'))
if d.get("object") != "list" or not d.get("data"): if d.get("object") != "list" or not d.get("data"):
error(f"嵌入服务响应格式错误: {d}") error(f"嵌入服务响应格式错误: {d}")
@ -146,7 +147,7 @@ class APIService:
} }
b = uapi.call(upappid, apiname, user, params_kw) b = uapi.call(upappid, apiname, user, params_kw)
d = json.loads(b.decode('utf-8')) d = json.loads(b.decode('utf-8'))
return d return d
async def neo4j_delete_document(self, request, document_id: str, upappid: str, apiname: str, user: str) -> Dict[str, Any]: async def neo4j_delete_document(self, request, document_id: str, upappid: str, apiname: str, user: str) -> Dict[str, Any]:
"""删除指定文档""" """删除指定文档"""