General  ·  Official

slack-gif-creator

Knowledge and utilities for creating animated GIFs optimized for Slack.

human agent ↗

Composite

3.6

C 4.4 · A 3.1

How we got there

Craft · D1–D5

D1 · Trigger clarity 4.5
D2 · Output specificity 4.5
D3 · Scope precision 4.5
D4 · Self-containment 4.5
D5 · Reusability 3.5

Adoption · A1–A5

A1 · Maintenance 2.5
A2 · Documentation 3.3
A3 · License 2.5
A4 · Adoption 5.0
A5 · Authorship 2.0

Spec

When this fires, what it takes, how it installs

Fires when

  • user asks for an animated GIF sized for Slack (custom emoji or in-message)
  • user wants a small looping animation written with PIL primitives (no video-encoder dependency)
  • user wants reusable easing functions (elastic, bounce, back, cubic) and a frame builder with palette quantization
  • agent workflows that emit reaction GIFs / status indicators / celebration overlays as part of a larger task

Skip when

  • user wants photorealistic motion, video frames, or anything beyond geometric PIL primitives
  • user uploads an image and expects automatic style transfer or AI generation — the skill loads images via PIL but provides no model
  • user needs alpha-channel transparency (GIFs are saved RGB; transparent backgrounds not wired in this toolkit)
  • user needs SVG / Lottie / APNG / WebM — the only output is .gif
  • user expects pre-packaged emoji graphics or icon library — the SKILL.md is explicit that none ship

Takes

  • prompt:free text a brief animation idea — the skill expects Claude to translate it into PIL drawing code, not a fill-in-the-blanks form
  • file:png/jpg optional — user-uploaded image loaded via PIL.Image.open; the skill provides no AI interpretation, the agent decides whether to use it directly or as inspiration

Returns

  • file:gif 128x128 emoji at 12 frames / 15 fps / 48 colors → 63 KB looping (loop=0, infinite); 480x480 message at 30 frames / 20 fps / 96 colors → 1.37 MB (over the comfortable Slack inline threshold)

Install

pip install pillow>=10.0.0 imageio>=2.31.0 imageio-ffmpeg>=0.4.9 numpy>=1.24.0

Ships a working requirements.txt (rare among the anthropic skills). Zero system deps; pure-Python via Pillow + imageio. Installed cleanly into a fresh venv in <10s on Python 3.11.

Caveats

  • FPS is silently quantized to GIF-spec centiseconds. Requesting fps=15 gives a frame duration of 1000/15 ≈ 66.67 ms, which imageio rounds to 60 ms — the resulting GIF plays at 16.7 fps, not 15. The validator reports the real 16.7 fps, but GIFBuilder.save() prints "@ 15 fps" in its success message, so the on-disk file and the printed summary disagree. Anything outside {10, 12.5, 16.7, 20, 25, 33.3, 50, 100} fps will drift.
  • Single-frame "GIFs" pass validation. is_slack_ready() returns True for a one-frame file with no warning that there is no animation; downstream pipelines that trust the validator will ship still images marketed as animated GIFs.
  • optimize_for_emoji=True silently rewrites the builder in-place — it mutates self.width / self.height to 128 and decimates self.frames from N to ~12. Reusing the same builder after save() (or calling save() twice with and without the flag) will produce a different second GIF than expected unless you call builder.clear() and re-add frames.
  • No alpha channel in output. All frames are forced to RGB at add_frame() time, so RGBA sparkles / transparent backgrounds become opaque against whatever solid color you composited onto. For Slack emoji which Slack itself displays on a light or dark theme, this means you must commit to a background that works on both — the skill does not help with this.
  • GIFBuilder.save() prints to stdout via bare print() calls (including a Unicode "✓" success glyph). Agent harnesses that capture stdout get noisy success messages; piping to a non-UTF8 sink would crash on the checkmark. Easy to wrap, but worth knowing before embedding in a CLI.
  • No font shipped for draw_text — it falls back to ImageFont.load_default(), which is the tiny built-in PIL bitmap font (~6×11 px). Useful for nothing on a 128×128 emoji. The SKILL.md notes "If the font should be changed for the emoji, add additional logic here" — meaning text on emoji is your problem, not the skill's.
  • 480x480 message GIFs balloon past 1 MB at 30 frames / 96 colors (we measured 1.37 MB). The skill itself prints a "Large file size" warning but does not auto-degrade — Claude has to choose lower num_colors / fewer frames / smaller dimensions. The optimization advice in the SKILL.md is correct; the defaults are not aggressive enough.
02 — Cross-validation

2 sources verified

Install

Use this skill

/plugin install slack-gif-creator
Use cases

Tasks this skill helps with


Auto-indexed. Editorial review pending — score is based on the rubric only.