An Emacs shell for OpenAI’s DALL-E
For related packages, see:
If you’re finding dall-e-shell
useful, help make the project sustainable and consider ✨sponsoring✨.
dall-e-shell
is in development. Please report issues or send pull requests for improvements.
Finding it useful? Like the package? I’d love to hear from you. Get in touch (Mastodon / Twitter / Reddit / Email).
(require 'dall-e-shell)
If using use-package, you can install with :ensure t
.
(use-package dall-e-shell :ensure t :custom ((dall-e-shell-openai-key (lambda () (auth-source-pass-get 'secret "openai-key")))))
You’ll first need to get a key from OpenAI.
;; if you are using the "pass" password manager (setq dall-e-shell-openai-key (lambda () ;; (auth-source-pass-get 'secret "openai-key") ; alternative using pass support in auth-sources (nth 0 (process-lines "pass" "show" "openai-key")))) ;; or if using auth-sources, e.g., so the file ~/.authinfo has this line: ;; machine api.openai.com password OPENAI_KEY (setq dall-e-shell-openai-key (auth-source-pick-first-password :host "api.openai.com")) ;; or same as previous but lazy loaded (prevents unexpected passphrase prompt) (setq dall-e-shell-openai-key (lambda () (auth-source-pick-first-password :host "api.openai.com")))
M-x set-variable dall-e-shell-openai-key
(setq dall-e-shell-openai-key "my key")
(setq dall-e-shell-openai-key (getenv "OPENAI_API_KEY"))
Launch with M-x dall-e-shell
.
Note: M-x =dall-e-shell
keeps a single shell around, refocusing if needed. To launch multiple shells, use C-u M-x dall-e-shell
.
Type clear
as a prompt.
Alternatively, use either M-x dall-e-shell-clear-buffer
or M-x comint-clear-buffer
.
👉 Find my work useful? Support this work via GitHub Sponsors or buy my iOS apps.
My other utilities, packages, apps, writing…RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4