Synergy of Innovation - AI Meets WordPress in the Digital Future

Empowering Your WordPress Site with AI: Building an OpenAI Assistant

The AI Powered Chatbot for WordPress plugin can leverage the power of OpenAI’s Larger Language Models (LLMs) to assist you or your clients with many different tasks.

Today I had a support question about the capabilities of the chatbot.  The use case described as wanting to load software manuals into an assistant so that it could answer questions and provide solutions based on that knowledge.

That’s an ideal use case.  I wrote about my own use of this way on this site in an article titled “Revolutionizing Development: My Journey with a GPT Assistant.  You can find it here:

https://kognetiks.com/2024/01/23/revolutionizing-development-my-journey-with-a-gpt-assistant/

In this article I explained how I used a GPT Assistant to help answer questions about the OpenAI API.  It’s been an invaluable assistant.  And I’m not sure why OpenAI hasn’t deployed its documentation with that capability.

I also built out a “Quantum AI Knowledge Helper” to answer my questions about Quantum computing and Artificial Intelligence (AI) – an area that I’m interested in exploring.  I also built out a “Microsoft Azure OpenAI Helper” to answer my questions about how I might incorporate their AI Service model into the plugin.  And – just for fun – I built a “General Purpose Gaming Assistant” that has knowledge of the card game Five Crowns.  I was hopeful that I would learn new strategies to win at this game.

So, let’s get stated building an OpenAI Assistant that can be incorporated into the chatbot.

You’ll need an OpenAI account.  Once setup head over the https://platform.openai.com/assistants to get started building an Assistant that can be deployed on your WordPress website.

Step 1

Follow the link to the Assistants platform at OpenAI.

Using the vertical menu on the left hand side of the platform, click on “Assistants”.

Then, in the upper right corner of the platform, click on the “+ Create” button.

Step 2

Once you’ve clicked on the “+Create” button, a form will appear where you can enter the name of your Assistant (area B in the diagram below).

You can add some specific instructions for the assistant, such as “You are a very smart assistant that knows all about creating Assistants on the platform.openai.com/assistants.  You can answer questions about what Assistants can do and how to use them.” (area C in the diagram below).

Then you can select the OpenAI model you want to use, for example “gpt-4-turbo-preview” (area D in the diagram below).

And then you can add Functions, enable Code interpreter, and Retrieval (area E in the diagram below).

Step 3

Upload the files you want to use with code interpreter or retrieval.  These could be documents of almost any type, such as PDF file or DOCX file (area F in the diagram below).

OpenAI Platform Assistants
OpenAI Platform Assistants

Step 4

Once you named your assistant, given it some instructions, chosen a model, selected/enabled tools and uploaded some files, its time to test your assistant.

In the image below you can see the OpenAI Assistants Help assistant.  The three areas highlighted illustrate the files that were included (see area A in the diagram below).

Then you can enter a question at the bottom of the assistant (see area B in the diagram below).

In this case I asked “In the file I’ve included some code, is it correct?” and uploaded a test file called “Upload test.txt” (see area C in the diagram below).

When I click run, the “Run Instructions” are displayed an the OpenAI Assistants Help returned the analysis.  First inspecting the code (code_interpreter) and then summarizing what the Assistant was able to determine.

On the right side, you can see the steps the assistants worked to analyze the question and the file that was uploaded.

OpenAI Assistants Help
OpenAI Assistants Help

All good so far!

Step 5 – The Last Step

Now that you’ve built the assistant and tested the assistant, it’s time to deploy the assistant on you website.

You can use the AI Powered Chatbot for WordPress plugin shortcode like this:

OpenAI Assistants Help Shortcode Example
OpenAI Assistants Help Shortcode Example

In this example the shortcode embeds the assistant in the page.

OpenAI Assistant Help Example
OpenAI Assistant Help Example

Easy enough?

The AI Powered Chatbot for WordPress plugin continues to evolve.  That evolution is driven by the rapidly growing installed base of users just like you.  I want to thank each of you for taking the time to share your valuable feedback, as it helps me continually improve and provide a better experience for all our users.

#AIIntegration #WordPressAI #OpenAIAssistant

About the Author

Stephen Howell is a multifaceted expert with a wealth of experience in technology, business management, and development. He is the innovative mind behind the cutting-edge AI powered Kognetiks Chatbot for WordPress plugin. Utilizing the robust capabilities of OpenAI's API, this conversational chatbot can dramatically enhance your website's user engagement. Visit Kognetiks Chatbot for WordPress to explore how to elevate your visitors' experience, and stay connected with his latest advancements and offerings in the WordPress community.

Stephen Howell
Stephen Howell is a multifaceted expert with a wealth of experience in technology, business management, and development. He is the innovative mind behind the cutting-edge AI powered Kognetiks Chatbot for WordPress plugin. Utilizing the robust capabilities of OpenAI's API, this conversational chatbot can dramatically enhance your website's user engagement. Visit Kognetiks Chatbot for WordPress to explore how to elevate your visitors' experience, and stay connected with his latest advancements and offerings in the WordPress community.
Posts created 75

Leave a Reply

Related Posts

Begin typing your search term above and press enter to search. Press ESC to cancel.

Back To Top