DEV Community

Cover image for How to build a chatbot with AI and low-code
Aakarsh Sahu
Aakarsh Sahu

Posted on

How to build a chatbot with AI and low-code

Anywhere we turn, it is “AI-this” and “AI-that”… It appears that almost everyone has experimented with large language models (LLMs), and with over 100 million weekly active users, ChatGPT has essentially become a household name. ChatGPT itself is forecasted to generate a revenue of $200 million by the end of 2023.

Many of us already live with A.I., an array of unseen algorithms that control our Internet-connected devices, from smartphones to security cameras and cars that heat the seats before you’ve even stepped out of the house on a frigid morning.

However, while we’ve encountered AI in various forms, its full potential remains to be realized.

Researchers are diligently working on streamlining the largest, most powerful machine-learning models into lightweight software capable of operating on “the edge,” encompassing small devices like wearables. Gradually, our lives will be intertwined with remarkable advancements in AI technology.

Image description
One increasingly popular application is personalized interactions through live chat – AI Chatbots!

AI Chatbot hype is picking up!

Image description

According to Chatbots Magazine, “Businesses can reduce customer service costs by up to 30% by deploying a conversational chatbot”.

Projections indicate that the market size of Conversational AI will reach USD 1.3 billion by 2025, experiencing a growth rate of 24%. (Cognizant).

By 2024, the estimated value of chatbot eCommerce transactions is set to reach $112 billion. (Juniper Research)

Furthermore, more than 50% of enterprises are expected to allocate more resources annually to bots and chatbot development than traditional mobile app development. (Gartner)

Between 75-90% of queries will be handled by bots by 2024. (CNBC)

The top beneficiaries of chatbots span various industries including real estate, travel, education, healthcare, and finance. (Service Bell)

Chatbots have the potential to save up to 50% in customer support costs. (Invespcro.com)

How deploying chatbots improves customer experience
Chatbots excel in providing instant responses, typically within 30 seconds, catering to customers who demand immediate assistance. Trends in AI chatbots focus on substantial cost savings when businesses transition from inefficient IVR technology to AI. Bots operating without human intervention efficiently handle straightforward requests such as password changes, balance inquiries, FAQs, appointment scheduling, and more.

AI bots operate 24/7, addressing information-based queries and reducing support tickets.

During peak hours, chatbots can easily scale up to engage customers and enhance the overall customer experience.

But, chatbots are not limited to external interactions. Here is how chatbot trends can be used across enterprise functions:

Human Resource (HR): Chatbots can assist in answering basic HR-related queries, maintaining employee engagement, and facilitating transactional HR services.

Employee Onboarding: Chatbots streamline the onboarding process by initiating the interview stage with screening questions, capturing responses, and guiding new hires through company policies.

Internal Help Desk: Chatbots manage common queries, enabling IT service desk agents to focus on resolving complex issues. The bot continually learns from repetitive queries, thereby improving response times.

Developing AI solutions using low-code
Over 79% of corporate strategists said that technologies such as analytics, artificial intelligence (AI), and automation will be critical to their success over the next two years, according to a Gartner survey.

Image description

Nevertheless, building custom AI solutions in-house can be challenging and time-consuming. Developers may spend days creating systems lacking adequate data context, struggling to access real-time inputs or risking privacy breaches by transmitting data to external AI providers.

DronaHQ has set out to make AI integration accessible and efficient for developers and businesses alike. With its pre-built blocks and versatile features, it promises to simplify the process of integrating AI into applications and workflows.

Read also: Advantages of Low-Code to Build AI-powered Apps

How to build a chatbot using AI and DronaHQ
We’re about to build a chatbot using seamless integration of DronaHQ’s low-code platform and AI API. We’re using Cohere APIs to create an AI chatbot that leverages FAQ data to respond to user queries efficiently.

Pre-requisites
A DronaHQ account
A Cohere account
Note: You can work with the LLM API of your choice. The method to integrate it with DronaHQ to create your functional chatbot remains the same.

Step 1: Leveraging Cohere APIs for Intelligent Responses
Cohere’s APIs provide access to large language models, making it a perfect match for enhancing your chatbot’s capabilities. APIs can also be used to generate or analyse text to do things like write copy, moderate content, classify data and extract information, all at a massive scale. Cohere offer a generous free developer tier, so you can build and test your ideas quickly.

Follow these steps to integrate Cohere APIs into your DronaHQ app:

Image description

Log in or sign up for a free Cohere account.
Keep your API key handy

Image description

In this demonstration, we are using the Trial API Key

Step 2: Getting Started with DronaHQ
DronaHQ’s low-code platform empowers users to build and launch applications swiftly, eliminating the need for extensive coding. Follow these steps to set up your DronaHQ account and start the chatbot creation process:

Login to your DronaHQ account or sign up for a free account

Image description
Signup - DronaHQ Low-Code App Development Platform_files

Head over to Connectors to configure the Cohere API
Add a name for the connector
Select the API Key authentication method
Enter the API key from your Cohere account
Configure the API to test

Image description

Image description

Once the connector is set, let’s go on and build the UI
Head back to DronaHQ console and select the + sign to create a new app. Enter a name and description for your app.

A new window will open after this step.

Head over to the ‘Controls’ library and drag-drop components to the canvas.
Note: This article focuses only on the Chatbot element. For a detailed DronaHQ platform walkthrough, refer this tutorial, or connect with one of our platform experts for a guided platform walkthrough.

Drag and drop the Chat control to the screen. (About Chat UI control)
Next, we need to configure the ‘Actionflow’ to take user input from the chat box and use it as a ‘prompt’ for the Cohere APIs

Image description

Passing chat control value

Image description

lastArray = chat_input[chat_input.length – 1]

output = lastArray.content

Now add a connector block – Cohere and pass to it the Chat UI control values.
Enter fullscreen mode Exit fullscreen mode

Image description

Next, drop a JSON block to transform the API response

Image description

let new_response = { 

  “role”: “assistant”,

  “content”: api_reply

  }

curr_history.push(new_response)

output = curr_history
Enter fullscreen mode Exit fullscreen mode

Set control

Image description
Next Steps

With DronaHQ’s low-code platform and Cohere APIs, you’ve unlocked the potential to create powerful AI chatbots effortlessly. Explore the documentation provided by DronaHQ and Cohere to discover more possibilities and features.

Join the community on Cohere’s Discord channel to share your innovative chatbot applications and connect with like-minded individuals. The possibilities are limitless, and we can’t wait to see the incredible chatbots you’ll build using DronaHQ and Cohere APIs. Start your chatbot journey today!

Top comments (0)