divamgupta / diffusionbee-stable-diffusion-ui

Diffusion Bee is the easiest way to run Stable Diffusion locally on your M1 Mac. Comes with a one-click installer. No dependencies or technical knowledge needed.
https://diffusionbee.com
GNU Affero General Public License v3.0
12.45k stars 612 forks source link

Please add a customize styles option #535

Open kernelzeroday opened 1 month ago

kernelzeroday commented 1 month ago

When I select a style I would like to see what that style is applying, and change these or create my own styles from scratch. My understanding is this is not a Lora, but injected prompt tokens?

Please correct my understanding if this is wrong, and consider adding a style customization or at least a way to view the applied style tokens.

clemsam commented 3 days ago

It's possible to edit the asar.app file inside DiffusionBee – but I don't have the necessary equipment for that.

Nevertheless, you may have a look at its pre-defined prompt-styles thus: – open DiffusionBee.app with right-click selecting "show package content" (or similar) – open "Contents/Resources/ and !!! MAKE A COPY of "app.asar". !!! – open "app.asar" with textEdit – find any style by: æ-F then type e.g. "neonpunk" which get's you =>

{name:"neonpunk",prompt:"neonpunk style {prompt} . cyberpunk, vaporwave, neon, vibes, vibrant, stunningly beautiful, crisp, detailed, sleek, ultramodern, magenta highlights, dark purple shadows, high contrast, cinematic, ultra detailed, intricate, professional",negative_prompt:"painting, drawing, illustration, glitch, deformed, mutated, cross-eyed, ugly, disfigured",tags:["Popular"]}

As you can see it's got a tag "Popular" … I changed this to "Meine! " (where 1 space at end were crucial, as changing the number of chars gets you a javascript error!). You can even add such a tag to styles without them – but you must "delete" the additional 17 chars somewhere else inside its definition; e.g. "cross-eyed, ugly," can be deleted and DiffusionBee will start, but then –theses negative_prompts no longer exist !!! You can change the order of styles by æ-X'ing its definition and æ-V'ing it behind some previous or following definition.

There's also a definition for tags' order and default selection, so æ-F in my already customized case gets: "tags":[["Meine! ","All"]],"default_selected_tag":"Meine! "

Additionally, if you change/add an undefined tag (like I did with "pixelArt", "retroGame" and others to "Child's") the app will add your "invention" to its GUI. (I didn't find out yet how you might influence the "All" tag…)

Please be aware that hampering with internal codes is dangerous – I tried this on an entirely duplicated DiffusioBee. And hopefully here's a screenshot: …

DiffusionBee_custom-styles