or run

tessl search
Log in

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
pypipkg:pypi/cloudinary@1.44.x
tile.json

tessl/pypi-cloudinary

tessl install tessl/pypi-cloudinary@1.44.0

Python and Django SDK for Cloudinary, a cloud-based image and video management service with comprehensive transformation, optimization, and delivery capabilities

Agent Success

Agent success rate when using this tile

94%

Improvement

Agent success rate improvement when using this tile compared to baseline

1.08x

Baseline

Agent success rate without this tile

87%

task.mdevals/scenario-5/

Image Quality Optimizer

A utility that generates multiple image URLs with different quality settings to help users find the optimal balance between file size and visual quality for their web applications.

Capabilities

Generate URLs with numeric quality values

  • Calling generate_quality_url("sample", 85) returns a URL containing the quality parameter q_85 @test
  • Calling generate_quality_url("photo", 100) returns a URL containing the quality parameter q_100 @test
  • Calling generate_quality_url("image", 50) returns a URL containing the quality parameter q_50 @test

Generate URLs with automatic quality optimization

  • Calling generate_quality_url("sample", "auto") returns a URL containing the quality parameter q_auto @test
  • Calling generate_quality_url("sample", "auto:good") returns a URL containing the quality parameter q_auto:good @test
  • Calling generate_quality_url("sample", "auto:best") returns a URL containing the quality parameter q_auto:best @test
  • Calling generate_quality_url("sample", "auto:eco") returns a URL containing the quality parameter q_auto:eco @test

Generate URLs with quality and transformation chains

  • Calling generate_quality_url("sample", "auto", width=800, crop="fill") returns a URL with both quality and transformation parameters @test
  • Calling compare_quality_settings("sample", [75, "auto", "auto:best"]) returns a dict with three URLs, each with different quality settings @test

Implementation

@generates

API

def generate_quality_url(public_id, quality, **transformations):
    """
    Generate a Cloudinary URL for an image with specified quality settings.

    Args:
        public_id (str): The public ID of the image on Cloudinary
        quality (int|str): Quality setting - can be integer (1-100) or string
                          ('auto', 'auto:good', 'auto:best', 'auto:eco', 'auto:low')
        **transformations: Additional transformation parameters (e.g., width, height,
                          crop, format, etc.)

    Returns:
        str: The generated Cloudinary URL with quality transformations
    """
    pass

def compare_quality_settings(public_id, quality_values, **base_transformations):
    """
    Generate multiple URLs for the same image with different quality settings.

    Args:
        public_id (str): The public ID of the image on Cloudinary
        quality_values (list): List of quality values to compare (can be integers
                              and/or strings)
        **base_transformations: Base transformation parameters to apply to all URLs

    Returns:
        dict: Dictionary mapping quality values to their respective URLs
    """
    pass

Dependencies { .dependencies }

cloudinary { .dependency }

Provides image transformation and URL generation capabilities.

@satisfied-by