mirror of
https://github.com/APIParkLab/APIPark.git
synced 2026-06-14 20:41:15 +08:00
Merge remote-tracking branch 'origin/feature/sunanzhi/1.6' into feature/1.6-liujian
This commit is contained in:
+7
-2
@@ -105,7 +105,9 @@ func (i *imlProviderModule) OnInit() {
|
||||
}
|
||||
} else {
|
||||
provider, _ := model_runtime.NewCustomizeProvider(p.Id, p.Name, iModels, p.DefaultLLM, p.Config)
|
||||
model_runtime.Register(p.Id, provider)
|
||||
if provider != nil {
|
||||
model_runtime.Register(p.Id, provider)
|
||||
}
|
||||
}
|
||||
}
|
||||
i.transaction.Transaction(ctx, func(ctx context.Context) error {
|
||||
@@ -644,8 +646,11 @@ func (i *imlProviderModule) UpdateProviderConfig(ctx context.Context, id string,
|
||||
}
|
||||
// customize provider
|
||||
if info.Type == 1 {
|
||||
if uri, uriErr := model_runtime.GetCustomizeProviderURI(input.Config, false); uriErr != nil {
|
||||
uri, uriErr := model_runtime.GetCustomizeProviderURI(input.Config, false)
|
||||
if uriErr != nil {
|
||||
p.SetURI(uri)
|
||||
} else {
|
||||
return uriErr
|
||||
}
|
||||
}
|
||||
if *pInfo.Status == 0 {
|
||||
|
||||
Reference in New Issue
Block a user