mirror of
https://git.mirrors.martin98.com/https://github.com/infiniflow/ragflow.git
synced 2025-04-23 14:40:03 +08:00
fix minimax init error (#1537)
### What problem does this PR solve? ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
parent
99adeabc85
commit
a5306e6345
@ -573,6 +573,7 @@ def completion_faq():
|
|||||||
response = MINIO.get(bkt, nm)
|
response = MINIO.get(bkt, nm)
|
||||||
data_type_picture["url"] = base64.b64encode(response).decode('utf-8')
|
data_type_picture["url"] = base64.b64encode(response).decode('utf-8')
|
||||||
data.append(data_type_picture)
|
data.append(data_type_picture)
|
||||||
|
break
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
return server_error_response(e)
|
return server_error_response(e)
|
||||||
|
|
||||||
|
@ -90,6 +90,11 @@ def init_superuser():
|
|||||||
|
|
||||||
|
|
||||||
def init_llm_factory():
|
def init_llm_factory():
|
||||||
|
try:
|
||||||
|
LLMService.filter_delete([(LLM.fid == "MiniMax" or LLM.fid == "Minimax")])
|
||||||
|
except Exception as e:
|
||||||
|
pass
|
||||||
|
|
||||||
factory_llm_infos = json.load(
|
factory_llm_infos = json.load(
|
||||||
open(
|
open(
|
||||||
os.path.join(get_project_base_directory(), "conf", "llm_factories.json"),
|
os.path.join(get_project_base_directory(), "conf", "llm_factories.json"),
|
||||||
@ -108,10 +113,6 @@ def init_llm_factory():
|
|||||||
LLMService.save(**llm_info)
|
LLMService.save(**llm_info)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
pass
|
pass
|
||||||
try:
|
|
||||||
LLMService.filter_delete([(LLM.fid == "MiniMax" or LLM.fid == "Minimax")])
|
|
||||||
except Exception as e:
|
|
||||||
pass
|
|
||||||
|
|
||||||
LLMFactoriesService.filter_delete([LLMFactories.name == "Local"])
|
LLMFactoriesService.filter_delete([LLMFactories.name == "Local"])
|
||||||
LLMService.filter_delete([LLM.fid == "Local"])
|
LLMService.filter_delete([LLM.fid == "Local"])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user