---
name: "pillow-python-image-manipulator"
description: "Automate batch image editing, watermarking, filtering, and text drawing with Python Pillow."
metadata:
  author: "Python Pillow"
  version: "1.0.0"
  runtime_compatibility:
    - "codex"
    - "claude-code"
    - "cursor"
    - "windsurf"
triggers:
  - "draw text on image pillow"
  - "add watermark python pillow"
  - "batch resize images pillow"
permissions:
  fs_read: true
  fs_write: "workspace"
  shell_exec: false
  net_access: false
---

# Pillow Python Image Manipulation Master

Manipulates images in Python using Pillow (PIL): ImageDraw text rendering with TrueType fonts, ImageFilter Gaussian blurs, alpha compositing, color quantization, and thumbnail generation.

## When to Invoke
Invoke this skill whenever you need to:
- draw text on image pillow
- add watermark python pillow
- batch resize images pillow

## Execution SOP & Rules
1. Open images using Image.open(path) and convert to RGBA when performing alpha compositing.
2. Draw crisp typography with ImageDraw.Draw(img).text((x, y), text, font=ImageFont.truetype('font.ttf', 32)).
3. Use img.thumbnail((max_w, max_h), Image.Resampling.LANCZOS) for high-quality downsampling.
4. Save optimized JPEGs using img.convert('RGB').save(output, 'JPEG', quality=85, optimize=True).

## Verification Checklist
- Run local linting, syntax validation, and type-checks before reporting completion.
- Ensure all created or modified files adhere to workspace boundaries and avoid uncommitted secrets.
- Verify tests or build commands exit cleanly with return code 0.
