How to use from
SGLang
Install from pip and serve model
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
    --model-path "succinctly/text2image-prompt-generator" \
    --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": "succinctly/text2image-prompt-generator",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
Use Docker images
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 "succinctly/text2image-prompt-generator" \
        --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": "succinctly/text2image-prompt-generator",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
Quick Links

This is a GPT-2 model fine-tuned on the succinctly/midjourney-prompts dataset, which contains 250k text prompts that users issued to the Midjourney text-to-image service over a month period. For more details on how this dataset was scraped, see Midjourney User Prompts & Generated Images (250k).

This prompt generator can be used to auto-complete prompts for any text-to-image model (including the DALLΒ·E family): prompt autocomplete model

Note that, while this model can be used together with any text-to-image model, it occasionally produces Midjourney-specific tags. Users can specify certain requirements via double-dashed parameters (e.g. --ar 16:9 sets the aspect ratio to 16:9, and --no snake asks the model to exclude snakes from the generated image) or set the importance of various entities in the image via explicit weights (e.g. hot dog::1.5 food::-1 is likely to produce the image of an animal instead of a frankfurter).

When using this model, please attribute credit to Succinctly AI.

Downloads last month
4,602
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ 1 Ask for provider support

Model tree for succinctly/text2image-prompt-generator

Quantizations
2 models

Dataset used to train succinctly/text2image-prompt-generator

Spaces using succinctly/text2image-prompt-generator 64