docker debugging modification (#82)

This commit is contained in:
KevinHuSh
2024-02-28 18:57:43 +08:00
committed by GitHub
parent 332d4874d0
commit 320cbf545f
7 changed files with 99 additions and 74 deletions

View File

@ -66,7 +66,7 @@ def init_superuser():
chat_mdl = LLMBundle(tenant["id"], LLMType.CHAT, tenant["llm_id"])
msg = chat_mdl.chat(system="", history=[{"role": "user", "content": "Hello!"}], gen_conf={})
if msg.find("ERROR: ") == 0:
print("\33[91m【ERROR】\33[0m: ", "'{}' dosen't work. {}".format(tenant["llm_id"]), msg)
print("\33[91m【ERROR】\33[0m: ", "'{}' dosen't work. {}".format(tenant["llm_id"], msg))
embd_mdl = LLMBundle(tenant["id"], LLMType.EMBEDDING, tenant["embd_id"])
v, c = embd_mdl.encode(["Hello!"])
if c == 0: