xenodium / chatgpt-shell

ChatGPT and DALL-E Emacs shells + Org babel 🦄 + a shell maker for other providers
https://xenodium.com
GNU General Public License v3.0
805 stars 72 forks source link

[Q] Is Dall-E 3 supported? #157

Closed NightMachinery closed 9 months ago

NightMachinery commented 9 months ago

Is Dall-E 3 supported? How do I use it in org-babel?

xenodium commented 9 months ago

It wasn't but https://github.com/xenodium/chatgpt-shell/commit/97b43d27906d8589c9c38363002c03735150839a added suport for it.

Use dall-e-shell-model-version if using the shell, otherwise in babel:

#+begin_src dall-e-shell :version dall-e-3
  fluffy clouds
#+end_src
NightMachinery commented 9 months ago

@xenodium DallE3 rewrites the user prompt before creating an image. I wonder if the API returns this new prompt? If so, including it in the output can be useful. The ChatGPT website does this. (Click on any generated image to see its rewritten prompt.)

xenodium commented 9 months ago

Just checked. It comes back in revised_prompt. Added it to the shell. Need to think about how ot handle for babel.

xenodium commented 9 months ago

Added. Use :results both in babel.

#+begin_src dall-e-shell :version dall-e-3 :results both
  Cuberpunk alleyway.
#+end_src

: /var/folders/m7/ky091cp56d5g68nyhl4y7frc0000gn/T/1701219872.png
:
: A dark, grungy, and steamy narrow alleyway set in a cyberpunk cityscape.