tessl install tessl/pypi-cloudinary@1.44.0Python 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%
Build a system that generates reports on image assets stored in a cloud media management service, using search functionality to query and analyze large collections of images.
Your system should provide a function that generates a comprehensive report based on search criteria. The function should:
The function should accept the following parameters:
format_type: Image format to filter by (e.g., "jpg", "png")min_bytes: Minimum file size in bytes (optional, defaults to 0)tag: Tag to filter by (optional)days_back: Number of days to look back from today (optional)Return a dictionary containing:
total_count: Total number of matching imagesimage_ids: List of public IDs for all matching imagestotal_bytes: Combined size of all images in bytesaverage_bytes: Average file size rounded to nearest integer@generates
def generate_image_report(format_type, min_bytes=0, tag=None, days_back=None):
"""Generate a report on images matching the specified criteria.
Args:
format_type (str): Image format to filter by (e.g., "jpg", "png")
min_bytes (int, optional): Minimum file size in bytes. Defaults to 0.
tag (str, optional): Tag to filter by. Defaults to None.
days_back (int, optional): Number of days to look back. Defaults to None.
Returns:
dict: Report containing:
- total_count (int): Total number of matching images
- image_ids (list): List of public IDs
- total_bytes (int): Combined size in bytes
- average_bytes (int): Average file size
"""Provides cloud-based media management capabilities including search, filtering, and pagination functionality.
@satisfied-by