From f8b2b1248c7d3115127704ce3004437923984b67 Mon Sep 17 00:00:00 2001 From: euvre <93761161+euvre@users.noreply.github.com> Date: Tue, 11 Aug 2026 23:46:37 -0700 Subject: [PATCH] fix: drop static catalog check when resolving tenant default models (#17714) --- internal/service/tenant.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/internal/service/tenant.go b/internal/service/tenant.go index e6502bfa45..b11c935b18 100644 --- a/internal/service/tenant.go +++ b/internal/service/tenant.go @@ -526,10 +526,9 @@ func (s *TenantService) GetModelInfo(ctx context.Context, tenantID string, defau return nil, nil, nil, false, err } - // Check if the model exists and is active. The tenant_model row is the - // source of truth here — providers with an empty factory catalog (e.g. - // OpenAI-API-Compatible, whose models are user-defined) cannot be - // validated against the catalog. Mirrors Python's _get_model_info. + // Check if the model exists and is active. Model type validity is + // enforced on the save path against the tenant_model record, so models + // added online that are absent from the static catalog still resolve. modelEntity, err := s.modelDAO.GetModelByProviderIDAndInstanceIDAndModelName(ctx, dao.DB, modelProvider.ID, modelInstance.ID, modelName) if err != nil { if !dao.IsNotFoundErr(err) {