New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

guff-gif

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

guff-gif

Generate animated GIFs using AI

latest
npmnpm
Version
0.2.1
Version published
Weekly downloads
2
100%
Maintainers
1
Weekly downloads
 
Created
Source

guff

Generate animated GIFs using AI. Claude writes TypeScript code that programmatically generates SVG animation frames using math and loops, which are then converted to PNGs and assembled into optimized GIFs.

Inspired by the Modal claude-slack-gif-creator example and the Anthropic slack-gif-creator skill, which use Claude to generate animation code instead of pixel images. Also supports Gemini's image generation as an alternative provider.

Examples

bouncing ballspinning starpulsing heartrotating cube
a bouncing balla spinning stara pulsing hearta rotating cube
waving flagflickering flameorbiting planetsdancing penguin
a waving flaga flickering flameorbiting planetsa dancing penguin

Usage

Set your API key:

export ANTHROPIC_API_KEY=your-key-here
bunx guff-gif@latest [options] <prompt>

Examples

bunx guff-gif@latest 'a bouncing ball'
bunx guff-gif@latest -f 16 -s 256x256 'a spinning star'
bunx guff-gif@latest -D 50 'a pulsing heart'
bunx guff-gif@latest -d 'a dancing penguin'  # debug: see generated code
bunx guff-gif@latest -m gemini/gemini-2-flash-preview-image-generation 'a waving hand'

Options

FlagDescriptionDefault
-f, --framesNumber of animation frames32
-D, --delayDelay between frames in ms100
-s, --sizeOutput size in WxH format128x128
-c, --colorsMax colors in GIF palette256
-t, --temperatureTemperature 0.0-2.01.0
-o, --outputOutput filenameAuto-generated from prompt
-i, --inputInput image(s) for reference (repeatable)None
-d, --debugLog full prompt, API details, and generated codeOff
-m, --modelProvider/modelclaude/claude-sonnet-4-6
-a, --aspectFrame aspect ratio (Gemini only)1:1
-r, --resolutionResolution: 1k, 2k, 4k (Gemini only)1k

How it works

  • Your prompt is sent to Claude with a system prompt instructing it to write a self-contained TypeScript script
  • Claude generates code that creates SVG strings for each frame using Math.sin, Math.cos, template literals, etc.
  • The script is executed with bun run and outputs a JSON array of SVG strings to stdout
  • Each SVG is converted to a PNG frame using sharp
  • Frames are assembled into an optimized GIF using gifsicle

Requirements

Built entirely with Claude Code.

FAQs

Package last updated on 21 Feb 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts