Blog Artificial Intelligence Leveraging ChatGPT in Automation Development and Design Leveraging ChatGPT in Automation Development and Design

  • Codignus
  • Wed, Sep 27, 2023 1:23 PM
Artificial Intelligence (AI)

In a matter of weeks, generative artificial intelligence (AI) has moved from the bleeding edge of technology to the mainstream. Right now, you, me, and just about anyone can use AI to create amazing artwork, narrate a book, write a blog, even create a new programming language from scratch. Imagine going back just a couple years ago and telling your colleagues you’d be able to do all of that today from your smartphone! The launch of OpenAI’s ChatGPT—a large language model (LLM) able to generate human-like text—has been a catalyst. It has revealed to millions of people around the world the recent advances in AI and focused minds on what’s possible with these models. It’s a big step forward in the democratization of AI, providing powerful foundational models that can be used to create even more valuable tools. With that in mind, I decided to check in with one of our resident expert robotic process automation (RPA) developers, Cristian Negulescu—and a few other friends—on some of the ways they find ChatGPT to be useful. (Note: ChatGPT is the most accessible generative AI tool available today, but similar results could be obtained from other emerging tools as well) 1. Use ChatGPT to understand other developers’ code A great use of ChatGPT is helping professional developers answer their questions about other developers’ code. It’s as simple as pasting the code into ChatGPT and asking for an explanation of what it does. This can help automation developers to better understand the likes of VB.Net, SOQL, JQL, LINQ, and any other coding language. Benefit: Enable developers to expand their knowledge of lesser-used programming languages 2. Quickly create documentation for your code ChatGPT can also help ease the pain of creating lots of user documentation for code. After you paste all the information related to your system into ChatGPT, you can ask it common questions users might have and use the output for your own documentation. Soon, a more advanced version of ChatGPT or a similar generative model could even help keep user documentation updated. Imagine communicating the latest changes to your system and having the model update all the collateral needed for the new version. Benefit: Create user documentation more efficiently, while potentially automating updates, saving developers time and effort 3. Create code from natural language requests One of the most exciting possibilities for ChatGPT is helping even non-technical users become developers. Generative AI models allow business users and citizen developers to generate automation workflows from natural language descriptions. By this, I mean they can explain what they want to achieve and ask the model to write the code to achieve it. This is the superpower of generative AI. A ‘buddy’ to help any level of user towards accomplishing their automation goals and realizing new potential in their day-to-day work. Benefit: Helps non-tech users generate automation workflows from their plain language descriptions, driving citizen development opportunities 4. Generate test data When a developer needs a set of test data—such as, marketing contact lists—with a set of specific fields (e.g., Name, Phone Number, and Address) for a specific state or region, ChatGPT can quickly generate a randomized set of fake data. Here is an example prompt: “I created an application that will work with phone numbers and addresses. The following fields will be used in a record: Name, Phone Number, and Address. Generate 30 examples of records, specific to Washington State, USA.” Change the prompt to your locality, or for only names starting with the letter A, and see how easily the output can be customized. Benefit: Accelerate the creation of test data for developers by generating randomized sets of fake data that respect logical integrity rules 5. Generate test code for a code sequence Let’s assume you have a sequence of code and want to create a test script for it. ChatGPT can assist and generate testing code, in languages such as Python, JSON, C or XAML (or even convert between the different languages). Additionally, ChatGPT will also create the test data needed to cover all the test cases. Benefit: Accelerating the creation of test scripts for workflows Moving beyond the realm of developer tools, let's explore some of the business applications of ChatGPT when paired with a UiPath automation.