Unlock The Full Power Of Stable Diffusion with Wildcards & Dynamic Prompts!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello there Engineers welcome to prompt geek in today's video I'm going to be showing you how you can create infinite counter portraits using stable diffusion with the dynamic prompts and wild cards extension and I'm going to show you how to create your own wild cards to control the exact items and elements that picture will show let's start off by installing this extension you're going to go to the extensions tab available load from search here for dynamic prompts you're then going to install it of this button go back to installed check for updates click apply and restart the UI when you start stable diffusion you'll now see down here in the extensions area Dynamic prompts and it's automatically enabled there are resources on the GitHub page for this Dynamic promise extension we've got the syntax tutorials lots of information there and you could of course read all of this or if you would prefer carry on watching this video because I'm going to show you exactly how it works right now so I'm using rev animated for this this will work with any model that you're running Dynamic prompts lets you actually eight prompts here that can change all of the elements randomly when using Dynamic prompts I actually like to think of it almost like it was an nft project with nfts they're automatically generated and they have different items different hairstyles different colors and facial features but they are built to have things swapped and changed you want to have the same level of variety available to you with your prompt as well to start off with our prefix keywords like best quality Masterpiece painting of now the first Dynamic element we're going to have here is whether this is going to be a male or female character so we're going to enter that here you need to open with a curly brace you're going to put in the First Choice mail separate it using the pipe symbol and then the next option female and we have to close that off with the closing curly brace next we need to decide what character is going to be we're going to put in another open curly brace and let's come up with a couple of options so we'll say Knight Barbarian Wizard necromance and maybe vampire could be fun we close that out with another curly brace now let's go with the color of hair add in a few colors we close out again and we'll finish this prompt with hair we could also put in a hairstyle here if we wanted I've just chosen a few braided long cropped Mohawk when we won obviously and now with hairstyle so that it knows that's what is created we want our character to have some piece of headwear so we will write here wearing a and then we're gonna do again our curly braces and we're going to put in a couple of items here and another point is probably worth here just so we avoid any and not safer work images YouTube wouldn't like that too much maybe you would you filthy lot with your waifus let's put in here dressed as I want to make sure that they're wearing clothes haven't we because we know that some of these models do tend to get a little bit hot under the collar should we say we can then put in the camera angle we want and we'll just give it a fantasy setting right now and then we're going to close this off with our suffix keywords such as realistic cinematic volumetric lighting painting by Art station highly detailed and 8K we've got our prompt here we could probably stick in Easy negative seven batch size up to four and we're going to generate and you're gonna see four different results and if we have a look at them you can see here we've got best quality Masterpiece painting of a male dressed as a vampire with blonde hair no hairstyle wearing animal ears portray 8 in a magical forest when you have rest of those prompts at the end there it's chosen those from the prompts that we have inside of our curly braces so really fantastic however you might want to use this over and over again you may not want the background just to be that one particular background and if we add more in here and use the curly braces method then we'll end up hitting our 150 token limit very quickly so we can actually use wild cards for if you can download other people's wild cards who've kindly uploaded them to civit AI they are effectively just text files you can download you need to make sure that when you've downloaded them they're in a zip file you will need to then put them into the stable diffusion folder extensions Dynamic prompts wild cards and then you want to extract them here you'll then be able to use them quite easily by just calling them up in the actual prompt editor so if you go back to stable diffusion you'll go to the wild cards manager and you'll want to then hit this button here refresh wildcards the wild cards you've saved will appear here and follow a file structure so if you put them in a folder the folder will appear here and you can then go into the folder and select from there let's go with a standard one for now if we go here and just choose architecture you see there that you see the name of the wild card and then you can also see all of the actual types of architecture listed inside of the wild card now a wild card is effectively a list of keywords so we're going to copy this we go back to our prompt and we're going to add it in here instead of this magic realm it's going to since good in front of and then we'll just paste it in now when you type them out it's double underscore then the folder name slash then the name of the text file followed by another two underscores that's how you call it we then are going to hit generate the first one here is a female wizard with black hair and she is stood in front of a river looks pretty nice we then have this one which is a little bit gross looking he'd say a female dressed as a knight wearing blood on her face stood of run of a wasteland and you could see that it definitely looks like that you can go a lot further than this and you can build your own wild cards I'm going to show you how so building an effective Wild Card takes planning now we've actually done a lot of that already here in that if you look at it we've come up with a structure already to make your remark cards you don't need any special software you commit in notepad we've copied our existing prompt because we're going to use that as the basic structure let's paste that in here we want turkey bar opening prefix keywords including painting of hey and let it choose male female here there's no need to have a separate file here though where it says Knight Barbarian wizard Necromancer vampire these don't have to be here because what you can do with your wild cards is you can actually Nest them inside of other wild cards let's first save this one give it a name so we're going to call this one fantasy prompts and just save that in our folder we create a new notepad and we're going to list in here all of the types of characters that we want our character to potentially be now you can either list them all out yourself by coming up with the ideas or you could of course go to somewhere like ciao GPT and get it to create a list for you and I've done that because I'm lazy I'm going to paste that in and so we've got a list there full of all of the different types of character let's save this now as well and let's call this character type so to call this and wild card and use it as a nested wildcard inside of here all we can do is we go back to the fantasy proms file we're gonna take these options we're going to get rid of them and what we're going to do is we're going to type underscore underscore and then we're going to type in character type because that's the name of the file followed by another two underscores now when we run this it's going to actually get to here and it's going to open the character type file and choose an option from that list now with the hair color we've only got a few hair colors we probably don't need to actually change this sometimes having a wild card isn't really actually that efficient when you've only got four or five options and they fit nicely on the line so we'll leave those there but what we would probably want to do is have more hairstyles so this is another file that we could make we then have the character wearing a crown and a ears or something like that so we'll do the same here we'll actually create another wildcard here and we'll pull this one headgear we've got our shots there by many using view so I mean elevens they are you can do another thing with dynamite prompts called globbing which is where if you have for example many different hairstyle files you can actually have it pull from any of them in this instance let's just say that we didn't have fantasy the meaning of that a better syntax would be to have hairstyle's fantasy because then I might have another file which I call hairstyles Urban or hairstyles sci-fi and in order to actually use any of the hairstyle's files it's as simple as calling the wild card and then at the point where the names are similar you can just pop in an asterisk when you run it it will look for any wild card that begins with the word hairstyles so this can be really powerful as well now I don't want our character to just be stood all the time so let's turn this into a dynamic prompt and also it's worth pointing down you can actually set weights to these as well so let's say that we don't want too many of our characters to be running okay so before each of the keywords you simply type in the weight that you want it to have so we'll go 0.4 and then you follow that with just two colons now the other thing to point out though is that if I set this to 0.4 it will assume that the other keywords in this array here is an array or a string I don't know I gotta remember but the other ones inside of these curly braces will all actually be set at one so I always suggest that unless you want to go through all of these and give them all custom weights you only attach weights to the ones you want to turn out less we've got this standard location wild card if we left it like this it would pull the location from that existing Wild Card however we're gonna have our own here so let's delete this and we're going to put our wildcard in here instead called fantasy setting we leave our suffix keywords as they are that is now ready to go we've created all our files they should all be inside of the wildcards folder under extensions just make sure we've got this saved with any changes and check they've got all of your wild cards in the folder a narrow there ready to go so now we just go back into stable diffusion we did a delete this existing prompt go to the wildcards manager refresh wildcards and see that from Geek fantasies popped up all our wild cards showing up in the folder structure there the main one that we're using is fantasy prompts you may actually have to close stable diffusion or restart it for the wild cards to work properly so ever restarted you copy the wildcard file name go back to the prompt paste that there and there we go we've got our first set of characters using our Wild Card prompt this year that the first one is painting of a female as an assassin a black outfit with black hair shoulder length hair star wearing a hood a medium shot she stood in the dark abyss Where Stars Are Born and Cosmic entities dwell so you can see there that's worked really nicely it takes quite a bit of time and ever effort to actually get the structure put together in the first place but afterwards you can literally generate unlimited amounts of characters or just by hitting that one generate button someone else you can do is you can even call on Laura's in the actual prompt so in your wild card and I've done this with this one so you can see here I've got sorrow vas for an only Mass it's calling on the samurai Punk AI Laura and the weight of it and everything is all set up here in the actual wild card and you can see that you can just generate images all day long using this method there is a bit of a quirky problem because it's using a list of shared hairstyles we end up getting some very feminine looking hairstyles on the male characters and vice versa that might be all right might be what you're after but if you want something more specific then you have to cut it with a bit of wet route if you are an advanced user you can create templates using Ginger 2 which is a script language you can actually get really clever and you can have it so that even characters are Mage it will only call on features from a separate list specifically for Magical characters it's a little bit out of my reach in terms of skills right now so there's a couple of workarounds the first of course is that you create two separate wild cards and then you use the different one depending on my view on male or female characters there is a cooler way to do it and that's by actually creating variables inside of your wildcard so I'll open our wild card here and we want to create a variable right at the beginning of this to Signal a variable use the dollar sign followed by an open girly brace and then we're going to call the variable this way put the name for the variable do you want we're going to call it gender and then we do the equal sign we put an exhalation Mark and then we're going to put in another girly brace and here put mail pipe female and then the closing curly brace for that and of course the closing curly brace wall the first one we opened with that is what sets how a variable and then what we can do is hear where we've got male female written to replace that with the dollar sign the open calibrace the name of the variable and then the cousin curly brace now whenever you mention gender in after this it will use the gender you've chosen here let's put here dollar sign open curly brace gender Frozen curly brace hairstyle that fantasy hairstyle now what this is doing is it's chosen the gender here and we told her what color we would like it to choose from and then we said with a and they'll say here now male or female and to see hairstyle this is a great way to deal with variables if you have to make sure we say now and let's generate again we've got four very different images here all pulling from the wild cards and the variables that we set up there in a painting of a female the female fantasy hairstyle again female fantasy hairstyle male fantasy hairstyle so it's really wet incredibly well there um this is a very powerful tool for being able to do this very quickly and then just a couple of last points there are a couple of other options here you can use one being from Magic this one here is very easy you're right here a woman on Bay Hill press generate and prom magic is going going to fill out the rest of the prompt for you and you could even get lazier than that if you really wanted to you could choose the I'm feeling lucky button and you can just hit that and it'll just do whatever it feels like doing but if you want to be able to make amazing infinite amount of character portraits for your project big story maybe for your RPG that you're playing Then You're Gonna Want to make use of dynamic prompts and the wild cards manager and even just knowing how to do those Dynamic prompts it's great if you want to iterate and test out different things in your prompt give it a go let me know how you get on in the comments down below I hope you found this video useful and if you did please make sure that you like this video subscribe to the channel and hit that notification Bell but I will see you in the next video Until then see you later prompt engineers
Info
Channel: PromptGeek
Views: 4,451
Rating: undefined out of 5
Keywords: Character Portraits, Stable Diffusion, Dynamic Prompts, Wildcards, Infinite Possibilities, Prompt Engineering, AI-generated Art, Customizable Characters, Artistic Prompts, AI-powered Creativity, RPG Character Design, Portrait Generation, Character Customization, Creative Extensions, AI-assisted Artwork, Image Generation, Fantasy Characters, Limitless Creativity, Artistic Techniques, AI-generated Fantasy Worlds, CivitAI, midjourney, NFT art
Id: s-1L6MCVh-E
Channel Id: undefined
Length: 16min 55sec (1015 seconds)
Published: Sun Jul 02 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.