Category: AI

  • I recently undertook a significant project: migrating the entire JavaScript codebase of my AI Services plugin for WordPress (GitHub repository) to TypeScript.

    Why is that significant?

    • We’re talking about over 80 JavaScript files, so it’s by no means a small project. Not gigantic like e.g. Gutenberg, but certainly a substantial amount of code.
    • Additionally, that JavaScript code is powering a plugin with a fairly unique feature set. This uniqueness often makes it harder for Large Language Models (LLMs) to assist, as there’s likely less similar code in their training data.

    The process taught me a lot about the synergy between a well-structured codebase and LLMs. It also strengthened my belief that, while an LLM isn’t magically going to solve complex development tasks for you, it can be a massive productivity booster when you prepare your project and guide it effectively.

    This post will walk you through how I used Cline in VS Code together with Google’s Gemini models to get it done efficiently and why I think this migration was worthwhile.

    Read more

  • In my initial post that announced the AI Services plugin for WordPress I mentioned several times how it simplifies using AI in WordPress by providing AI service abstractions as central infrastructure.

    In this post, let’s take a more hands-on look how you as a developer can use the AI Services plugin: We will write a WordPress plugin that generates alternative text for images in the block editor – a crucial aspect of good accessibility, which AI can be quite helpful with. Since the feature will be built on top of the AI Services plugin, it will work with Anthropic, Google, OpenAI – or any other AI service that you may want to use. And the entire plugin will consist of less than 200 lines of code – most of which will in fact be for the plugin’s UI.

    Read more

  • It’s safe to say the topic of generative AI doesn’t need an introduction in today’s age. It has been emerging throughout the tech world. However its adoption in the WordPress ecosystem has been slower than in other ecosystems. This is for various, mostly technical reasons that make implementing generative AI features in WordPress harder than elsewhere.

    That’s what I’m trying to address with AI Services, a new free open-source plugin that is now available for early access on GitHub, and as an early version 0.1.0 in the WordPress plugin directory.

    AI Services is an infrastructure plugin which makes AI centrally available in WordPress, whether via PHP, REST API, JavaScript, or WP-CLI – for any provider. Other plugins can make use of the APIs from the AI Services plugin to easily add AI capabilities to their own plugins, for whichever third party service they prefer: Whether it’s Anthropic, Google, or OpenAI, whether you’d like to use another service, or whether you’d like to leave the choice up to the end users of your plugin – AI Services makes it possible by providing access to the various APIs in a uniform way. It acts as a central hub for integrating AI services, allowing plugin developers to focus on functionality instead of managing individual service integrations. As an end user of WordPress, that means you have more control on how you would like to use the AI capabilities provided by the plugins.

    Read more