{"id":13910608,"url":"https://github.com/dr413677671/PromptGallery-stable-diffusion-webui","last_synced_at":"2025-07-18T09:32:14.349Z","repository":{"id":178537191,"uuid":"570150467","full_name":"dr413677671/PromptGallery-stable-diffusion-webui","owner":"dr413677671","description":"A prompt cookbook worked as stable-diffusion-webui extenstions.","archived":false,"fork":false,"pushed_at":"2023-10-28T07:56:04.000Z","size":1269,"stargazers_count":153,"open_issues_count":6,"forks_count":16,"subscribers_count":7,"default_branch":"main","last_synced_at":"2024-11-15T15:13:07.585Z","etag":null,"topics":["computer-vision","deep-learning","gan","gradio","image-generation","stable-diffusion","stable-diffusion-webui","stable-diffusion-webui-plugin","vuejs"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dr413677671.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-11-24T12:58:58.000Z","updated_at":"2024-10-20T00:53:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"cc632ab7-f152-4226-a2bd-aefa77e78f60","html_url":"https://github.com/dr413677671/PromptGallery-stable-diffusion-webui","commit_stats":null,"previous_names":["dr413677671/promptgallery-stable-diffusion-webui"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dr413677671%2FPromptGallery-stable-diffusion-webui","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dr413677671%2FPromptGallery-stable-diffusion-webui/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dr413677671%2FPromptGallery-stable-diffusion-webui/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dr413677671%2FPromptGallery-stable-diffusion-webui/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dr413677671","download_url":"https://codeload.github.com/dr413677671/PromptGallery-stable-diffusion-webui/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226388662,"owners_count":17617315,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["computer-vision","deep-learning","gan","gradio","image-generation","stable-diffusion","stable-diffusion-webui","stable-diffusion-webui-plugin","vuejs"],"created_at":"2024-08-07T00:01:37.807Z","updated_at":"2024-11-25T19:31:24.792Z","avatar_url":"https://github.com/dr413677671.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"\n\u003ca name=\"readme-top\"\u003e\u003c/a\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n\u003c!-- [![Contributors][contributors-shield]][contributors-url] --\u003e\n[![Forks][forks-shield]][forks-url]\n[![Stargazers][stars-shield]][stars-url]\n[![Issues][issues-shield]][issues-url]\n\n\u003c/div\u003e\n\u003c!-- [![MIT License][license-shield]][license-url]\n[![LinkedIn][linkedin-shield]][linkedin-url] --\u003e\n\n\n\n\u003c!-- PROJECT LOGO --\u003e\n\u003cbr /\u003e\n\u003cdiv align=\"center\"\u003e\n  \u003ca href=\"https://github.com/dr413677671/PromptGallery-stable-diffusion-webui\"\u003e\n    \u003cimg src=\"images/logo.png\" alt=\"Logo\" width=\"206.25\" height=\"131.25\"\u003e\n  \u003c/a\u003e\n\n  \u003ch3 align=\"center\"\u003ePrompt Gallery\u003c/h3\u003e\n  \u003cp align=\"center\"\u003e\n    A prompt cookbook worked as \u003ca href=\"https://github.com/AUTOMATIC1111/stable-diffusion-webui\"\u003estable-diffusion-webui\u003c/a\u003e extenstions.\n    \u003cbr /\u003e\n    \u003ca href=\"https://www.youtube.com/watch?v=9U6-moIJUkk\"\u003e\u003cstrong\u003eWatch Demo »\u003c/strong\u003e\u003c/a\u003e\n    \u003cbr /\u003e\n    \u003cbr /\u003e\n    \u003ca href=\"https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/README.md\"\u003eExplore the docs\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/issues\"\u003eReport Bug\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/issues\"\u003eRequest Feature\u003c/a\u003e\n  \u003c/p\u003e\n\u003c/div\u003e\n\n\n\n\u003c!-- TABLE OF CONTENTS --\u003e\n\u003cdetails\u003e\n  \u003csummary\u003eTable of Contents\u003c/summary\u003e\n  \u003col\u003e\n    \u003cli\u003e\n      \u003ca href=\"#about-the-project\"\u003eAbout The Project\u003c/a\u003e\n      \u003cul\u003e\n        \u003cli\u003e\u003ca href=\"#built-with\"\u003eBuilt With\u003c/a\u003e\u003c/li\u003e\n      \u003c/ul\u003e\n    \u003c/li\u003e\n    \u003cli\u003e\n      \u003ca href=\"#getting-started\"\u003eGetting Started\u003c/a\u003e\n      \u003cul\u003e\n        \u003cli\u003e\u003ca href=\"#Prerequisites-\u0026-Installation\"\u003ePrerequisites\u0026Installation\u003c/a\u003e\u003c/li\u003e\n      \u003c/ul\u003e\n    \u003c/li\u003e\n    \u003cli\u003e\n      \u003ca href=\"#usage\"\u003eUsage\u003c/a\u003e\n      \u003cul\u003e\n        \u003cli\u003e\u003ca href=\"#build-library\"\u003eBuild Library\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#start-stable-diffusion-webui\"\u003eStart stable-diffusion-webui\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#build-library\"\u003eBuild Library\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#start-prompt-gallery\"\u003eStart Prompt Gallery\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#populate-previews-and-qc\"\u003ePopulate previews \u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#populate-previews-and-qc\"\u003eQuality Contorl\u003c/a\u003e\u003c/li\u003e\n      \u003c/ul\u003e\n    \u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#contributing\"\u003eContributing\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#contact\"\u003eContact\u003c/a\u003e\u003c/li\u003e\n    \u003cli\u003e\u003ca href=\"#acknowledgments\"\u003eAcknowledgments\u003c/a\u003e\u003c/li\u003e\n  \u003c/ol\u003e\n\u003c/details\u003e\n\n\n\n\u003c!-- ABOUT THE PROJECT --\u003e\n\n\u003cdiv align=center\u003e\n\u003cimg src='./images/front.JPG'\u003e\n\u003c/div\u003e\n\n## About The Project\n\n\u003e Please star the repo if you likes it :\u003e\n\n\u003e 🐘 Good news: the extension now support webui dark theme.\n\nPrompt Gallery works as a prompt-set library extension of [stable-diffusion-webui](https://github.com/AUTOMATIC1111/stable-diffusion-webui). Stable-diffusion is an AI model which can generate illustration based on text-based prompts\n\nThe extension combined with four features:\n1. prompt-set library management\n2. preview pictures management\n3. select a combination of prompt-sets and generate illustration in webui\n4. avatar/character system\n\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#readme-top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- GETTING STARTED --\u003e\n## Getting Started\n\n\n### Prerequisites \u0026 Installation\n \n1. Install [stable-diffusion-webui](https://github.com/AUTOMATIC1111/stable-diffusion-webui)\n\n2. Edit webui-user.bat (Win) or webui-user.sh (Linux) with these arguments \"--api --listen --cors-allow-origins http://localhost:5173\"\n\n\u003e\u003e ![install](./images/0-1.JPG)\n\n\n3. Start webui\n\n4. Install Prompt-gallery extension in Web-UI\n\n\u003e\u003e 4.1 Inout https://github.com/dr413677671/PromptGallery-stable-diffusion-webui.git in \"URL for extension's git repository\"\n\n\u003e\u003e 4.2 Input \"Prompt Gallery\" in Local directory name\n\n \u003e\u003e ![install](./images/install.JPG)\n\n\nPlease refer to section \u003ca href=\"###Customized extension ip and port (optional)\"\u003eCustomized extension ip and port (optional)\u003c/a\u003e if you are using customized webui ip/port.\n\n\n## Usage\n\nRestart webui. You should see a initial frontpage like this.\n\n![preset](./images/0-0.png)\n\nThere is no preview pictures. Prompt Gallery works like a framework. You need to create your own prompt-set library folloting by two steps:\n1. edit your prompt-set dictionary\n2. generate preview pictures for prompt-sets\n\nPlease follow the instructions below to build your own prompt-set library: Alternatively you could watch the video tutorial:\n\u003ca href=\"https://www.youtube.com/watch?v=9U6-moIJUkk\"\u003eView Demo\u003c/a\u003e\n\n\n### Build prompt-set library\n\nDefinition of avatars.yaml:\n\n| value | negative | param |\n| :-----| ----: | :----: |\n| Positive prompts | Negative prompts | Other params for webui image generation |\n\n#### Build Avatar library\n\n\u003e Avatars is the charater displayed on the top of the extension. Defined your own character by editing \u003cstable-diffusion-webui-path\u003e/extensions/your-prompt-gallery-extension-name/assets/avatars.yaml\n\n\u003e The field \"value\" is the prompt-set for each characters.\n\nTeamplate: \n   ```yaml\n    whiteHair: \n      value: \"1 girl,  blush, White hair, Red eyes, animal ears,  looking at viewer, gothic lolita, dramatic angle, very beautiful, beautiful eyes, \"\n      negative: \"\"\n    pinkGirl: \n      value: \"petite, 1girl, solo, pink hair, very long hair, school uniform, happy,outdoors, flower field, excited\"\n   ```\n\n#### Build prompt-set library\n\n\u003e Prompt-sets are prompts displayed as cart boxes below. \n\n\u003e Customized your own prompt-set by editing \u003cstable-diffusion-webui-path\u003e/extensions/your-prompt-gallery-extension-name/assets/tags.yaml\n\n```yaml\n    category-tier-1:\n      category-tier-1-1:\n        \"prompt-set-name-1\":\n          value: \"prompt1, prompt2\"\n          negative: \"neg-prompt1, neg-prompt2\"\n        \"prompt-set-name-2\"\n          value: \"prompt1\"\n          negative: \"neg-prompt1\"\n      category-tier-1-2:\n        \"prompt-set-name-3\":\n          value: \"prompts\"\n```\n\n\n\u003e The prompt-set are managed hierarchyly (e.g. the config below defined a tier 1 category \"Figure\" containes two tier two categories \"Hair\" and \"Face\")\n\n   ```yaml\n    Figure:\n      Hair:\n        \"ponny-tail\":\n          value: \"ponny-tail\"\n          negative: \"lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, \"\n        \"short_hair\"\n          value: \"short_hair\"\n          negative: \"long_hair，lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, \"\n      Face:\n        \"smile\":\n          value: \"smile\"\n\n    Background:\n      '':\n        simple background:\n          value: simple background\n        sunburst background:\n          value: sunburst background\n      Nature:\n        Space:\n          value: \"space background, space,\"\n        Startrails:\n          value: colorful startrails\n        Woods:\n          value: \"Woods background, fantacy background,\"\n   ```\n\n\u003e Additionally you could edit field \"param\" to customized AI model parameters (or switch models using the webui model selection tab.):\n\n   ```yaml\n    Style:\n      General Effect:\n        \"General_ice_high_res\":\n          value: \"flowing ice, portrait, focus on face, complex, extremely detailed , elegant, CG, (an extremely delicate and beautiful girl), incredibly absurdres, best quality,concept art\"\n          negative: \"lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, \"\n          param: \"Steps: 30, Sampler: Euler, CFG scale: 11.5, Seed: 1058629707, Size: 512x768, Variation seed: 1692844643, Variation seed strength: 0.27, Seed resize from: 1088x512\"\n    Background:\n      '':\n        simple background:\n          value: simple background\n        sunburst background:\n          value: sunburst background\n      Nature:\n        Space:\n          value: \"space background, space,\"\n        Startrails:\n          value: colorful startrails\n   ```\n\n\u003e Useful links for anime prompts:\n\u003e\u003e [sd-danbooru-tags](https://github.com/Vetchems/sd-danbooru-tags) or [DeepDanbooru](https://github.com/KichangKim/DeepDanbooru).\n\n\n### Using Prompt Gallery\n\n1. Slect tab \"Prompt Gallery\" on top navigation bar. You should see your dined prompt-sets in prompt-gallery.\n\n2. Select the avatar (model for demo)\n\n3. Select multiple prompt-sets \n \n4. Click \"send WebUI\"\n\n  ![2-1](./images/2-1.JPG)\n\n5. In a few minutes, Images geneated with teh selected prompt-sets will be downloaded in your browser\n\n  ![2-2](./images/2-2.JPG)\n\n6. The preview picture is missing. To add preview picture for each prompt-set, please refer to the next section.\n\n### Populate previews and QC\n\n1. For newly installed exteantion, there will be no preview pictures for each prompt-set.\n\n  ![3-1](./images/3-1.JPG)\n\n2. Goto tab \"txt2img\" in webui and Select \"Prompt Gallery\" in \"scripts\"\n\n  ![3-2](./images/3-2.JPG)\n\n3. Upload the avatar yaml library mentioned in section \"Build Avatar library\".\n\n  ![3-3](./images/3-3.JPG)\n\n4. Add default prompts or default negative (optional), default prompts are additional prompts that applied for each prompt-set preview picture generation\n\n5. Select \"skip exists\" if you wish to skip generating preview if preview picture exists for a prompt-set\n\n  ![3-4](./images/3-4.JPG)\n\n6. Wait for stable-diffusion-webui generate previews automatically.\n\n  ![3-5](./images/3-5.JPG)\n\n7. Pick the best image for preview picture of each prompt-set.\n\n  ![3-6](./images/3-6.JPG)\n\n8. Reflesh the browser. You should see the preview pictures in Prompt Gallery.\n\n  ![3-7](./images/3-7.JPG)\n\n9. The preview pictures are stored in prompt-gallery-directory/assets/preview/. You could always inspect the pictures manually.\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#readme-top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\n### Cutomize default image generation parameters\n\nSometimes you need to defined the default values for the AI model parameters.\n\n1. Change the params  at the top of webui-directory/extension/prompt-gallery-extension-name/paste_this_to_webui_scripts_folder/prompt_gallery.py\n\n\n```python\nBATCH_SIZE = 4\nN_ITER = 2\nSTEPS = 30\nCFG_SCALE = 11.5\nWIDTH = 512\nHEIGHT = 768\nSAMPLER_INDEX = 1\nRESTORE_FACE = 'true'\nTILING = 'false'\nDO_NOT_SAVE_GRID = 'false'\n```\n\n### Customized extension ip and port (optional)\n\nIf you are using customized ip for webui and the extension fail to automatically detected your customized ip. Please try:\n\n1. Search %extension-path%\\assets\\index.*.js, change \"127.0.0.1\" to your customized webui ip\n\n2. Search %extension-path%\\scripts\\prompt_gallery.py change \n\n```python\npg_ip = \"%your_webui_ip%\" if shared.cmd_opts.listen else 'localhost'\npg_port = %your_webui_port%--\n```\n3. Change the ip address in webui-user.bat (Win) or webui-user.sh (Linux)\n\n\u003c!-- CONTRIBUTING --\u003e\n## Contributing\n\nContributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.\n\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#readme-top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n### Built With\n\n* [![Vue][Vue.js]][Vue-url]\n* [![JavaScript][JSP]][JSP-url]\n* Gradio\n* [![Pytorch][Pytorch]][Pytorch-url]\n* [![React][fastapi-img]][fastapi-url]\n\n\u003c!-- CONTACT --\u003e\n## Talk with me\n\n* dr413677671 - [@zhihu-Calcifer](https://www.zhihu.com/people/kumonoue) - 413677671@qq.com\n* Project Link: [https://github.com/dr413677671/PromptGallery-stable-diffusion-webui](https://github.com/dr413677671/PromptGallery-stable-diffusion-webui)\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#readme-top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\u003c!-- ACKNOWLEDGMENTS --\u003e\n## Acknowledgments\n* [stable-diffusion-webui](https://github.com/AUTOMATIC1111/stable-diffusion-webui)\n* [novelai-tag](https://github.com/blacktunes/novelai-tag)\n* [Gradio](https://github.com/gradio-app/gradio)\n\n\u003cp align=\"right\"\u003e(\u003ca href=\"#readme-top\"\u003eback to top\u003c/a\u003e)\u003c/p\u003e\n\n\n\n\u003c!-- MARKDOWN LINKS \u0026 IMAGES --\u003e\n\u003c!-- https://www.markdownguide.org/basic-syntax/#reference-style-links --\u003e\n[contributors-shield]: https://img.shields.io/github/contributors/dr413677671/PromptGallery-stable-diffusion-webui.svg?style=for-the-badge\n[contributors-url]: https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/graphs/contributors\n[forks-shield]: https://img.shields.io/github/forks/dr413677671/PromptGallery-stable-diffusion-webui.svg?style=for-the-badge\n[forks-url]: https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/network/members\n[stars-shield]: https://img.shields.io/github/stars/dr413677671/PromptGallery-stable-diffusion-webui.svg?style=for-the-badge\n[stars-url]: https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/stargazers\n[issues-shield]: https://img.shields.io/github/issues/dr413677671/PromptGallery-stable-diffusion-webui.svg?style=for-the-badge\n[issues-url]: https://github.com/dr413677671/PromptGallery-stable-diffusion-webui/issues\n\n[product-screenshot]: images/screenshot.png\n[Vue.js]: https://img.shields.io/badge/Vue.js-35495E?style=for-the-badge\u0026logo=vuedotjs\u0026logoColor=4FC08D\n[Vue-url]: https://vuejs.org/\n[JSP]: https://img.shields.io/badge/JavaScript-323330?style=for-the-badge\u0026logo=javascript\u0026logoColor=F7DF1E\n[JSP-url]: https://github.com/TheAlgorithms/JavaScript\n[python-img]: https://img.shields.io/badge/Python-FFD43B?style=for-the-badge\u0026logo=python\u0026logoColor=blue\n[python-url]: https://www.python.org/\n[fastapi-img]: https://img.shields.io/badge/fastapi-109989?style=for-the-badge\u0026logo=FASTAPI\u0026logoColor=white\n[fastapi-url]: https://fastapi.tiangolo.com/\n[Pytorch]: https://img.shields.io/badge/PyTorch-EE4C2C?style=for-the-badge\u0026logo=PyTorch\u0026logoColor=white\n[Pytorch-url]: https://github.com/pytorch/pytorch\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdr413677671%2FPromptGallery-stable-diffusion-webui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdr413677671%2FPromptGallery-stable-diffusion-webui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdr413677671%2FPromptGallery-stable-diffusion-webui/lists"}