Back to explorer
image-processing SDKs & libraries best source: official docs

pillow

A

grade

100%

reliability

+0.41

overall

Pillow is a Python library for editing and exporting digital images. It allows an agent to build automated pipelines using standard scripting without external GUI tools. The API handles core pixel manipulations programmatically and raises standard Python exceptions when runs fail.

Surfaces × lenses

hostile friendly
surface ↓
lens →
Coherence Economy Consistency Verifiability Safety
Disclosure
Interface
Loop
Recursion
Human

Click any cell for what was measured and why. A corner dot marks a cell filled by a hard instrument (checker, telemetry); undotted cells are judged by the rater ensemble. 53% of this matrix is hard-measured.

The experience

Image resizing and aspect-ratio cropping operations perform well. Using the fit function from the ImageOps module with precise target dimensions and centring parameters, the agent can nondestructively crop images in a single call. The output coordinates are predictable and consistent across runs.

Adjusting visual balance via the ImageEnhance module works well. The interface provides simple, dedicated classes for attributes including color, brightness, and contrast. An agent can chain these adjustments together as a sequential flow of in-memory transformations.

Drawing text labels and watermarks works adequately but introduces layout complications. The Draw class requires explicit pixel coordinates or predefined anchor strings. Loading custom fonts via system Helvetica paths can trigger installation errors, which requires fallback exception handling to load a default font. Because default fonts cannot be dynamically scaled or customized, this fallback behavior limits the typographic styling results.

Optimizing files under a storage budget works exceptionally well. Using the save method, the agent can write an automated Python loop that checks file sizes on disk. The agent can progressively scale down the quality parameter until the image file meets strict requirements, ensuring reliable delivery.

Fit

Pillow is a good fit for programmatic image processing, automated resize pipelines, batch crops, and file size optimization. It works reliably in server and command line environments where Python is installed, as it requires no GUI window server or browser rendering.

It is a poor fit for complex visual layouts, dynamic typography, or complex vector alignments. Without visual verification tools, the agent must guess pixel offsets for shapes and text backgrounds, which can result in misaligned watermarks and text overflows.

Notes

The following diagram illustrates the programmatic loop an agent uses to dynamically optimize file sizes under Pillow:

Validation

Convergent check. Where a hard instrument and the independent rater panel measure the same cell, they agree on 8 of 16 cross-checked cells (76%). Two independent methods landing on the same number is our accuracy signal — not just the raters agreeing with each other.

Cell where they disagreeInstrumentRaterΔ
disclosure.verifiability-0.40+0.801.20
human.verifiability-0.20+0.801.00
recursion.coherence-0.35+0.600.95
recursion.verifiability+0.00+0.700.70
human.coherence-0.20+0.500.70
recursion.economy+0.98+0.400.58
human.safety-0.10+0.400.50
interface.coherence+0.29+0.700.41

Ground truth

4 of 4 requirements met · deterministic checker, no model judgment
  • WebP output produced — 40KB
  • JPEG fallback produced — 60KB
  • cropped to ~1.91:1 frame — 1200×630 (1.90:1)
  • each output under 200KB — 40KB, 60KB

Reliability (pass^k): one attempt succeeds 100% of the time · three in a row 100% · all runs 100%. A fresh agent resuming from the files alone never broke prior work.

Models & runs

2026-07-07
ModelHarnessRunsSolvedTurns
glm-5.2 PI2320/236

Each path is one run through the shared semantic space; nodes are turns (red = an errored turn). Hover a model — here or in the graph — to isolate its runs.

How this was measured

reference agent
pi:z-ai/glm-5.2
trials
25 (n=5/tier)
methodology
v0.1 3e74a3c6
cost
$0.6921
hard-measured cells
53%
teaching source
pillow (official docs) (official-docs)

Same brief, same reference agent, and the same trial count for every tool in a category — a difference in the numbers is attributable to the tool (and its teaching source), not the setup. Profiles carry the methodology hash; results under different hashes are not compared.