mirror of
https://github.com/mudler/LocalAI.git
synced 2025-01-13 00:10:14 +00:00
chore: simplify passing options to ModelOptions
Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
This commit is contained in:
parent
f157314fb8
commit
6e468e9b8e
@ -129,10 +129,8 @@ func newModel(cl *config.BackendConfigLoader, ml *model.ModelLoader, appConfig *
|
|||||||
|
|
||||||
if cfg.Pipeline.LLM == "" || cfg.Pipeline.TTS == "" || cfg.Pipeline.Transcription == "" {
|
if cfg.Pipeline.LLM == "" || cfg.Pipeline.TTS == "" || cfg.Pipeline.Transcription == "" {
|
||||||
// If we don't have Wrapped model definitions, just return a standard model
|
// If we don't have Wrapped model definitions, just return a standard model
|
||||||
opts := backend.ModelOptions(*cfg, appConfig, []model.Option{
|
opts := backend.ModelOptions(*cfg, appConfig, model.WithBackendString(cfg.Backend),
|
||||||
model.WithBackendString(cfg.Backend),
|
model.WithModel(cfg.Model))
|
||||||
model.WithModel(cfg.Model),
|
|
||||||
})
|
|
||||||
return ml.BackendLoader(opts...)
|
return ml.BackendLoader(opts...)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user