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
B3 コアタイム 第6回目 ( 2014年12月09日(火) )
Search
MIKAMI-YUKI
December 08, 2014
Education
170
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
B3 コアタイム 第6回目 ( 2014年12月09日(火) )
MIKAMI-YUKI
December 08, 2014
More Decks by MIKAMI-YUKI
See All by MIKAMI-YUKI
2016年_年次大会_発表資料
mikamiy
0
140
文献紹介_10_意味的類似性と多義解消を用いた文書検索手法
mikamiy
0
360
文献紹介_9_コーパスに基づく動詞の多義解消
mikamiy
0
140
文献紹介_8_単語単位による日本語言語モデルの検討
mikamiy
0
110
文献紹介_7_自動獲得した未知語の読み・文脈情報による仮名漢字変換
mikamiy
0
130
文献紹介_6_複数の言語的特徴を用いた日本語述部の同義判定
mikamiy
0
120
文献紹介_5_マイクロブログにおける感情・コミュニケーション・動作タイプの推定に基づく顔文字の推薦
mikamiy
0
160
文献紹介_4_結合価パターンを用いた仮名漢字変換候補の選択
mikamiy
0
420
文献紹介_3_絵本のテキストを対象とした形態素解析
mikamiy
1
430
Other Decks in Education
See All in Education
[2026前期火5] 論理学(京都大学文学部 前期 第6回)「かつとまたはの規則」
yatabe
0
510
輻射安全管理系統2.0暨輻防e++學園平台說明會
aecrp
0
2k
データマネジメント試験対策教材1〜データマネジメント基礎〜
yoshimura_datam
1
730
Tableau Public入門ハンズオン|Titanicデータで学ぶViz作成とMakeover
hayashi_ds017
0
130
新入社員を「あの子」と呼ばない運動 -PBL その前に- / Stop Calling New Hires "Kids"
aokiplayer
2
860
Comentario del plano urbano de Madrid hasta 1860 (1ª parte )
juanmartin2026
1
73k
20260908_ターゲットとスコープを決める発表法
masakiokuda
1
110
【新規入学者様】ZEPメタバース校舎ガイド
ainischool
0
140
良書紹介08_ 頭のいい子がやっているすごいグラフの読み方
bunnchinn3
0
160
チームの鏡になるー自分の癖を知ると、チームのパターンが見えてくる@スクフェス仙台
saorimurooka
0
180
形骸化しない社内勉強会の取り組み - オーナーシップの作り方 / In-house study session
soudai
PRO
1
270
2026年度春学期 統計学 第14回 分布についての仮説を検証する ― 仮説検定(1) (2026. 7. 2)
akiraasano
PRO
0
150
Featured
See All Featured
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.7k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
3
1.2k
Testing 201, or: Great Expectations
jmmastey
46
8.3k
Tell your own story through comics
letsgokoyo
1
1.1k
Deep Space Network (abreviated)
tonyrice
0
310
Principles of Awesome APIs and How to Build Them.
keavy
128
18k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
128
56k
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.6k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.6k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.8k
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
2
270
Applied NLP in the Age of Generative AI
inesmontani
PRO
4
2.5k
Transcript
「入門 自然言語処理」 5章:単語の分類とタグ付け B3 三上侑城
もくじ •タガーの利用 •タグ付きコーパス •ディクショナリ(重要) •自動タグ付け •Nグラムタグ付け
タガーの利用 ・品詞タガー それぞれの単語に品詞のタグを付ける。 >>> text = nltk.word_tokenize(“And now for something
completely different") >>> nltk.pos_tag(text)
タガーの利用 ここで出てくる分類名の意味 詳細は以下のようにタグを指定する。 >>> nltk.help.upenn_tagset(’CC’) 分類名 意味 CC 等位接続詞 RB
副詞 IN 前置詞 NN 名詞 JJ 形容詞
タグ付きコーパス ・str2suple() タグ付きトークンに変換 >>> tagged_token = nltk.tag.str2tuple('fly/NN') >>> tagged_token >>>
tagged_token[0] >>> tagged_token[1]
タグ付きコーパス ・タグ付きコーパスを読み込む NLTKにはタグ付きのサンプルがある。 例 >>> nltk.corpus.brown.tagged_words() >>> nltk.corpus.nps_chat.tagged_words()
ディクショナリ(P204~) ・ディクショナリ型と呼ばれるデータ型 ・リストには整数の添字を使ってアクセス ・マップ、ハッシュ、ハッシュマップとも 呼ばれる
ディクショナリ >>> pos = {} >>> pos >>> pos['colorless'] =
'ADJ' >>> pos >>> pos['ideas'] = 'N' >>> pos['sleep'] = 'V' >>> pos['furiously'] = 'ADV' >>> pos
ディクショナリ ・キー指定で値を得る >>> pos['ideas'] >>>pos['colorless'] ・ないものはエラーが出る。 >>>pos['green']
ディクショナリ ・リストに変換 >>> list(pos) ・キーを整列させる >>> sorted(pos)
ディクショナリ ・最後にsがつくものを探す >>> [w for w in pos if w.endswith('s')]
・ディクショナリの中身を全て表示 >>> for word in sorted(pos): ... print word + ":", pos[word]
ディクショナリ ・キーの一覧メソッド >>> pos.keys() ・値の一覧メソッド >>> pos.values() ・ペアの一覧メソッド >>> pos.items()
ディクショナリ ・ディクショナリを定義 >>> pos = {'colorless':'ADJ','ideas':'N','sleep' :'V','furiously':'ADV'}
ディクショナリ ・デフォルトディクショナリ 存在しないものにアクセス 通常→エラー デフォルトディクショナリ→自動生成 nltk.defaultdict()を使用する
ディクショナリ ・デフォルトディクショナリ 整数型の場合 >>> freq1 = {} >>> freq1['colorless'] =
4 >>> freq1['ideas'] #エラーが出る >>> freq2 = nltk.defaultdict(int) >>> freq2['colorless'] = 4 >>> freq2[‘ideas’] #エラーは出ない
ディクショナリ ・デフォルトディクショナリ リスト型の場合 >>> pos1 = {} >>> pos1['sleep'] =
['N','V'] >>> pos1['ideas'] #エラーが出る >>> pos2 = nltk.defaultdict(list) >>> pos2['sleep'] = ['N','V'] >>> pos2[‘ideas’] #エラーは出ない
ディクショナリ ・デフォルトディクショナリ デフォルト値の設定 >>> pos = nltk.defaultdict(lambda:'N') >>> pos['colorless'] =
'ADJ' >>> pos['blog'] #Nが自動的に入る >>> pos.items()
自動タグ付け ・テキストに自動的に品詞タグを付け てくれる。 ・様々なタガーがあり、それぞれに 特徴がある。 ・必要となった時に参照してもらい たい(P214~)
Nグラムタグ付け ・文脈を考慮してタグを付けてくれる ・いくつかのタガーを組み合わせて 使い、精度を高められる。 ・必要となった時に参照してもらい たい(P219~)