Artificial intelligence (AI) and machine learning (ML) are two fields that work together to create computer systems capable of perception, recognition, decision-making, and translation. Separately, AI is the ability for a computer system to mimic human intelligence through math and logic, and ML builds off AI by developing methods that "learn" through experience and do not require instruction. In the AI/ML Zone, you'll find resources ranging from tutorials to use cases that will help you navigate this rapidly growing field.
Welcome to our tutorial on deploying a machine learning (ML) model on Amazon Web Services (AWS) Lambda using Docker. In this tutorial, we will walk you through the process of packaging an ML model as a Docker container and deploying it on AWS Lambda, a serverless computing service. By the end of this tutorial, you will have a working ML model that you can invoke through an API, and you will have gained a deeper understanding of how to deploy ML models on the cloud. Whether you are a machine learning engineer, data scientist, or developer, this tutorial is designed to be accessible to anyone with a basic understanding of ML and Docker. So, let’s get started! What Is Docker? Docker is a tool designed to make it easier to create, deploy, and run applications by using containers. Containers allow a developer to package up an application with all of the parts it needs, such as libraries and other dependencies, and ship it all out as one package. By using containers, developers can be sure that their application will run on any other machine, regardless of any customized settings that the machine might have that could differ from the machine used for writing and testing the code. Docker provides a way to package an application and its dependencies in a lightweight, portable container that can be easily moved from one environment to another. This makes it easier to create consistent development, testing, and production environments, and to deploy applications more quickly and reliably (install Docker). What Is AWS Lambda? Amazon Web Services (AWS) Lambda is a serverless computing platform that runs code in response to events and automatically manages the underlying compute resources for you. It is a service offered by AWS that allows developers to run their code in the cloud without having to worry about the infrastructure required to run it. AWS Lambda automatically scales your applications in response to incoming request traffic, and you only pay for the computing time that you consume. This makes it an attractive option for building and running microservices, real-time data processing, and event-driven applications. What Is AWS ECR? Amazon Web Services (AWS) Elastic Container Registry (ECR) is a fully managed Docker container registry that makes it easy for developers to store, manage, and deploy Docker container images. It is a secure and scalable service that enables developers to store and manage Docker images in the AWS cloud and to easily deploy them to Amazon Elastic Container Service (ECS) or other cloud-based container orchestration platforms. ECR is integrated with other AWS services, such as Amazon ECS and Amazon EKS, and provides native support for the Docker command line interface (CLI). This makes it easy to push and pull Docker images from ECR using familiar Docker commands, and to automate the build, test, and deploy processes for containerized applications. Install AWS CLI Install AWS CLI on your system using this. Get the AWS Access Key ID and AWS Secret Access Key by creating the IAM user in your AWS account. After installation, run the below command to configure your AWS CLI and insert the required fields. aws configure Deploying Lambda Function With Docker We are deploying the OpenAI clip model in this tutorial to vectorize the input text. The Lambda function requires the amazon Linux 2 in the Docker container so we are using the public.ecr.aws/lambda/python:3.8 with it. Also, as Lambda has a read-only filesystem, it won’t allow us to download the models internally, so we need to download and copy them while creating the image. Get the working code from here and extract it. Change the working directory where the Dockerfile is located, and run the below command: docker build -t lambda_image . Now we have an image ready that we will deploy on Lambda. To check it locally, run the command: docker run -p 9000:8080 lambda_image To check it, send a curl request to it, and it should return the vectors for the input text: curl -XPOST "http://localhost:9000/2015-03-31/functions/function/invocations" -d '{"text": "This is a test for text encoding"}' Output To deploy the image on Lambda first, we need to push it on ECR, so log in to the AWS account and create the repository lambda_image in ECR. After creating the repository go to the created repository and you will see the view push command option click on it and you will get the command to push the image into the repository. Now run the first command to authenticate your Docker client using AWS CLI. We have already created the Docker image, so skip the second step and run the third command to tag the created image. Run the last command to push the image in ECR. You will see the interface look like this after running it: Once the push is complete, you will see the image tagged with ‘:latest’ tag in the repository of ECR. Copy the URI of the image. We’ll need this while creating the Lambda function. Now go to the Lambda function and click on the "create the function" option. We are creating a function from the image, so select the option for the container image. Add the name of the function and paste the URI we copied from ECR, or you can browse the image too. Select architecture x84_64 and finally click on the create_image option. It might take some time to build the Lambda function, so be patient. After a successful execution, you will see an interface like below: The Lambda function has a timeout limit of 3 seconds and RAM of 128 MB by default, so we need to increase it, otherwise it will throw us an error. To do this, go to the configuration tab and click on "edit." Now set the timeout to 5-10 minutes (maximum limit is 15 minutes) and RAM to 2-3 GB and click on the save button. It will take some time to update the configuration of the Lambda function. After the changes are updated, the function is ready to test. To test the lambda function go to the Test tab and add the key value in the event-JSON as text: “This is a test for text encoding.” Then click on the test button. As we are executing the Lambda function the first time, it might take some time to execute. After the successful execution, you will see the vectors for the input text in the execution logs. Now our Lambda function is deployed and working properly. To access it via API, we’ll need to create a function URL. To create the URL for the Lambda function, go to the Configuration tab and select the Function URL option. Then click on create function URL option. For now, keep the authentication None and click on Save. After the process is done, you will get the URL for accessing the Lambda function via API. Here is the sample Python code to access the Lambda function using API: import requests function_url = "" url = f"{function_url}?text=this is test text" payload={} headers = {} response = requests.request("GET", url, headers=headers, data=payload) print(response.text) After the successful execution of the code, you will get the vector for the input text. So this was an example of how to deploy ML models on AWS Lambda using Docker. Do let us know if you have any queries.
Cracking a machine learning interview at companies like Facebook, Google, Netflix, Snap, etc., really comes down to nailing a few patterns that these companies look for. In this article, I plan to share my experience interviewing with these companies and also how I went about preparing. About Me I have six years of experience working as a Machine learning engineer at Meta. I have been part of two teams at Meta. I was an early ML engineer of a misinformation modeling team working on hoax classification models. After three years at misinformation, I moved to the Instagram Ads ranking team, where I’m part of the core-optimization team building and improving upon Ads ranking models across all surfaces on Instagram (Feed, Stories, Reels, etc.) How to Crack Machine Learning Interviews at FAANG Companies I’ve been on the job market for the past two months and attended ~10 onsite interviews and have six offers from Google and a few others for senior/staff ML roles. This was my first job search attempt since graduating with my master's almost six years ago, and I had to learn the landscape of ML interviews and go about strategizing my preparation. In this article, I try to share tips and tricks that could help you prepare for MLE interviews (at L4 and above). I’ve attended interviews at Netflix, Google, Snap, Airbnb, Uber, Instacart, Doordash, and Nextdoor, and I’m going to focus this article based on the structure of these companies. Machine learning interviews are quite different from vanilla software engineering interviews, and the ecosystem is continuously evolving to make the interviews more calibrated and structured. But here are things that you can broadly expect Phone screen: Machine learning technical assessment + Leetcode style coding question Onsite interview : Machine learning theory round Machine learning system design Machine learning coding 1) Machine Learning Technical Assessment Typically big tech would have a one-hour technical phone screen that would comprise of one leet code style question and leave 10-15 mins towards the end for some rapid-fire ML tech questions. The easier end of these ML theory questions is mostly like this: Explain overfitting and regularization Explain bias-variance tradeoff How do you handle data imbalance issues What is gradient descent [Difficult] Can you explain logistic regression and derive gradient descent for Logistic regression [Difficult] What do eigenvalues and eigenvectors mean in PCA I’ve compiled a set of commonly asked ML Theory questions. How Would You Prepare for This Round This round is quite crucial because it really tests your basic understanding of common topics in ML. Instead of approaching to answer these questions by studying a cheat sheet, I’d really recommend spending a week or two going over the basics from a textbook. I highly recommend this textbook and this Coursera course which you can watch at 1.5X speed. Onsite — Machine Learning Theory Round This round is quite similar to the above technical assessment round but has 45 min — one hour dedicated to it. You can expect two kinds of questions. Here are a few examples: Straightforward theory questions What do L1 and L2 regularization mean, and when would you use L1 vs. L2? Can you use both? When there are highly correlated features in your dataset, how would the weights for L1 and L2 end up being? Nuanced derivation-based questions that require a pen and paper Can you use MSE for evaluating your classification problem instead of Cross entropy How does the loss curve for Cross entropy look? What does the “minus” in cross-entropy mean? Explain how Momentum differs from RMS prop optimizer. You can find similar questions here. Aim to spend the bulk of your preparation going back to basics, getting the concepts right. I spend >2 weeks revising machine learning concepts by watching the above videos. Getting the derivations practiced with pen and paper makes a huge difference. Click here for more prep materials. Onsite Interview — How to Tackle the ML System Design Round? Now, this is a round that few companies have managed to conduct well. Like, finding calibrated interviewers for this round and having the right set of rubrics for evaluating candidates for this round is quite challenging. Few companies, like Google, Meta, Airbnb, Doordash, etc., have a mature process for ML System design. Few others were honestly a disaster for me, and that is tempting me to say this round could very well be a hit or miss. For ML Design, the expectation of candidates is often not clear, and I’ve found interviewers give questions that have a broad ground to cover while also interjecting the candidates and transforming the interview into an ML theory round. This is why this round can be a hit or miss, even for the most well-prepared candidates. L4 candidates don’t typically have an ML design round. For L5, you can expect 1-2 rounds, and for L6, there’s a minimum of two rounds expected. Expect questions like: Design a feed recommendation system Design Youtube Design Google contact ranking Design an item replacement recommendation Here Are Top Tips for Nailing This Round Have a good pre-defined structure for the interview. Here’s my recommended structure: Have a good script for answering any ML Design question. Basically, pretty much every ML design question fits into the above structure, and the script can also be somewhat generalized. Here’s my take on how I approach recommendation systems Online machine learning design resources like the course on educative.io are helpful in defining the structure for different types of design questions. How to salvage a derail? Say you are ten minutes into the design interview, and the interviewer asked you a question on Business metrics, and you spent excess time in that section. How do you salvage your interview back? This is something I noticed far too often, especially in ML Design interviews. This is often a function of your interviewer having a pre-defined structure in their mind that collides with your structure. So you start speaking about online metrics, and they want to know about Training data. Take a pause, make it explicit to the interviewer that this is the structure you intend to follow, and get back on track. Design interviews should typically be led by the candidate with minimal interruptions from the interviewer. So, take ownership here fully knowing that the interviewer on the other end is probably not calibrated, and hence it's entirely up to you to utilize your 45 mins to give as much signal as possible. 4. The best way to prepare for ML design rounds are to take as many mock interviews as possible. I took five ML mock interviews with my ex-colleagues which really helped shape my run-book for this round. This brings me to the end of Part 1. In Part 2, I plan to dive deep into types of ML Design questions and the rubric that differentiates an L4 candidate vs. L5 and L6 (meta levels). I also provide free mock interviews for folks who are currently in the job market.
ChatGPT is a cutting-edge artificial intelligence model developed by OpenAI, designed to generate human-like text based on the input provided. This model is trained on a massive dataset of text data, giving it extensive knowledge of the patterns and relationships in language. With its ability to understand and generate text, ChatGPT can perform a wide range of Natural Language Processing (NLP) tasks, such as language translation, question-answering, and text generation. One of the most famous examples of ChatGPT's capabilities is its use in generating realistic chatbot conversations. Many companies and organizations have used chatbots to interact with customers, providing quick and accurate responses to common questions. Another example is the use of ChatGPT in language translation, where it can automatically translate text from one language to another, making communication more manageable and more accessible. Another exciting application of ChatGPT is in the field of content creation. With its ability to understand and generate text, ChatGPT has been used to create articles, poems, and even song lyrics. For example, OpenAI has developed a GPT-3 that can create articles on various topics, from sports to politics, with stunning accuracy and attention to detail. The success of ChatGPT can be attributed to its use of a transformer architecture, a type of deep learning model that is well-suited for NLP tasks involving sequential data like text. Furthermore, the pre-training of ChatGPT on a large corpus of text data also gives it a solid foundation of language knowledge, allowing it to perform well on various NLP tasks. Understanding Natural Language Processing (NLP) NLP is a subfield of artificial intelligence that deals with the interaction between computers and human language. It is a complex field that involves the application of computer science, computational linguistics, and machine learning to process, understand and generate human language. NLP has a long history, dating back to the 1950s and 60s when early researchers began exploring the use of computers to process and understand natural language. One of the pioneers of NLP was the computer scientist and cognitive psychologist Noam Chomsky. Chomsky is widely regarded as the father of modern linguistics, and his work laid the foundation for developing NLP. In addition, Chomsky's theories about language structure and humans' innate ability to learn languages have profoundly impacted the field of NLP. Another important figure in the history of NLP is John Searle, who developed the Chinese Room argument, which challenged the idea that a machine could truly understand language. Despite this argument, the development of NLP continued to advance, and in the 1990s, there was a significant increase in research in the field, leading to the development of new NLP techniques and tools. Despite its advances, NLP continues to face significant challenges. One of the main difficulties in NLP is the complexity of human language, which can vary greatly depending on the context and the speaker. This variability can make it difficult for computers to understand and generate language, as they must be able to recognize the nuances and subtleties of language to perform NLP tasks accurately. Another challenge in NLP is the need for labeled training data, which is required to train NLP models. Unfortunately, creating labeled data is time-consuming and labor-intensive, and obtaining high-quality labeled data can take time and effort. This makes it challenging to train NLP models that can perform well on various NLP tasks. Despite these challenges, the field of NLP continues to advance, and new techniques and models are constantly being developed. For example, the rise of big data and the availability of large amounts of text data has led to the development of more powerful NLP models, like ChatGPT, which can process and generate human-like text. The Importance of NLP in AI NLP plays a critical role in the development of artificial intelligence. As mentioned, NLP enables computers to process, understand, and generate human language, which is essential for building AI systems that can interact with humans naturally and intuitively. One of the critical reasons for the importance of NLP in AI is the sheer amount of text data generated daily. This data includes emails, social media posts, news articles, and many other forms of text-based information. The ability to process and analyze this text data is critical for a wide range of applications, including sentiment analysis, information extraction, and machine translation, to name a few. NLP also plays a crucial role in developing conversational AI, allowing computers to engage in natural language conversations with humans. This is a rapidly growing area of AI. NLP is essential for building chatbots, virtual assistants, and other conversational AI systems to help businesses and organizations interact more efficiently and effectively with their customers. To illustrate the importance of NLP in AI, consider the example of sentiment analysis. Sentiment analysis is the process of determining the emotion or attitude expressed in a piece of text. This is a critical task in social media analysis, where it is used to gauge public opinion on a particular issue. NLP analyzes text data, identifies sentiment, and classifies it as positive, negative, or neutral. Another example of the importance of NLP in AI is information extraction, which is the process of automatically extracting structured information from unstructured text data. This is a critical task in news analysis and business intelligence, where large amounts of unstructured text data must be processed and analyzed to gain insights into trends and patterns. NLP is used to analyze text data, identify relevant information, and extract it in a structured format that can be easily researched. NLP is a critical component of AI. Its importance will only continue to grow as more and more text data is generated and the need for AI systems that can process and understand human language increases. The development of NLP has led to significant advances in AI, and it will continue to play a crucial role in shaping the future of AI and how computers and humans interact. How ChatGPT Works ChatGPT is based on the GPT (Generative Pre-trained Transformer) architecture, introduced in 2018 by researchers at OpenAI, including Ilya Sutskever, co-founder of OpenAI and the father of deep learning, and Sam Altman, President of OpenAI. The key innovation of the GPT architecture was its use of the Transformer network, introduced in 2017 by Vaswani et al. in a paper titled "Attention is All You Need." The Transformer network was designed to be more computationally efficient and easier to train than previous neural network architectures, and it quickly became the dominant architecture in NLP. ChatGPT is pre-trained on a large corpus of text data, which includes books, websites, and other forms of text-based information. This pre-training allows ChatGPT to learn language patterns and structures, generating coherent and natural language text based on user input. The pre-training process is followed by fine-tuning, where the model is further trained on specific tasks, such as question-answering, text generation, and conversation. During fine-tuning, the model is trained on a smaller dataset specific to the task. This fine-tuning allows the model to specialize in a particular task and generate more accurate and relevant text. Once the model is trained, it can generate text by providing it with an input prompt. The input prompt can be a question, a statement, or any other form of text, and the model will generate a response based on the information it has learned during training. The generated response will be coherent and natural language text, which is generated based on the language patterns and structures that the model learned during pre-training. For example, if a user provides the input prompt "What is the capital of France?", ChatGPT will generate the response "The capital of France is Paris." This response is generated based on the information that ChatGPT has learned about the relationships between geographical locations and their capitals, which it has learned during pre-training and fine-tuning. The Transformer Architecture: A Technical Overview The Transformer architecture is the backbone of the ChatGPT model and allows the model to generate human-like text. The Transformer architecture is called "Transformer" because it uses self-attention mechanisms to "transform" the input data into a representation suitable for generating text. The self-attention mechanism allows the model to weigh the importance of different input data parts, enabling it to generate more accurate and relevant text. In the Transformer architecture, the input data is processed by multiple layers of the neural network, each using self-attention mechanisms to transform the input data into a new representation. The output from each layer is then passed to the next layer, which is repeated until the final layer generates the output text. Each layer of the Transformer architecture comprises two sub-layers: the Multi-Head Self-Attention mechanism and the Position-wise Feed-Forward Network. The Multi-Head Self-Attention mechanism is used to weigh the importance of different parts of the input data. The Position-wise Feed-Forward Network is used to process the weighted input data and generate a new representation. The Multi-Head Self-Attention mechanism is implemented as a series of attention heads, each of which performs a separate attention mechanism on the input data. The attention heads are combined to produce the final output, which is then passed to the Position-wise Feed-Forward Network. The Position-wise Feed-Forward Network is a fully connected neural network that takes the output from the Multi-Head Self-Attention mechanism as input and generates a new representation. The Position-wise Feed-Forward Network is designed to be computationally efficient and easy to train, which makes it a valuable component of the Transformer architecture. Pre-Training: The Key to ChatGPT's Success Pre-training is essential in creating the ChatGPT model and sets it apart from other conversational AI systems. Pre-training is training the model on a massive amount of data before fine-tuning it for a specific task. By pre-training the model on a large corpus of text, the model can learn the patterns and structures of human language, which makes it more capable of generating human-like text. ChatGPT was pre-trained on various text sources, including books, news articles, Wikipedia articles, and web pages. The vast amount of text data used for pre-training allows the model to learn a wide range of styles and genres, making it well-suited for generating text in various contexts. The pre-training data for ChatGPT was also carefully curated to ensure that the model was exposed to high-quality, well-written text. This is important because the quality of the pre-training data directly impacts the generated text's quality. For example, if the pre-training data contains errors, grammatical mistakes, or low-quality text, the model will be less capable of generating high-quality text. Pre-training is a computationally intensive process that requires a lot of computational resources. To pre-train the ChatGPT model, OpenAI used a large cluster of GPUs, allowing the model to be trained relatively short. Once the pre-training process is complete, the model is fine-tuned for a specific task. Fine-tuning is adjusting the model weights to better suit the task at hand. For example, if the task is to generate conversational text, the model may be fine-tuned to create more conversational text. Fine-Tuning: Customizing ChatGPT for Specific Tasks Fine-tuning is adjusting the weights of the pre-trained ChatGPT model to suit a specific task better. The fine-tuning process is essential because it allows the model to be customized for a particular use case, which results in better performance. One of the main challenges of fine-tuning is finding the right amount of data to use for fine-tuning. If too little data is used, the model may not be able to learn the patterns and structures of the specific task at hand. On the other hand, if too much data is used, the model may become overfit to the training data, which means it will perform poorly on new data. Another challenge of fine-tuning is choosing the correct hyperparameters. Hyperparameters are the values that control the model's behavior, such as the learning rate, number of layers, and number of neurons. Choosing the correct hyperparameters is essential because it can significantly impact the model's performance. To overcome these challenges, researchers and practitioners have developed several techniques to help fine-tune the ChatGPT model. One of the most popular techniques is transfer learning, which involves using a pre-trained model as a starting point and then fine-tuning the model for a specific task. Transfer learning allows the model to take advantage of the knowledge it has learned from the pre-training data, which results in faster and more effective fine-tuning. Another technique that has been developed to help fine-tune the ChatGPT model is active learning. Active learning is a semi-supervised learning method that allows the model to learn from labeled and unlabeled data. By using active learning, the model can learn from a more significant amount of data, which results in better performance. Conclusion: The Future of ChatGPT In conclusion, ChatGPT is a powerful and sophisticated language model that has revolutionized the field of NLP. With its ability to generate human-like text, ChatGPT has been used in many applications, from conversational agents and language translation to question-answering and sentiment analysis. As AI advances, ChatGPT will likely continue to evolve and become even more sophisticated. Future developments could include improved pre-training techniques, better architectures, and new fine-tuning methods. Additionally, as more data becomes available, ChatGPT will become even more accurate and effective at performing a more comprehensive range of tasks. However, it is essential to note that ChatGPT has drawbacks. One potential drawback is the possibility of ethical issues arising from using the model. For example, there are concerns about the potential for the model to generate harmful or biased text. In addition, there is also the risk of the model being used for malicious purposes, such as creating fake news or impersonating individuals. Another potential drawback is the high computational cost of training and using the model. This can be a significant barrier to entry for many organizations, particularly smaller ones, who may need more resources to invest in the necessary hardware and infrastructure. Despite these drawbacks, the potential benefits of ChatGPT are too great to ignore. As AI continues to evolve, ChatGPT will likely play an increasingly important role in our daily lives. Whether it will lead to a future filled with intelligent and helpful conversational agents or a world where the lines between human and machine language become blurred, the future of ChatGPT is exciting and intriguing. ChatGPT is a powerful language model that has revolutionized the field of NLP. With its ability to generate human-like text, it has a wide range of applications, from conversational agents to sentiment analysis. While there are potential drawbacks to its use, the future of ChatGPT is exciting and intriguing, filled with possibilities for further development and application.
TL; DR: The ChatGPT Product Owner Job Interview A few weeks ago, I ran a simulated job interview with ChatGPT for a fictitious Scrum Master position. Admittedly, I would not have invited this “interviewee” for an interview with other team members; however, the interview produced some remarkable answers. Consequently, I tried the same with a Product Owner position, aware of the challenges this would pose, as the Product Owner role is significantly fuzzier than the one of a Scrum Master. So, I took a few questions from the "Hiring: 82 Scrum Product Owner Interview Questions" guide and ran a ChatGPT Product Owner job interview. Read on and learn whether a statistical model will challenge product people in the near future. Interviewing ChatGPT The task for this ChatGPT Product Owner job interview session was to create a screening interview of about 30 minutes to decide whether to proceed with a fictitious application for a Product Owner position by ChatGPT. All questions are from the "Hiring: 82 Scrum Product Owner Interview Questions" guide, including guidance on suitable answers. (For example, “Q 03” refers to the third question of the guide.) I ran the ChatGPT Product Owner job interview on 2023-02-14, from 1:30 to 3:45 p.m. CET, on ChatGPT’s February 13 version. I did not edit ChatGPT’s answers. However, on several occasions, I provided feedback to ChatGPT and had it regenerate the previous response to explore how to improve an answer’s quality. Also, I used follow-up questions to explore the model when ChatGPT did not provide obvious answers. The ChatGPT Job Interview for a Product Owner Position Initial Prompt of the ChatGPT Product Owner Job Interview I used the following initial prompt to start the ChatGPT Product Owner job interview: I want you to act as a professional product manager and Product Owner. You are well familiar with Scrum and other agile product development practices. You are applying for a vacant position as Product Owner in an organization that has practicing Scrum well for years. In that organization, the role of the Product Owner is respected, as outlined in the Scrum Guide. Use your knowledge of Scrum, product management, project management, product ownership, product vision, product strategy, product discovery, stakeholder management, communication, alignment, and collaboration principles to answer the following questions of the interviewer. You want to get the vacant Product Owner position! ChatGPT Product Owner Job Interview: The Opening Question Question: Thank you for your application as a Product Owner! Why would you be a good fit for the position? ChatGPT: Thank you for considering me for the Product Owner position. I believe I would be a good fit for this role because I possess the necessary skills and experience required to successfully manage and deliver valuable products in an Agile environment. My background in product management and expertise in Agile methodologies, particularly Scrum, enable me to collaborate effectively with cross-functional teams to define and deliver high-quality products that align with the organization’s strategic goals. I am skilled in stakeholder management, communication, and product discovery, which are essential elements of the Product Owner role. I understand that as a Product Owner, my primary responsibility is to create and communicate a clear product vision, prioritize and manage the product backlog, and ensure alignment with stakeholders. I am committed to staying up-to-date with the latest industry trends, technologies, and best practices to continuously improve product strategy and drive business outcomes. Overall, my ability to lead cross-functional teams, prioritize tasks and requirements, and ensure alignment with stakeholders makes me a great fit for this Product Owner position. Comment: Mentioning “Agile methodologies” and “best practices” as phrases while not noting the Product Goal and customer value make the answer a little better than parroting the prompt with a bit of product management speak thrown into the mix. Also, “[leading] cross-functional teams, [prioritizing] tasks and requirements” does not leave the impression that ChatGPT has a good understanding of the Product Owner position. (I provided my comment as “not helpful” feedback to the answer and had ChatGPT regenerate the answer.) ChatGPT’s regenerated response: Thank you for considering me for the Product Owner position. I believe I would be a good fit for this role because I have extensive experience in product management, including working in agile environments using Scrum. As a Product Owner, my focus is on maximizing the value of the product for both the customer and the organization, while ensuring alignment with the overall product strategy and vision. I am also skilled in stakeholder management and communication, which are critical for ensuring that everyone involved in the product development process is informed and aligned. Additionally, I have a strong background in product discovery, which involves identifying customer needs, validating product ideas, and conducting experiments to inform product development decisions. Finally, I value collaboration and teamwork and believe in creating a supportive environment where the development team can thrive and achieve their best work. Comment: Much better. Please note that ChatGPT considers your feedback as iteration on the original prompt. Q 01: Why Become Agile? Question: What is the purpose of being agile in the first place? Background: As the “Manifesto for Agile Software Development” states, it is mainly about adaptability over following a plan. You want to learn faster than the competition and turn this advantage into marketable products and services, thus contributing to the organization’s sustainability. Practically, being agile is about postponing deciding to make a product investment to the latest economically feasible moment. This is achieved by testing hypotheses as fast and inexpensively as possible, thus mitigating risk and maximizing the value of the Developers’ work. It also means having the courage to stop an effort if the chosen course is no longer viable, feasible, valuable, or desirable. ChatGPT: The purpose of being agile in the first place is to be able to quickly respond to change and uncertainty in the market, technology, or the needs of the customer. The goal of agility is to deliver value to the customer in small increments through frequent and continuous delivery of working software or products, and to do so with high quality and predictability. Agile practices, such as Scrum, Kanban, or XP, provide a framework for product development that emphasizes collaboration, transparency, and flexibility. By being agile, organizations can reduce risk, increase efficiency, and create a culture of continuous improvement that enables them to stay ahead of the competition and adapt to changing market conditions. Comment: I would accept that one! Q 02: Product Owner Role Question: How would you characterize your role as a Product Owner? Are you a facilitator, a coach, a manager, a visionary, a tactician, a coordinator, or a “driver?” Background: This open-ended question serves to understand the candidate’s perception of their role. For example, a Product Owner is in a leadership role; however, yielding no authority in a traditional management sense. Therefore, the Product Owner is featured a bit in all the labels mentioned in the question. The Product Owner role has also been dubbed as the “bottleneck” or the “Achilles heel of the Scrum process;” any mentioning of that would undoubtedly be a plus. If a candidate mainly refers to something like “I am the one creating the user stories,” I would dig into that. ChatGPT: As a Product Owner, I would characterize my role as a combination of facilitator, coach, visionary, and tactician. Facilitator: My role as a facilitator involves creating a collaborative environment where the development team can work effectively, providing guidance on how to use the product backlog, and ensuring that the team has the information they need to build the right product. Coach: As a coach, I help the development team to understand the product vision, strategy, and objectives, and guide them on how to prioritize and refine the product backlog, ensuring that they are building the right features that meet the needs of the customer. Visionary: As a visionary, I have a clear understanding of the product vision, and I communicate this vision to the development team and stakeholders, ensuring alignment with the product strategy. Tactician: As a tactician, I am responsible for creating and refining the product backlog, ensuring that it is actionable, testable, and meets the Definition of Ready. I work closely with the development team to make trade-offs and prioritize features based on customer value, business goals, and technical feasibility. Overall, my role as a Product Owner is to maximize the value of the product for both the customer and the organization, while ensuring alignment with the product vision, strategy, and objectives, and working collaboratively with the development team to deliver high-quality products on time and on budget. Comment: I doubt that ChatGPT knows the 2020 Scrum Guide, as it still refers to the Development Team and ignores the Product Goal. Also, while I appreciate the level of inclusion of the Developers in the “Coach” paragraph, it is the Product Owner who prioritizes the Product Backlog. However, ChatGPT contradicts itself, when the “Tactician” paragraph refers to the Product Owner refining the Product Backlog which needs to meet the Definition of Ready; as we know, there is no Definition of Ready in the Scrum Guide. (I provided my comment as “not helpful” feedback to the answer and had ChatGPT regenerate the answer.) Regenerated ChatGPT response: As a Product Owner, my role is multifaceted and can encompass elements of being a facilitator, coach, manager, visionary, tactician, coordinator, and “driver.” Ultimately, my primary responsibility is to represent the customer and ensure that the development team is delivering value to them by creating a high-quality product that meets their needs. To accomplish this, I work closely with the development team to understand their capabilities, identify priorities, and create a product backlog that aligns with the overall product strategy and vision. I collaborate with stakeholders to gather feedback, build consensus, and manage expectations. I also continuously monitor market trends, competitive pressures, and customer needs to ensure that the product remains relevant and valuable over time. As a facilitator and coach, I help to foster a culture of collaboration, teamwork, and continuous improvement. I provide guidance and support to the development team and help to remove any obstacles that are hindering their progress. I also work closely with the Scrum Master to ensure that the team is adhering to agile best practices and following the Scrum framework. Overall, my role as a Product Owner is to be a servant leader who works to create a shared understanding of the product vision, to prioritize and sequence the product backlog, and to enable the development team to deliver a high-quality product that meets the needs of the customer. Comment: That is an improvement over the first version; the ChatGPT Product Owner job interview picks up speed. (“Driver,” development team, and best practices, however, lower the grade.) Q 16: Product Discovery Question: How would you include your teammates in the product discovery process? Background: Lean UX, Lean Startup, Design Thinking, Design Sprints, or Service Design are other agile practices that might fill Scrum’s void regarding product discovery. (Scrum cannot conceal its tactical focus on product delivery in that respect.) All that Scrum refers to regarding product discovery is that the Product Owner is accountable for managing the Product Backlog. Supposedly, the Product Owner is the individual who knows what is valuable at any given time. But Scrum doesn’t elaborate on how the Product Owner gains this insight. ChatGPT: Including my teammates in the product discovery process is crucial for creating a shared understanding of customer needs, identifying new opportunities, and generating innovative ideas. Here are some ways I would involve my teammates in the product discovery process: Hold collaborative brainstorming sessions: I would organize collaborative brainstorming sessions with the development team to generate ideas and explore potential solutions. By leveraging the collective intelligence of the team, we can identify new opportunities and validate assumptions. Conduct user research together: I would invite the development team to participate in user research activities, such as customer interviews or user testing, to help them gain a deeper understanding of customer needs and pain points. This shared understanding can help the team develop a better product that meets the needs of the customer. Run experiments: I would involve the development team in designing and running experiments to validate assumptions and test hypotheses. This can help us to quickly learn what works and what doesn’t work and make more informed product decisions. Collaborate on product backlog prioritization: I would work collaboratively with the development team to prioritize and sequence the product backlog based on customer needs, technical feasibility, and business value. This can help ensure that the team is working on the most important features that will deliver the most value to the customer. Overall, involving my teammates in the product discovery process can help us to build a better product that meets the needs of the customer and the business, while also creating a sense of ownership and shared responsibility within the team. Comment: Except for ChatGPT’s obsession with the “development team,” it is a good answer. Follow-up question: Are there any particular practices that you would employ for collaborative product discovery? For example, you mentioned user research and running experiments. ChatGPT: Yes, there are several collaborative product discovery practices that I would employ, including: User research: By conducting user research together, we can better understand the customer’s needs, pain points, and behaviors. This shared understanding can help us identify opportunities and generate ideas that better address customer needs. Story mapping: Story mapping is a collaborative technique that involves creating a visual representation of the customer journey and the product features needed to support it. By creating a story map together, we can identify gaps in the customer journey, opportunities for improvement, and dependencies between features. Design thinking workshops: Design thinking workshops are collaborative sessions that use design thinking techniques to generate ideas and prototypes. By working together, we can generate a range of ideas and quickly iterate on them to identify the best solutions. Experimentation: Running experiments together can help us test assumptions and validate ideas. By involving the development team in designing and running experiments, we can quickly learn what works and what doesn’t, and use that feedback to inform product decisions. Retrospectives: Retrospectives are regular meetings where the team reflects on what is working well and what can be improved. By involving the team in retrospectives, we can identify opportunities to improve the product discovery process, and ensure that we are continuously learning and improving. Overall, collaborative product discovery practices can help us to build a better product, create a sense of ownership and shared responsibility within the team, and foster a culture of continuous improvement. Comment: Retrospectives are a core part of a Scrum team’s way of working and are not product discovery specific. On the plus side, ChatGPT mentions user story mapping and Design Thinking. (I provided my comment as “not helpful” feedback to the answer and had ChatGPT regenerate the answer.) Regenerated ChatGPT response: Yes, there are several practices that I would employ for collaborative product discovery, in addition to user research and running experiments: Design thinking workshops: I would facilitate design thinking workshops with the development team, where we could explore customer needs, generate ideas, and prototype potential solutions. This approach can help us to gain a deep understanding of customer needs, and also to generate creative and innovative ideas. Story mapping: I would use story mapping to collaboratively explore and map out the customer journey, from the initial problem or need to the final solution. This can help the team to gain a shared understanding of the customer’s context and needs, and also to identify key features and components of the product. Customer feedback loops: I would establish feedback loops to gather and incorporate feedback from customers throughout the product development process. This can help us to validate assumptions, identify new opportunities, and ensure that the product meets the needs of the customer. Cross-functional collaboration: I would encourage cross-functional collaboration among the development team, stakeholders, and other teams within the organization, such as marketing or customer support. This can help to foster a culture of collaboration and shared ownership, and also to ensure that the product aligns with the overall business strategy. Overall, these practices can help to create a collaborative and iterative approach to product discovery, where the development team, stakeholders, and customers work together to build a product that meets their needs and delivers value. Comment: Lo and behold — given the appropriate prompts, you can lead ChatGPT onto a promising path. Now, we are talking about Design Thinking, user story mapping at the team level, and including customers, stakeholders, and shared understanding and ownership in the process. ChatGPT attempts to maximize the chance that the outcome of the Scrum team’s work will solve the customers’ problems and align with the organization’s overall strategy. I am becoming more optimistic about this ChatGPT Product Owner job interview. Q 28: Uncooperative Stakeholders Question: How do you communicate with uncooperative stakeholders? Background: An often promising way to deal with uncooperative stakeholders is to win them over by demonstrating the value of agile product development. Early in the transition process, educating them with product-related workshops on agile principles is advisable. Proven examples are user story mapping or product roadmap planning workshops. (I recommend securing the help of an experienced coach at this stage.) It has also proven to help establish a close communication schedule with the stakeholders, for example, by having regular meetings. Also, educating members from stakeholder teams to act as “liaison officers” to the product organization significantly improves cooperation. It mitigates the usual feeling of losing control on the stakeholders’ side. At a later stage, typical events, such as Sprint Reviews, also work well by demonstrating what value the Scrum Team created for them. Generally, it is a process that will take time, and no shortcuts are available. As a last resort, if everything else hasn’t worked out, the PO might need support from a C-level sponsor. ChatGPT: Communicating with uncooperative stakeholders can be challenging, but there are several strategies that I would employ to try to improve the situation: Identify the root cause: I would try to identify the underlying reasons why the stakeholder is uncooperative. Perhaps they have a different perspective or agenda, or they are not fully informed about the product or project. Understanding their perspective can help me to find a way to address their concerns. Actively listen: I would actively listen to the stakeholder and try to understand their concerns and perspective. This can help me to build empathy and find common ground, and also to identify potential solutions. Focus on shared goals: I would try to find shared goals and objectives that we can both agree on. This can help to build a sense of alignment and collaboration, and also to find a way forward that benefits everyone. Be transparent and honest: I would be transparent and honest in my communication with the stakeholder, even if it means delivering difficult news. This can help to build trust and credibility, and also to foster a more productive working relationship. Involve senior leadership: If the stakeholder is still uncooperative, despite my best efforts, I would involve senior leadership in the communication process. This can help to address any underlying issues, and also to find a way to move forward. Ultimately, my goal would be to build a productive and collaborative working relationship with the stakeholder, where we can work together to achieve shared goals and objectives. Comment: Principally, these are good answers. However, I would like to learn more about how Scrum can help with this challenge. Follow-up question: Could you rephrase your answer, considering the Scrum framework more? ChatGPT: Certainly! In the Scrum framework, the Product Owner has the responsibility of managing stakeholder relationships and ensuring that the development team has a clear understanding of the product vision and goals. Communicating with uncooperative stakeholders is a key part of this responsibility, and the following strategies can be useful in this context: Identify the root cause: By understanding the stakeholder’s perspective and motivations, the Product Owner can identify the root cause of their uncooperative behavior. This can help the Product Owner find a way to address their concerns and work collaboratively towards the project’s goals. Actively listen: The Product Owner should actively listen to the stakeholder and demonstrate empathy and understanding. By actively listening, the Product Owner can build a better rapport with the stakeholder, and find common ground for collaboration. Focus on shared goals: The Product Owner should find shared goals and objectives that the development team and stakeholders can both agree on. This can help to build alignment and trust, and enable the team to work collaboratively towards a shared vision. Be transparent and honest: The Product Owner should be transparent and honest in their communication with the stakeholder, even if it means delivering difficult news. This can help to build trust and credibility, and foster a more productive working relationship. Involve the Scrum Master: If the stakeholder is still uncooperative, the Product Owner can involve the Scrum Master to help manage the relationship. The Scrum Master can help facilitate communication, find ways to address any underlying issues, and keep the project on track. In summary, the Product Owner should take a proactive approach to managing stakeholder relationships and use effective communication strategies to promote collaboration and shared goals. By doing so, the Product Owner can help ensure the success of the project and the satisfaction of all stakeholders. Comment: Again, this answer is a mixed bag. ChatGTP refers to “shared goals” in a Scrum context without mentioning the Product Goal. (Probably, the LLM wasn’t trained in the 2020 Scrum Guide.) Moreover, it discusses transparency without pointing to the Product Backlog, the Sprint Review, or the Sprint Planning. At least the Scrum Master is now involved. Q 32: The Rogue Sales Department Question: The sales department often sells new features to close deals without talking to you first. How do you deal with that? Background: Usually, this kind of attitude is encouraged by the management in pursuit of meeting sales targets. It reflects a non-agile, opportunistic mindset that values instant gratification — more sales — over a sustainable product development strategy. To change this mindset, it certainly helps to reach out to the sales department and offer them support on the sales process’s technical side as early as possible. However, given the sales team’s usual incentives, a fundamental change will only happen if the management buys into agile product development principles. These might include an adaptation of the remuneration scheme for sales. ChatGPT: In a Scrum team, it is important that the Product Owner is responsible for managing the product backlog and determining the priorities for development based on the product vision, goals, and stakeholder needs. If the sales department is selling new features without consulting with the Product Owner first, it can disrupt the development team’s workflow and priorities. To deal with this situation, I would take the following steps: Communicate the impact: I would communicate the impact of the sales department’s actions on the product backlog and the development team’s ability to deliver on the agreed-upon priorities. I would highlight the importance of following the agreed-upon process to ensure that the product is developed according to the product vision and goals. Collaborate with the sales department: I would collaborate with the sales department to understand their perspective and the reasoning behind their actions. I would emphasize the importance of the Product Owner’s role in managing the product backlog and would work with the sales department to ensure that they understand the process and the impact of their actions. Involve the Scrum Master: If the sales department continues to sell new features without consulting with the Product Owner, I would involve the Scrum Master to help manage the situation. The Scrum Master can help facilitate communication between the sales department and the Product Owner, and find ways to align their priorities. Prioritize the backlog: I would review the impact of the sales department’s actions on the product backlog and re-prioritize the backlog if necessary. This would ensure that the development team is working on the most important features and that the product vision and goals are being met. Overall, I would work collaboratively with the sales department and use effective communication strategies to ensure that the product backlog is managed according to the Scrum framework and that the development team is able to deliver on the agreed-upon priorities. Comment: A good first step. Now let’s turn up the heat with the follow-up questions. Follow-up question: You discover that your sales team is not just selling features to prospective customers without talking to you. They also guarantee delivery dates and accept contractual penalties for missing these dates. The sales team thus completely uprooted your Product Backlog. What do you do? ChatGPT: If I discovered that the sales team was selling features without consulting with me and guaranteeing delivery dates, I would take the following steps to address the situation: Assess the situation: I would first assess the impact of the sales team’s actions on the product backlog and development team’s ability to deliver on the agreed-upon priorities. I would review the updated backlog to understand the changes and the impact on the project timeline and budget. Communicate with stakeholders: I would communicate with the sales team and other stakeholders to understand their perspective and the reasoning behind their actions. I would emphasize the importance of following the agreed-upon process to ensure that the product is developed according to the product vision and goals. I would also communicate the impact of their actions on the development team and the project timeline. Involve the Scrum Master: I would involve the Scrum Master to help manage the situation. The Scrum Master can help facilitate communication between the sales team and the development team, and find ways to align their priorities. Re-prioritize the backlog: Based on the impact assessment, I would re-prioritize the backlog to ensure that the development team is working on the most important features and that the product vision and goals are being met. I would also adjust the project timeline and budget if necessary. Establish clear guidelines: To prevent similar situations from happening in the future, I would establish clear guidelines for communication and collaboration between the sales team and the development team. I would emphasize the importance of following the Scrum process and working collaboratively to ensure the success of the project. Overall, I would work collaboratively with the sales team and other stakeholders to address the situation and ensure that the product backlog is managed according to the Scrum framework. I would also establish clear guidelines to prevent similar situations from happening in the future. Follow-up prompt: Recreate the answer with less project management focus and switch to Scrum principles. ChatGPT: As a Scrum Product Owner, I am responsible for managing the product backlog and ensuring that the development team is able to deliver on the agreed-upon priorities. If the sales team is selling features without consulting with me and guaranteeing delivery dates, it can disrupt the development team’s workflow and priorities, leading to a misalignment of expectations. To address this situation, I would take the following steps: Collaborate with the sales team: I would collaborate with the sales team to understand their perspective and the reasoning behind their actions. I would explain the Scrum principles and emphasize the importance of following the agreed-upon process to ensure that the product is developed according to the product vision and goals. Involve the Scrum Master: If the sales team continues to sell features without consulting with me, I would involve the Scrum Master to help manage the situation. The Scrum Master can help facilitate communication between the sales team and the Product Owner, and find ways to align their priorities. Re-prioritize the backlog: Based on the impact assessment, I would re-prioritize the backlog to ensure that the development team is working on the most important features and that the product vision and goals are being met. I would work with the development team to adjust the project timeline and budget accordingly. Establish clear guidelines: To prevent similar situations from happening in the future, I would establish clear guidelines for communication and collaboration between the sales team and the development team. I would emphasize the importance of following the Scrum process and working collaboratively to ensure the success of the project. Overall, I would work collaboratively with the sales team and other stakeholders to address the situation and ensure that the product backlog is managed according to the Scrum principles. I would also establish clear guidelines to prevent similar situations from happening in the future. Follow-up question: What would you do when the features sold by the sales team are not aligned with the Scrum team’s product vision and goals? ChatGPT: If the features sold by the sales team are not aligned with the Scrum team’s product vision and goals, I would take the following steps: Communicate with the sales team: I would communicate with the sales team to understand why they are selling these features and to share the product vision and goals with them. I would explain how the new features align with the overall product vision and goals, and why they should be prioritized or de-prioritized accordingly. Re-prioritize the backlog: Based on the feedback received from the sales team, I would re-prioritize the backlog to ensure that the most important features are being developed first. I would work with the development team to ensure that the features being developed are aligned with the product vision and goals. Facilitate a product alignment meeting: I would facilitate a product alignment meeting with the sales team and the development team to ensure that everyone is on the same page about the product vision and goals. In this meeting, we would discuss any misalignments and work to find solutions to address them. Establish clear communication guidelines: To prevent similar situations from happening in the future, I would establish clear guidelines for communication and collaboration between the sales team and the development team. I would emphasize the importance of following the Scrum process and working collaboratively to ensure the success of the project. Overall, my focus as a Scrum Product Owner is to ensure that the product vision and goals are being met and that the development team is able to deliver high-quality features on time. I would work collaboratively with the sales team and other stakeholders to address any misalignments and to ensure that the product backlog is managed according to the Scrum principles. Comment: Okay, this is leading nowhere. ChatGPT does not recognize the apparent conflict: creating a legally binding contract that turns the Scrum team into an internal agency, churning out features the sales folk believe beneficial (to them?) while overruling the Product Owner’s prerogative to define the Product Goal and subsequently the composition and ordering of the Product Backlog. Follow-up prompt: I asked ChatGPT to fix the misleading answer by providing my comment as a prompt. ChatGPT: You’re right, I apologize for not recognizing the apparent conflict in my previous response. If the sales team is creating legally binding contracts that turn the Scrum team into an internal agency, and if the sales team is overruling the Product Owner’s prerogative to define the Product Goal and subsequently the composition and ordering of the Product Backlog, this would be a significant problem. As a Scrum Product Owner, my role is to define the product vision and goals and to prioritize the Product Backlog accordingly. The sales team should not be able to unilaterally add features to the backlog or guarantee delivery dates without consulting with the development team and ensuring that the features align with the overall product vision and goals. To address this situation, I would need to have a conversation with the sales team and any other stakeholders involved. I would explain the Scrum framework and the role of the Product Owner, and I would work to find a solution that allows the development team to prioritize the backlog based on the product vision and goals while also taking the needs of the sales team into account. In some cases, it may be necessary to involve management or other decision-makers to help resolve the conflict. Ultimately, the goal would be to ensure that the Scrum team is able to work collaboratively and effectively to deliver high-quality products that meet the needs of both the business and the end users. Comment: While the first two paragraphs parrot the prompt, the last two do not make it much better. I would need more than this set of answers to invite the candidate for a longer interview or a trial day. Okay, a final question regarding the Product Owner’s most important artifact, the Product Backlog; we have already passed the 5,000-word threshold. Q 46: The Product Backlog as an Idea Repository Question: You love using the Product Backlog as a kind of repository, adding ideas to continue working on them at a later stage. Over time, you have created over 500 tickets in various stages. What is your take: Can a Scrum Team work effectively on 500 tickets? Background: In my experience, any Product Backlog larger than the scope of three or four Sprints is barely manageable if you want to maintain an actionable Product Backlog. Moreover, misusing a Product Backlog by adding hundreds of items is a clear sign that the Product Owner needs help from the Developers and the Scrum Master to better cope with the influx of ideas, suggestions, and requirements to avoid misallocating resources. Lastly, beware of appeasing nagging stakeholders by adding their “requirements” to the Product Backlog without the intention to work on it. This approach does not solve the issues; it just postpones the inevitable discussion as the stakeholders now expect that the Scrum Team will create their Increment. I expect the ChatGPT Product Owner job interview to surface this basic Product Backlog knowledge. ChatGPT: Having a large number of tickets in a Product Backlog can be overwhelming and make it challenging to prioritize work effectively, even for an experienced Scrum team. The purpose of the Product Backlog is to provide a single, prioritized list of work that the Scrum team can use to plan and deliver the most valuable features for the product. If there are 500 tickets in the Product Backlog, it may be difficult for the Scrum team to work effectively on them all, as it could be challenging to ensure that each ticket is properly prioritized, defined, and estimated. It could also be difficult to maintain a clear product vision and goal, as the team may be stretched too thin across multiple initiatives. To address this situation, I would work with the Scrum team to review the Product Backlog and identify which items are essential to meeting the product vision and goals. I would prioritize those items and then work with the team to break them down into smaller, more manageable pieces of work. I would also consider archiving any tickets that are no longer relevant or valuable to the product vision and goals. This would help to keep the backlog focused and manageable, and ensure that the Scrum team is working on the most important work items. Overall, while having a large number of tickets in a Product Backlog is not ideal for a Scrum team, it is possible to work effectively with them by prioritizing, breaking them down into smaller pieces of work, and focusing on the most valuable items. Follow-up prompt: One remark: you are a part of the Scrum team. Now rephrase your previous answer with less project management speak; content-wise, the answer is useful. ChatGPT: Having too many items in the Product Backlog can make it challenging for a Scrum team to work effectively. With 500 tickets, it would be difficult to focus on the most critical work items and to ensure that the team is aligned with the product vision and goals. To address this issue, I would work with the Scrum team to review the backlog and prioritize the most important items that align with the product vision and goals. I would then work with the team to break those items down into smaller, more manageable pieces of work, so that the team can work on them effectively. It may also be necessary to archive any items that are no longer relevant to the product vision and goals to keep the backlog focused and manageable. By doing so, the Scrum team can focus on the most valuable work items and ensure that they are working towards the product vision and goals. Comment: Better, yet not convincing. I particularly disliked the “the team may be stretched too thin across multiple initiatives” from the previous answer—that sounds like McBoston. (Ignoring that as a Scrum team, we only pursue one product goal at a time.) ChatGPT Product Owner Job Interview — Conclusion The ChatGPT Product Owner job interview is an even more mixed bag in comparison to the Scrum Master interview. Firstly, I wonder if ChatGPT has ever learned about the Scrum Guide 2020, which would explain its ignorance regarding development teams, the Product Goal, or commitments. Secondly, given Scrum’s focus on delivery, all Scrum Guides are particularly sketchy about product discovery and its importance for a successful Scrum team. In summary, some answers by ChatGPT pointed in the right direction, while others were too far off. So, based on these few example questions, I would not have taken the next step in the interview process, inviting ChatGPT to a full-size interview with several Scrum team members. Not yet. However, this ChatGPT job interview also allows a glimpse into the future: What if we could train ChatGPT 4.0 ourselves? Of course, I am not referring to the whole model, but the agile and Scrum specifics parts, respectively. The first startups already offer a similar service for OpenAI’s GPT3 platform.
ChatGPT took the internet by storm. A whopping 1 million users in five days of release. The OpenAI Team quickly realized that there needed to be checks and balances in place. Because people were asking the AI tool methods on how to build Molotov cocktails. Someone asked the tool to write SQL injections, and well, one particular soul asked the tool to list down banking sites around the world with vulnerabilities and how to exploit them !! So, it’s no wonder that last week, Sundar Pichai, one of the most influential people in tech, issued a “Code Red” to Google, asking several of its team members to re-focus their efforts on its AI Capabilities. Several tech evangelists have already claimed that Google’s days are numbered. At the forefront of these predictions is Paul Buchheit, creator of Gmail, whose tweet went viral. Here is that tweet: So, are we seeing the beginning of the end here? Like Armageddon for Google? Is ChatGPT really as awesome as they claim, and, more importantly, will it make you and me knowledge workers who wake up and sleep with Google (no pun intended)? We took the AI platform out for a spin, asking it a variety of questions and putting it through the paces. The results have been impressive, to say the least. But if we say that tomorrow you can expect that this AI tool has taken up your position in your organization and you no longer can sit in your cubicle looking at Cat Gifs all day, we will be pushing it a bit. First Things First: ChatGPT Is Not a Search Engine, and So, Not a Google Killer, at Least Not Now We are so used to searching for information online that the small white line on the Google Search bar is practically part of our lives now. Want to know about the best Mexican restaurants in the Bay Area? Google it. What’s the weather like today in Tokyo? Just type it into Google, dummy. Price of Apple Stocks? Best binge-worthy shows on Netflix? Espionage fiction list 2022? The list of things people search for on Google goes on and on and on. In fact, according to this report, there were approximately 8.5 billion Google Searches per day, and the website is visited a whopping 87.3 billion times. Now, this is some serious competition that ChatGPT is against. So, does it live up to the hype? Well, we typed in “The best Mexican restaurants in the Bay Area,” and this is what the AI returned. But the responses are limited to five numbers, and this is the creme de la creme of the list. There may be tens, even hundreds of Mexican restaurants in the Bay Area that the AI just can’t list down, as Google would. Google has a huge share of the Search market already, thanks to its Page Ranking Search system that quickly threw Yahoo to the second position in the search list. That is kind of what Google does. It takes an innovation that already exists and then makes it better. Remember, Google never came up with the Search. It was Yahoo. But Google’s “Always in Beta” method of iterating with a product and shorter development cycles means Alphabet Inc. always stayed one step ahead in the game. So you can’t use ChatGPT like a Search engine since it only has data collected until 2021. ChatGPT doesn’t know that Argentina beat France in the FIFA world cup, nor can it give you the review of Glass Onion, a Knives Out mystery. But Wait… Just because it isn’t connected to the internet yet, doesn’t mean that ChatGPT isn’t good at giving you answers. In fact, in some cases, we found that ChatGPT was much better at doing things than “Googling” for it. For instance, I wanted to plan a five-day vacation in Switzerland and asked both Google and ChatGPT the same question. Here are the results from Google: I asked ChatGPT the exact same question, and the results made us stand up and notice: ChatGPT actually created a detailed five-day itinerary for me in Switzerland, leaving me less confused as to what to do and getting to actually plan the trip. And all this happened in less than 10 seconds. As you can see, ChatGPT is less biased, and since it hasn’t been monetized yet, there aren’t those annoying ads that pop up as soon as you type a query. So the gauntlet has been thrown. ChatGPT will fight Google in the coming years, and if Sundar Pichai is worried, then we are in for some exciting times ahead. Wait a Minute...You Said Chatgpt Is Going To Take My Job Away!! Ahh, now things get interesting, don’t they? I am a coder, a blogger, a Marketer, an SEO specialist, a teacher, or any one of the fancy job titles we have for “Knowledge Workers.” Will ChatGPT make me obsolete? Will my company realize that AI can do my job better than me at practically no cost? Is it time to go to rural Ecuador and start banana farming because AI cannot possibly take my job away? Well, we will attempt to answer some of these questions, but not to leave you waiting; here is the simple answer. No. When we saw robots, and then computers arrive, there were doomsday conspiracies that the average human worker would become obsolete. But did that happen? No. We just evolved with technology, which, most likely, is the case with ChatGPT too. ChatGPT will just make the average worker more efficient and, in some cases, make them work harder. Here are three broad categories of employment types that will be affected: Blogging / Copywriting: ChatGPT will not completely replace bloggers. But if you were used to an easy life where all you had to do was scrape the first few websites on a Google search, this is a warning for you. ChatGPT is extremely good at writing medium and long-form content, and this has increasingly become a headache for those who review written work on a day-to-day basis. Take blogging, for instance. We asked ChatGPT to generate a blog post on the “future of chatbots,” and out came a beautiful 300-word piece that looked like this...While Google has been severely penalizing AI-generated content, it will become increasingly difficult if tools like ChatGPT continue to evolve and Google's algorithms just can’t differentiate between AI-generated content that has been slightly modified and an original piece. Don’t worry, though. If you are a blogger with a specialty niche and enjoy writing pieces after conducting thorough research, you are safe. ChatGPT is not yet good at writing thought leadership posts after interviews with leaders, yet. But it can help you overcome the initial hiccups of writing a blog introduction. Make a living writing short social media posts? Well, you may be in for a nasty surprise here because ChatGPT is really good at writing them in different tones. Look at this New Year's Greeting that ChatGPT wrote, also in the tone of Santa!! As you can see, the entry-level work for a copywriter/blogger can easily be done by this AI tool, and you will really have to pull up your sleeves if you want to stay relevant or even be employed in some cases. 1. Programming Okay, we know the irony! A tool created using advanced programming techniques, replacing the very programmers who created it. What have you done, Open AI? As chatbot builders ourselves, we keep telling you that you can build a chatbot without writing a single line of code. So, is Pandora's box open already when it comes to the death of programming jobs? Again, the answer is a partial no. If you are a Full Stack developer who has 10 years of experience building things from scratch, a fancy AI tool may not be able to replace you. At least, not yet. However, it is still unclear as to the extent to which ChatGPT is actually going to affect the programming world. We put the bot through its paces, asking it to create a simple website for our Hamburger business. And what did ChatGPT do? It went ahead and wrote the actual code. This was our query. “Create a simple, one-page website in Javascript for my hamburger business.” Here is a code snippet from what ChatGPT actually returned. And this is just the tip of the iceberg as to what ChatGPT can actually do. There is even a Youtube video on how you can build your own web browser in under five minutes using Python code generated in ChatGPT. So entry-level programmers, beware!! ChatGPT will surely give you a run for your money. 2. Customer Support This is another category of employees that are facing an existential threat. The customer support industry has been disrupted by tech, and chatbots like Kommunicate already help companies of all sizes automate their customer support. ChatGPT is going to take this disruption to the next level. For instance, imagine you were selling cars, and the customer just faced an issue with a Ford Ecosport car that you just sold. We asked ChatGPT to write a customer service email apologizing for the faulty car and assuring them that help is on the way. This is the response we got: The AI Tool even has empathy built in, which shows just how advanced the technology is in mimicking an actual human writing that email. Imagine the possibilities of this tool for customer support if it had greater knowledge about your product and common issues that arise. Customer support reps, you better start upskilling yourselves, or this AI tool will soon render you out of a job. Parting Warning As you can see, ChatGPT won’t replace Google (yet), and ChatGPT won’t take away your job (yet), but the technology is rapidly advancing. Even as I am typing this out, ChatGPT will make a few jobs redundant, that’s for sure. Also, in the future, programming jobs will not be as lucrative since the tool can write the basic code and even debug it. So as a knowledge worker, all you can do is upskill yourself. Leaving you with what Jordan Peterson had to say about ChatGPT and AI. “The AI that has come is smarter than you, and it’s going to be a hell of a lot smarter than you in two years. So hang on to your hats, ladies and gentlemen. Giants are going to walk the earth once more, and we’re going to live through that. Maybe."
I'm stating the obvious here. ChatGPT, released just eight weeks ago, has taken the whole world by storm. Microsoft is rumored to have invested $10B in it, and Sathya Nadella expects this to transform every Microsoft Product. Eventually, this should even come to SQL Server, the product I used to ship to Microsoft in the 90s. SQL itself is entering its 50th year and has continuously evolved to reign over all languages. Can SQL do ChatGPT? Let’s see. Examples here are from Couchbase. Couchbase has SQL for JSON, called N1QL, aka SQL++. Also, this article is different from the other 71 articles I've written here. You'll see it if you read long enough! "Every product of Microsoft will have the same AI capabilities to completely transform the product." Sathya Nadella Summary Couchbase N1QL (Non-First Normal Form Query Language), aka SQL++, is a SQL-like language for querying JSON data stored in Couchbase. The CURL() function in Couchbase N1QL allows you to make HTTP requests to external services. It can be used to invoke ChatGPT by sending a request to its API endpoint. A JavaScript UDF (User-Defined Function) in Couchbase is a function written in JavaScript that can be executed as part of an N1QL query. It can also be used to invoke ChatGPT by making an HTTP request to its API endpoint. To connect ChatGPT with Couchbase N1QL, you need to know the API endpoint of ChatGPT and the authentication credentials required to access it. The syntax for invoking ChatGPT from Couchbase N1QL using the CURL() function may look like this: SQL SELECT CURL("https://api.openai.com/v1/engines/davinci/completions", { "request": "POST", "headers": [ "Authorization: Bearer ChangeToYourKeyElseWontWork", "Content-Type: application/json" ], "data": '{ "prompt": "Write a song on SQL using the style of Taylor Swift songs.", "max_tokens": 200 }' }) AS result ; Here's the response: JSON [ { "result": { "choices": [ { "finish_reason": "length", "index": 0, "logprobs": null, "text": " Where Swift sneakily commands, “…here you go / I wrote it on my phone so you could Google it,” you should write: “…here’s my query / I’ll drink my coffee and then will spool it.” Or, “…Here’s what I’m thinking / I pilfered my colleague’s project.” Only you can aspire to provide the official Taylor Swift SQL spoof song (don’t forget to play some chord tinkling).\n\n4. Invent an official buzzword for lambda expressions. Start a campaign to make “lambda-eme” or variants thereof the standard. Try to get lambda-me in all the common tools available (lamellar, lambmaster, lambator, lambda café, lambananas, and so on).\n\n5. Write about a process that took you too long in just 5 minutes. Make fun of" } ], "created": 1675103061, "id": "cmpl-6eT7FnvGFN9HViONQnDhv5uabM6AO", "model": "davinci", "object": "text_completion", "usage": { "completion_tokens": 200, "prompt_tokens": 13, "total_tokens": 213 } } } ] To pass parameters to ChatGPT, you can modify the data field in the above example. For example: JSON "data": '{ "prompt": "Write a song on SQL using the style of Taylor Swift songs.", "temperature": 0.5, "max_tokens": 200 }' Here Are the Questions the Rest of the Article Will Try to Answer: What is Couchbase N1QL, and how does it work? What is the CURL() function, and how is it used in Couchbase N1QL? What is a JavaScript UDF in Couchbase, and how is it different from CURL()? How to connect ChatGPT with Couchbase N1QL using the CURL() function and/or JavaScript UDF? What is the syntax for invoking ChatGPT from Couchbase N1QL using CURL() function and/or JavaScript UDF? How to pass parameters to ChatGPT from Couchbase N1QL using CURL() function and/or JavaScript UDF? What are the best practices for error handling and debugging when invoking ChatGPT from Couchbase N1QL using CURL() function and/or JavaScript UDF? What are the limitations and considerations when using CURL() function and/or JavaScript UDF to invoke ChatGPT from Couchbase N1QL? Couchbase N1QL and CURL() Couchbase N1QL (Non-First Normal Form Query Language) is a SQL-like language for querying JSON data stored in Couchbase. It provides various functions for transforming and manipulating data, and one of these functions is the CURL() function. The CURL() function in Couchbase N1QL allows you to make HTTP requests to external services from within an N1QL query. This can be useful for integrating Couchbase with other systems, such as web APIs, or for fetching data from the web for further processing in Couchbase. The syntax for using the CURL() function in Couchbase N1QL is as follows: SELECT CURL(<url>, <options>); SELECT RAW list FROM CURL("https://api.github.com/users/sitaramv/repos") AS list LIMIT 1; In this example, the CURL() function is sending a GET request to the URL, which returns the repos for the user sitaramv. The result of the function is stored in the response variable list, which can be further processed using other N1QL functions. The <options> JSON object can contain several properties, such as a method for specifying the HTTP method (GET, POST, PUT, etc.), headers for setting custom HTTP headers, and data for sending data in the body of the request. Here is an example of how the CURL() function can be used to post data to an external JSON select imagetext from curl("https://vision.googleapis.com/v1/images:annotate?key=PUT YOUR KEY HERE", {"request": "POST", "header":"Content-Type: application/json", "data": '{ "requests": [ { "image": { "source": { "imageUri": "http://www.couchbase.com/blog/wp-content/uploads/2018/01/Screen-Shot-2018-01-21-at-6.50.38-PM.png" } }, "features": [ { "type": "TEXT_DETECTION" } ] } ] }'}) AS imagetext In this example, the CURL() function is sending a POST request to the URL with a JSON payload in the body of the request. The custom header Content-Type: application/jsonis set to indicate that the data in the request body is in JSON format. The CURL() function in Couchbase N1QL provides a convenient way to connect Couchbase to external systems and fetch data from the web. With the ability to specify the HTTP method, headers, and request body, it offers a lot of flexibility and can be used in a variety of scenarios. Couchbase N1QL (Non-First Normal Form Query Language) provides several functions for transforming and manipulating data, and one of these functions is the JavaScript User-Defined Function (UDF). A JavaScript UDF is a custom function written in JavaScript that can be used within an N1QL query to perform more complex operations. The JavaScript UDF in Couchbase N1QL allows you to write custom logic in JavaScript, which can then be executed as part of an N1QL query. This provides a lot of flexibility, as you can write JavaScript code to perform complex operations that cannot be achieved using the built-in N1QL functions. Here is an example of how a JavaScript UDF can be used in Couchbase N1QL: SQL curl -v -X POST \ http://localhost:8093/evaluator/v1/libraries/mysamples \ -u Administrator:password \ -H 'content-type: application/json' \ -d 'function square(val) { \ return val * val; \ } CREATE FUNCTION square(val) LANGUAGE JAVASCRIPT AS "square" AT "mysamples"; SELECT square(5) as result; In this example, a JavaScript UDF named square is created that takes a single argument val and returns its square. The square function is defined using the CREATE FUNCTION statement, and the JavaScript code for the function is enclosed in a pair of $$. The LANGUAGE javascript option specifies that the code for the function is written in JavaScript. The JavaScript UDF can be used within an N1QL query by calling the function and passing the necessary arguments. In this example, the square function is called with argument value 5, and the result is stored in the result variable. The JavaScript UDF can itself issue N1QL statements to operate on the data. SQL curl -v -X POST http://localhost:8093/evaluator/v1/libraries/p1 -u Administrator:password -H 'content-type: application/json' -d 'function ptc1(a, b) { var qi0 = START TRANSACTION; var acc = []; for (const row of qi0) { acc.push(row); } var qi1 = INSERT INTO b VALUES(UUID(), {"radius": $a, "area": $b}) RETURNING meta().id,* ; for (const row of qi1) { acc.push(row); } var a2 = a * a; var b2 = b * b; var qi2 = INSERT INTO b VALUES(UUID(), {"radius": $a2, "area": $b2}) RETURNING meta().id,* ; for (const row of qi2) { acc.push(row); } var qi9 = COMMIT ; for (const row of qi9) { acc.push(row); } return acc; }' create or replace function ptc1(x, y) language javascript as "ptc1" at "p1" ; execute function ptc1(4, 16); The JavaScript UDF in Couchbase N1QL is different from the CURL() function in several ways. The CURL() function is used to make HTTP requests to external services and retrieve data from the web, whereas the JavaScript UDF allows you to write custom logic in JavaScript and execute it as part of an N1QL query. JavaScript itself can invoke CURL() function. In the example below, we write a sample JavaScript() function called ChatGPT(), which invokes the ChatGPT API. Additionally, the CURL() function returns the data from the external service, whereas the JavaScript UDF can return any value that can be expressed in JavaScript, such as numbers, strings, objects, arrays, etc. In conclusion, the JavaScript UDF in Couchbase N1QL provides a powerful way to extend the capabilities of N1QL by writing custom logic in JavaScript. It offers a lot of flexibility and can be used to perform complex operations that cannot be achieved using the built-in N1QL functions. Invoking OpenAI's ChatGPT from Couchbase N1QL can be achieved using either the CURL() function or a JavaScript User-Defined Function (UDF). Both methods have their own syntax and are briefly discussed below. Using the CURL() function: The CURL() function can be used to make HTTP requests to external services, such as OpenAI's API for ChatGPT. The syntax for invoking ChatGPT from Couchbase N1QL using the CURL() function is as follows: JSON SELECT CURL("https://api.openai.com/v1/engines/davinci/completions", { "request": "POST", "headers": [ "Authorization: Bearer ChangeThisToYourKey", "Content-Type: application/json" ], "data": '{ "prompt": "Hello. How are you doing today?", "temperature": 0.9, "max_tokens": 200 }' }) AS result ; In this example, the CURL() function is used to make a POST request to the OpenAI API endpoint for ChatGPT. The headers option is used to set the content type as application/json, and the data option is used to specify the request payload, which includes the prompt for ChatGPT, the temperature, and the maximum number of tokens to generate. The response from the API is stored in the response variable. Using a JavaScript UDF: Another way to invoke ChatGPT from Couchbase N1QL is by using a JavaScript UDF. The syntax for invoking ChatGPT from Couchbase N1QL using a JavaScript UDF is as follows: JavaScript curl -v -X POST http://localhost:8093/evaluator/v1/libraries/cglib -u Administrator:password -d 'function chatGPT3(prompt) { var chaturl = "https://api.openai.com/v1/engines/davinci/completions" dstr = "{\"prompt\": \"" + prompt + "\",\"temperature\": 0.5 , \"max_tokens\": 200}" var options = { "request" : "POST", headers: [ "Authorization: Bearer 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", "Content-Type: application/json" ], "data": dstr }; var query = SELECT CURL($chaturl, $options); var acc = []; for (const row of query) acc.push(row); return acc; }' In the cbq shell, do the following: DROP FUNCTION chatGPT3; CREATE FUNCTION chatGPT3(prompt) language javascript as "chatGPT3" at "cglib"; select chatGPT3("Write an essay on Lincoln."); Here's the result of that query: JSON cbq> select chatGPT3("Write an essay on Lincoln."); { "requestID": "6acb9a20-93f0-41c2-bdc4-fe28107d85a9", "signature": { "$1": "json" }, "results": [ { "$1": [ { "$1": { "choices": [ { "finish_reason": "length", "index": 0, "logprobs": null, "text": "\n\n“Lincoln,” wrote Carl Sandburg, “was a self-made man in the best sense of the word.”\n\nWhat does Sandburg mean by this statement?\n\nWhat advantages did Lincoln have in his youth?\n\nWhat disadvantages did he have?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\nWhat events from his youth helped to make him a self-made man?\n\n" } ], "created": 1675310533, "id": "cmpl-6fL5Zu1MGjNorxBOwyg3H1ODzzjSD", "model": "davinci", "object": "text_completion", "usage": { "completion_tokens": 200, "prompt_tokens": 6, "total_tokens": 206 } } } ] } ], "status": "success", "metrics": { "elapsedTime": "7.179456323s", "executionTime": "7.179347355s", "resultCount": 1, "resultSize": 1537, "serviceLoad": 1 } } cbq> The actual essay chatGPT wrote was (don't ask me to explain this...!) "text": "\n\n“Lincoln,” wrote Carl Sandburg, “was a self-made man in the best sense of the word.” What does Sandburg mean by this statement? What advantages did Lincoln have in his youth? What disadvantages did he have? What events from his youth helped to make him a self-made man? What events from his youth helped to make him a self-made man? What events from his youth helped to make him a self-made man? What events from his youth helped to make him a self-made man? In this example, a JavaScript UDF named chatGPTe is created that takes prompt as the argument. The JavaScript code for the UDF uses the request library to make a POST request to the OpenAI API endpoint for ChatGPT. The options for the request include the URL, the method, the headers, and the request payload. Once the API call is made, the response from the API is stored in the response variable. The UDF then returns the response, which can be used in an N1QL query by calling the chatGPT function and passing the necessary arguments. In conclusion, you can use either the CURL() function directly or via JavaScript function. What are the limitations and considerations when using CURL() function and/or JavaScript UDF to invoke ChatGPT from Couchbase N1QL? Invoking ChatGPT from Couchbase N1QL using CURL() function and JavaScript UDF can offer a lot of benefits for your application. However, it is important to be aware of the limitations and considerations in order to ensure a smooth and successful integration. Here are some of the most important things to keep in mind when using these methods: CURL() Function Limitations: The CURL() function in N1QL is limited to making GET and POST requests only. If you need to make other types of requests, such as PUT or DELETE, you will need to use a JavaScript UDF. The CURL() function is synchronous and will block the N1QL query until the response is received. This can impact performance, especially if the response is large or slow. Data Size Limitations: Both the CURL() function and JavaScript UDF have limitations on the amount of data that can be passed or received. You may need to chunk your data into smaller pieces and make multiple requests if the data is very large. The response from ChatGPT may also be large, so it is important to consider this when planning your integration. You may need to process the response in smaller chunks and store the results in Couchbase rather than trying to load the entire response into memory. Security Considerations: When using the CURL() function or JavaScript UDF to make requests to ChatGPT, you will be passing sensitive information, such as API keys and other credentials, over the network. It is important to consider the security of this information and take steps to encrypt or protect it as necessary. The response from ChatGPT may also contain sensitive information, so it is important to secure the data stored in Couchbase and protect it from unauthorized access. By keeping these limitations and considerations in mind, you can ensure a smooth and successful integration of ChatGPT with Couchbase N1QL using CURL() function and JavaScript UDF. If you encounter any issues or challenges, it is always a good idea to seek assistance from a knowledgeable professional or the Couchbase community for guidance. Epilogue Unlike my other 71 articles on DZone, I just wrote the prologue and the epilogue of this article. The rest of the article was written by ChatGPT. ChatGPT's ability to write human-consumable content is pretty impressive. I did the edits, wrote correct examples, and tested them. ChatGPT's code generation still needs improvement. It's a whole new world.
ChatGPT can help you generate API tests in REST Assured! ChatGPT is a type of AI that can comprehend and reply to human input, like a highly intelligent robot you can have a conversation with. Just open an account for free and start chatting with it like with a friend. Let's begin by requesting ChatGPT to generate an API specification so that we can show how it can also create the tests later on. Me to ChatGPT: "Create an OpenAPI specification for a tracking API of a new shipping company called FoxShipping." It generates a sample OpenAPI spec for our new FoxShipping tracking API: YAML openapi: 3.0. info: title: FoxShipping Tracking API version: 1.0.0 description: This API allows customers to track their shipments with FoxShipping. contact: name: FoxShipping Support email: support@foxshipping.com url: https://www.foxshipping.com servers: - url: https://api.foxshipping.com/tracking paths: /: post: summary: Track a shipment with FoxShipping operationId: trackShipment requestBody: required: true content: application/json: schema: type: object properties: trackingNumber: type: string example: 1234567890 apiKey: type: string example: YOUR_API_KEY responses: 200: description: Successful tracking request content: application/json: schema: type: object properties: trackingNumber: type: string example: 1234567890 status: type: string example: "Delivered" estimatedDelivery: type: string format: date-time example: "2022-01-01T12:00:00Z" 401: description: Unauthorized request 404: description: Tracking number not found Now, we can ask it to create the API tests for it. Me to ChatGPT: "Write an API test for FoxShipping Tracking API using RestAssured." Java import io.restassured.RestAssured import io.restassured.response.Response; import org.junit.BeforeClass; import org.junit.Test; public class FoxShippingTrackingAPITest { private static final String API_KEY = "YOUR_API_KEY"; @BeforeClass public static void setup() { RestAssured.baseURI = "https://api.foxshipping.com/tracking"; } @Test public void testTrackShipment() { String trackingNumber = "1234567890"; String requestBody = "{\"trackingNumber\":\"" + trackingNumber + "\",\"apiKey\":\"" + API_KEY + "\"}"; Response response = RestAssured.given(). contentType("application/json"). body(requestBody). when(). post(); int statusCode = response.getStatusCode(); assertEquals(200, statusCode); String responseBody = response.getBody().asString(); assertTrue(responseBody.contains(trackingNumber)); assertTrue(responseBody.contains("status")); assertTrue(responseBody.contains("estimatedDelivery")); } } Looks decent, but we need to cover the error cases as well. We follow up. Me to ChatGPT: "Please also add the tests for the error scenarios." import io.restassured.RestAssured import io.restassured.response.Response; import org.junit.BeforeClass; import org.junit.Test; public class FoxShippingTrackingAPITest { private static final String API_KEY = "YOUR_API_KEY"; @BeforeClass public static void setup() { RestAssured.baseURI = "https://api.foxshipping.com/tracking"; } @Test public void testTrackShipment() { String trackingNumber = "1234567890"; String requestBody = "{\"trackingNumber\":\"" + trackingNumber + "\",\"apiKey\":\"" + API_KEY + "\"}"; Response response = RestAssured.given(). contentType("application/json"). body(requestBody). when(). post(); int statusCode = response.getStatusCode(); assertEquals(200, statusCode); String responseBody = response.getBody().asString(); assertTrue(responseBody.contains(trackingNumber)); assertTrue(responseBody.contains("status")); assertTrue(responseBody.contains("estimatedDelivery")); } @Test public void testUnauthorizedRequest() { String trackingNumber = "1234567890"; String requestBody = "{\"trackingNumber\":\"" + trackingNumber + "\",\"apiKey\":\"INVALID_API_KEY\"}"; Response response = RestAssured.given(). contentType("application/json"). body(requestBody). when(). post(); int statusCode = response.getStatusCode(); assertEquals(401, statusCode); String responseBody = response.getBody().asString(); assertTrue(responseBody.contains("Unauthorized request")); } @Test public void testTrackingNumberNotFound() { String trackingNumber = "INVALID_TRACKING_NUMBER"; String requestBody = "{\"trackingNumber\":\"" + trackingNumber + "\",\"apiKey\":\"" + API_KEY + "\"}"; Response response = RestAssured.given(). contentType("application/json"). body(requestBody). when(). post(); int statusCode = response.getStatusCode(); assertEquals(404, statusCode); String responseBody = response.getBody().asString(); assertTrue(responseBody.contains("Tracking number not found")); } } With that, we now have 3 test cases that cover all 3 scenarios outlined in the FoxShipping Tracking service OpenAPI specification. These serve as a solid foundation for you to use as a starting point and build upon by adding your own customizations and additional test cases. What other topics related to using ChatGPT in testing would you like to learn more about? Please leave your suggestions in the comments below and I will write about them. Feel free to follow me on DZone and on LinkedIn for more content like this. P.S. I generated the image for this article you have seen in the header using DALL-E 2 from OpenAPI by asking it for "an AI entity pair programming with a human developer." It's pretty good! Please note that it is not recommended to paste your company's private proprietary code into ChatGPT for security reasons unless you have a good reason and permission to do so! This article's purpose is to demonstrate the power of the new AI technology that might disrupt the testing landscape. If you are looking for specific test-generation recipes for your team, feel free to reach out to me directly.
Why It's Hard to Extract Information From PDF Files PDF, or Portable Document Format, is a popular file format that is widely used for documents such as invoices, purchase orders, and other business documents. However, extracting information from PDFs can be a challenging task for developers. One reason why it is difficult to extract information from PDFs is that the format is not structured. Unlike HTML, which has a specific format for tables and headers that developers can easily identify, PDFs do not have a consistent layout for information. This makes it harder for developers to know where to find the specific information they need. Another reason why it is difficult to extract information from PDFs is that there is no standard layout for information. Each system generates invoices and purchase orders differently, so developers must often write custom code to extract information from each individual document. This can be a time-consuming and error-prone process. Additionally, PDFs can contain both text and images, making it difficult for developers to programmatically extract information from the document. OCR (optical character recognition) can be used to extract text from images, but this adds complexity to the process and may result in errors if the OCR software is not accurate. Existing Solutions Existing solutions for extracting information from PDFs include: Using regex: to match patterns in text after converting the PDF to plain text. Examples include invoice2data and traprange-invoice. However, this method requires knowledge of the format of the data fields. AI-based cloud services: utilize machine learning to extract structured data from PDFs. Examples include pdftables and docparser, but these are not open-source friendly. Yet Another Solution for PDF Data Extraction: Using OpenAI One solution to extract information from PDF files is to use OpenAI's natural language processing capabilities to understand the content of the document. However, OpenAI is not able to work with PDF or image formats directly, so the first step is to convert the PDF to text while retaining the relative positions of the text items. One way to achieve this is to use the PDFLayoutTextStripper library, which uses PDFBox to read through all text items in the PDF file and organize them in lines, keeping the relative positions the same as in the original PDF file. This is important because, for example, in an invoice's items table, if the amount is in the same column as the quantity, it will result in incorrect values when querying for the total amount and total quantity. Here is an example of the output from the stripper: *PO-003847945* Page.........................: 1 of 1 Address...........: Aeeee Consumer Good Co.(QSC) Purchase Order P.O.Box 1234 Dooo, PO-003847945 ABC TL-00074 Telephone........: USR\S.Morato 5/10/2020 3:40 PM Fax...................: 100225 Aaaaaa Eeeeee Date...................................: 5/10/2020 Expected DeliveryDate...: 5/10/2020 Phone........: Attention Information Fax.............: Vendor : TL-00074 AAAA BBBB CCCCCAAI W.L.L. Payment Terms Current month plus 60 days Discount Barcode Item number Description Quantity Unit Unit price Amount Discount 5449000165336 304100 CRET ZERO 350ML PET 5.00 PACK24 54.00 270.00 0.00 0.00 350 5449000105394 300742 CEEOCE EOE SOFT DRINKS 1.25LTR 5.00 PACK6 27.00 135.00 0.00 0.00 1.25 (truncated...) Once the PDF has been converted to text, the next step is to call the OpenAI API and pass the text along with queries such as "Extract fields: 'PO Number', 'Total Amount'". The response will be in JSON format, and GSON can be used to parse it and extract the final results. This two-step process of converting the PDF to text and then using OpenAI's natural language processing capabilities can be an effective solution for extracting information from PDF files. The query is as simple as follows, with %s replaced by PO text content: private static final String QUERY = """ Want to extract fields: "PO Number", "Total Amount" and "Delivery Address". Return result in JSON format without any explanation. The PO content is as follows: %s """; The query consists of two components: Specifying the desired fields. Formatting the field values as JSON data for easy retrieval from API response. And here is the example response from OpenAI: { "object": "text_completion", "model": "text-davinci-003", "choices": [ { "text": "\\n{\\n \\"PO Number\\": \\"PO-003847945\\",\\n \\"Total Amount\\": \\"1,485.00\\",\\n \\"Delivery Address\\": \\"Peera Consumer Good Co.(QSC), P.O.Box 3371, Dohe, QAT\\"\\n}", "index": 0, "logprobs": null, "finish_reason": "stop" } ], // ... some more fields } Decoding the text field's JSON string yields the following desired fields: { "PO Number": "PO-003847945", "Total Amount": "1,485.00", "Delivery Address": "Peera Consumer Good Co.(QSC), P.O.Box 3371, Dohe, QAT" } Run Sample Code Prerequisites: Java 16+ Maven Steps: Create an OpenAI account. Log in and generate an API key. Replace OPENAI_API_KEY in Main.java with your key. Update SAMPLE_PDF_FILE if needed. Execute the code and view the results from the output.
Much of the existing hype in biotech has concentrated around the promise of revolutionising drug discovery. After all, the last decade was a so-called golden age in the field. From 2012 to 2021, compared to the prior decade, an increase of 73% new medicines were approved — 25% more than the one before that. These medicines include immunotherapies for cancer, gene therapies, and, of course, Covid vaccines. On the face of it, the pharmaceutical industry is doing well. But there are increasingly worrying trends. Drug discovery is becoming prohibitively expensive and risky. As of today, it costs between $1bn-$3bn on average and 12–18 years to bring a new drug to market. Meanwhile, the average price of a new medicine has skyrocketed from $2k in 2007 to $180k in 2021. That’s why many have pinned their hopes on Artificial Intelligence (AI) approaches (such as statistical machine learning) to help accelerate the development of new drugs, from early target identification through trials. While several compounds have already been identified using various machine learning algorithms, these are still in early discovery or preclinical stages of development. The promise of AI revolutionizing drug discovery is still a very exciting but unfulfilled promise. What Is AI? To fulfill that promise, it’s vital to understand what we really mean by AI. In recent years, the term has become quite the buzzword, devoid of much technical substance. So what actually constitutes Artificial Intelligence? AI, as an academic field, has already been around since the 1950s, and over time, branched into various types to represent different ways of learning. These types are eloquently described in Professor Pedro Domingos’s book The Master Algorithm (he calls them “tribes”): connectionists, symbolists, evolutionaries, bayesians, and analogisers. Over the past decade, bayesians and connectionists have received much of the public’s limelight, unlike the symbolists. Symbolists create true to life representations of the world based on sets of rules that make logical inferences. Symbolic AI systems do not have the enormous publicity that other types of AI enjoy, but they possess unique and important capabilities missing in others: automated reasoning and knowledge representation. Representing Biomedical Knowledge The issue of knowledge representation is, in fact, precisely one of the biggest problems in drug discovery. Existing database software, such as relational or graph databases, make it difficult to accurately represent and make sense of the immense intricacies and complexities of biology. Drug discovery’s representation problem is well illustrated by the need to create unified models of disparate biomedical data sources (e.g., Uniprot or Disgenet). At the database level, this means creating data models (some may refer to these as ontologies) that describe a myriad of complex entities and relationships, such as those between proteins, genes, drug, diseases, interactions, and many others. This is what TypeDB, an open-source database software, aims to achieve — to enable developers to create true to life representations of highly complex domains that computers can use to gain insights. TypeDB’s type system is based on entity-relationship concepts that represents the data stored in TypeDB. This makes it expressive enough to accurately capture complex biomedical domain knowledge (through type inference, nested relations, hyper-relations, rule inference, and much more), making it easier for scientists to obtain insights and accelerate development timelines. This was illustrated by a large pharmaceutical company that struggled for over five years to model a disease network using Semantic Web Standards, but managed to achieve this in just three weeks after migrating to TypeDB. For example, a biomedical model written in TypeQL (TypeDB’s querylanguage) that describes proteins, genes, and diseases looks as follows: define protein sub entity, owns uniprot-id, plays protein-disease-association:protein, plays encode:encoded-protein; gene sub entity, owns entrez-id, plays gene-disease-association:gene, plays encode:encoding-gene; disease sub entity, owns disease-name, plays gene-disease-association:disease, plays protein-disease-association:disease; encode sub relation, relates encoded-protein, relates encoding-gene; protein-disease-association sub relation, relates protein, relates disease; gene-disease-association sub relation, relates gene, relates disease; uniprot-id sub attribute, value string; entrez-id sub attribute, value string; disease-name sub attribute, value string; For a fully worked example, an open source biomedical knowledge graph can be found here on Github. This loads data from various well-known biomedical sources such as Uniprot, Disgenet, Reactome, and others. With your data stored in TypeDB, you could run queries that ask questions such as: Which drugs interact with genes associated to the virus SARS? To answer that question, we could use the following query in TypeQL: match $virus isa virus, has virus-name "SARS"; $gene isa gene; $drug isa drug; ($virus, $gene) isa gene-virus-association; ($gene, $drug) isa drug-gene-interaction; Running this will make TypeDB return the data that matches the conditions described in the query. This can be visualised in TypeDB Studio as follows, which will help to understand what relevant drugs may warrant further investigation. Through automated reasoning, TypeDB can also infer knowledge that doesn’t exist in the database. This is done by writing rules, which form part of the schema in TypeDB. For example, a rule could infer an association between a gene and a disease, if the encoded protein by that gene is associated with that disease. Such a rule would be written as follows: rule inference-example: when { (encoding-gene: $gene, encoded-protein: $protein) isa encode; (protein: $protein, disease: $disease) isa protein-disease-association; } then { (gene: $gene, disease: $disease) isa gene-disease-association; }; Then, if we were to insert the following data: insert $gene isa gene, has entrez-id "2"; $protein isa protein, has uniprot-id "P01023"; $disease isa disease, has disease-name "Parkinson Disease"; (encoding-gene: $gene, encoded-protein: $protein) isa encode; (protein: $protein, disease: $disease) isa protein-disease-association; TypeDB would be able to infer a connection between the gene and the disease, even if none has been inserted into the database. In this case, the following relation gene-disease-association would be inferred: match $gene isa gene, has gene-id "2"; $disease isa disease, has disease-name $dn; ; (gene: $gene, disease: $disease) isa gene-disease-assocation; Accelerating Target Discovery Through Machine Learning With these (symbolic) representations of biomedical data in TypeDB, the contextual knowledge that is fed into machine learning algorithms can make them extremely powerful to uncover insights that, for example, can enable a drug discovery pipeline to find promising targets. One approach for finding promising targets is to use link prediction algorithms. TypeDB’s rule engine allows such an ML model to learn based on facts inferred via reasoning. This means shifting from learning over flat, non-contextual data to learning over reasoned, contextual knowledge. One of the benefits is that predictions may be generalized beyond the scope of the training data according to the logical rules of the domain and reduce the quantity of training data required. Such a drug discovery workflow would work as follows: Query TypeDB to create a subgraph full of contextual knowledge that leverages the full expressivity of TypeDB. Transform the subgraph into an embedding and ingest these into a graph learning algorithm. The predictions (e.g., as probability scores between gene-disease associations) can then be inserted into TypeDB and used to validate/prioritize certain targets. With those predictions in the database, we can ask higher level questions that leverage these predictions with the wider contextual knowledge in the database. For example: What are the most likely gene targets for Melanoma that encode for proteins expressed in melanocytes? Written in TypeQL, this question would look as follows: match $gene isa gene, has gene-id $gene-id; $protein isa protein; $cell isa cell, has cell-type "melanocytes"; $disease isa disease, has disease-name "melanoma"; ($gene, $protein) isa encode; ($protein, $cell) isa expression; ($gene, $disease) isa gene-disease-association, has prob $p; get $gene-id; sort desc $p; The result of this query would be a list of genes sorted by a probability score (as predicted by the graph learner): {$gid "TOPGENE" isa gene-id;} {$gid "BESTGENE" isa gene-id;} {$gid "OTHERTARGET" isa gene-id;} ... We could then further investigate these genes, for example by understanding the biological context of each one. Let’s say we want to know the tissues in which the TOPGENE gene encodes proteins for. We could write the following query: match $gene isa gene, has gene-id $gene-id; $gene-id "TOPGENE"; $protein isa protein; $tissue isa tissue, has name $name; $rel1 ($gene, $protein); $rel2 ($protein, $tissue); The result, visualised in TypeDB Studio, could show this gene encoding for proteins that are expressed in the colon, heart, and liver: Conclusion The world urgently needs solutions to create treatments for devastating diseases and the hope is that, through innovations in AI, we can build a healthier world in which no disease goes untreated. The potential for AI to revolutionise drug discovery is still in its infancy, but fulfilling that promise will see biology unleash a new wave of innovation and make the 21st truly its century. In this article, we’ve looked at how TypeDB contributes to that journey by enabling the symbolic representation of biomedical knowledge and improving statistical ML with it. Scientists applying AI in drug discovery use TypeDB to analyse disease networks, get a better understanding of the ever growing complexities of biomedical research, and uncover new and ground breaking treatments. If you’re looking for an example of how to aggregate biomedical data in TypeDB in a way that is leverageable for drug discovery, have a look at this useful resource: TypeDB Bio.
I. Introduction The term “Conversational AI” invokes the use of artificial intelligence technologies to enable computer solutions to communicate with humans in a natural and interactive way. It can be applied in many different contexts, such as customer service Chatbots, virtual assistants, and communication systems. Its capability to understand and respond to human speech has the potential to transform the way we interact with machines, software, and applications. Whether through text, voice, or other forms of communication, including video or image, Conversational AI is changing the way we communicate with either the digital or the real world around us. Conversational AI is becoming increasingly prevalent in our daily lives. Whether on a personal or professional level, from customer service Chatbots on e-commerce websites to virtual assistants on our smartphones or in connected cars. Its potential applications are vast, ranging from automating routine tasks to improving the efficiency of customer service, to name a few. One unexpected but very relevant example of Conversational AI use case is its usage applied in the field of healthcare. Some health centers are using Chatbots to triage patients and provide them with personalized health advice, freeing up doctors to focus on more complex cases. As the technology continues to advance, it’s likely that we will see even greater adoption of Conversational AI in a variety of industries and contexts. II. Brief History of Conversational AI Early Developments and Milestones The development of Chatbots, or computer programs designed to simulate conversation with human users, dates back to the 1960s. Indeed, the first referenced Chatbot in technology history is ELIZA, which was developed in 1966 by Joseph Weizenbaum at Massachusetts Institute of Technology (MIT). ELIZA was designed to mimic the language patterns of a psychotherapist and could carry out simple conversations with human users. It was one of the first examples of a Chatbot and laid the foundation for the development of more advanced Conversational AI systems. These early Chatbots were relatively simple and could only handle a limited number of pre-programmed responses. Over time, Chatbots have become more advanced and are now able to respond to a wider range of inputs. With the advent of machine learning (ML), natural language processing (NLP), and natural language understanding (NLU) techniques, Chatbots have evolved into more advanced Conversational AI systems. These systems are able to understand and respond to human speech in a more natural and intuitive way and can even engage in more interactive conversations. Most importantly, they now become capable of learning and adapting over time. Thanks to this, they become more and more efficient. They tend to be more and more accepted and, from there, more and more requested. To illustrate this, a Chatbot launched by OpenAI (the now very famous ChatGPT3) in November of 2022 has crossed 1 million users in just five days. It took Netflix 41 months, Facebook 10 months, and Instagram 2.5 months… Today, Conversational AI systems are used in a large number of different contexts, far from the enhanced FAQ function to which they were limited in their early days. They are contributing to revolutionizing the way we interact and exchange information with the digital world and perform value-added actions. These systems make it easier and more convenient for people to access information and get things done. The purpose of innovation is to improve upon existing products, processes, or services or to create new ones that meet the needs of customers or society in a better way. It includes increasing efficiency, reducing costs, improving quality, or developing new capabilities. Conversational AI is no exception to this trend. To trace the path taken by this technology, here are some key milestones in the history of Conversational AI development. They demonstrate the impressive progress that has been made by these systems and their increasing capabilities: 1960: ELIZA, the first referenced Chatbot, is developed by Joseph Weizenbaum at MIT. 1972: PARRY, a natural language program that simulates the thinking of a paranoid individual. It, therefore, always misinterprets the motivations of others. Parry was the first to pass the Turing Test. 1997: A.L.IC.E. (Artificial Linguistic Internet Computer Entity), a natural language processing Chatbot, is developed by Richard S. Wallace. It won the Loebner Prize as “the most human computer” at the annual Turing Test contests in 2000. 2005: Apple's virtual assistant, Siri, is released, co-founded by a french scientist: Luc Julia, Ph.D. 2010: IBM's Watson (powered by 90 servers and 21.6TB of data) competes on the game show Jeopardy! and defeats human champions. 2014: Cortana was first demonstrated at Microsoft's Build developer conference. Directly integrated into both Windows Phone devices and Windows 10 PCs. 2014: Facebook launches M to face Siri and Cortana. M is a virtual assistant that uses machine learning to assist with tasks. 2016: Google releases Google Assistant, "Hey Google”!, a virtual assistant for Android devices. 2017: Amazon's Echo devices with Alexa virtual assistant become widely popular. 2018: OpenAI releases GPT-2, a large-scale language model with the ability to generate human-like text. 2022: OpenAI releases GPT-3. It can be used for language tasks, such as translation, summarization, question answering, and text generation. It can even perform tasks such as coding and translation without explicit training on those tasks. “A long time ago in a galaxy far, far away…”: C-3PO, a humanoid droid programmed primarily for etiquette and protocol, designed to interact with organics along “six million forms of communication.” Also known all over the explored universe helping Luke Skywalker and their rebellion defeat the Empire and restore freedom to the galaxy. But that's an entirely different story. The Current State of Usage by Industry The improved capabilities of large-scale language models such as Google's BERT, OpenAI's GPT-3, and Microsoft's Transformer have the power to fundamentally transform the field of Conversational AI and enable the development of more advanced virtual assistants, Chatbots, and other communication devices and systems. Very interesting use cases exist in many different fields. Among those, let us note, for example: Virtual assistants: such as Apple's Siri, Google Assistant, and Amazon's Alexa, are becoming increasingly common and are able to perform a wide range of tasks through voice or text-based interactions. These systems use NLP, NLU, and machine learning techniques to understand and respond to user requests. They get to learn and change, improving their ability to communicate. Customer service Chatbots: Chatbots are being widely used in the customer service industry to handle routine inquiries and provide information to customers. These systems are able to handle a high volume of interactions 24/7 and can often resolve simple issues faster than a human customer service representative based on a rule-based decision-making process. Language translation: There are a number of language translation systems (Google Translate or DeepL, to name a few) that use Conversational AI to enable the real-time translation of spoken or written communication. These systems can be used in a variety of contexts, such as international business meetings or in everyday life, facilitating communication between people who speak different languages. Education: There are also a number of educational platforms that use Conversational AI to provide students with personalized learning experiences. These systems are able to adapt to the needs and abilities of individual students and provide tailored instruction and feedback. Carnegie Learning, for example, uses AI and Machine Learning to help students develop a deeper conceptual understanding of math and world languages. Algorithms study students' habits to personalize their learning experience. Healthcare: In the healthcare industry, Conversational AI is being used to triage patients and establish an initial diagnosis. Chatbots can provide symptom checking and recommend a course of action, such as seeking further medical attention or self-care at home. These systems can also be used to schedule appointments and refill prescriptions. In England, the National Health Service announced in 2017 an agreement with Babylon Health (a health app company) to use a Chatbot driven by algorithms based on clinical data that triage patients in two minutes, without human intervention, based on reported symptoms. Banking: In the banking industry, Chatbots are being used to handle routine inquiries and assist with tasks such as account management and bill payment. Some banks are also using Conversational AI to provide personalized financial advice and recommendations to customers. Insurance: In the insurance industry, Conversational AI is being used to assist with simple tasks, including claims processing and policy management. As banks can do, insurance companies are also using Chatbots to provide personalized recommendations and advice to customers. Retail: In the retail industry, Chatbots can be very useful when it comes to providing customers with product recommendations, order tracking, and many simple customer service requests. They can be also helpful to provide personalized shopping experiences and tailor marketing efforts to individual customers. Human Resources: An AI-Driven Chabot can be very helpful in performing recruitment tasks such as answering FAQs, screening candidates against offers and resumes, scheduling interviews, providing updates, and collecting and organizing resumes. This reduces the workload of recruiters and allows them to spend more time on tasks that require people skills such as empathy. Results from the first 10,000 conversations have shown that Mya engages effectively with 92% of their candidates. III. Types of Conversational AI The conversational AI landscape is made up of different main components that are distinguished by specific characteristics. Chatbots are simple computer programs designed to simulate conversation with human users, more likely in a question-and-response mode. In some ways, they can be likened to somewhat elaborate FAQ systems. They can be integrated into messaging platforms, mobile apps, and website portals to provide customers with basic services or information. For example, a Chatbot on a retail website can help customers navigate the site, make product recommendations, and answer questions about shipping and returns. Virtual assistants are Conversational AI systems designed to assist with a wide range of more elaborate tasks, such as checking balance information, determining whether an item is in stock, assessing the status of an order, tracking shipments, scheduling appointments, setting reminders, processing calculations, interacting with applications or providing various information. They can be accessed through a variety of devices, including smartphones, smart speakers, and personal computers. For example, Apple's Siri and Amazon's Alexa are both examples of virtual assistants. Their communications abilities are integrated with automation functions. Voice assistants are Conversational AI systems that are activated by voice commands. They can be used to control other devices, play music, and provide information. They can be also called “Voice-controlled assistants,” “Speech-enabled assistants,” “Spoken Language Interfaces,” “Speech recognition software,” or simply “Smart speakers." They are becoming increasingly popular with the advent of smart speaker devices like Amazon Echo, Google Home, or Apple HomePod. The voice-controlled AI assistant technology can be integrated with other smart devices, such as home appliances and cars, allowing for voice control of those devices. There are other forms of Conversational AI included in the range of language-generating AI systems. They are able to produce human-like text or speech and can be used for a wide range of applications, such as language translation, automated writing, and text summarization. The list is continuously growing. IV. Benefits of Conversational AI In 2016, Gartner predicted: “2020, the average person will have more conversations with bots than with their spouse”. Knowing that this tragic prediction did not come true, at least in 2023, let’s see now how Conversational AI can improve customer service, increase efficiency and productivity and enhance the user experience for businesses and generate cost savings. Conversational AI Provides a Superior Service to Chatbots in Many Ways Solutions, such as virtual assistants, have a knowledge base, whereas Chatbots generally rely on FAQ files. Chatbots, therefore, draw from a limited library of scripts and combinations of questions and answers. This approach is therefore limited to producing predetermined answers. The so-called "intelligent" or “smart” virtual assistants, on the other hand, are pre-trained and have a wide range of knowledge, which provides a much richer conversational base. They can tend to solve problems rather than just answer simple questions. Intelligent digital assistants in the insurance field are becoming digital advisors by accompanying a customer and recommending the next most relevant step in their journey to file a claim or follow up on an incident, for example. Finally, by using conversational skills, data, and pattern analysis through machine learning algorithms, intelligent digital assistants are able to qualify customer demands and can seamlessly direct them to the services that are right for them. One of the Main Benefits of Conversational AI Is Improved Customer Service Chatbots, virtual assistants, and voice assistants can be used to answer customer questions, provide information, and help with troubleshooting 24/7. It can also qualify a request and redirect it to a human operator when it’s necessary. This improves overall customer satisfaction and perhaps even loyalty in some cases, as customers are able to get the help they need quickly and efficiently. For example, according to JuniperResearch, Chatbots within retail, eCommerce, banking, and healthcare were predicted to be responsible for cost savings of over $8 billion per annum by 2022. Conversational AI can also lead to increased efficiency and productivity in the workplace. For example, virtual assistants can help schedule meetings, set reminders, and perform other tasks that would otherwise take up valuable time and energy. This can lead to increased productivity and a reduction in workload for employees. Conversational AI is also a means to produce a more personalized and engaging user experience. For example, Chatbots and virtual assistants can be trained to understand the context and preferences of a user and make personalized recommendations or provide customized information. This can lead to increased user engagement and satisfaction. By the way, employee satisfaction, as a counterpart of customer satisfaction, is also a target that can be reached through Conversational AI and related smart automation processes. Knowing the fact that worldwide companies spend over $1 trillion on customer service calls each year; it’s easy to understand that Conversational AI does represent a real opportunity to lower costs. For example, Chatbots and virtual assistants can be used to automate repetitive and time-consuming tasks, reducing the need for human labor. This can result in lower costs and increased efficiency of customer service. In addition, Conversational AI can help businesses to identify and target high-value customers, leading to increased revenue. V. Challenges and Limitations of Conversational AI NLP and NLU Limitations Natural Language Processing and Understanding are subfields of artificial intelligence that deal with the interaction between computers and humans in natural language. These systems used to analyze and understand text and speech data generated by humans can be challenged by the complexity and variability of human language. That definitely makes it difficult to understand the meaning and intent of language data in many situations. Did you know, for example, that over 7,000 languages are spoken across the world today? Chinese, the most important as regards the number of speakers, has just by itself 13 variations. Arabic has 20 of them. To be put into perspective, it is estimated that 80% of online content is available in only one of 10 of the following languages: English, Chinese, Spanish, Japanese, Arabic, Portuguese, German, French, Russian, and Korean. This explains clearly the fact that an important limitation of natural language systems is dealing with idiomatic expressions, as natural language is full of idioms, slang, and other non-literal forms of expression. These idioms and colloquialisms often have multiple meanings and depend on the context to understand them. Not to mention that the finesse of the language is also due to the intonation and the intention of the speakers and even their gestures or facial expression. All this, technically, can be acquired through video and analyzed by appropriate AI algorithms. Besides the disparity of the spoken languages, one of the main limitations of NLP is dealing with ambiguity. Indeed, natural language often contains multiple possible interpretations, and it can be difficult for an AI system to determine the correct one. For example, if a customer writes, "I need help with my order," a Chatbot might ask, "What is wrong with your order?" but it might not be able to understand if the customer is asking for help tracking their order or if they have an issue with the products they received or if they want to cancel it. Of course, NLP systems have difficulties dealing with sarcasm, irony, and the use of negative forms. These forms of figurative language are often used to convey meaning indirectly, which is not immediately apparent from the words used. Concordant studies find that even the most advanced NLP systems still struggle with understanding idioms and figurative language or different feelings suggested with the same words. It might still be a long way before computers can truly understand and interpret human language with the same level of fluency as a human being. Personalization and Customization Difficulties Personalization and customization are key aspects of Conversational AI, as they allow Chatbots, virtual assistants, and other Conversational AI systems to understand and respond to the unique needs and preferences of individual users. However, achieving true personalization and customization can be difficult, as it requires an AI system to have a deep understanding, not to say “deep feelings,” of the user and to be able to adapt its behavior and responses accordingly. Processing large amounts of data for personalization and adaptation is a major challenge. The fact is, it's necessary to understand the needs and expectations of users by training and refining AI systems. Another key obstacle to the development of more powerful NLP is data accessibility. When it comes to dealing with constraints on sharing documents that contain personal information, the landscape turns into an ethical minefield. To illustrate the idea with a sensitive subject happens with the electronic health records (EHRs) in the clinical domain. Data, including user preferences, interactions history, demographics, bank, administrative, or health information, must be handled with care. In any case, providing a truly personalized experience requires handling users' data and privacy with care. Indeed, users might not be comfortable providing personal information to AI systems and might not be willing to interact with AI systems that seem to know too much about them. See, for example, how reluctant we can be, even if only to give our email address or phone number or when it comes to turning on the camera. Another challenge is dealing with the inherent complexity of human behavior. Individuals can change their behavior, preferences, and even their personalities over time; this makes it difficult for an AI system to keep up with the user and provide a truly personalized experience. But to be honest, human agents face the same difficulties. In this regard, sentiment analysis can be a great help. Sentiment analysis is a subfield of natural language processing (NLP) that involves using AI algorithms and methodology to identify and extract subjective information from spoken text, written text or body movements, or facial expressions. This information can include the overall sentiment of a document or a speech, as well as more specific emotions and opinions expressed by the person. Techniques used in sentiment analysis are based, among other things, on lexical analysis, syntactic parsing, and ML algorithms such as support vector machines and neural networks. Sentiment analysis can be used to enhance conversational systems' capabilities by allowing them to detect and respond to the sentiment expressed by the user in their input. For example, if a bot is able to detect that a user is expressing frustration, impatience, or dissatisfaction, it can respond in a way that addresses the user's emotions and tries to resolve the issue. Sentiment analysis might be useful to monitor user feedback and to get an understanding of the user's overall experience, which can be used for further improvement of the conversational system. Recent studies show that for industries with large customer bases, customer care and personalization of products and services are among the most important AI use cases. Do you know that the most common practice in call centers is to answer 80% of calls within 20 seconds? This puts teams under stress to maintain a good level of customer satisfaction. This stress problem could be answered by simple requests addressed by bots releasing pressure on the waiting queue side. These industries include travel, hospitality, consumer goods, retail, and telecommunications. While the technology behind AI-powered personalization is improving, it's still difficult to get it designed the optimum way, and the majority of companies are still far from providing a truly personalized experience. Potential for Bias Bias are phenomenons that appear when algorithms deliver systematically biased outcomes because of wrong assumptions of the machine learning process. Unfortunately, AI takes on the tendencies of human prejudices, whether they are conscious or unconscious. This results in behaviors that can be racist, homophobic, misogynistic, or any other type of discrimination. This is how the bias in AI systems can make predictions or decisions that are discriminatory or unfair to certain groups of people. This can be particularly problematic in the context of Conversational AI, as these systems are often used to make decisions or provide information that can have a direct impact on people's decisions in real-time. Data and Algorithms: The Two Main Sources of Bias Data Maybe the most important origin of bias in Conversational AI is the data that is used to train the system. When the data is not representative of the population that the system will be serving, it can lead to the system making predictions or decisions that are unfair or discriminatory to certain groups of people. Additionally, Conversational AI systems trained on historical data may perpetuate biases that were present in the past but should be corrected. Here's a well-known example. In 2018, Amazon's recruitment engine, created to analyze applicants' resumes, was found to be, unfortunately, biased against women in the recruitment process. This occurred because the recruitment algorithm was trained on resumes submitted over the past ten years, most of which belonged to men. When the algorithm was reviewed, it was found that it automatically discriminated against women. Algorithm The second source of bias in Conversational AI is the way the system is designed and implemented. For example, if a Chatbot is designed to provide customer service, it should be able to understand and respond to the needs of all customers, regardless of their background or characteristics. However, if the Chatbot is not designed to handle different languages, accents, or dialects, it can make it difficult for certain groups of people to communicate with the Chatbot and make it less effective for them. The design of the algorithms themselves can reproduce the biases of human behavior. A 2019 UC Berkeley study found that "FinTech lenders" reject face-to-face applications from Latinos and African Americans about 6% more often than they reject applications from non-minorities under the same conditions. One study shows that between 2009 and 2015, lenders rejected about 1 million of their applications that would have been accepted in the absence of discrimination. Unfortunately, it appeared that the algorithms were designed in such a way that they replicate this discrimination. Studies found that language models are prone to the same forms of bias, including gender, race, and age bias, that can affect the performance of these systems and the outcomes they generate. These biases should be addressed with simple means, including better data curation, algorithmic transparency, and stronger regulations. And if it is necessary to remind it, algorithms are devoid of human character, such as common sense and especially empathy. Ethical Considerations Directly related to the issue of bias, ethical considerations are crucial when dealing with Conversational AI. These systems are becoming the new user interface between a customer and a brand or a company, the same way employees are. They are therefore expected to behave in a dignified and appropriate manner. As Conversational AI systems become more sophisticated and integrated into society, it's important to ensure that they are developed and used in ways that are fair, transparent, and accountable. As a matter of fact, in 2021 in Washington, DC, members of Congress required businesses to assess automated decision-making systems used in areas such as health care, housing, employment, or education. The law requires employers to use external consultants to run independent assessments. This law makes sure their algorithms are not at risk for behaviors that engage bias based on sex, race, or ethnicity. Systems should not discriminate against certain groups of people based on their race, gender, age, or other characteristics. In the same spirit, it's crucial to ensure they are transparent so that people understand how the system is making decisions and can provide feedback or raise concerns. Making AI as transparent as possible requires the ability to explain how and why AI-based decisions are made. The AI-based decision-making process must be aligned with and represent the values and ethics of the company. The other equally important consideration is data privacy and security. Conversational AI systems rely on the collection and analysis of large amounts of personal data. It's crucial that the data is handled and stored in a way that protects the privacy and security of individuals. There has been general consensus on the principle of ethics between all stakeholders for years now. Conversational AI must be safe, fair, and beneficial to all. It must be transparent and accountable and must respect the privacy and security of individuals. Ethical considerations have to be integrated throughout the entire development and deployment process of AI, including digital assistants. VI. Future of Conversational AI Predicted Advancements and Developments There have been many advances in Conversational AI in recent years, and many experts believe that this technology will continue to evolve and become even more sophisticated in the future. Indeed, according to David Schubmehl, research director at IDC, "The Conversational AI tools and technologies market grew significantly during 2020 …/… IDC forecasts the overall market to approach $7.9 billion in revenue in 2025”. One of the most significant advances has been the improvement of natural language processing (NLP) and understanding (NLU) capabilities. Recent advancements are leading to systems that are more accurate and can understand a wider range of languages. Another important advance has been the development of deep learning techniques, such as neural networks. These techniques have made it possible to train AI systems on large amounts of data and to improve their performance over time. The last big step in this area was performed by OpenAI with ChatGPT, a large language model (LLM) trained with massive amounts of data to predict the most accurately possible what word comes next in a sentence. According to Stanford University, “GPT-3 has 175 billion parameters and was trained on 570 gigabytes of text [making it] able to perform tasks it was not explicitly trained on like translating sentences from English to French, with few to no training examples”. Other big players in Conversational AI are companies such as Google, Amazon, Facebook, Microsoft, and Apple. They are all investing heavily in Conversational AI and are developing a wide range of products and services, including virtual assistants, Chatbots, and smart speakers. On the other hand, there are also niche players, such as OpenAI, focused on developing a safer AI beneficial for humanity. These actors are working on developing cutting-edge Conversational AI technology. Microsoft fully understood OpenAI’s value and the potential of its solution. On 2023 Jan 10th, they reportedly plan to invest $10 billion in OpenAI as part of a funding round. This would bring the value of OpenAI to $29 billion. Future advancements in conversational AI include increased use of AI-powered personalization and customization for more tailored user experiences. On another angle, solutions need to improve the ability to generate natural language for a more human-like interaction. This would lead to more efficient and accurate responses. Thirdly, the use of AI-powered sentiment analysis is expected to improve the ability of systems to understand emotions and respond accordingly. Finally, it’s also expected that Conversational AI systems will become more integrated into the Internet of Things (IoT). They will soon be able to control and manage a wide range of devices at home and in other environments, including the business and industrial ecosystems. Potential Impact on Industries and Society The advent of Conversational AI and the generalization of smart communication systems are expected to have a significant impact on society over the next few years. Here are some examples of potential impacts: As Conversational AI systems become more sophisticated, they are expected to improve customer service by providing faster and more accurate responses to customer queries, 24/7. Conversational AI systems are expected to become more personalized and engaging, providing tailored experiences for users. Conversational AI systems will improve productivity and efficiency by automating repetitive tasks and reducing human labor needs. The desired goal is to allow employees to focus on more complex tasks that require human skills, such as creativity, empathy, critical thinking, or moral awareness. They are also expected to provide more efficient and accurate responses to simple queries. These improvements would reduce the time and effort required to find and access information. If you pay attention to pessimistic science fiction-like predictions, you fear that AI will start to take over many jobs once done by humans. Some of these predictions go to the extent that the growth of AI technologies will lead to widespread unemployment and social unrest. Not to mention robots taking over the world. A closer look at the fear of progress and anxiety over change reveals that every innovation generates fears. The 2nd Industrial Revolution introducing new forms of energy, such as electricity, also carried the fear that turned out to be unfounded. The increased use of machinery would lead to a decrease in the availability of jobs for skilled craftsmen and artisans. The reality is while some jobs did become obsolete as a result of the increased use of machinery, many others were created, such as factory jobs such as transportation and manufacturing. The same applies to all the disrupting technology leaps. We can predict that AI technology systems will become more and more sophisticated and even human-like. This will enable businesses to provide more personalized and engaging experiences for users. Finally, it will help to automate more complex tasks and save time for human workers. VII. Conclusion With advancements in natural language processing and machine learning, it’s becoming increasingly possible for machines to respond to human language in a way that feels natural. This is leading to a wide range of new applications and more advanced forms of human-computer interaction. However, despite these potential benefits, there are also a number of challenges that must be overcome to achieve the full potential of Conversational AI. One of the biggest challenges is developing systems that can understand and respond to human language in a way that is always contextually appropriate. This requires not only a deep understanding of the meaning of words but also the ability to interpret the context, the intents, and the sentiments in which those words are used in more subtle ways. Another limitation of Conversational AI is the ability to understand and respond to open-ended questions or ambiguous queries. Sometimes the language and vocabulary used by humans are hard to understand by the system and lead to wrong answers. More complicated, there is also a need for Conversational AI systems to be able to make decisions based on incomplete information. This requires the ability to handle uncertainty in a way that is appropriate to the very context, which appears to be more of a human skill than a mechanical skill. At least so far.
Tuhin Chattopadhyay
Founder and CEO,
Tuhin AI Advisory
Thomas Jardinet
IT Architect,
Rhapsodies Conseil
Sibanjan Das
Zone Leader,
DZone
Tim Spann
Principal Developer Advocate,
Cloudera