NLP
NLP
NLP
between computers and humans using natural language. The goal of NLP is to enable
computers to understand, interpret, and generate human language in a way that is both
meaningful and contextually relevant. NLP involves a range of tasks, including but not
limited to, text and speech recognition, language translation, sentiment analysis, and language
generation. It plays a crucial role in applications such as chatbots, language translation
services, voice assistants, and other language-related technologies.
The first phase of NLP is the Lexical Analysis. This phase scans the source code as a stream
of characters and converts it into meaningful lexemes. It divides the whole text into paragraphs,
sentences, and words.
Syntactic Analysis is used to check grammar, word arrangements, and shows the relationship
among the words.
In the real world, Agra goes to the Poonam, does not make any sense, so this sentence is
rejected by the Syntactic analyzer.
3. Semantic Analysis
Semantic analysis is concerned with the meaning representation. It mainly focuses on the literal
meaning of words, phrases, and sentences.
4. Discourse Integration
Discourse Integration depends upon the sentences that proceeds it and also invokes the meaning
of the sentences that follow it.
5. Pragmatic Analysis
Pragmatic is the fifth and last phase of NLP. It helps you to discover the intended effect by
applying a set of rules that characterize cooperative dialogues.
Levels of NLP
There are seven independent levels to understand and extract meaning from a text to or
spoken word. To understand natural languages it’s important to differentiate between them.
1. Phonology level: This level basically deals with the pronunciation. As English
spelling is especially only partially phonemic, John inputs the data does not show
these very clearly; for example, the h in John is silent and the two as in data resemble
to very unlike sounds.
2. Morphological level: Morphology deals with the smallest parts of words that convey
meaning, and suffixes and prefixes. Morphemes means studying how the words are
built from smaller meaning. For example, the word 'dog' has single morpheme while
the word 'rats' have two morphemes 'rat' and morpheme 's' denotes singular and plural
concepts.
3. Lexical level: The lexical level deals with the study at the level of words with respect
to their lexical meaning and Part-Of-Speech (POS). This level uses lexicon that is a
collection of individual lexemes. A lexeme is a basic unit of lexical meaning; which is
an abstract unit of morphological analysis that represents the set of forms or "senses"
taken by a single morpheme. For example, "Duck", can take the form of a noun or a
verb but its POS and lexical meaning can only be derived in context with other words
used in the phrase/sentence.
4. Syntactic level: Syntactic level deals with grammar and structure of sentences. It
studies the proper relationships between words. The POS tagging output of the lexical
analysis can be used at the syntactic level of two group words into the phrase and
clause brackets. Syntactic Analysis also referred to as "parsing", allows the extraction
of phrases which convey more meaning than just the individual words by themselves,
such as in a noun phrase.
5. Semantic level: This level deals with the meaning of words and sentences. There are
two approaches of semantic levels: 1. Syntax-driven semantic analysis 2. Semantic
grammar. It is a study of the meaning of words that are associated with grammatical
structure. For example, John inputs the data from this statement we can understand
that John is an Agent.
6. Discourse level: This level deals with the structure of different kinds of text. There are
two types of discourse: 1.Anaphora resolution, 2. Discourse / text structure
recognition. The words are replaced in Anaphora resolution, for example pronouns.
Discourse structure recognition determines the purpose of sentences in the text which
enhances meaningful illustration of the text.
7. Pragmatic level: This level deals with the use of real world knowledge and
understanding of how this influences meaning of what is being communicated. By
analysis documents and queries, a more detailed representation is derived.
Lexical Ambiguity: When words have multiple assertion then it is known as lexical
ambiguity. For example, the word back can be a noun or an adjective. Noun: back stage,
Adjective: back door
Syntactic Ambiguity: Syntactic ambiguity means sentences are parsed in multiple syntactical
forms or A sentence can be parsed in different ways.
Semantic Ambiguity: Semantic ambiguity is related to the sentence interpretation.
Metonymy Ambiguity: Metonymy is most difficult ambiguity. It deals with phrases in which
the literal meaning is different from the figurative assertion.
Application of NLP
1. Machine Translation: In machine translation, the translation of the text from one
human language to another human language is performed automatically. For
performing the translation, it is important to have the knowledge of the words and
phrases, grammar of two languages that are involved in translation, semantics of the
language and knowledge of the word.
2. Speech recognition: Speech recognition is the process where the acoustic speech
signals are mapped to the set of words. Speech recognition is used for converting
spoken words into text. It is used in applications, such as mobile, home automation,
video recovery, dictating to Microsoft Word, voice biometrics, voice user interface,
and so on.
3. Speech synthesis: Automatic production of speech is known as speech synthesis. It
means speaking a sentence in natural language.
4. Information Retrieval: It refers to the human-computer interaction (HCI) that happens
when we use a machine to search a body of information for information objects
(content) that match our search query. A Person's query is matched against a set of
documents to find a subset of 'relevant' document. Examples: Google, Yahoo,
Altavista, etc.
5. Text Categorization: Text categorization (also known as text classification or topic
spotting) is the task of automatically sorting a set of documents into categories
(clusters).
6. Sentiment Analysis: Sentiment Analysis is also known as opinion mining. It is mainly
used on the web to analyse the behaviour, attitude, and emotional state of the sender.
This application is implemented through a combination of NLP) and statistics by
assigning the values to the text (natural, positive or negative), identify the mood of the
context (sad, happy, angry, etc.)
7. Question-Answering systems: Question Answering focuses on constructing systems
that automatically answer the questions asked by humans in a natural language. It
presents only the requested information instead of searching full documents like
search engine. The basic idea behind the QA system is that the users just have to ask
the question and the system will retrieve the most appropriate and correct answer for
that question.
8. Spam Detection: To detect unwanted e-mails getting to a user's inbox, spam detection
is used.
9. Chatbot: Chatbot is one of the most important applications of NLP. It is used by many
companies to provide the customer's chat services.
10. Text summarization: This task aims to create short summaries of longer documents
while retaining the core content and preserving the overall meaning of the text.
11. Information Extraction - Identify specific pieces of information in unstructured or
semi-structured textual document. Transform unstructured information in a corpus of
documents or web pages into a structured database.