Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Introduction_to_ZeroshotLearning
Search
payanotty
September 08, 2022
350
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Introduction_to_ZeroshotLearning
payanotty
September 08, 2022
More Decks by payanotty
See All by payanotty
トークナイザー入門
payanotty
5
2.7k
LLM_Prompt_Recovery
payanotty
3
1.1k
Embeddingモデルを使ったベクトル化のしくみ、fine-tuning手法を解説
payanotty
15
6.5k
Transformerによるテキストベクトル化を解説
payanotty
6
4.3k
Kaggle_LLMコンペの攻略法を解説.pdf
payanotty
1
1.7k
ManimMLでイケてるアニメーションを作ろう
payanotty
0
860
Lets Finetune LLM
payanotty
3
1.5k
Stable Diffusion Web UI, Let Your Fave Eat Ramen
payanotty
1
1.2k
Lets Finetune Stable Diffusion
payanotty
0
1.4k
Featured
See All Featured
GitHub's CSS Performance
jonrohan
1033
470k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
380
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
More Than Pixels: Becoming A User Experience Designer
marktimemedia
3
520
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
56
3.5k
Code Reviewing Like a Champion
maltzj
528
40k
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
700
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
3k
Between Models and Reality
mayunak
4
450
Bash Introduction
62gerente
615
220k
Scaling GitHub
holman
464
140k
Heart Work Chapter 1 - Part 1
lfama
PRO
9
36k
Transcript
Zeroshot Text Classification さっくり解説 早野康太
自己紹介 • 名前 ◦ 早野 康太 • お仕事 ◦ 自然言語モデルの改善
• 趣味 ◦ 猫、犬 ▪ YouTube ◦ ゲーム ▪ 音ゲ、遊戯王MD ◦ アニメ ▪ リコリコやばくない?
Zeroshot Learningとは • 見たことないクラスのものを 正しく分類できるようなモデルを学習する
Zeroshot Learningとは • 見たことないクラスのものを 正しく分類できるようなモデルを学習する
Zeroshot Learningとは • 見たことないクラスのものを 正しく分類できるようなモデルを学習する
Zeroshot Learningとは • 見たことないクラスのものを 正しく分類できるようなモデルを学習する • Zeroshot → 学習データにCATが全くない •
Fewshot → 学習データにCATが めちゃくちゃ少ないけどある
Zeroshot Learningとは • 役に立ちそうな場面 ◦ データのラベル付けが難しい場合 (専門知識が必要など) ◦ ラベル付けされたデータが大量に用意できない場合 ◦
データ収集時点で想定していなかった 新しいラベルのデータに対して分類が求められる場合
自然言語におけるZeroshot学習 • 文章をモデルにぶちこんで 意味が”それっぽい”かどうかを判定させる (Entailment Approach) ◦ Benchmarking Zero-shot Text
Classification: Datasets, Evaluation and Entailment Approach
自然言語におけるZeroshot学習 吾輩は猫である。 分類したい文章 Hypothesis これは犬の文だ。 Entailment Score + 0.50 吾輩は猫である。
これは鳥の文だ。 + 0.12 = = これは{}の文だ。 Hypothesis Template
自然言語におけるZeroshot学習 吾輩は猫である。 分類したい文章 Hypothesis これは犬の文だ。 Entailment Score + 0.50 吾輩は猫である。
これは鳥の文だ。 + 0.12 = = 吾輩は猫である。 これは猫の文だ。 + 0.61 = これは{}の文だ。 学習していないラベル: 猫 Hypothesis Template
• Bidirectional Encoder Representations from Transformers ◦ BERT: Pre-training of
Deep Bidirectional Transformers for Language Understanding ◦ Transformerによる双方向のエンコード表現 ▪ Transformerモデルの一部分を利用したモデル ◦ Googleが2018年に発表 • 当時の自然言語処理タスクの最高記録を軒並み塗り替えた • fine-tuningにより あらゆる自然言語処理タスクに応用可能な汎用性の高さ Zeroshot ✕ BERT
TransformersでZeroshot • Transformers ◦ さまざまな自然言語の事前学習済みモデルを 利用することができるライブラリ ◦ ZeroshotClassificationPipelineを使えば 簡単にZeroshot分類を試すことができる ▪
Pipelines — transformers 4.5.0.dev0 documentation ▪ が、日本語のPretrained ModelはModel Hubで全然公開されていない • 日本語でやる場合は自分でモデルを作る必要あり • 例えばこういうデータセットを使うなど ◦ 日本語SNLI(JSNLI)データセット - KUROHASHI-CHU-MURAWAKI LAB
まとめ • Zeroshot Learningとは ◦ 学習していないラベルのデータを予測しようとする試み • 自然言語分野では、”これは{}の文だ”のように テンプレートにラベル名を埋め込んでEntailmentスコアを計算する方法が
試されている ◦ TransformersライブラリでもZeroshotPipelineが利用可能なので 興味があれば試してみるのもおもしろいかも