OCS 101: How to Create a Chatbot
For first-time users of OCS, this page provides an overview of simple steps to follow to build your first chatbot. More detailed context on different features is provided in subsequent sections.
Get started by watching the OCS 101 video. Follow along with further instructions provided below.
Video: How to Build an OCS Chatbot |
---|
4-Step Guide to Building a Simple Chatbot on OCS
Step 1: Use Prompt Builder to create and test different prompts.
Prompt Builder allows users to create chatbot prompts and rapidly iterate on them.
Navigate to Prompt Builder. Write a prompt specifying what the purpose of your chatbot is and what functions your chatbot should carry out. Test the prompt by chatting with the bot. As you interact with the chatbot, you can make changes to the chatbot prompt on the left-hand side of the screen.
(To help you get started, check out our starter Prompt Library).
Step 2: Save your prompt and create your chatbot.
Once you are satisfied with your prompt, you can save it to create a chatbot.
On the lower right-hand side of the Prompt Builder page, click the "save to prompt" button. You will then see a page titled "Create prompt". Give your prompt a name and description and save it.
Step 3: Create a chatbot (called 'experiment' on OCS).
It's time to use your prompt to create a new chatbot. Note that on OCS, "experiments" are synonymous with "chatbots". Navigate to the Experiments page and click the "Add New" button on the top right. The following steps cover the basic inputs necessary to create a chatbot (i.e. experiment). More detailed information on the other options on this page are available in subsequent sections.
Give your chatbot (experiment) a name and description.
Select an LLM provider (currently the only option is OpenAI)
Select a model (e.g. GPT-4)
Select a temperature (can keep to 0.7 for now)
Select your chatbot prompt from the drop-down menu
Add a seed message (e.g. "hi"): every time a new chatbot session is initiated (e.g. by a user on WhatsApp/Telegram/web), this message will be sent to the chatbot behind the scenes so that the bot knows to kick off the conversation. It's important to add the seed message because this enables the first message of any interaction to be sent by the chatbot.
Click the create button at the end.
Step 4: Deploy your chatbot!
On the main Experiments page, locate your chatbot. Select it, and on the top right-hand side of the chatbot page, select the option to deploy the chatbot on the web browser. Start chatting!
Related articles