Skip to main content

Image consistency checks with OpenAI vision models.

Project description

consistize

Check whether an image is consistent with a set of reference images using OpenAI vision models.

Install

pip install -e .

Usage

from consistize import Consistize

checker = Consistize(
    reference_images=["./refs/ref1.jpg", "./refs/ref2.jpg"],
)

result = checker.run("./inputs/target.jpg")
print(result.consistency_score)
print(result.inconsistent_parts)
print(result.background_fix_prompts)

Set OPENAI_API_KEY in your environment or pass api_key to Consistize.

Custom prompt or model

result = checker.run(
    "./inputs/target.jpg",
    prompt="Check the first image against the references; focus on lighting.",
    model="gpt-5.2-pro"
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

consistize-0.1.0.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

consistize-0.1.0-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file consistize-0.1.0.tar.gz.

File metadata

  • Download URL: consistize-0.1.0.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.7

File hashes

Hashes for consistize-0.1.0.tar.gz
Algorithm Hash digest
SHA256 42436c751552cd99ce9fbbbd3ca58c8449ea0dfe664f2e5e55203f68866f3d5b
MD5 72cd7c6b3864a206d7633ae54ef54463
BLAKE2b-256 4a400f93c5d4ced5dd5a1c099df6f0b2b38772591579a0937952385de5d71df9

See more details on using hashes here.

File details

Details for the file consistize-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: consistize-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.7

File hashes

Hashes for consistize-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 038336f8ac0178b273092d432a488a201fdb7bb3bd0da6b81e7c030078c8973e
MD5 4d9054839b3c4fb418259a196f49baf5
BLAKE2b-256 560852d476468f5b0203f3efa0e4f86a2d3c4b4c3f8794f21e9c433844b9c0d4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page