In December, ChatGPT crossed the 1 million user mark and Twitter has many creative questions and applications for the chatbot powered by AI. The language model, created by OpenAI, is powered by GPT-3.5, a suite of models trained on text and code prior to Q4 2021. The model has a dialogue format that allows ChatGPT to “answer follow-up questions, admit mistakes, refute incorrect premises, and reject inappropriate requests.” While some predict the end of search engines and sound the death knell for human-generated writing, others are fascinated by the potential of AI systems to fundamentally change the creation process. WordPress developer Johnathon Williams brought this closer when he asked ChatGPT to create a WordPress plugin. Normally, creating a plugin requires a certain level of technical skill. Williams showed that, with a little expert guidance, ChatGPT can dramatically reduce the time it takes to expand WordPress. Williams installed the plugin and found that it worked on the first try. Although he didn’t save the command from this first attempt, he published a gist on GitHub of the generated code. On a second attempt to create another plugin, he used the following command: Create a custom WordPress plugin called “Big Daddy Media” that deletes images older than one year from the media library. OOP. Custom admin screen. one button delete. log the full URL of all deleted media files. Williams said that while he had mixed results with his prompts, he got the best results by asking ChatGPT to generate entire functions rather than specific filters or actions.
Open AI’s ChatGPT can generate an entire WordPress plugin based on a simple description. Watch it work: pic.twitter.com/LZQbxFq0aP
— Johnathon Williams (@johnofhousejohn) December 6, 2022
Naturally, we were also curious and gave a simple command to create a WordPress dashboard plugin with the best-selling products: Create a custom WordPress plugin called “Top orders” that displays WooCommerce’s best-selling products in the WordPress dashboard. With the result below: Theoretically, with additional training on plugin best practices and common architecture, ChatGPT could be used by people at all levels to extend WordPress in creative ways. “Very soon, describing the WordPress plugin you need to ChatGPT will generate a new plugin faster than searching for an existing plugin in the plugin directory,” Williams said. “Of course, this will not apply to all types of plugins. But for relatively simple plugins that perform well-established tricks… very soon though, probably read ‘now’.” Ps. this blog post was written using ChatGPT 🙂