SlideShare a Scribd company logo
1 of 26
Download to read offline
Relational
Knowledge and
Language Models
Cardiff NLP Reading Group
Asahi Ushio
Cardiff University
Language Model Pretraining
● Large scale language model is now a huge trend
● Many architectures (seq2seq, uni/bi-directional,
non-autoregressive, external knowledge, etc)
● Growing data/model size
What actually language model knows?
Agenda
An overview of recent study in “relational knowledge
understanding in pretrained language models”
- Petroni, et al. "Language models as knowledge bases?" 2019
- Jiang, et al. "How can we know what language models know?"
2019
- Bouraoui, et al. "Inducing relational knowledge from BERT."
2019
What LM knows?
Petroni, et al. "Language models as knowledge bases?"
LM knows the fact
“Dante was born in Florence”
It’s a knowledge graph!
Petroni, et al. "Language models as knowledge bases?"
LM knows the fact
“Dante was born in Florence”
KG includes the fact
“(Dante, born-in, Florence)”
Dataset
Petroni, et al. "Language models as knowledge bases?"
● Dataset requirements:
○ Each entry has (prompt, answer)
■ eg) (Dante was born in, Florence)
○ Answer should be single token
○ Query should represent relational knowledge given a head and a
relation in a KG
■ eg) Dante was born in = (Dante, born-in)
Whole pipeline
Petroni, et al. "Language models as knowledge bases?"
KG
Prompting
( head, relation, tail ) ( query, tail )
LM (BERT, etc)
Dataset generation
Model evaluation
eg) (Dante, born-in, Florence)
eg) Dante was born-in
Results
Petroni, et al. "Language models as knowledge bases?"
BERT Large
Effect of prompt type
What’s the best prompt? 🤔
KG
Prompting
( head, relation, tail ) ( query, tail )
Dataset generation
eg) (Dante, born-in, Florence)
● Dante was born-in Florence.
● Florence is where Dante was born
● Dante was born-in Florence, Italy.
● etc
Jiang, et al. "How can we know what language models know?"
Prompt ensembling/selection
● Prompting methods
○ Manual
○ Mined: Frequency in a large corpus
○ Paraphrased: Back-translation
● Ensembling prompt
○ Optimization over training set
● Data:
○ Test: T-Rex
○ Training: Wikidata
Jiang, et al. "How can we know what language models know?"
Improve manual prompt
Jiang, et al. "How can we know what language models know?"
Ensembling
Averaging
Mined prompts
Jiang, et al. "How can we know what language models know?"
Paraphrased prompts
Jiang, et al. "How can we know what language models know?"
Ensembling weight
Jiang, et al. "How can we know what language models know?"
Issue with link prediction
● Spurious correlation among subject and object
○ Birds cannot [MASK] → fly, Kassner and Schütze, 2020
○ The capital of Macintosh is [MASK] → apple, Bouraoui, et al. 2019
● Heuristics on surface form
○ BERT is very good at IR, Petroni, et al. 2020
Relation classification
Bouraoui, et al. "Inducing relational knowledge from BERT."
KG
Prompting
( head, relation, tail ) ( sentence, relation )
Dataset generation
Model training
LM + Linear
Model evaluation
LM + Linear
eg) (Dante, born-in, Florence) eg) (Dante was born-in Florence, born-in)
Template search and prompt
Bouraoui, et al. "Inducing relational knowledge from BERT."
1) Extract sentences over all (head, tail)
⇒ relation template candidates
2) BERT-based filtering
⇒ find template to the relation
Wikipedia
KG (training set)
( relation, template )
Prompting
sent rel A: False
sent rel B: False
sent rel C: True
Classification result
Bouraoui, et al. "Inducing relational knowledge from BERT."
word embedding
language model
Result breakdown: Google
Bouraoui, et al. "Inducing relational knowledge from BERT."
Result breakdown: DiffVec
Bouraoui, et al. "Inducing relational knowledge from BERT."
Result breakdown: BATS
Bouraoui, et al. "Inducing relational knowledge from BERT."
Recap
Link prediction: finetuning-free, but other factors
- Petroni, et al. "Language models as knowledge bases?" 2019
- Jiang, et al. "How can we know what language models know?"
2019
Relation classification: relation evaluation, but finetuning
- Bouraoui, et al. "Inducing relational knowledge from BERT."
2019
Limitation/Open issue
● Object with multiple tokens
● Better template
● More dataset
● Effect on other tasks
● etc...
Thanks for listening 🎉
Related Topic
1. KB augmented LM
○ Latent Relation LMs, KnowBERT, COMET
2. LM training with KB
○ RAG, REALM
3. LM inference with KB
○ kNN-LM, BERT-kNN, IR+BERT
4. KB completion
○ Commonsense KB completion, LMs are open KG
LM
KB
LM KB
Learnable
LM KB
Learnable
LM KB
Learnable
Comment given to the talk
● We need to differentiate LM as a language generator and
fact retriever
● BPE subword handling
● More complex reasoning

More Related Content

Similar to 2020-12, Cardiff NLP Reading Group, Commonsense Knowledge Probing

Hoopingarner.Actfl2008
Hoopingarner.Actfl2008Hoopingarner.Actfl2008
Hoopingarner.Actfl2008dhoopingarner
 
Mini seminar presentation on context-based NED optimization
Mini seminar presentation on context-based NED optimizationMini seminar presentation on context-based NED optimization
Mini seminar presentation on context-based NED optimizationFilip Ilievski
 
Portuguese Linguistic Tools: What, Why and How
Portuguese Linguistic Tools: What, Why and HowPortuguese Linguistic Tools: What, Why and How
Portuguese Linguistic Tools: What, Why and HowValeria de Paiva
 
2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...
2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...
2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...asahiushio1
 
The future of language learning in virtual worlds
The future of language learning in virtual worldsThe future of language learning in virtual worlds
The future of language learning in virtual worldsUniversity of Hawaii
 
Sample Of A Cause And Effect Essay
Sample Of A Cause And Effect EssaySample Of A Cause And Effect Essay
Sample Of A Cause And Effect EssayKathy Murray
 
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 CALLLawrie Hunter
 
Module 8: Natural language processing Pt 1
Module 8:  Natural language processing Pt 1Module 8:  Natural language processing Pt 1
Module 8: Natural language processing Pt 1Sara Hooker
 
ChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptx
ChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptxChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptx
ChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptxapicciano
 
CUNY IT Picciano.pptx
CUNY IT Picciano.pptxCUNY IT Picciano.pptx
CUNY IT Picciano.pptxapicciano
 
Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...
Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...
Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...eaquals
 
Presentation alex
Presentation alexPresentation alex
Presentation alexAlex Curtis
 
Should we be afraid of Transformers?
Should we be afraid of Transformers?Should we be afraid of Transformers?
Should we be afraid of Transformers?Dominik Seisser
 
Leu Iespp Final
Leu Iespp FinalLeu Iespp Final
Leu Iespp Finaldjleu
 

Similar to 2020-12, Cardiff NLP Reading Group, Commonsense Knowledge Probing (20)

lexicographic evidence
lexicographic evidencelexicographic evidence
lexicographic evidence
 
Hoopingarner.Actfl2008
Hoopingarner.Actfl2008Hoopingarner.Actfl2008
Hoopingarner.Actfl2008
 
Mini seminar presentation on context-based NED optimization
Mini seminar presentation on context-based NED optimizationMini seminar presentation on context-based NED optimization
Mini seminar presentation on context-based NED optimization
 
Portuguese Linguistic Tools: What, Why and How
Portuguese Linguistic Tools: What, Why and HowPortuguese Linguistic Tools: What, Why and How
Portuguese Linguistic Tools: What, Why and How
 
2103 ACM FAccT
2103 ACM FAccT2103 ACM FAccT
2103 ACM FAccT
 
2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...
2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...
2021-05, ACL, BERT is to NLP what AlexNet is to CV: Can Pre-Trained Language ...
 
Parameter setting
Parameter settingParameter setting
Parameter setting
 
The future of language learning in virtual worlds
The future of language learning in virtual worldsThe future of language learning in virtual worlds
The future of language learning in virtual worlds
 
Sample Of A Cause And Effect Essay
Sample Of A Cause And Effect EssaySample Of A Cause And Effect Essay
Sample Of A Cause And Effect Essay
 
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
 
Module 8: Natural language processing Pt 1
Module 8:  Natural language processing Pt 1Module 8:  Natural language processing Pt 1
Module 8: Natural language processing Pt 1
 
2104 Talk @SSU
2104 Talk @SSU2104 Talk @SSU
2104 Talk @SSU
 
Euro Exam
Euro Exam Euro Exam
Euro Exam
 
ChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptx
ChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptxChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptx
ChatGPT - ADSUP 717 New PPT Revised 1 1 1 1 1 1.pptx
 
CUNY IT Picciano.pptx
CUNY IT Picciano.pptxCUNY IT Picciano.pptx
CUNY IT Picciano.pptx
 
Suzana_Delic
Suzana_DelicSuzana_Delic
Suzana_Delic
 
Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...
Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...
Andrew Bax & Bruce Bax: Using an online tool to benchmark texts to the CEFR: ...
 
Presentation alex
Presentation alexPresentation alex
Presentation alex
 
Should we be afraid of Transformers?
Should we be afraid of Transformers?Should we be afraid of Transformers?
Should we be afraid of Transformers?
 
Leu Iespp Final
Leu Iespp FinalLeu Iespp Final
Leu Iespp Final
 

More from asahiushio1

2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...
2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...
2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...asahiushio1
 
2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...
2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...
2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...asahiushio1
 
2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...
2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...
2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...asahiushio1
 
2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...
2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...
2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...asahiushio1
 
2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...
2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...
2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...asahiushio1
 
2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...
2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...
2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...asahiushio1
 

More from asahiushio1 (6)

2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...
2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...
2022-11, AACL, Named Entity Recognition in Twitter: A Dataset and Analysis on...
 
2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...
2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...
2022-10, UCL NLP meetup, Toward a Better Understanding of Relational Knowledg...
 
2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...
2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...
2017-12, Keio University, Projection-based Regularized Dual Averaging for Sto...
 
2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...
2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...
2017-07, Research Seminar at Keio University, Metric Perspective of Stochasti...
 
2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...
2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...
2017-03, ICASSP, Projection-based Dual Averaging for Stochastic Sparse Optimi...
 
2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...
2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...
2021-04, EACL, T-NER: An All-Round Python Library for Transformer-based Named...
 

Recently uploaded

G9 Science Q4- Week 1-2 Projectile Motion.ppt
G9 Science Q4- Week 1-2 Projectile Motion.pptG9 Science Q4- Week 1-2 Projectile Motion.ppt
G9 Science Q4- Week 1-2 Projectile Motion.pptMAESTRELLAMesa2
 
Boyles law module in the grade 10 science
Boyles law module in the grade 10 scienceBoyles law module in the grade 10 science
Boyles law module in the grade 10 sciencefloriejanemacaya1
 
Orientation, design and principles of polyhouse
Orientation, design and principles of polyhouseOrientation, design and principles of polyhouse
Orientation, design and principles of polyhousejana861314
 
Stunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCR
Stunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCRStunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCR
Stunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCRDelhi Call girls
 
Natural Polymer Based Nanomaterials
Natural Polymer Based NanomaterialsNatural Polymer Based Nanomaterials
Natural Polymer Based NanomaterialsAArockiyaNisha
 
Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.aasikanpl
 
Cultivation of KODO MILLET . made by Ghanshyam pptx
Cultivation of KODO MILLET . made by Ghanshyam pptxCultivation of KODO MILLET . made by Ghanshyam pptx
Cultivation of KODO MILLET . made by Ghanshyam pptxpradhanghanshyam7136
 
Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Nistarini College, Purulia (W.B) India
 
Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.aasikanpl
 
Biopesticide (2).pptx .This slides helps to know the different types of biop...
Biopesticide (2).pptx  .This slides helps to know the different types of biop...Biopesticide (2).pptx  .This slides helps to know the different types of biop...
Biopesticide (2).pptx .This slides helps to know the different types of biop...RohitNehra6
 
Spermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatidSpermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatidSarthak Sekhar Mondal
 
Recombination DNA Technology (Nucleic Acid Hybridization )
Recombination DNA Technology (Nucleic Acid Hybridization )Recombination DNA Technology (Nucleic Acid Hybridization )
Recombination DNA Technology (Nucleic Acid Hybridization )aarthirajkumar25
 
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...Lokesh Kothari
 
STERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCE
STERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCESTERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCE
STERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCEPRINCE C P
 
Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...
Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...
Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...Sérgio Sacani
 
Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...
Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...
Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...jana861314
 
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43bNightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43bSérgio Sacani
 
SOLUBLE PATTERN RECOGNITION RECEPTORS.pptx
SOLUBLE PATTERN RECOGNITION RECEPTORS.pptxSOLUBLE PATTERN RECOGNITION RECEPTORS.pptx
SOLUBLE PATTERN RECOGNITION RECEPTORS.pptxkessiyaTpeter
 
Biological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdfBiological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdfmuntazimhurra
 
Grafana in space: Monitoring Japan's SLIM moon lander in real time
Grafana in space: Monitoring Japan's SLIM moon lander  in real timeGrafana in space: Monitoring Japan's SLIM moon lander  in real time
Grafana in space: Monitoring Japan's SLIM moon lander in real timeSatoshi NAKAHIRA
 

Recently uploaded (20)

G9 Science Q4- Week 1-2 Projectile Motion.ppt
G9 Science Q4- Week 1-2 Projectile Motion.pptG9 Science Q4- Week 1-2 Projectile Motion.ppt
G9 Science Q4- Week 1-2 Projectile Motion.ppt
 
Boyles law module in the grade 10 science
Boyles law module in the grade 10 scienceBoyles law module in the grade 10 science
Boyles law module in the grade 10 science
 
Orientation, design and principles of polyhouse
Orientation, design and principles of polyhouseOrientation, design and principles of polyhouse
Orientation, design and principles of polyhouse
 
Stunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCR
Stunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCRStunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCR
Stunning ➥8448380779▻ Call Girls In Panchshil Enclave Delhi NCR
 
Natural Polymer Based Nanomaterials
Natural Polymer Based NanomaterialsNatural Polymer Based Nanomaterials
Natural Polymer Based Nanomaterials
 
Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Munirka Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
 
Cultivation of KODO MILLET . made by Ghanshyam pptx
Cultivation of KODO MILLET . made by Ghanshyam pptxCultivation of KODO MILLET . made by Ghanshyam pptx
Cultivation of KODO MILLET . made by Ghanshyam pptx
 
Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...
 
Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
Call Girls in Mayapuri Delhi 💯Call Us 🔝9953322196🔝 💯Escort.
 
Biopesticide (2).pptx .This slides helps to know the different types of biop...
Biopesticide (2).pptx  .This slides helps to know the different types of biop...Biopesticide (2).pptx  .This slides helps to know the different types of biop...
Biopesticide (2).pptx .This slides helps to know the different types of biop...
 
Spermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatidSpermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatid
 
Recombination DNA Technology (Nucleic Acid Hybridization )
Recombination DNA Technology (Nucleic Acid Hybridization )Recombination DNA Technology (Nucleic Acid Hybridization )
Recombination DNA Technology (Nucleic Acid Hybridization )
 
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
 
STERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCE
STERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCESTERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCE
STERILITY TESTING OF PHARMACEUTICALS ppt by DR.C.P.PRINCE
 
Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...
Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...
Discovery of an Accretion Streamer and a Slow Wide-angle Outflow around FUOri...
 
Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...
Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...
Traditional Agroforestry System in India- Shifting Cultivation, Taungya, Home...
 
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43bNightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
 
SOLUBLE PATTERN RECOGNITION RECEPTORS.pptx
SOLUBLE PATTERN RECOGNITION RECEPTORS.pptxSOLUBLE PATTERN RECOGNITION RECEPTORS.pptx
SOLUBLE PATTERN RECOGNITION RECEPTORS.pptx
 
Biological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdfBiological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdf
 
Grafana in space: Monitoring Japan's SLIM moon lander in real time
Grafana in space: Monitoring Japan's SLIM moon lander  in real timeGrafana in space: Monitoring Japan's SLIM moon lander  in real time
Grafana in space: Monitoring Japan's SLIM moon lander in real time
 

2020-12, Cardiff NLP Reading Group, Commonsense Knowledge Probing

  • 1. Relational Knowledge and Language Models Cardiff NLP Reading Group Asahi Ushio Cardiff University
  • 2. Language Model Pretraining ● Large scale language model is now a huge trend ● Many architectures (seq2seq, uni/bi-directional, non-autoregressive, external knowledge, etc) ● Growing data/model size What actually language model knows?
  • 3. Agenda An overview of recent study in “relational knowledge understanding in pretrained language models” - Petroni, et al. "Language models as knowledge bases?" 2019 - Jiang, et al. "How can we know what language models know?" 2019 - Bouraoui, et al. "Inducing relational knowledge from BERT." 2019
  • 4. What LM knows? Petroni, et al. "Language models as knowledge bases?" LM knows the fact “Dante was born in Florence”
  • 5. It’s a knowledge graph! Petroni, et al. "Language models as knowledge bases?" LM knows the fact “Dante was born in Florence” KG includes the fact “(Dante, born-in, Florence)”
  • 6. Dataset Petroni, et al. "Language models as knowledge bases?" ● Dataset requirements: ○ Each entry has (prompt, answer) ■ eg) (Dante was born in, Florence) ○ Answer should be single token ○ Query should represent relational knowledge given a head and a relation in a KG ■ eg) Dante was born in = (Dante, born-in)
  • 7. Whole pipeline Petroni, et al. "Language models as knowledge bases?" KG Prompting ( head, relation, tail ) ( query, tail ) LM (BERT, etc) Dataset generation Model evaluation eg) (Dante, born-in, Florence) eg) Dante was born-in
  • 8. Results Petroni, et al. "Language models as knowledge bases?" BERT Large
  • 9. Effect of prompt type What’s the best prompt? 🤔 KG Prompting ( head, relation, tail ) ( query, tail ) Dataset generation eg) (Dante, born-in, Florence) ● Dante was born-in Florence. ● Florence is where Dante was born ● Dante was born-in Florence, Italy. ● etc Jiang, et al. "How can we know what language models know?"
  • 10. Prompt ensembling/selection ● Prompting methods ○ Manual ○ Mined: Frequency in a large corpus ○ Paraphrased: Back-translation ● Ensembling prompt ○ Optimization over training set ● Data: ○ Test: T-Rex ○ Training: Wikidata Jiang, et al. "How can we know what language models know?"
  • 11. Improve manual prompt Jiang, et al. "How can we know what language models know?" Ensembling Averaging
  • 12. Mined prompts Jiang, et al. "How can we know what language models know?"
  • 13. Paraphrased prompts Jiang, et al. "How can we know what language models know?"
  • 14. Ensembling weight Jiang, et al. "How can we know what language models know?"
  • 15. Issue with link prediction ● Spurious correlation among subject and object ○ Birds cannot [MASK] → fly, Kassner and Schütze, 2020 ○ The capital of Macintosh is [MASK] → apple, Bouraoui, et al. 2019 ● Heuristics on surface form ○ BERT is very good at IR, Petroni, et al. 2020
  • 16. Relation classification Bouraoui, et al. "Inducing relational knowledge from BERT." KG Prompting ( head, relation, tail ) ( sentence, relation ) Dataset generation Model training LM + Linear Model evaluation LM + Linear eg) (Dante, born-in, Florence) eg) (Dante was born-in Florence, born-in)
  • 17. Template search and prompt Bouraoui, et al. "Inducing relational knowledge from BERT." 1) Extract sentences over all (head, tail) ⇒ relation template candidates 2) BERT-based filtering ⇒ find template to the relation Wikipedia KG (training set) ( relation, template ) Prompting sent rel A: False sent rel B: False sent rel C: True
  • 18. Classification result Bouraoui, et al. "Inducing relational knowledge from BERT." word embedding language model
  • 19. Result breakdown: Google Bouraoui, et al. "Inducing relational knowledge from BERT."
  • 20. Result breakdown: DiffVec Bouraoui, et al. "Inducing relational knowledge from BERT."
  • 21. Result breakdown: BATS Bouraoui, et al. "Inducing relational knowledge from BERT."
  • 22. Recap Link prediction: finetuning-free, but other factors - Petroni, et al. "Language models as knowledge bases?" 2019 - Jiang, et al. "How can we know what language models know?" 2019 Relation classification: relation evaluation, but finetuning - Bouraoui, et al. "Inducing relational knowledge from BERT." 2019
  • 23. Limitation/Open issue ● Object with multiple tokens ● Better template ● More dataset ● Effect on other tasks ● etc...
  • 25. Related Topic 1. KB augmented LM ○ Latent Relation LMs, KnowBERT, COMET 2. LM training with KB ○ RAG, REALM 3. LM inference with KB ○ kNN-LM, BERT-kNN, IR+BERT 4. KB completion ○ Commonsense KB completion, LMs are open KG LM KB LM KB Learnable LM KB Learnable LM KB Learnable
  • 26. Comment given to the talk ● We need to differentiate LM as a language generator and fact retriever ● BPE subword handling ● More complex reasoning