diff options
| author | Grail Finder <wohilas@gmail.com> | 2026-03-01 08:22:02 +0300 |
|---|---|---|
| committer | Grail Finder <wohilas@gmail.com> | 2026-03-01 08:22:02 +0300 |
| commit | cdfccf9a2440dc4d8094e7ae94aa85cb446e7cfb (patch) | |
| tree | 43658a89dd2fbd89106cf58c6a4a48792f4f97ac /popups.go | |
| parent | 1f112259d2ff58bbe25f25f8c65694d5a7569e68 (diff) | |
Enha (llama.cpp): show loaded model on startup
Diffstat (limited to 'popups.go')
| -rw-r--r-- | popups.go | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,6 +1,7 @@ package main import ( + "gf-lt/models" "slices" "strings" @@ -51,7 +52,7 @@ func showModelSelectionPopup() { // Find the current model index to set as selected currentModelIndex := -1 for i, model := range modelList { - if strings.TrimPrefix(model, "(loaded) ") == chatBody.Model { + if strings.TrimPrefix(model, models.LoadedMark) == chatBody.Model { currentModelIndex = i } modelListWidget.AddItem(model, "", 0, nil) @@ -61,7 +62,7 @@ func showModelSelectionPopup() { modelListWidget.SetCurrentItem(currentModelIndex) } modelListWidget.SetSelectedFunc(func(index int, mainText string, secondaryText string, shortcut rune) { - modelName := strings.TrimPrefix(mainText, "(loaded) ") + modelName := strings.TrimPrefix(mainText, models.LoadedMark) chatBody.Model = modelName cfg.CurrentModel = chatBody.Model pages.RemovePage("modelSelectionPopup") |
