Natural-language generation

Natural-language generation (NLG) is a software process that produces natural language output. While it is widely agreed that the output of any NLG process is text, there is some disagreement on whether the inputs of an NLG system need to be non-linguistic.[1] Common applications of NLG methods include the production of various reports, for example weather [2] and patient reports;[3] image captions;[4] and chatbots. Automated NLG can be compared to the process humans use when they turn ideas into writing or speech. Psycholinguists prefer the term language production for this process, which can also be described in mathematical terms, or modeled in a computer for psychological research. NLG systems can also be compared to translators of artificial computer languages, such as decompilers or transpilers, which also produce human-readable code generated from an intermediate representation. Human languages tend to be considerably more complex and allow for much more ambiguity and variety of expression than programming languages, which makes NLG more challenging.

NLG may be viewed as complementary to natural-language understanding (NLU): whereas in natural-language understanding, the system needs to disambiguate the input sentence to produce the machine representation language, in NLG the system needs to make decisions about how to put a representation into words. The practical considerations in building NLU vs. NLG systems are not symmetrical. NLU needs to deal with ambiguous or erroneous user input, whereas the ideas the system wants to express through NLG are generally known precisely. NLG needs to choose a specific, self-consistent textual representation from many potential representations, whereas NLU generally tries to produce a single, normalized representation of the idea expressed.[5]

NLG has existed since ELIZA was developed in the mid 1960s, but the methods were first used commercially in the 1990s.[6] NLG techniques range from simple template-based systems like a mail merge that generates form letters, to systems that have a complex understanding of human grammar. NLG can also be accomplished by training a statistical model using machine learning, typically on a large corpus of human-written texts.[7]

## Contents

* 1 Example
* 2 Stages
* 3 Applications
* 4 Evaluation
* 5 See also
* 6 References
* 7 Further reading
* 8 External links

## Example

The Pollen Forecast for Scotland system[8] is a simple example of a simple NLG system that could essentially be a template. This system takes as input six numbers, which give predicted pollen levels in different parts of Scotland. From these numbers, the system generates a short textual summary of pollen levels as its output.

For example, using the historical data for July 1, 2005, the software produces:

> Grass pollen levels for Friday have increased from the moderate to high levels of yesterday with values of around 6 to 7 across most parts of the country. However, in Northern areas, pollen levels will be moderate with values of 4.

In contrast, the actual forecast (written by a human meteorologist) from this data was:

> Pollen counts are expected to remain high at level 6 over most of Scotland, and even level 7 in the south east. The only relief is in the Northern Isles and far northeast of mainland Scotland with medium levels of pollen count.

Comparing these two illustrates some of the choices that NLG systems must make; these are further discussed below.

## Stages

The process to generate text can be as simple as keeping a list of canned text that is copied and pasted, possibly linked with some glue text. The results may be satisfactory in simple domains such as horoscope machines or generators of personalised business letters. However, a sophisticated NLG system needs to include stages of planning and merging of information to enable the generation of text that looks natural and does not become repetitive. The typical stages of natural-language generation, as proposed by Dale and Reiter,[5] are:

Content determination: Deciding what information to mention in the text. For instance, in the pollen example above, deciding whether to explicitly mention that pollen level is 7 in the south east.

Document structuring: Overall organisation of the information to convey. For example, deciding to describe the areas with high pollen levels first, instead of the areas with low pollen levels.

Aggregation: Merging of similar sentences to improve readability and naturalness. For instance, merging the two following sentences:

* Grass pollen levels for Friday have increased from the moderate to high levels of yesterday and
* Grass pollen levels will be around 6 to 7 across most parts of the country

into the following single sentence:

* Grass pollen levels for Friday have increased from the moderate to high levels of yesterday with values of around 6 to 7 across most parts of the country.

Lexical choice: Putting words to the concepts. For example, deciding whether medium or moderate should be used when describing a pollen level of 4.

Referring expression generation: Creating referring expressions that identify objects and regions. For example, deciding to use in the Northern Isles and far northeast of mainland Scotland to refer to a certain region in Scotland. This task also includes making decisions about pronouns and other types of anaphora.

Realization: Creating the actual text, which should be correct according to the rules of syntax, morphology, and orthography. For example, using will be for the future tense of to be.

An alternative approach to NLG is to use "end-to-end" machine learning to build a system, without having separate stages as above.[9] In other words, we build an NLG system by training a machine learning algorithm (often an LSTM) on a large data set of input data and corresponding (human-written) output texts. The end-to-end approach has perhaps been most successful in image captioning,[10] that is automatically generating a textual caption for an image.

## Applications

The popular media has paid the most attention to NLG systems which generate jokes (see computational humor), but from a commercial perspective, the most successful NLG applications have been data-to-text systems which generate textual summaries of databases and data sets; these systems usually perform data analysis as well as text generation. Research has shown that textual summaries can be more effective than graphs and other visuals for decision support,[11][12][13] and that computer-generated texts can be superior (from the reader's perspective) to human-written texts.[14]

The first commercial data-to-text systems produced weather forecasts from weather data. The earliest such system to be deployed was FoG,[2] which was used by Environment Canada to generate weather forecasts in French and English in the early 1990s. The success of FoG triggered other work, both research and commercial. Recent applications include the UK Met Office's text-enhanced forecast.[15]

Currently there is considerable commercial interest in using NLG to summarise financial and business data. Indeed, Gartner has said that NLG will become a standard feature of 90% of modern BI and analytics platforms.[16] NLG is also being used commercially in automated journalism, chatbots, generating product descriptions for e-commerce sites, summarising medical records,[17][3] and enhancing accessibility (for example by describing graphs and data sets to blind people[18]).

An example of an interactive use of NLG is the WYSIWYM framework. It stands for What you see is what you meant and allows users to see and manipulate the continuously rendered view (NLG output) of an underlying formal language document (NLG input), thereby editing the formal language without learning it.

## Evaluation

As in other scientific fields, NLG researchers need to test how well their systems, modules, and algorithms work. This is called evaluation. There are three basic techniques for evaluating NLG systems:

* Task-based (extrinsic) evaluation: give the generated text to a person, and assess how well it helps him perform a task (or otherwise achieves its communicative goal). For example, a system which generates summaries of medical data can be evaluated by giving these summaries to doctors, and assessing whether the summaries helps doctors make better decisions.[3]
* Human ratings: give the generated text to a person, and ask him or her to rate the quality and usefulness of the text.
* Metrics: compare generated texts to texts written by people from the same input data, using an automatic metric such as BLEU, METEOR and ROUGE.

An ultimate goal is how useful NLG systems are at helping people, which is the first of the above techniques. However, task-based evaluations are time-consuming and expensive, and can be difficult to carry out (especially if they require subjects with specialised expertise, such as doctors). Hence (as in other areas of NLP) task-based evaluations are the exception, not the norm.

Recently researchers are assessing how well human-ratings and metrics correlate with (predict) task-based evaluations. Work is being conducted in the context of Generation Challenges[19] shared-task events. Initial results suggest that human ratings are much better than metrics in this regard. In other words, human ratings usually do predict task-effectiveness at least to some degree (although there are exceptions), while ratings produced by metrics often do not predict task-effectiveness well. These results are preliminary. In any case, human ratings are the most popular evaluation technique in NLG; this is contrast to machine translation, where metrics are widely used.

## See also

* Autocompletion
* Automated journalism
* Automated paraphrasing
* Markov text generators
* Meaning-text theory
* Generative art § Literature

## References

1. ↑ "Survey of the state of the art in natural language generation: Core tasks, applications and evaluation.". Journal of Artificial Intelligence Research 61 (61): 65–170. 2018. doi:10.1613/jair.5477.
2. ↑ 2.0 2.1 "Using Natural-Language Processing to Produce Weather Forecasts". IEEE Expert 9 (2): 45–53. 1994. doi:10.1109/64.294135.
3. ↑ 3.0 3.1 3.2 "Automatic Generation of Textual Summaries from Neonatal Intensive Care Data". Artificial Intelligence 173 (7–8): 789–816. 2009. doi:10.1016/j.artint.2008.12.002. https://hal.archives-ouvertes.fr/hal-00953707/file/aij-bt45.pdf.
4. ↑ "Every picture tells a story: Generating sentences from images". European conference on computer vision. Berlin, Heidelberg: Springer. 2010-09-05. pp. 15–29.
5. ↑ 5.0 5.1 Dale, Robert; Reiter, Ehud (2000). Building natural language generation systems. Cambridge, U.K.: Cambridge University Press. ISBN 978-0-521-02451-8.
6. ↑ Ehud Reiter (2021-03-21). History of NLG.
7. ↑ "Recent Advances in Natural Language Generation: A Survey and Classification of the Empirical Literature". Computing and Informatics 36 (1): 1–32. 2017. doi:10.4149/cai_2017_1_1.
8. ↑ R Turner, S Sripada, E Reiter, I Davy (2006). Generating Spatio-Temporal Descriptions in Pollen Forecasts. Proceedings of EACL06
9. ↑ "E2E NLG Challenge". http://www.macs.hw.ac.uk/InteractionLab/E2E/.
10. ↑ "DataLabCup: Image Caption". https://www.kaggle.com/c/datalabcup-image-caption.
11. ↑ "A Comparison of Graphical and Textual Presentations of Time Series Data to Support Medical Decision Making in the Neonatal Intensive Care Unit". Journal of Clinical Monitoring and Computing 19 (3): 183–94. 2005. doi:10.1007/s10877-005-0879-3. PMID 16244840.
12. ↑ "Data-to-Text Generation Improves Decision-Making Under Uncertainty". IEEE Computational Intelligence Magazine 12 (3): 10–17. 2017. doi:10.1109/MCI.2017.2708998. https://napier-surface.worktribe.com/687579/1/gui-journal-paper-27Apr.pdf.
13. ↑ "Text or Graphics?". 2016-12-26. https://ehudreiter.com/2016/12/26/text-or-graphics/.
14. ↑ "Choosing Words in Computer-Generated Weather Forecasts". Artificial Intelligence 167 (1–2): 137–69. 2005. doi:10.1016/j.artint.2005.06.006.
15. ↑ S Sripada, N Burnett, R Turner, J Mastin, D Evans(2014). Generating A Case Study: NLG meeting Weather Industry Demand for Quality and Quantity of Textual Weather Forecasts. Proceedings of INLG 2014
16. ↑ "Neural Networks and Modern BI Platforms Will Evolve Data and Analytics". https://www.gartner.com/smarterwithgartner/nueral-networks-and-modern-bi-platforms-will-evolve-data-and-analytics/.
17. ↑ Harris MD (2008). "Building a Large-Scale Commercial NLG System for an EMR". pp. 157–60. http://www.aclweb.org/anthology/W08-1120.pdf.
18. ↑ http://www.inf.udec.cl/~leo/iGraph.html
19. ↑ Generation Challenges 2009

## Further reading

* Dale, Robert; Reiter, Ehud (2000). Building natural language generation systems. Cambridge, UK: Cambridge University Press. ISBN 978-0-521-02451-8.
* Evans, Roger; Piwek, Paul; Cahill, Lynne (2002). "What is NLG?". INLG2002. New York, US. paper
* Gatt, Albert; Krahmer, Emiel (2018). "Survey of the State of the Art in Natural Language Generation: Core tasks, applications and evaluation". Journal of Artificial Intelligence Research 61: 65–170. doi:10.1613/jair.5477. https://www.jair.org/index.php/jair/article/view/11173.
* Reiter, Ehud (2018-01-16). "How do I Learn about NLG?". https://ehudreiter.com/2018/01/16/learn-about-nlg/.

## External links

* ACL Special Interest Group on Generation (SIGGEN)
* SIGGEN part of ACL Anthology (contains NLG research papers)
* ACL NLG Portal (contains list of NLG resources)
* Bateman and Zock's 'almost complete' list of NLG systems now maintained as a Wiki with a variety of visualisations and overview tables available on demand
* Ehud Reiter's blog on Natural Language Generation

* v
* t
* e

Natural language processing

General terms|

* Natural language understanding
* Text corpus
* Speech corpus
* Stopwords
* Bag-of-words
* AI-complete
* n-gram (Bigram, Trigram)

Text analysis|

* Text segmentation
* Part-of-speech tagging
* Text chunking
* Compound term processing
* Collocation extraction
* Stemming
* Lemmatisation
* Named-entity recognition
* Coreference resolution
* Sentiment analysis
* Concept mining
* Parsing
* Word-sense disambiguation
* Ontology learning
* Terminology extraction
* Textual entailment
* Truecasing

Automatic summarization|

* Multi-document summarization
* Sentence extraction
* Text simplification

Machine translation|

* Computer-assisted
* Example-based
* Rule-based
* Neural

Automatic identification
and data capture|

* Speech recognition
* Speech synthesis
* Optical character recognition
* Natural language generation

Topic model|

* Pachinko allocation
* Latent Dirichlet allocation
* Latent semantic analysis

Computer-assisted
reviewing|

* Automated essay scoring
* Concordancer
* Grammar checker
* Predictive text
* Spell checker
* Syntax guessing

Natural language
user interface|

* Automated online assistant
* Chatbot
* Interactive fiction
* Question answering
* Voice user interface

* Interactive Multimedia Explanation for Equipment Maintenance and Repair \- article describing Coordinated Multimedia Explanation Testbed (COMET)

0.00

(0 votes)

|

Retrieved from "https://handwiki.org/wiki/index.php?title=Natural-language_generation&oldid=320002"
*[v]: View this template
*[t]: Discuss this template
*[e]: Edit this template