SlideShare a Scribd company logo
State of NLP &
Amazon Comprehend
Brief Overview of the State of NLP and
AWS NLP Offering
Egor Pushkin
Principal Engineer
Amazon AI
January 2020
Introductions
Presenter
Machine learning at AWS, Amazon AI
Internet-scale services and global mobile deployments at Glympse
This Talk
Audience
How many people are familiar with T5 model? BERT? Transformer?
Given a passage of natural text and a question, find a span in the initial passage
that constitutes the answer (if the one is available).
State of NLP
Dark Ages... or Once Upon a Time...
Rule-based Systems
hardcoded rules
regular expressions
Statistical / Shallow Neural
corpus-based statistics
feature engineering
linear models
Stepping Stones / Driving Forces
Perceptron / Backpropagation
Automatic Differentiation
Deep Neural / CNN / LSTM / Transformer
Computational Resources / GPU
Data Availability
Attention to the Space
Natural Language Understanding
Language Analysis
Task → Dataset → Challenge → Model
What is "progress" in NLU?
higher accuracy on existing tasks and datasets
new (more complex) tasks and datasets
new categories of problems
“Language shapes the way we think, and determines what we can think about.”
– Benjamin Lee Whorf
Categories of NLU Tasks
sequence tagging
semantic relations
question answering
classification
language generation
...
Journey
to common
sense
reasoning
(hopefully)
In 1935, in an annual birthday celebration interview, Tesla announced a method of
transmitting mechanical energy with minimal loss over any terrestrial distance, a
related new means of communication, and a method of accurately determining the
location of underground mineral deposits.
SQuAD 1.1
How far did he claim the mechanical energy could be transmitted?
DROP
The median age in the city was 22.1 years. 10.1% of residents were under the age
of 18; 56.2% were between the ages of 18 and 24; 16.1% were from 25 to 44;
10.5% were from 45 to 64; and 7% were 65 years of age or older. The gender
makeup of the city was 64.3% male and 35.7% female.
Which age group was the second largest?
Why do people read gossip magazines?
entertained | get information | learn | improve know how | lawyer told to
CommonSense QA
...
???
via increasing
task complexity
Non Existing QA Challenge
P( Summer is over | LMs are essential to NLP )
Natural Language Modeling
Fundamentals
Evolution
“You shall know the nature of a word by the company it keeps.”
– John Rupert Firth
P(w) and P(wi
| wi-n-1:i-1
)
>100mm params
>10GB pre-training data
P( time | Once upon a )
Count-based LMs
Continuous-space LMs
(shallow)
Recurrent/Transformer LMs
Word Embeddings
Input representation
Semantic embeddings
Contextualized word embeddings
Word pieces
Hello? Is there
anybody in there?
surrealistic
existentialism
surreal ##istic existent
##ial ##ism ...
word2vec
GloVe
FastText
ELMO
BERT
walked
swam
walking
swimming
Sequence to Sequence
Encoder/decoder architecture
Sequence to Sequence Learning with Neural Networks (Sutskever et al., 2014)
encoder
decoder
input
output
internal
representation
A B C <EOS>
<EOS>
W X Y Z
W X Y Z
Encoder input and state as
input sequence is being fed into it.
Decoder state and output in process of
output sequence generation.
<BOS>
Previously generated context is added back to
the network giving it some context on what has
already been produced.
Translation, language generation
Multi-modal applications
Actual (or expected) output from training dataset
is used when model is trained with teacher
forcing enabled.
inference
training
Attention
Neural Machine Translation by Jointly Learning to Align and Translate (Bahdanau et al., 2014)
(Prior to attention) Context
vector (encoder state)
tended to forget things...
Attention mechanism was
introduced to memorize
long sentences
Was born for translation
A B C <EOS>
x x x x
‱ ‱ ‱ ‱
+
<EOS>
W X Y Z
softmax
Each item is dot producted
with the query to produce a
score, describing how well it
matches the query. The
scores are fed into a
softmax to create the
attention distribution.
q
decoder
states
encoder
states
Transformer
Multi-head self-attention
Attention Is All You Need (Vaswani et al., 2017)
Encoder/decoder
stacks
x
+
x
⁀
x ...
combining output of
multiple attention heads
k
q
v
self-attention
...
...
...
Word-pieces
Positional encoding
Segment embeddings
Learning objectives
Masked language modeling
Next sentence prediction
Large scale pre-training
English Wikipedia, BooksCorpus
Bidirectional, autoencoder
BERT
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding (Devlin et al., 2018)
...
transformer
encoder
stack
tokenized input
token representations
output of
downstream task
pre-training
setup
fine-tuning
setup
LM learning objective at
training time
additional
layer(s)
output
probabilities
Transformer
contributions
embeddings
embeddings'
+ softmax
fully-connected
+ GELU + norm
Example tasks:
Classification
NER
Question Answering
Relation Extraction
Coreference Resolution
Natural Language Inference
...
Transfer Learning via Fine-tuning LM Models
Transfer Learning in Natural Language Processing (quick ~230 slide overview)
“NLP's ImageNet moment has arrived”
– Sebastian Ruder
Transfer Learning
Inductive
Transfer Learning
Transductive
Transfer Learning
Multi-task
Learning
Sequential Transfer
Learning
Domain
Adaptation
Cross-lingual
Learning
Different tasks;
labeled data in target
domain
Same tasks;
labeled data only in
source domain
Different
domains
Different
languages
Tasks learned
simultaneously
Tasks learned
sequentially
How far ... transmitted?
Extractive, open-domain
question answering based on
the given context
Training
fine-tune BERT encoder layers
train dense layer from scratch
tokenizer vocabulary stays intact
Inference
BERT for QA In 1935, in an annual birthday celebration interview, Tesla announced a method of
transmitting mechanical energy with minimal loss over any terrestrial distance, a
related new means of communication, and a method of accurately determining the
location of underground mineral deposits.
How far did he claim the mechanical energy could be transmitted?
SQuAD 1.1
BERT
In 1935, in 
 mineral deposits.
[CLS] 'In' '1935' ',' 'in' ... 'mineral' 'deposits' '.' [SEP] 'how' 'far' ... 'transmitted' '?'
BERT Tokenizer
Start Position End Position

 minimal loss over any terrestrial distance, a related new means of ...
Fully-connected layer
with weight matrix of
size [T*H, 2]
0 0 0 0 0 0 0 0 1 1 1 1 1
p
q
BERT for QA
BERT for QA
What about multi-hop questions?
Pace Of Innovation
Perceptron 1957
Word Embeddings ~1960s
CNN 1989 ~30 years
LSTM 1997 12 years
Continuous-space LM 2001 4 years
Multi-task Learning 2008 7 years
Seq to Seq | Attention Sep, 2014 6 years
Transformer Jul 12, 2017 3 years
BERT Oct 11, 2018 1 year SoTA 11 tasks
Transformer-XL Jan 9, 2019 3 months SoTA 4 tasks
XLNet June 19, 2019 5 months SoTA 18 tasks
roBERTa July 26, 2019 1 month SoTA 6 tasks
ERNIE 2.0 July 29, 2019 3 days SoTA 9 tasks (ch)
ALBERT Sep 25, 2019 2 months SoTA 10 tasks
T5 Oct 24, 2019 1 month SoTA 16 tasks
...
All SoTA results below
this line are attributed to
transformer models
Topical Problems
Bias
Explainability
Troubleshooting
Control / Nuances
Privacy
...
Areas of Research
Transformers
Explainability
Auto ML / NAS
Low Resource / Green AI
Common Sense

...
Tasks
https://nlusense.com
One biased opinion
regarding the structure
of NLP discipline
AI/ML at AWS
Overview
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
AI Services
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
new
new
new
Amazon Comprehend
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Use Cases
Text Analytics
Search Optimization
Knowledge Discovery
Classification
Amazon Comprehend © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Sentiment Analysis
The Sentiment Analysis API returns the overall sentiment of a text (Positive, Negative, Neutral, or Mixed).
Can't wait to visit rainforest again! Such a magical place...
Analysis
Examples
positive: 0.95 | negative: 0.0 | neutral: 0.03 | mixed: 0.0
Been there twice and won't go ever again. Bad and not getting better...
positive: 0.01 | negative: 0.96 | neutral: 0.01 | mixed: 0.0
The Sun is a G-type main-sequence star (G2V) based on its spectral class.
positive: 0.02 | negative: 0.0 | neutral: 0.96 | mixed: 0.0
The food was great but the service could be improved.
positive: 0.08 | negative: 0.01 | neutral: 0.0 | mixed: 0.89
Comprehend Sentiment Analysis © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Named Entity Recognition
Amazon.com, Inc. is located in Seattle, WA and was founded
July 5th, 1994 by Jeff Bezos , allowing customers to buy
everything from books to blenders. Seattle is north of Portland
and south of Vancouver, BC . Other notable Seattle -based
companies are Starbucks and Boeing .
PERSON
LOCATION
ORGANIZATION
COMMERCIAL_ITEM
EVENT
DATE
QUANTITY
TITLE
OTHER
ORGANIZATION
DATE
LOCATION
PERSON
LOCATION LOCATION
LOCATION LOCATION
ORGANIZATION ORGANIZATION
Entity Types
Recognition Example
The Entity Recognition API returns the named entities ("People," "Places," "Locations," etc.) that
are automatically categorized based on the provided text.
Comprehend Entities Recognition © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Keyphrase Extraction
The Keyphrase Extraction API returns the key phrases or talking points and a confidence score to
support that this is a key phrase.
I'm an avid photographer , and I'm primarily found shooting with
my DSLR or my instant film camera that I carry around for
casual use . While nothing beats my DSLR in power and
convenience , there's something magical about my instant film camera .
Extraction Example
Comprehend Keyphrase Extraction © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Language Detection
The Language Detection API automatically identifies text written in over 100 languages and
returns the dominant language with a confidence score to support that a language is dominant.
Amazon Elastic Compute Cloud (Amazon EC2) Ăš un servizio Web che
fornisce capacità di elaborazione sicura e scalabile nel cloud. È
concepito per rendere piĂč semplice il cloud computing su scala Web per
gli sviluppatori.
Detection Example
af | am | ar | as | az | ba
be | bn | bs | bg | ca | ceb
cs | cv | cy | da | de | el
en | eo | et | eu | fa | fi
fr | gd | ga | gl | gu | ht
he | hi | hr | hu | hy | ilo
id | is | it | jv | ja | kn
ka | kk | km | ky | ko | ku
la | lv | lt | lb | ml | mr
mk | mg | mn | ms | my | ne
new | nl | no | or | pa | pl
pt | ps | qu | ro | ru | sa
si | sk | sl | sd | so | es
sq | sr | su | sw | sv | ta
tt | te | tg | tl | th | tk
tr | ug | uk | ur | uz | vi
yi | yo | zh | zh-TW
Italian: 0.99
Comprehend Language Detection © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Syntax Analysis
The Amazon Comprehend Syntax API enables customers to analyze text using tokenization and Parts of
Speech (PoS), and identify word boundaries and labels like nouns and adjectives within the text.
He also investigated the thermal properties of light
which laid the foundation of the photon theory
of light . In 1917 .
PRON
ADJ
ADP
ADV
AUX
CONJ
DET
INTJ
NOUN
NUM
PoS Tags
Comprehend Syntax Analysis
O
PART
PRON
PROPN
PUNCT
SCONJ
SYM
VERB
DET
ADV VERB ADJ NOUN ADP NOUN
PRON VERB DET NOUN ADP DET NOUN NOUN
ADP NOUN PUNCT ADP NUM PUNCT
Analysis Example
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Input document 1
Input document 2
Custom Classification (Multi-Class)
CLASS_1
CLASS_1
CLASS_2
CLASS_3
CLASS_4
...
Training
DOC_1
DOC_2
DOC_3
DOC_4
DOC_5
...
The Custom Classification API enables you to easily build custom text classification models using your
business-specific labels without learning ML.
Comprehend Custom Classification
Classification
CLASS_1: 0.85 | CLASS_2: 0.1 | CLASS_4: 0.4
CLASS_2: 0.05 | CLASS_3: 0.76 | CLASS_4: 0.23
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Custom Classification (Multi-Label)
LABEL_1 | LABEL_2
LABEL_3
LABEL_3 | LABEL_4 | LABEL_5
LABEL_1 | LABEL_3 |
LABEL_6
...
Training
DOC_1
DOC_2
DOC_3
DOC_4
DOC_5
...
Multi-label Text Classification provides ability to tag documents with multiple labels at the same time
(unlike mult-class mode, where each document is associated with a single class).
Comprehend Custom Classification
Classification
LABEL_3: 0.34 | LABEL_4: 0.87
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
new
LABEL_5: 0.26
Input document 2
LABEL_3: 0.73 | LABEL_6: 0.78
LABEL_1: 0.51 | LABEL_2: 0.93
LABEL_6: 0.85
Input document 1
Custom Entities
File
Doc1
Doc2
...
Annotations Mode
Line
0
1
...
Begin Offset
10
0
...
Begin Offset
23
8
...
Type
LAWYER
JUDGE
...
Text
John
Bob
Roy
...
Entity List Mode
Type
LAWYER
LAWYER
JUDGE
...
Custom Entities allows you to customize
Amazon Comprehend to identify terms that
are specific to your domain.
Robert Shelby , who in June 2018 imposed a preliminary
injunction stopping the sales while the suit was litigated, ruled on
motions by both sides seeking summary judgment.
JUDGE
Recognition Example
Comprehend Custom Entities
or
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Topic Modeling
Topic Modeling identifies relevant terms or topics from a collection of documents stored in Amazon S3. It
will identify the most common topics in the collection and organize them in groups and then map which
documents belong to which topic.
Comprehend Topic Modeling
Topic
1
1
2
2.
Topic Terms
Term
Amazon
Seattle
Holidays
Shopping
Weight
0.87
0.13
0.78
0.22
Document
Doc1.txt
Doc2.txt
Doc3.txt
Doc4.txt
Topics
Topic
1
1
2
2
Proportion
0.87
0.65
0.78
0.67
Input Documents
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
Q&A
Egor Pushkin
https://www.linkedin.com/in/egorpushkin/
@egorpushkin
© 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved

More Related Content

What's hot

LanGCHAIN Framework
LanGCHAIN FrameworkLanGCHAIN Framework
LanGCHAIN Framework
Keymate.AI
 
Regulating Generative AI - LLMOps pipelines with Transparency
Regulating Generative AI - LLMOps pipelines with TransparencyRegulating Generative AI - LLMOps pipelines with Transparency
Regulating Generative AI - LLMOps pipelines with Transparency
Debmalya Biswas
 
How do OpenAI GPT Models Work - Misconceptions and Tips for Developers
How do OpenAI GPT Models Work - Misconceptions and Tips for DevelopersHow do OpenAI GPT Models Work - Misconceptions and Tips for Developers
How do OpenAI GPT Models Work - Misconceptions and Tips for Developers
Ivo Andreev
 
Holland & Barrett: Gen AI Prompt Engineering for Tech teams
Holland & Barrett: Gen AI Prompt Engineering for Tech teamsHolland & Barrett: Gen AI Prompt Engineering for Tech teams
Holland & Barrett: Gen AI Prompt Engineering for Tech teams
Dobo Radichkov
 
Natural language processing and transformer models
Natural language processing and transformer modelsNatural language processing and transformer models
Natural language processing and transformer models
Ding Li
 
An introduction to the Transformers architecture and BERT
An introduction to the Transformers architecture and BERTAn introduction to the Transformers architecture and BERT
An introduction to the Transformers architecture and BERT
Suman Debnath
 
Customizing LLMs
Customizing LLMsCustomizing LLMs
Customizing LLMs
Jim Steele
 
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdf
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdfRetrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdf
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdf
Po-Chuan Chen
 
GenAIforPPs100223.pdf
GenAIforPPs100223.pdfGenAIforPPs100223.pdf
GenAIforPPs100223.pdf
SaadAhmedBhatti
 
Large Language Models - Chat AI.pdf
Large Language Models - Chat AI.pdfLarge Language Models - Chat AI.pdf
Large Language Models - Chat AI.pdf
David Rostcheck
 
What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?
What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?
What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?
Bernard Marr
 
Chatbots
ChatbotsChatbots
Chatbots
Vectr.Consulting
 
The current state of generative AI
The current state of generative AIThe current state of generative AI
The current state of generative AI
Benjaminlapid1
 
Build Text Analytics Solutions with Amazon Comprehend and Amazon Translate
Build Text Analytics Solutions with Amazon Comprehend and Amazon TranslateBuild Text Analytics Solutions with Amazon Comprehend and Amazon Translate
Build Text Analytics Solutions with Amazon Comprehend and Amazon Translate
Amazon Web Services
 
Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...
Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...
Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...
Databricks
 
OpenAI Chatgpt.pptx
OpenAI Chatgpt.pptxOpenAI Chatgpt.pptx
OpenAI Chatgpt.pptx
Nawroz University
 
Generative AI at the edge.pdf
Generative AI at the edge.pdfGenerative AI at the edge.pdf
Generative AI at the edge.pdf
Qualcomm Research
 
Insight Asset Management in Jira and eazyBI Powered Insight Reporting
Insight Asset Management in Jira and eazyBI Powered Insight ReportingInsight Asset Management in Jira and eazyBI Powered Insight Reporting
Insight Asset Management in Jira and eazyBI Powered Insight Reporting
eazyBI
 
OpenAI-Copilot-ChatGPT.pptx
OpenAI-Copilot-ChatGPT.pptxOpenAI-Copilot-ChatGPT.pptx
OpenAI-Copilot-ChatGPT.pptx
Udaiappa Ramachandran
 
Generative AI con Amazon Bedrock.pdf
Generative AI con Amazon Bedrock.pdfGenerative AI con Amazon Bedrock.pdf
Generative AI con Amazon Bedrock.pdf
Guido Maria Nebiolo
 

What's hot (20)

LanGCHAIN Framework
LanGCHAIN FrameworkLanGCHAIN Framework
LanGCHAIN Framework
 
Regulating Generative AI - LLMOps pipelines with Transparency
Regulating Generative AI - LLMOps pipelines with TransparencyRegulating Generative AI - LLMOps pipelines with Transparency
Regulating Generative AI - LLMOps pipelines with Transparency
 
How do OpenAI GPT Models Work - Misconceptions and Tips for Developers
How do OpenAI GPT Models Work - Misconceptions and Tips for DevelopersHow do OpenAI GPT Models Work - Misconceptions and Tips for Developers
How do OpenAI GPT Models Work - Misconceptions and Tips for Developers
 
Holland & Barrett: Gen AI Prompt Engineering for Tech teams
Holland & Barrett: Gen AI Prompt Engineering for Tech teamsHolland & Barrett: Gen AI Prompt Engineering for Tech teams
Holland & Barrett: Gen AI Prompt Engineering for Tech teams
 
Natural language processing and transformer models
Natural language processing and transformer modelsNatural language processing and transformer models
Natural language processing and transformer models
 
An introduction to the Transformers architecture and BERT
An introduction to the Transformers architecture and BERTAn introduction to the Transformers architecture and BERT
An introduction to the Transformers architecture and BERT
 
Customizing LLMs
Customizing LLMsCustomizing LLMs
Customizing LLMs
 
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdf
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdfRetrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdf
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks.pdf
 
GenAIforPPs100223.pdf
GenAIforPPs100223.pdfGenAIforPPs100223.pdf
GenAIforPPs100223.pdf
 
Large Language Models - Chat AI.pdf
Large Language Models - Chat AI.pdfLarge Language Models - Chat AI.pdf
Large Language Models - Chat AI.pdf
 
What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?
What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?
What Is GPT-3 And Why Is It Revolutionizing Artificial Intelligence?
 
Chatbots
ChatbotsChatbots
Chatbots
 
The current state of generative AI
The current state of generative AIThe current state of generative AI
The current state of generative AI
 
Build Text Analytics Solutions with Amazon Comprehend and Amazon Translate
Build Text Analytics Solutions with Amazon Comprehend and Amazon TranslateBuild Text Analytics Solutions with Amazon Comprehend and Amazon Translate
Build Text Analytics Solutions with Amazon Comprehend and Amazon Translate
 
Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...
Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...
Building a Pipeline for State-of-the-Art Natural Language Processing Using Hu...
 
OpenAI Chatgpt.pptx
OpenAI Chatgpt.pptxOpenAI Chatgpt.pptx
OpenAI Chatgpt.pptx
 
Generative AI at the edge.pdf
Generative AI at the edge.pdfGenerative AI at the edge.pdf
Generative AI at the edge.pdf
 
Insight Asset Management in Jira and eazyBI Powered Insight Reporting
Insight Asset Management in Jira and eazyBI Powered Insight ReportingInsight Asset Management in Jira and eazyBI Powered Insight Reporting
Insight Asset Management in Jira and eazyBI Powered Insight Reporting
 
OpenAI-Copilot-ChatGPT.pptx
OpenAI-Copilot-ChatGPT.pptxOpenAI-Copilot-ChatGPT.pptx
OpenAI-Copilot-ChatGPT.pptx
 
Generative AI con Amazon Bedrock.pdf
Generative AI con Amazon Bedrock.pdfGenerative AI con Amazon Bedrock.pdf
Generative AI con Amazon Bedrock.pdf
 

Similar to State of NLP and Amazon Comprehend

ICDM 2019 Tutorial: Speech and Language Processing: New Tools and Applications
ICDM 2019 Tutorial: Speech and Language Processing: New Tools and ApplicationsICDM 2019 Tutorial: Speech and Language Processing: New Tools and Applications
ICDM 2019 Tutorial: Speech and Language Processing: New Tools and Applications
Forward Gradient
 
Machine Learning in NLP
Machine Learning in NLPMachine Learning in NLP
Machine Learning in NLP
Vijay Ganti
 
RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013
RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013
RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013
CA API Management
 
Neural Text Embeddings for Information Retrieval (WSDM 2017)
Neural Text Embeddings for Information Retrieval (WSDM 2017)Neural Text Embeddings for Information Retrieval (WSDM 2017)
Neural Text Embeddings for Information Retrieval (WSDM 2017)
Bhaskar Mitra
 
The NLP Muppets revolution!
The NLP Muppets revolution!The NLP Muppets revolution!
The NLP Muppets revolution!
Fabio Petroni, PhD
 
AWS re:Invent 2016: Deep Learning in Alexa (MAC202)
AWS re:Invent 2016: Deep Learning in Alexa (MAC202)AWS re:Invent 2016: Deep Learning in Alexa (MAC202)
AWS re:Invent 2016: Deep Learning in Alexa (MAC202)
Amazon Web Services
 
Bridging the gap between AI and UI - DSI Vienna - full version
Bridging the gap between AI and UI - DSI Vienna - full versionBridging the gap between AI and UI - DSI Vienna - full version
Bridging the gap between AI and UI - DSI Vienna - full version
Liad Magen
 
Diversity In Localization (Olga Melnikova)
Diversity In Localization (Olga Melnikova)Diversity In Localization (Olga Melnikova)
Diversity In Localization (Olga Melnikova)
Olga Melnikova
 
Natural Language Processing
Natural Language ProcessingNatural Language Processing
Natural Language Processing
punedevscom
 
Devoxx traitement automatique du langage sur du texte en 2019
Devoxx   traitement automatique du langage sur du texte en 2019 Devoxx   traitement automatique du langage sur du texte en 2019
Devoxx traitement automatique du langage sur du texte en 2019
Alexis Agahi
 
MACHINE-DRIVEN TEXT ANALYSIS
MACHINE-DRIVEN TEXT ANALYSISMACHINE-DRIVEN TEXT ANALYSIS
MACHINE-DRIVEN TEXT ANALYSIS
Massimo Schenone
 
Gadgets pwn us? A pattern language for CALL
Gadgets pwn us? A pattern language for CALLGadgets pwn us? A pattern language for CALL
Gadgets pwn us? A pattern language for CALL
Lawrie Hunter
 
Understanding Names with Neural Networks - May 2020
Understanding Names with Neural Networks - May 2020Understanding Names with Neural Networks - May 2020
Understanding Names with Neural Networks - May 2020
Basis Technology
 
ppt
pptppt
ppt
butest
 
ppt
pptppt
ppt
butest
 
The State of ML for iOS: On the Advent of WWDC 2018 🕯
The State of ML for iOS: On the Advent of WWDC 2018 🕯The State of ML for iOS: On the Advent of WWDC 2018 🕯
The State of ML for iOS: On the Advent of WWDC 2018 🕯
Meghan Kane
 
Day2-Slides.ppt pppppppppppppppppppppppppp
Day2-Slides.ppt ppppppppppppppppppppppppppDay2-Slides.ppt pppppppppppppppppppppppppp
Day2-Slides.ppt pppppppppppppppppppppppppp
ratnapatil14
 
Recurrent Neural Networks for Text Analysis
Recurrent Neural Networks for Text AnalysisRecurrent Neural Networks for Text Analysis
Recurrent Neural Networks for Text Analysis
odsc
 
Nltk
NltkNltk
Nltk
Anirudh
 
Diving deep into NLP
Diving deep into NLPDiving deep into NLP
Diving deep into NLP
Paolo Montrasio
 

Similar to State of NLP and Amazon Comprehend (20)

ICDM 2019 Tutorial: Speech and Language Processing: New Tools and Applications
ICDM 2019 Tutorial: Speech and Language Processing: New Tools and ApplicationsICDM 2019 Tutorial: Speech and Language Processing: New Tools and Applications
ICDM 2019 Tutorial: Speech and Language Processing: New Tools and Applications
 
Machine Learning in NLP
Machine Learning in NLPMachine Learning in NLP
Machine Learning in NLP
 
RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013
RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013
RESTing in the ALPS Mike Amundsen's Presentation from QCon London 2013
 
Neural Text Embeddings for Information Retrieval (WSDM 2017)
Neural Text Embeddings for Information Retrieval (WSDM 2017)Neural Text Embeddings for Information Retrieval (WSDM 2017)
Neural Text Embeddings for Information Retrieval (WSDM 2017)
 
The NLP Muppets revolution!
The NLP Muppets revolution!The NLP Muppets revolution!
The NLP Muppets revolution!
 
AWS re:Invent 2016: Deep Learning in Alexa (MAC202)
AWS re:Invent 2016: Deep Learning in Alexa (MAC202)AWS re:Invent 2016: Deep Learning in Alexa (MAC202)
AWS re:Invent 2016: Deep Learning in Alexa (MAC202)
 
Bridging the gap between AI and UI - DSI Vienna - full version
Bridging the gap between AI and UI - DSI Vienna - full versionBridging the gap between AI and UI - DSI Vienna - full version
Bridging the gap between AI and UI - DSI Vienna - full version
 
Diversity In Localization (Olga Melnikova)
Diversity In Localization (Olga Melnikova)Diversity In Localization (Olga Melnikova)
Diversity In Localization (Olga Melnikova)
 
Natural Language Processing
Natural Language ProcessingNatural Language Processing
Natural Language Processing
 
Devoxx traitement automatique du langage sur du texte en 2019
Devoxx   traitement automatique du langage sur du texte en 2019 Devoxx   traitement automatique du langage sur du texte en 2019
Devoxx traitement automatique du langage sur du texte en 2019
 
MACHINE-DRIVEN TEXT ANALYSIS
MACHINE-DRIVEN TEXT ANALYSISMACHINE-DRIVEN TEXT ANALYSIS
MACHINE-DRIVEN TEXT ANALYSIS
 
Gadgets pwn us? A pattern language for CALL
Gadgets pwn us? A pattern language for CALLGadgets pwn us? A pattern language for CALL
Gadgets pwn us? A pattern language for CALL
 
Understanding Names with Neural Networks - May 2020
Understanding Names with Neural Networks - May 2020Understanding Names with Neural Networks - May 2020
Understanding Names with Neural Networks - May 2020
 
ppt
pptppt
ppt
 
ppt
pptppt
ppt
 
The State of ML for iOS: On the Advent of WWDC 2018 🕯
The State of ML for iOS: On the Advent of WWDC 2018 🕯The State of ML for iOS: On the Advent of WWDC 2018 🕯
The State of ML for iOS: On the Advent of WWDC 2018 🕯
 
Day2-Slides.ppt pppppppppppppppppppppppppp
Day2-Slides.ppt ppppppppppppppppppppppppppDay2-Slides.ppt pppppppppppppppppppppppppp
Day2-Slides.ppt pppppppppppppppppppppppppp
 
Recurrent Neural Networks for Text Analysis
Recurrent Neural Networks for Text AnalysisRecurrent Neural Networks for Text Analysis
Recurrent Neural Networks for Text Analysis
 
Nltk
NltkNltk
Nltk
 
Diving deep into NLP
Diving deep into NLPDiving deep into NLP
Diving deep into NLP
 

Recently uploaded

Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
Adtran
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
IndexBug
 
Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
Zilliz
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
Zilliz
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
Tomaz Bratanic
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
DianaGray10
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
panagenda
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
Matthew Sinclair
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
Octavian Nadolu
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
SOFTTECHHUB
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
DianaGray10
 
Climate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing DaysClimate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing Days
Kari Kakkonen
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
Zilliz
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Safe Software
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 

Recently uploaded (20)

Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
 
Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
 
Climate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing DaysClimate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing Days
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 

State of NLP and Amazon Comprehend

  • 1. State of NLP & Amazon Comprehend Brief Overview of the State of NLP and AWS NLP Offering Egor Pushkin Principal Engineer Amazon AI January 2020
  • 2. Introductions Presenter Machine learning at AWS, Amazon AI Internet-scale services and global mobile deployments at Glympse This Talk Audience How many people are familiar with T5 model? BERT? Transformer? Given a passage of natural text and a question, find a span in the initial passage that constitutes the answer (if the one is available).
  • 4. Dark Ages... or Once Upon a Time... Rule-based Systems hardcoded rules regular expressions Statistical / Shallow Neural corpus-based statistics feature engineering linear models
  • 5. Stepping Stones / Driving Forces Perceptron / Backpropagation Automatic Differentiation Deep Neural / CNN / LSTM / Transformer Computational Resources / GPU Data Availability Attention to the Space
  • 6. Natural Language Understanding Language Analysis Task → Dataset → Challenge → Model What is "progress" in NLU? higher accuracy on existing tasks and datasets new (more complex) tasks and datasets new categories of problems “Language shapes the way we think, and determines what we can think about.” – Benjamin Lee Whorf Categories of NLU Tasks sequence tagging semantic relations question answering classification language generation ...
  • 7. Journey to common sense reasoning (hopefully) In 1935, in an annual birthday celebration interview, Tesla announced a method of transmitting mechanical energy with minimal loss over any terrestrial distance, a related new means of communication, and a method of accurately determining the location of underground mineral deposits. SQuAD 1.1 How far did he claim the mechanical energy could be transmitted? DROP The median age in the city was 22.1 years. 10.1% of residents were under the age of 18; 56.2% were between the ages of 18 and 24; 16.1% were from 25 to 44; 10.5% were from 45 to 64; and 7% were 65 years of age or older. The gender makeup of the city was 64.3% male and 35.7% female. Which age group was the second largest? Why do people read gossip magazines? entertained | get information | learn | improve know how | lawyer told to CommonSense QA ... ??? via increasing task complexity Non Existing QA Challenge
  • 8. P( Summer is over | LMs are essential to NLP ) Natural Language Modeling Fundamentals Evolution “You shall know the nature of a word by the company it keeps.” – John Rupert Firth P(w) and P(wi | wi-n-1:i-1 ) >100mm params >10GB pre-training data P( time | Once upon a ) Count-based LMs Continuous-space LMs (shallow) Recurrent/Transformer LMs
  • 9. Word Embeddings Input representation Semantic embeddings Contextualized word embeddings Word pieces Hello? Is there anybody in there? surrealistic existentialism surreal ##istic existent ##ial ##ism ... word2vec GloVe FastText ELMO BERT walked swam walking swimming
  • 10. Sequence to Sequence Encoder/decoder architecture Sequence to Sequence Learning with Neural Networks (Sutskever et al., 2014) encoder decoder input output internal representation A B C <EOS> <EOS> W X Y Z W X Y Z Encoder input and state as input sequence is being fed into it. Decoder state and output in process of output sequence generation. <BOS> Previously generated context is added back to the network giving it some context on what has already been produced. Translation, language generation Multi-modal applications Actual (or expected) output from training dataset is used when model is trained with teacher forcing enabled. inference training
  • 11. Attention Neural Machine Translation by Jointly Learning to Align and Translate (Bahdanau et al., 2014) (Prior to attention) Context vector (encoder state) tended to forget things... Attention mechanism was introduced to memorize long sentences Was born for translation A B C <EOS> x x x x ‱ ‱ ‱ ‱ + <EOS> W X Y Z softmax Each item is dot producted with the query to produce a score, describing how well it matches the query. The scores are fed into a softmax to create the attention distribution. q decoder states encoder states
  • 12. Transformer Multi-head self-attention Attention Is All You Need (Vaswani et al., 2017) Encoder/decoder stacks x + x ⁀ x ... combining output of multiple attention heads k q v self-attention ... ... ...
  • 13. Word-pieces Positional encoding Segment embeddings Learning objectives Masked language modeling Next sentence prediction Large scale pre-training English Wikipedia, BooksCorpus Bidirectional, autoencoder BERT BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding (Devlin et al., 2018) ... transformer encoder stack tokenized input token representations output of downstream task pre-training setup fine-tuning setup LM learning objective at training time additional layer(s) output probabilities Transformer contributions embeddings embeddings' + softmax fully-connected + GELU + norm
  • 14. Example tasks: Classification NER Question Answering Relation Extraction Coreference Resolution Natural Language Inference ... Transfer Learning via Fine-tuning LM Models Transfer Learning in Natural Language Processing (quick ~230 slide overview) “NLP's ImageNet moment has arrived” – Sebastian Ruder Transfer Learning Inductive Transfer Learning Transductive Transfer Learning Multi-task Learning Sequential Transfer Learning Domain Adaptation Cross-lingual Learning Different tasks; labeled data in target domain Same tasks; labeled data only in source domain Different domains Different languages Tasks learned simultaneously Tasks learned sequentially
  • 15. How far ... transmitted? Extractive, open-domain question answering based on the given context Training fine-tune BERT encoder layers train dense layer from scratch tokenizer vocabulary stays intact Inference BERT for QA In 1935, in an annual birthday celebration interview, Tesla announced a method of transmitting mechanical energy with minimal loss over any terrestrial distance, a related new means of communication, and a method of accurately determining the location of underground mineral deposits. How far did he claim the mechanical energy could be transmitted? SQuAD 1.1 BERT In 1935, in 
 mineral deposits. [CLS] 'In' '1935' ',' 'in' ... 'mineral' 'deposits' '.' [SEP] 'how' 'far' ... 'transmitted' '?' BERT Tokenizer Start Position End Position 
 minimal loss over any terrestrial distance, a related new means of ... Fully-connected layer with weight matrix of size [T*H, 2] 0 0 0 0 0 0 0 0 1 1 1 1 1 p q
  • 17. BERT for QA What about multi-hop questions?
  • 18. Pace Of Innovation Perceptron 1957 Word Embeddings ~1960s CNN 1989 ~30 years LSTM 1997 12 years Continuous-space LM 2001 4 years Multi-task Learning 2008 7 years Seq to Seq | Attention Sep, 2014 6 years Transformer Jul 12, 2017 3 years BERT Oct 11, 2018 1 year SoTA 11 tasks Transformer-XL Jan 9, 2019 3 months SoTA 4 tasks XLNet June 19, 2019 5 months SoTA 18 tasks roBERTa July 26, 2019 1 month SoTA 6 tasks ERNIE 2.0 July 29, 2019 3 days SoTA 9 tasks (ch) ALBERT Sep 25, 2019 2 months SoTA 10 tasks T5 Oct 24, 2019 1 month SoTA 16 tasks ... All SoTA results below this line are attributed to transformer models
  • 20. Areas of Research Transformers Explainability Auto ML / NAS Low Resource / Green AI Common Sense
 ...
  • 23. Overview © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 24. AI Services © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved new new new
  • 25. Amazon Comprehend © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 26. Use Cases Text Analytics Search Optimization Knowledge Discovery Classification Amazon Comprehend © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 27. Sentiment Analysis The Sentiment Analysis API returns the overall sentiment of a text (Positive, Negative, Neutral, or Mixed). Can't wait to visit rainforest again! Such a magical place... Analysis Examples positive: 0.95 | negative: 0.0 | neutral: 0.03 | mixed: 0.0 Been there twice and won't go ever again. Bad and not getting better... positive: 0.01 | negative: 0.96 | neutral: 0.01 | mixed: 0.0 The Sun is a G-type main-sequence star (G2V) based on its spectral class. positive: 0.02 | negative: 0.0 | neutral: 0.96 | mixed: 0.0 The food was great but the service could be improved. positive: 0.08 | negative: 0.01 | neutral: 0.0 | mixed: 0.89 Comprehend Sentiment Analysis © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 28. Named Entity Recognition Amazon.com, Inc. is located in Seattle, WA and was founded July 5th, 1994 by Jeff Bezos , allowing customers to buy everything from books to blenders. Seattle is north of Portland and south of Vancouver, BC . Other notable Seattle -based companies are Starbucks and Boeing . PERSON LOCATION ORGANIZATION COMMERCIAL_ITEM EVENT DATE QUANTITY TITLE OTHER ORGANIZATION DATE LOCATION PERSON LOCATION LOCATION LOCATION LOCATION ORGANIZATION ORGANIZATION Entity Types Recognition Example The Entity Recognition API returns the named entities ("People," "Places," "Locations," etc.) that are automatically categorized based on the provided text. Comprehend Entities Recognition © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 29. Keyphrase Extraction The Keyphrase Extraction API returns the key phrases or talking points and a confidence score to support that this is a key phrase. I'm an avid photographer , and I'm primarily found shooting with my DSLR or my instant film camera that I carry around for casual use . While nothing beats my DSLR in power and convenience , there's something magical about my instant film camera . Extraction Example Comprehend Keyphrase Extraction © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 30. Language Detection The Language Detection API automatically identifies text written in over 100 languages and returns the dominant language with a confidence score to support that a language is dominant. Amazon Elastic Compute Cloud (Amazon EC2) Ăš un servizio Web che fornisce capacitĂ  di elaborazione sicura e scalabile nel cloud. È concepito per rendere piĂč semplice il cloud computing su scala Web per gli sviluppatori. Detection Example af | am | ar | as | az | ba be | bn | bs | bg | ca | ceb cs | cv | cy | da | de | el en | eo | et | eu | fa | fi fr | gd | ga | gl | gu | ht he | hi | hr | hu | hy | ilo id | is | it | jv | ja | kn ka | kk | km | ky | ko | ku la | lv | lt | lb | ml | mr mk | mg | mn | ms | my | ne new | nl | no | or | pa | pl pt | ps | qu | ro | ru | sa si | sk | sl | sd | so | es sq | sr | su | sw | sv | ta tt | te | tg | tl | th | tk tr | ug | uk | ur | uz | vi yi | yo | zh | zh-TW Italian: 0.99 Comprehend Language Detection © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 31. Syntax Analysis The Amazon Comprehend Syntax API enables customers to analyze text using tokenization and Parts of Speech (PoS), and identify word boundaries and labels like nouns and adjectives within the text. He also investigated the thermal properties of light which laid the foundation of the photon theory of light . In 1917 . PRON ADJ ADP ADV AUX CONJ DET INTJ NOUN NUM PoS Tags Comprehend Syntax Analysis O PART PRON PROPN PUNCT SCONJ SYM VERB DET ADV VERB ADJ NOUN ADP NOUN PRON VERB DET NOUN ADP DET NOUN NOUN ADP NOUN PUNCT ADP NUM PUNCT Analysis Example © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 32. Input document 1 Input document 2 Custom Classification (Multi-Class) CLASS_1 CLASS_1 CLASS_2 CLASS_3 CLASS_4 ... Training DOC_1 DOC_2 DOC_3 DOC_4 DOC_5 ... The Custom Classification API enables you to easily build custom text classification models using your business-specific labels without learning ML. Comprehend Custom Classification Classification CLASS_1: 0.85 | CLASS_2: 0.1 | CLASS_4: 0.4 CLASS_2: 0.05 | CLASS_3: 0.76 | CLASS_4: 0.23 © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 33. Custom Classification (Multi-Label) LABEL_1 | LABEL_2 LABEL_3 LABEL_3 | LABEL_4 | LABEL_5 LABEL_1 | LABEL_3 | LABEL_6 ... Training DOC_1 DOC_2 DOC_3 DOC_4 DOC_5 ... Multi-label Text Classification provides ability to tag documents with multiple labels at the same time (unlike mult-class mode, where each document is associated with a single class). Comprehend Custom Classification Classification LABEL_3: 0.34 | LABEL_4: 0.87 © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved new LABEL_5: 0.26 Input document 2 LABEL_3: 0.73 | LABEL_6: 0.78 LABEL_1: 0.51 | LABEL_2: 0.93 LABEL_6: 0.85 Input document 1
  • 34. Custom Entities File Doc1 Doc2 ... Annotations Mode Line 0 1 ... Begin Offset 10 0 ... Begin Offset 23 8 ... Type LAWYER JUDGE ... Text John Bob Roy ... Entity List Mode Type LAWYER LAWYER JUDGE ... Custom Entities allows you to customize Amazon Comprehend to identify terms that are specific to your domain. Robert Shelby , who in June 2018 imposed a preliminary injunction stopping the sales while the suit was litigated, ruled on motions by both sides seeking summary judgment. JUDGE Recognition Example Comprehend Custom Entities or © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 35. Topic Modeling Topic Modeling identifies relevant terms or topics from a collection of documents stored in Amazon S3. It will identify the most common topics in the collection and organize them in groups and then map which documents belong to which topic. Comprehend Topic Modeling Topic 1 1 2 2. Topic Terms Term Amazon Seattle Holidays Shopping Weight 0.87 0.13 0.78 0.22 Document Doc1.txt Doc2.txt Doc3.txt Doc4.txt Topics Topic 1 1 2 2 Proportion 0.87 0.65 0.78 0.67 Input Documents © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved
  • 36. Q&A Egor Pushkin https://www.linkedin.com/in/egorpushkin/ @egorpushkin © 2020 Amazon Web Services, Inc. or its affiliates. All rights reserved