@@ -521,7 +521,7 @@ Downloaded from https://github.com/f/awesome-chatgpt-prompts."
521521 (setq chatgpt-shell-models (chatgpt-shell--make-default-models))
522522 (message " Reloaded %d models " (length chatgpt-shell-models)))
523523
524- (defcustom chatgpt-shell-model-filter nil
524+ (defcustom chatgpt-shell-swap- model-filter nil
525525 " Filter models to swap from using this function as a filter.
526526
527527See `chatgpt-shell-allow-model-versions' and
@@ -547,7 +547,7 @@ See also `chatgpt-shell-swap-model'."
547547(defun chatgpt-shell-allow-model-versions (versions )
548548 " Return a filter function to keep known model VERSIONS only.
549549
550- Use with `chatgpt-shell-model-filter' ."
550+ Use with `chatgpt-shell-swap- model-filter' ."
551551 (lambda (models )
552552 (seq-filter (lambda (model )
553553 (member (map-elt model :version ) versions))
@@ -556,7 +556,7 @@ Use with `chatgpt-shell-model-filter'."
556556(defun chatgpt-shell-ignore-model-versions (versions )
557557 " Return a filter function to drop model VERSIONS.
558558
559- Use with `chatgpt-shell-model-filter' ."
559+ Use with `chatgpt-shell-swap- model-filter' ."
560560 (lambda (models )
561561 (seq-filter (lambda (model )
562562 (not (member (map-elt model :version ) versions)))
@@ -568,6 +568,9 @@ Use with `chatgpt-shell-model-filter'."
568568To select a model, it uses `chatgpt-shell-swap-model-selector' if
569569non-nil; otherwise `completing-read' ."
570570 (interactive )
571+ (when (and (boundp 'chatgpt-shell-model-filter )
572+ chatgpt-shell-model-filter)
573+ (user-error " chatgpt-shell-model-filter is now retired. Please use chatgpt-shell-swap-model-filter" ))
571574 (if-let* ((last-label (chatgpt-shell--model-label))
572575 (width (let ((width))
573576 (mapc (lambda (model )
@@ -583,8 +586,8 @@ non-nil; otherwise `completing-read'."
583586 (format (format " %% -%d s %% s" width)
584587 (map-elt model :provider )
585588 (map-elt model :version )))
586- (if chatgpt-shell-model-filter
587- (funcall chatgpt-shell-model-filter chatgpt-shell-models)
589+ (if chatgpt-shell-swap- model-filter
590+ (funcall chatgpt-shell-swap- model-filter chatgpt-shell-models)
588591 chatgpt-shell-models)))
589592 (selection (nth 1 (split-string (if chatgpt-shell-swap-model-selector
590593 (funcall chatgpt-shell-swap-model-selector models)
0 commit comments