AI image generation has quickly become more accessible over the past few months and is making its way into different industries that require asset creation. Although it’s still somewhat limited, AI image generators can create breathtaking photorealistic images from complex prompts. AI-assisted artists have even begun selling their works on stock photography sites.

DALL-E 2 was the first to make a big splash on social media. Its closed platform and invite-only beta has kept many potential creators on the sidelines, but open source alternatives like Stable Diffusion are taking off. The machine learning, text-to-image model is improving thanks to its growing ecosystem of contributors and extenders.

Kevin Batdorf, an Application Developer at Extendify, has created a free plugin called Block Diffusion that uses Stable Diffusion to generate images inside the block editor based on text prompts.

Block Diffusion uses the public Replicate API to generate images in the cloud. This requires users have an account at replicate.com. It will generate some images for free but thereafter will be $0.01 USD per image using Replicate’s Stable Diffusion model. Images generate in six seconds.

The model was trained on LAION-5B, an open AI training dataset containing over five billion image-text pairs. It has some limitations in that it cannot achieve perfect photorealism or render legible text. It also may have difficulty rendering faces and people.

For many WordPress content use cases, the Stable Diffusion model should be adequate for illustrating posts and creating unique featured images. Batdorf plans to add the following features in future releases:

  • Use an existing image as starting point
  • Add an image mask to only generate specific areas
  • Help with prompt ideas and inspiration
  • Run multiple image predictions at once
  • Have more control over the image generation steps
  • View your prediction history
  • Model selection from collections

The Block Diffusion plugin is a personal side project for Batdorf and he doesn’t plan to turn it into a commercial plugin.

“There are no plans to lock any features behind a pro or premium plugin,” he said. “All features will be added to this version on wordpress.org. Over time I plan to add all features supported by Replicate, as well as additional features for the WordPress community specifically.”

In the meantime, Batdorf said users who find the plugin useful can support its continued development by sponsoring the project on GitHub through monthly or one-time contributions .