mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-06-29 15:31:05 +08:00
Fix: model list (#15860)
### What problem does this PR solve? Remove tenant_llm call in rag. ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
@@ -115,8 +115,6 @@ def init_default_admin():
|
||||
|
||||
|
||||
def add_tenant_for_admin(user_info: dict, role: str):
|
||||
from api.db.services.tenant_llm_service import TenantLLMService
|
||||
from api.db.services.llm_service import get_init_tenant_llm
|
||||
|
||||
tenant = {
|
||||
"id": user_info["id"],
|
||||
@@ -135,10 +133,10 @@ def add_tenant_for_admin(user_info: dict, role: str):
|
||||
"role": role
|
||||
}
|
||||
|
||||
tenant_llm = get_init_tenant_llm(user_info["id"])
|
||||
# tenant_llm = get_init_tenant_llm(user_info["id"])
|
||||
TenantService.insert(**tenant)
|
||||
UserTenantService.insert(**usr_tenant)
|
||||
TenantLLMService.insert_many(tenant_llm)
|
||||
# TenantLLMService.insert_many(tenant_llm)
|
||||
logging.info(
|
||||
f"Added tenant for email: {user_info['email']}, A default tenant has been set; changing the default models after login is strongly recommended.")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user