mirror of
https://github.com/coalaura/whiskr.git
synced 2025-09-09 17:29:54 +00:00
fixes and dynamic prompts
This commit is contained in:
@@ -23,6 +23,8 @@ type Model struct {
|
||||
var ModelMap = make(map[string]*Model)
|
||||
|
||||
func LoadModels() ([]*Model, error) {
|
||||
log.Info("Loading models...")
|
||||
|
||||
client := OpenRouterClient()
|
||||
|
||||
list, err := client.ListUserModels(context.Background())
|
||||
@@ -56,6 +58,8 @@ func LoadModels() ([]*Model, error) {
|
||||
ModelMap[model.ID] = m
|
||||
}
|
||||
|
||||
log.Infof("Loaded %d models\n", len(models))
|
||||
|
||||
return models, nil
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user