skillfed

clip-interrogator

Generate a prompt from an image

clip-interrogator v0.6.0 289.2K downloads/30d#8,004 on PyPI2,979
Permissive license MIT DORMANT released

What it is and what it does

CLIP Interrogator is a prompt engineering tool that analyzes an image and generates a natural-language text prompt describing it, optimized to work with text-to-image models. It combines CLIP and BLIP to understand image content and produce prompts that, when fed back into a generative model, would recreate similar images.

The package is designed primarily as a library for Python scripts. It requires torch, torchvision, transformers, accelerate, open-clip-torch, and several other dependencies. Configuration options let you trade speed and quality for memory usage, and you can rank custom term lists against images. However, the project is dormant—no releases since 2023-03-20 and no recent commits—so it receives no active maintenance or updates.

Use it for:

  • Generate prompts from reference images to create similar artwork without manual prompt writing.
  • Analyze existing images to understand what visual features a model should prioritize.
  • Build custom image-to-prompt pipelines by ranking domain-specific term lists against images.
  • Reverse-engineer prompts from generated images to understand model behavior or reproduce styles.
  • Batch process image collections to extract descriptive prompts for metadata or tagging.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Generates natural-language prompts from images by combining CLIP and BLIP models to reverse-engineer what text would recreate a given image.

Yes, if you need to generate prompts from images and can tolerate dormant maintenance. The package is stable with no known vulnerabilities, but expect no updates or bug fixes. Install only if you're comfortable pinning versions and managing torch dependencies yourself, and if the last release from 2023-03-20 meets your needs.

Install

clip-interrogator on PyPI

pip

pip install clip-interrogator

uv

uv add clip-interrogator

poetry

poetry add clip-interrogator

Installing clip-interrogator

Before you install

Low friction to install, but requires torch and torchvision as runtime dependencies, which are large downloads. Maintenance is dormant—last release was 2023-03-20 and no commits since 2024-05-15, so expect no active support or updates.

License in practice

MIT license is permissive; you can use this package freely in commercial and private projects with minimal restrictions.

Quickstart

pip install clip-interrogator

from clip_interrogator import Config, Interrogator
ci = Interrogator(Config(clip_model_name="ViT-L-14/openai"))
print(ci.interrogate(image))

Requires torch with GPU support (or CPU fallback); on low-VRAM systems, call config.apply_low_vram_defaults() to reduce memory use.

Verify before relying

  • Whether the package works with recent torch versions or if version pinning is needed
  • Current state of precomputed embeddings cache and whether downloads still work
  • Performance and accuracy changes between version 0.5.5 (in docs) and current 0.6.0
  • Exact VRAM requirements and whether 6.3GB and 2.7GB figures remain accurate

Package facts

License MIT (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies 9 — torch, torchvision, Pillow, requests, safetensors, tqdm, open-clip-torch, accelerate, transformers
Maintenance dormant — 1,243 days since the last release
Last repo commit
First released
Downloads 289,175/month — #8,004 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: clip_interrogator-0.6.0-py3-none-any.whl

Keywords: blip, clip, prompt-engineering, stable-diffusion, text-to-image

Intended Audience :: DevelopersIntended Audience :: Science/ResearchLicense :: OSI Approved :: MIT LicenseTopic :: EducationTopic :: Scientific/EngineeringTopic :: Scientific/Engineering :: Artificial Intelligence

Tags

image to prompt generationreverse engineer image promptsclip interrogatortext-to-image prompt engineeringimage caption to promptstable diffusion prompt from imageblip clip image analysis
image-analysisprompt-engineeringgenerative-ai

More Scientific/Engineering packages

Further reading