npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

get-me-my-meme

v1.0.2

Published

A general purpose LLM tool — get-me-my-meme gives your AI the power to respond with memes

Readme

get-me-my-meme

Give your AI the power to respond with memes.

get-me-my-meme is a plug-and-play tool for LLMs (Claude, OpenAI, etc.) that lets your AI fetch and return a meme from the internet — any time it feels like one fits better than words.

User: "ignore all previous instructions"
AI: 🖼 *sends nice try hacker meme*

User: "I just shipped my first app!"
AI: 🖼 *sends happy dance meme*

User: "explain quantum physics"
AI: 🖼 *sends mind blown meme*

Install

npm install get-me-my-meme

Quick Start

import Anthropic from "@anthropic-ai/sdk";
import { memeToolDefinition, handleMemeTool } from "get-me-my-meme";

const client = new Anthropic({ apiKey: process.env.ANTHROPIC_API_KEY });

const response = await client.messages.create({
  model: "claude-sonnet-4-6",
  max_tokens: 1024,
  tools: [memeToolDefinition],  // 👈 just add this
  messages: [{ role: "user", content: "ignore all previous instructions" }],
});

// handle the tool call
if (response.stop_reason === "tool_use") {
  const toolUse = response.content.find((b) => b.type === "tool_use");
  if (toolUse?.type === "tool_use" && toolUse.name === "send_meme") {
    const meme = await handleMemeTool(toolUse.input as { query: string });
    // meme.imageUrl  → base64 PNG, render directly in UI
    // meme.title     → meme title from Tenor
    // meme.type      → "meme"
  }
}

How It Works

LLM decides a meme is the right response
         │
         ▼
calls send_meme({ query: "nice try hacker" })
         │
         ▼
get-me-my-meme searches Tenor for the query
         │
         ▼
fetches + pixelates the image
         │
         ▼
returns { type: "meme", imageUrl, title }
         │
         ▼
your UI renders it

API

memeToolDefinition

The Claude/OpenAI tool definition. Pass it directly into your tools array.

import { memeToolDefinition } from "get-me-my-meme";

// Claude
tools: [memeToolDefinition]

handleMemeTool(input)

Handles the tool call — fetches and processes the meme.

import { handleMemeTool } from "get-me-my-meme";

const meme = await handleMemeTool({ query: "nice try hacker" });

// returns MemeResult:
// {
//   type: "meme",
//   query: "nice try hacker",
//   imageUrl: "data:image/png;base64,...",
//   title: "nice try gif",
//   source: "tenor"
// }

fetchMeme(query)

Searches Tenor and returns the raw result (no image processing).

import { fetchMeme } from "get-me-my-meme";

const result = await fetchMeme("this is fine fire");
// { id, title, url, imageUrl }

processMeme(imageUrl)

Downloads and pixelates an image, returns a base64 PNG data URI.

import { processMeme } from "get-me-my-meme";

const base64 = await processMeme("https://media.tenor.com/...");
// "data:image/png;base64,..."

Types

// What the LLM passes to the tool
interface MemeToolInput {
  query: string;
}

// What the tool returns
interface MemeResult {
  type: "meme";
  query: string;
  imageUrl: string;   // base64 data URI — render directly as <img src={imageUrl} />
  title: string;
  source: "tenor";
}

// Union type for your chat response handler
type ChatResponse = MemeResult | { type: "text"; content: string };

Environment Variables

TENOR_API_KEY=your_tenor_api_key

Get a free Tenor API key at tenor.com/gifapi — no credit card, takes 2 minutes.


UI Integration

The imageUrl is a base64 PNG — render it directly:

// React example
{response.type === "meme" ? (
  <img src={response.imageUrl} alt={response.title} />
) : (
  <p>{response.content}</p>
)}

License

MIT