FredZhang7/anime-prompts-180K
Updated • 107 • 28
How to use ssonpull519/safebooru-prompt-generation with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="ssonpull519/safebooru-prompt-generation") # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("ssonpull519/safebooru-prompt-generation")
model = AutoModelForCausalLM.from_pretrained("ssonpull519/safebooru-prompt-generation")How to use ssonpull519/safebooru-prompt-generation with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "ssonpull519/safebooru-prompt-generation"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "ssonpull519/safebooru-prompt-generation",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/ssonpull519/safebooru-prompt-generation
How to use ssonpull519/safebooru-prompt-generation with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "ssonpull519/safebooru-prompt-generation" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "ssonpull519/safebooru-prompt-generation",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker run --gpus all \
--shm-size 32g \
-p 30000:30000 \
-v ~/.cache/huggingface:/root/.cache/huggingface \
--env "HF_TOKEN=<secret>" \
--ipc=host \
lmsysorg/sglang:latest \
python3 -m sglang.launch_server \
--model-path "ssonpull519/safebooru-prompt-generation" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "ssonpull519/safebooru-prompt-generation",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use ssonpull519/safebooru-prompt-generation with Docker Model Runner:
docker model run hf.co/ssonpull519/safebooru-prompt-generation
A safebooru-style anime prompt generator revised from FredZhang7/anime-anything-promptgen-v2 for SFW applications and description-focused prompts.
You can use it in WebUI Prompt Generator extension by adding appropriate model information to model.json:
{
"Title":"ssonpull519/safebooru-prompt-generation",
"Tokenizer":"distilgpt2",
"Model":"ssonpull519/safebooru-prompt-generation"
}
Input text:
anime girl wearing a red hat and holding a pencil in front of a chalkboard
Generated prompts from FredZhang7/anime-anything-promptgen-v2:
1. anime girl wearing a red hat and holding a pencil in front of a chalkboard, animated, audible speech, audible speech, black hair, blue eyes, blunt ends, commentary, english commentary, fangs, gawr gura, grey hair, hololive, hololive english, long hair, looking at viewer, medium hair, mori calliope, multicolored hair, open mouth, paper, pixel art,
2. anime girl wearing a red hat and holding a pencil in front of a chalkboard, artist name, bangs, black shirt, black skirt, black socks, blue archive, blush, book, bookshelf, chair, closed mouth, collared shirt, desk, hair between eyes, halo, hand on own cheek, hand on table, hand up, head rest, highres, holding, indoors, kneehighs, legs together
3. anime girl wearing a red hat and holding a pencil in front of a chalkboard meme, black eyes, blue hair, bocchi the rock, chair, computer, cup, drinking straw, highres, ijichi nijika, monitor, no shoes, open mouth, pink cardigan, playing games, puffy short sleeves, puffy sleeves, rico rico rnt, short hair, short sleeves, sitting, computer
4. anime girl wearing a red hat and holding a pencil in front of a chalkboard, artist name, bangs, black hair, blue eyes, blurry, blurry background, book, bow, brown bow, buttons, closed mouth, computer, desk, dot nose, expressionless, eyebrows hidden by hair, hair bow, hand up, highres, indoors, kagamihara nadeshiko, long sleeves, looking at viewer, low tw
5. anime girl wearing a red hat and holding a pencil in front of a chalkboard, artist name, blue eyes, blush stickers, buttons, commentary, computer, computer on head, english commentary, green hair, grey shirt, hair between eyes, hatsune miku, headset, highres, long sleeves, looking up, monitor, mouse computer, nintendo switch, no humans, open mouth, paper, pen, pink background, plaid
Generated images with prompts above:
| 1 | 2 | 3 |
|---|---|---|
![]() |
![]() |
![]() |
Generated prompts from ours:
1. anime girl wearing a red hat and holding a pencil in front of a chalkboard, white shirt, black hair, hairclip, green eyes, closed mouth, holding pencil, open mouth, blue dress, skirt, standing, standing, long hair, short sleeves, sidelocks, hat, hat, dress, blush, standing,
2. anime girl wearing a red hat and holding a pencil in front of a chalkboard, school uniform, ribbon, holding pencil, apron, green eyes, hat ornament, holding, holding sword, apron, sword, black hair, holding, blue eyes, gloves, red hair, purple hair, sword, white background, short
3. anime girl wearing a red hat and holding a pencil in front of a chalkboard, blue eyes, purple shirt, medium hair, green hair, green sailor collar, holding pen, holding, long sleeves, red hair, comic, long hair, holding, smile, pencil skirt, pink hair, hat, bow, solo, a
4. anime girl wearing a red hat and holding a pencil in front of a chalkboard, blue hair, solo, shirt, hat, holding, holding pencil, red eyes, holding, blue shirt, holding, artist name, ftkouzaku, red eyes, long sleeves, holding paper, simple background, brown eyes, holding
5. anime girl wearing a red hat and holding a pencil in front of a chalkboard, holding sword, white background, holding sword, green eyes,Bellman, hair between eyes, ahoge, hat, green background, weapon, solo, red jacket, sword, hat, green headwear, black vest, vest, yellow
Generated images with prompts above:
| 1 | 2 | 3 |
|---|---|---|
![]() |
![]() |
![]() |