About

onlypepes is my personal collection of Pepe memes and my playground for learning about AI tools and digital technology in general.

The project consists of a database of Pepe images, a web interface to browse and search through them, a public API, and a Telegram bot for searching memes on the go.

This project has evolved significantly over the years. One of the key features I've implemented is AI-powered image analysis to automatically generate descriptions for each meme, enabling users to search and filter images by their content rather than just filenames.

When I first started building the collection, I gathered images from various Telegram channels. To maintain quality and avoid duplicates, I researched and implemented perceptual hashing (pHash) to detect duplicate images before adding them to the database. This uses Hamming distance calculations to identify similar images, even if they've been slightly modified.

I documented my journey of automating descriptions for over 10,000 Pepe memes in an article I wrote. I tested multiple AI models including OpenAI's GPT-4, Google's Gemini, LLaVA, Baklava, and various models from Hugging Face and Ollama. After comparing results, OpenAI's API provided the best balance of accuracy and quality. While I explored local alternatives to reduce costs, none delivered satisfactory results. The entire process ended up costing less than $5 using OpenAI's API (approximately $4.34 for input tokens and $0.40 for output tokens). I automated everything with a Python script that processes all database images, generates descriptions via the OpenAI API, and saves them automatically.

As the collection grew, I expanded it by automatically extracting Pepe memes from additional Telegram channels and Twitter profiles.

However, as I needed to generate more descriptions, I wanted to avoid the ongoing costs of using OpenAI's API. This motivated me to learn how to run AI models locally using technologies like llama.cpp and vLLM.

To get started with local AI models, I experimented with tools like LMStudio for text and image recognition LLMs, and ComfyUI for image generation using various models.

I successfully got Gemma3 4B running on a VPS with 8GB of RAM and 6 ARM cores, which now automatically generates descriptions whenever a new image is added to the database.

As the project grew more complex, I decided to simplify it by removing some features. For instance, the automated scrapers for Telegram and Twitter have been disabled to keep the project more focused and maintainable.