Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Machine Learning and Sentiment Classification i...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Matt D.
May 30, 2011
Programming
1
1k
Machine Learning and Sentiment Classification in Ruby
Matt D.
May 30, 2011
Tweet
Share
Other Decks in Programming
See All in Programming
Spinner 軸ズレ現象を調べたらレンダリング深淵に飲まれた #レバテックMeetup
bengo4com
1
230
CSC307 Lecture 07
javiergs
PRO
0
550
LLM Observabilityによる 対話型音声AIアプリケーションの安定運用
gekko0114
2
430
AIと一緒にレガシーに向き合ってみた
nyafunta9858
0
220
KIKI_MBSD Cybersecurity Challenges 2025
ikema
0
1.3k
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
550
Oxlintはいいぞ
yug1224
5
1.3k
CSC307 Lecture 01
javiergs
PRO
0
690
izumin5210のプロポーザルのネタ探し #tskaigi_msup
izumin5210
1
110
今から始めるClaude Code超入門
448jp
8
8.6k
15年続くIoTサービスのSREエンジニアが挑む分散トレーシング導入
melonps
2
190
AgentCoreとHuman in the Loop
har1101
5
230
Featured
See All Featured
The Spectacular Lies of Maps
axbom
PRO
1
520
Designing Powerful Visuals for Engaging Learning
tmiket
0
230
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
0
170
Faster Mobile Websites
deanohume
310
31k
Bash Introduction
62gerente
615
210k
Rails Girls Zürich Keynote
gr2m
96
14k
sira's awesome portfolio website redesign presentation
elsirapls
0
150
Become a Pro
speakerdeck
PRO
31
5.8k
How to Ace a Technical Interview
jacobian
281
24k
Making Projects Easy
brettharned
120
6.6k
Designing Experiences People Love
moore
144
24k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
450
Transcript
.BDIJOF -FBSOJOH BOE 4FOUJNFOU $MBTTJGJDBUJPO JO 3VCZ by Matt Drozdzynski
@matid
None
.BDIJOF -FBSOJOH … or how to teach your computer to
do back flips for you.
4FOUJNFOU $MBTTJGJDBUJPO … or how to quantify people’s opinions.
#euruko is definitely the most amazing Ruby conference ever!
I’ve been to many dreadful conferences, but #euruko is certainly
not one of them.
Ruby is a true delight compared to how horrendous Java
can be.
d JO 3VCZ
None
None
%BUB (BUIFSJOH
None
None
-BOHVBHF "DDVSBDZ 0% 25% 50% 75% 100% 2007 English Spanish
German Italian Polish
"OOPUBUJPOT … or I have the tweets—now what?
%BUB $MFBOJOH … or how to separate wheat from the
chaff.
'FBUVSF 3FEVDUJPO … or Matt’s crash course in selective ignorance.
$MBTTJGJDBUJPO … and the ‘not so rocket’ science behind it
all.
/BJWF #BZFT Simple and robust Assumes independence of features Scalable!
require "ankusa" require "ankusa/memory_storage" storage = Ankusa::MemoryStorage.new classifier = Ankusa::NaiveBayesClassifier.new(storage)
training.each do |tweet| classifier.train tweet.sentiment, tweet.to_s end sentiment = classifier.classify tweet.to_s
.BYJNVN &OUSPQZ No independence assumptions Suffers from overfitting Substantially slower
than Naive Bayes
require "maxent_string_classifier" classifier = MaxentStringClassifier::Loader.train(Classifier.root + "max_ent" + "data") classification
= classifier.classify tweet.to_s
4VQQPSU 7FDUPS .BDIJOFT Non-probabilistic binary linear classifier Only directly applicable
to two-class problems “Works by constructing a set of hyperplanes in a high or infinite dimensional space”—what?
None
require "eluka" classifier = Eluka::Model.new training.each do |tweet| classifier.add(tweet.features, tweet.sentiment)
end classifier.build sentiment = classifier.classify tweet.features
$PODMVTJPOT … or is the whole thing worth the hassle?
2VFTUJPOT
@matid spkr8.com/t/7678 bit.ly/matid-dissertation bit.ly/matid-dissertation-pdf 5IBOLT