Natural Language Generation
The Basic Idea
You may know by now that artificial intelligence (AI) can produce incredibly human-like text and speech. The fascinating technology behind this generative ability is natural language generation (NLG), a software process driven by AI that outputs natural written language or speech from data.1,2
NLG translates complex computer data into a language we can understand. It involves generating coherent, contextually appropriate, and often creative text. Essentially, this allows computers to communicate with us using words rather than numbers and symbols. AI systems that generate text, such as ChatGPT, rely on NLG technology to respond to input in a way that seems human.
But NLG isn’t limited to advanced conversational tools like chatbots. Weather reports are an excellent example of simpler NLG in action. These NLG systems take meteorological data, such as temperature readings and satellite imagery, and translate it into reports. This allows weather apps to generate clear and concise weather forecasts that anyone can understand. NLG is also used in financial reporting, medical reporting, customer service chatbots, sports summaries, accessibility tools, content creation, and many more valuable applications.
The speed and accuracy with which computers can translate data to text is what makes these tools so valuable. AI systems can now produce time-sensitive information much faster than humans, which is very beneficial for industries like journalism and healthcare that rely on rapid data analysis. However, NLG also tends to generate inaccurate information and perpetuate biases present in their training data, so these systems still require human oversight (more on this later).
So, how does NLG work? Watching AI programs like ChatGPT generate human-like text seems almost magical. However, NLG actually relies on several technologies working together to execute a series of steps.2 Let’s go over these steps briefly:
- Data Analysis: The system filters data from prompts and databases to identify key topics and create a final product that will be relevant to the user.
- Data Understanding: Using machine learning the NLG system identifies patterns in the data and adds context to the information based on its training.
- Document Planning: The system decides how exactly to structure and present the output. This step generates an outline for the text.
- Sentence Assembly and Creation: Sentences are constructed to summarize the topic.
- Grammatical Structuring: The program applies grammatical rules to ensure the output (text) sounds natural to us humans.
- Output: Finally, the text is generated and the output is delivered in the desired format (written text or speech).
This process produces text that is amazingly similar to natural language. However, NLG still faces several challenges, often struggling with the nuances of human creativity like humor, sarcasm, or producing truly original ideas. As NLG systems continue to learn from us, we can expect them to get better at capturing the intricacies of our language.
About the Author
Kira Warje
Kira holds a degree in Psychology with an extended minor in Anthropology. Fascinated by all things human, she has written extensively on cognition and mental health, often leveraging insights about the human mind to craft actionable marketing content for brands. She loves talking about human quirks and motivations, driven by the belief that behavioural science can help us all lead healthier, happier, and more sustainable lives. Occasionally, Kira dabbles in web development and enjoys learning about the synergy between psychology and UX design.