summaryrefslogtreecommitdiff
path: root/popups.go
diff options
context:
space:
mode:
authorGrail Finder <wohilas@gmail.com>2026-03-02 11:25:20 +0300
committerGrail Finder <wohilas@gmail.com>2026-03-02 11:25:20 +0300
commit4f6000a43ad2ee019a799c5b5154af9f853e2b83 (patch)
treec0a74081e043aeb1e479c8540789050be468c4d9 /popups.go
parent9ba46b40cc7fb058ff506ff554ba19e7337448d9 (diff)
Enha: check if model has vision before giving it vision tools
Diffstat (limited to 'popups.go')
-rw-r--r--popups.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/popups.go b/popups.go
index 471a8d9..9998daa 100644
--- a/popups.go
+++ b/popups.go
@@ -143,6 +143,7 @@ func showAPILinkSelectionPopup() {
apiListWidget.SetSelectedFunc(func(index int, mainText string, secondaryText string, shortcut rune) {
// Update the API in config
cfg.CurrentAPI = mainText
+ UpdateToolCapabilities()
// Update model list based on new API
// Helper function to get model list for a given API (same as in props_table.go)
getModelListForAPI := func(api string) []string {
@@ -162,6 +163,7 @@ func showAPILinkSelectionPopup() {
if len(newModelList) > 0 && !slices.Contains(newModelList, chatBody.Model) {
chatBody.Model = strings.TrimPrefix(newModelList[0], models.LoadedMark)
cfg.CurrentModel = chatBody.Model
+ UpdateToolCapabilities()
}
pages.RemovePage("apiLinkSelectionPopup")
app.SetFocus(textArea)