From the course: Introduction to Prompt Engineering for Generative AI

Trying out Dall-E

From the course: Introduction to Prompt Engineering for Generative AI

Trying out Dall-E

- [Instructor] When it comes to language models that can generate images from text, DALL-E by OpenAI is quite the powerhouse. Now, if you head over to OpenAI's blog, there's a great article called "DALL-E: Creating Images from Text," and it shows you a little bit about the inner workings of the model and how it was created. It's really neat, and it's also an interesting way to start digging into how these models represent meaning in something called embeddings. Now, go ahead and create an account, if you already have one, log in, and let's go ahead and make something. So here I am at DALL-E's main page, and there are some great ideas for prompts that work, and I encourage you to take a look at these to get a taste for what's a good prompt. Now we're going to create a booth for a conference. So let's go ahead and type in a booth for an AI chip company. Now you can put a comma and specify style. You can also type in digital art, which is OpenAI's recommendation if you want to enhance results of your generation. And I'm going to do something like this. I'm going to say a branded booth, and I'm also going to say a high-quality photo of a branded booth for an AI chip company, digital art. And I'll go ahead and generate. So once I've submitted my prompt, generating an image from text is going to take a few moments. A lot of times detail is key to getting good generations, so the more details you can squeeze in your prompt, the better off you do. And this is actually quite cool. Now, suppose I want to show this with people in it. I can say slightly crowded booth. And let's see how that comes out. Great. Now if there's something I like, I can always ask the model for variations of it. Great. While these are not as good as I may have expected, I can back up a bit, and let's try to do this one. So here I have variations of this booth. Now, suppose I wanted to create a lobby. The lobby of an AI company's headquarters. So here I have a few ideas for this design. Another cool thing I could do, and we'll just dive into this a little bit, is I can open one of these and edit it. So I can make some room here and sort of delete around this right here. And I can say something like a car inside. And you can describe what it is you want the model to fill the gap with. Sometimes this works, sometimes it's not as successful. You can always try to regenerate over again and make slight modifications. Oh, so this time it gave me this futuristic car to go with. I'm going to take it back a little bit. And I noticed that in this generation, I didn't say a high-quality photo, and maybe that made a little bit of a difference, so I'm going to say high-quality photo of the lobby of an AI chip company headquarters. And let's see if that changes the results. And it looks like it did. It came up with something that looks a bit more realistic. So after a while, you can have a collection of templates for different prompts, maybe some for generating images of spaces, and some for generating different characters, and you can build on those. So the possibilities with something like DALL-E are endless. You can upload your own photos, you can delete portions of images by hitting edit and then describing what it is you want to see in the deleted portion. I encourage you to think of these models that turn text into images and modify images as additional tools in your creativity toolset.

Contents