Skip to content

Commit

Permalink
✨ feat(utils): deepseek
Browse files Browse the repository at this point in the history
切换 gptel 使用 deepseek
  • Loading branch information
alisonlai committed Feb 12, 2025
1 parent c8863d4 commit b317666
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions lisp/init-gptel-local.el
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,16 @@
;;; Code:
(require-package 'gptel)

;; OPTIONAL configuration
(setq gptel-backend (gptel-make-azure "Azure-1"
:protocol "https"
:host "chataiwho.openai.azure.com"
:endpoint "/openai/deployments/alison-azure/chat/completions?api-version=2023-05-15"
:stream t
:key "be727c6906d5447798647babf95c03ad"
:models '("gpt-3.5-turbo" "gpt-4"))
)
;; DeepSeek offers an OpenAI compatible API
(setq gptel-model 'deepseek-chat
gptel-backend
(gptel-make-openai "DeepSeek" ;Any name you want
:host "api.deepseek.com"
:endpoint "/chat/completions"
:stream t
:key "sk-key" ;can be a function that returns the key
:models '(deepseek-chat deepseek-coder)))


(provide 'init-gptel-local)
;;; init-gptel-local.el ends here

0 comments on commit b317666

Please sign in to comment.