How did language modelling, which was conceived in the middle of the previous century, become an integral part of artificial intelligence with practical applications in modern life? How did this blend of artificial intelligence and computational linguistics become the core of our world? Let’s journey along the concept of natural language processing (NLP) and its popular applications such as chatbots, in-voice commands and virtual assistants such as Google Assistant, Siri, Cortana and Amazon’s Alexa.
What is NLP?
In simple words, NLP helps computers understand, interpret and utilise the human tongue and also allows complete communication in a more nuanced fashion. NLP draws from various disciplines, including linguistics and computer science, and provides computers with the ability to read text, hear speech and interpret a vast amount of data. It has extensively evolved since the 1950s and has become a part of our daily lives. It is likely to continue providing standard and innovative solutions to common problems, reducing time, human effort and cost.
History of NLP
Alan Turing, a theoretical computer science and artificial intelligence expert, first conceived the idea of natural language processing in the 1950s. He wrote a paper elucidating a test for a machine, in which he stated that if a machine can be part of a conversation using a teleprinter, then it can also be taught how to imitate a human. Repeated patterns would allow a machine to learn this act, after which it could be considered capable of thinking.
In 1954, an experiment by Georgetown University and IBM strived to automatically translate six Russian sentences into English, planting the seed of hope that machine translation would be possible in a short span of time. However, it was not until the late 1980s that the first statistical machine translation system (translations generated through a statistical model) was developed. Over a period of 1950s-80s, progress was made in building other natural language programs.
Of these, ELIZA took the centre stage in the mid-1960s. This was a computer program developed at the MIT Artificial Intelligence Laboratory by Joseph Weizenbaum to elucidate the superficiality of communication between humans and machines. It revealed that communication with machines did not involve contextualising events and only followed a script. Yet, users attributed human feelings to the program. ELIZA paved the way for what we now know as chatbots (also known as chatterbots), which evolved over time.
The 1970s was the decade of creating structured real-world information into computer-understandable data, and a number of programs improved on the available technology. Notable ones included PARRY (a 1972 chatbot with emotional responses), and later, Racter (a tongue-in-cheek chatbot created in 1984) and Jabberwacky (a chatbot conceived in 1988 that aimed to simulate a human conversation in an entertaining way).
The 1980s were revolutionary in natural language processing, when machine learning algorithms were used for language processing. There was a surge in computational power and the gradual simplification of linguistics. With decision trees, speech tagging and focus on statistical models, cache language models and speech recognition, the results became more reliable.
The early successes of machine learning can be attributed to IBM Research, where successively, more complicated statistical models were developed, including translation of all governmental proceedings into all official languages of Canada and the European Union.
The 21st century brought in representation learning (automatic feature learning) and deep neural network-style machine learning methods to achieve state-of-the-art results. This includes word embeddings to capture semantics and higher-level questions and answers, giving birth to neural machine translation (NMT), which uses an artificial neural network to predict a sequence of words, modelling an entire sentence in a single integrated model.
Within the last two decades, NLP has explored more neural language models, multi-task learning, word embeddings, more advanced neural networks, sequence-to-sequence models, memory-based networks and pre-trained language models. This advancement has led to applications such as intelligent keyboards and email response suggestions to speech-enabled assistance by machines.
Now there is a steady move from Natural Language Processing (NLP) to Natural Language Understanding (NLU), where a user having a human emotional connection with the machines will not be heretical.
Coding Versus Statistical NLP
Initially, language processing systems were designed by hand-coding, essentially by writing grammar or devising heuristic rules. However, in the mid-1980s, this changed to machine learning, which used statistical inference to automatically learn these rules through the analysis of a large set of real-world examples. This resulted in a palpable difference in speed and understanding of the language processing systems.
The learning procedures used during machine learning automatically focused on the most common cases. They could point out and correct erroneous inputs, misspelt words and handle more complex tasks via algorithms. This was a game-changer and reached a scenario where NLP could be used widely and successfully on a global scale.
It was a long road to reach a point where grammar induction, lemmatisation, morphological segmentation, speech tagging, parsing, sentence breaking, stemming, word segmentation and terminology extraction could be used to create robust platforms for using NLP.
NLP Applications in Real Life
1. Machine Translation
NLP has developed several touchpoints in our lives, especially in the last decade. One of the most popular applications is machine translation, best known as Google Translate. Based on SMT (statistical machine translation, which refers to machine translation generated on basis of statistical models), Google Translate does not do a word-for-word translation but assigns semantic value to the words in order to translate them in a coherent manner.
However, owing to the inherent ambiguity and flexibility in human language, such translation is not entirely accurate. Having said that, Google Translate is still the most popular tool used for translation when travelling, bridging the language gap.
2. Speech Recognition
Another exemplary and relatable example of NLP. Speech recognition software programs allow decoding of human voice, which can be used in mobile telephony, home automation, hands-free computing, virtual assistance, video games, and more. The most popular use of this in our daily lives has come with the advent of Google Assistant, Siri and Amazon’s Alexa.
Natural Language Processing
How does this work? In the case of Google Assistant, speech is transformed into text using the Hidden Markov Model (HMM) system. The HMM system listens to 10–20-millisecond clips of spoken words and searches for phonemes and compares them with pre-recorded speech. The process of understanding is followed by identifying the language and context.
The system breaks each word down into its part of speech (noun, verb, etc.) and then determines the context of your orders. Then, it categorises this command and effectively executes a task. Alexa, on the other hand, functions a little differently.
Each time you say something, the words go back to the Amazon server to be deciphered. The system relies on a massive database of words and instructions to assess and execute a command. For example, if Alexa detects words such as ‘pizza’ or ‘dinner’, it would open a food app, or if it detects the word ‘play’, it will connect to music options.
3. Sentiment Analysis
When talking about NLP, sentiment analysis cannot be ignored. This is also known as opinion mining or emotion AI, which measures the inclination of people’s opinions. It involves identifying subjective information in the text and has a number of applications. Brand monitoring and reputation management is the most common use of sentiment analysis in industries.
It allows businesses to track the perception of a brand, identify trends, keep an ear to the ground for influencers and their impact, monitor the reviews of a product or service, mine for new ideas and variations and tweak marketing strategies accordingly. Apart from the brand perception and customer opinion, market research is another prominent field of sentiment analysis application.
Creation and tracking of user-generated content (reviews), news articles, competitor content and filling the gap on market intelligence are often the subsets of sentiment analysis. Reputation management and product analysis is yet another application of sentiment analysis that is used across industries. With this, brands can get nuanced feedback on their products.
Aspect-based sentiment analysis is another way in which brands can use sentiment analysis productively. The aspect-based analysis approach allows extraction of the most viable points regarding customer feedback. Given this rich information and analysis, brands are able to tweak, refresh and direct communication and make changes to the product or service accordingly.
4. Virtual Assistants
Virtual assistance with the help of more mature chatbots is a modern-day approach towards speedy and effective communication with consumers. Low-priority but high-turnover tasks, which require no skill, can be easily provided with the help of chatbots. There has been a growing trust and popularity among users and developers as we move towards the rapid evolution of intelligent chatbots that will offer personalised assistance to the customer in the near future.
In fact, the application of chatbots has also pushed marketing professionals to use virtual assistance more productively, creating new formats of ads and communication that fit the chatbot programs.
In the medical world, AI-powered primary care service involves solving many NLP tasks. Some of the current use cases of NLP in medicine involve the extraction of different medical entities, including symptoms, diseases, or treatments from a large amount of information.
Knowledge discovery from unstructured medical texts to draw patterns and relationships is extremely useful for medical care professionals. As much as NLP can be used to draw information, it can also be used to communicate relevant responses and create autocomplete functionality for a medically aware communication system.
6. Email System
In 2017, Google rolled out SmartReply, its machine-learning-based prowess, to respond to emails with little effort. Faster typing, predictive typing, spell check and grammar check are part of this. Smart Reply scans the text of an incoming message and suggests three basic responses that the user can tweak and send, reducing the time spent for simple or mundane replies.
This is entirely based on neural networks trained to analyse messages and convert them into numerical codes that represent their meaning. Within the email system, email classification and SPAM detection are other ways in which NLP has simplified our lives.
7. Search behaviour
Search behaviour is another NLP-backed aspect that we encounter on a daily basis. Search engines use NLP to show relevant results based on similar search behaviours or user intent, so the average user finds what they need with ease. For example, Google not only predicts what popular searches may apply to an individual’s query as they start typing but also looks at the whole picture comprehensively showing relevant tangential results.
8. Digital Phone Calls
Digital phone calls may seem like an intrusive part of the day, when a voice recorded marketing message talks to you, but this is a great medium to reach a large number of people and resolve problems swiftly. NLP enables computer-generated language close to the voice of a human, which can gather information from a consumer and do simple tasks such as relaying information and booking an appointment.
9. Smart Homes
In-car voice commands, such as locking doors, rolling down windows or playing certain music, are just a few of the functions that NLP has enabled in the auto industry. In the automation arena, home automation is also closely linked to NLP, where voice commands to shut or open blinds, lights and appliances are at the core of ‘smart homes.’
These are only a few of the many NLP usages that we encounter in our lives. The touchpoints are in the world of business, personal development, HR, sales, teaching, medicine, telecommunications, automobiles, infrastructure, coaching and many more.
NLP, though still nascent as compared to big data and deep learning, is widely considered the future of customer service. It promises to make the data more user-friendly and conversational, making it the tent pole of business analytics. Chatbots, for example, will be even more sophisticated and wholesome with the ability to decode complex and long-form requests in real-time.
What is likely to change regarding the current NLP abilities is the nuanced understanding of language. The NLP of the future will enable understanding the subtleties and tone of language and provide useful knowledge and insights, which could be in the sphere of annual reports, call transcripts, investor-sensitive communications or legal and compliance documents.
Expanded use of NLP can also be seen in the robotics, healthcare, financial services, auto and infrastructure industries, with touchpoints in daily use. The NLP of the future will be the core of analytics to enhance and grow businesses worldwide.
If you are interested to know more about natural language processing, check out our PG Diploma in Machine Learning and AI program which is designed for working professionals and provide 30+ case studies & assignments, 25+ industry mentorship sessions, 5+ practical hands-on capstone projects, more than 450 hours of rigorous training & job placement assistance with top firms.