What you’ll learn
- What are chatbots?
- What can they do for programmers?
- Why they need to be used with care.
Chatbots are one form of generative machine-learning (ML) model designed to interact with people in a conversational mode through multiple interactions, unlike many other types of ML models that are presented with an input and provide an output. Chatbots such as ChatGPT, Google Bard, YouChat, JasperChat, Bing Chat, and now Amazon’s Bedrock are just the tip of the iceberg, and much of the world is the beta tester for these tools.
Generative artificial-intelligence (AI) tools like chatbots are typically trained using massive amounts of data, enabling them to respond based on this information. The challenge for these tools is that they need to turn a question into a search and then provide a response-based analysis of the question as well as the data it was trained with. Generative AI goes a step further with the ability to accept additional questions and combine those with the prior query to provide a subsequent response.
To many, this may appear to be “real AI.” However, it’s a far cry from the “positronic brains” of movies like I, Robot based on science fiction from authors like Isaac Asimov. The current crop of chatbots are improving, but they typically go “off the rails” into nonsense or bad responses after more than half a dozen consecutive interactions. Likewise, bias in data, training, and implementation can affect the quality and reliability of the responses.
One aspect of generative AI tools is “explainability,” or the ability to describe why a response was provided. Other ML models can provide similar information, which can be invaluable in determining the usefulness of the results. Still, that leads to the issues about using chatbots for embedded programming chores.
Useful Chatbot Chores
So, what can chatbots do for embedded programmers? They’re being tasked to do many things from finding errors to writing programs to finding examples of other programs that might be useful. The latter is a relatively safe way to use chatbots. It’s the reason so many big names in the search category are interested in them, as they can improve the search results in a more user-friendly way. From our perspective, it does the same and we can still evaluate the identified software based on our expertise.
A similar observation can be made when using a chatbot to identify problems in code, although many issues should be considered. They range from the amount of false positives to the scope of the query.
The chatbots’ interactive nature and ability to explain its reasoning can make them better than conventional static-analysis tools. However, the quality, scope, and efficiency make conventional tools better for now. Many will be augmented using chatbot technology, but for now this is more in the experimental stage.
Creating and modifying programs also can be performed by some chatbots—this is where developers need to step carefully. Keep in mind that these tools are utilizing training content like the hoard of programs stored on github. They can range from trivial and poorly designed systems to massive, well-architected solutions.
Currently available generative AI is simply taking it all in with no real understanding of these differences. It may be nice to get a custom application to blink an LED, but it’s probably not a good idea to have one of these tools generate the braking system for an airplane.
I’m both amazed and horrified by the interactions I’ve had with various chatbots. Unfortunately, oftentimes they’re like dealing with search engine optimization (SEO) in that SEO tends to involve a black box with ever-changing secret algorithms.
My advice is to not ignore the technology, but be very, very careful in how you use it.