Data-driven AI · classical modelsAI berbasis data · model klasik
Five classic ways a machine learns from examplesLima cara klasik mesin belajar dari contoh
Instead of searching for a solution, these models are shown labelled data and must generalise from it. Each tab is one classic learner — fitting, voting, separating, splitting, or counting. Edit the data by clicking on the canvas and watch the model's belief change.
Alih-alih mencari solusi, model-model ini diperlihatkan data berlabel dan harus menggeneralisasi darinya. Tiap tab adalah satu learner klasik — mencocokkan, memungut suara, memisahkan, membelah, atau menghitung. Sunting datanya dengan mengeklik kanvas dan lihat keyakinan model berubah.
Fit a curve to noisy pointsCocokkan kurva ke titik berderau
Regression finds the polynomial that minimises squared error on training points — solved in one shot from the normal equations, no search needed. Raise the degree and the curve hugs the training data ever more tightly, while error on held-out test points starts to climb: overfitting, live.
Regresi mencari polinomial yang meminimalkan galat kuadrat pada titik latih — diselesaikan sekali jalan dari persamaan normal, tanpa pencarian. Naikkan derajatnya dan kurva memeluk data latih makin erat, sementara galat pada titik uji yang disisihkan mulai menanjak: overfitting, langsung.
DataData
Click to add point as
ModelModel
Train MSE
–
Test MSE
–
R² (train)
–
Data & fitted curveData & kurva terfit
train pointtitik latihtest point (never seen in fitting)titik uji (tak dilihat saat fit)fitted polynomialpolinomial terfitresidualresidu
log₁₀ MSE vs polynomial degree — the overfitting picturelog₁₀ MSE vs derajat polinomial — gambar overfitting
train errorgalat latihtest errorgalat ujicurrent degreederajat saat ini
Let the nearest neighbors voteBiarkan tetangga terdekat memilih
k-NN never really "trains" — it memorises every example and, at query time, lets the k closest ones vote. Small k gives a jagged, noise-chasing boundary; large k smooths it out. Move your mouse over the canvas to interrogate any point.
k-NN tak benar-benar "berlatih" — ia menghafal tiap contoh dan, saat kueri, membiarkan k terdekat memilih. k kecil memberi batas bergerigi yang mengejar derau; k besar menghaluskannya. Gerakkan mouse di atas kanvas untuk menyelidiki titik mana pun.
DataData
Click to add point of classKlik untuk menambah titik kelas
ModelModel
Stored examplesContoh tersimpan
0
Leave-one-out accuracyAkurasi leave-one-out
–
Hovered point → classTitik tersorot → kelas
–
Hover the canvas: the k neighbors of your cursor are wired up and their vote decides the colour under it. Click to drop a new training point of the selected class.
Arahkan mouse ke kanvas: k tetangga kursormu terhubung dan suara mereka menentukan warna di bawahnya. Klik untuk menaruh titik latih baru dari kelas terpilih.
Decision mapPeta keputusan
class Akelas Aclass Bkelas Bclass Ckelas Cregion a query would be classified intowilayah tempat kueri akan diklasifikasikan
Find the widest street between two classesCari jalan terlebar antara dua kelas
A support vector machine places the boundary that keeps the biggest possible margin to both classes. Only the ringed points — the support vectors — hold the boundary up; every other point could vanish and nothing would move. Kernels bend the margin around non-linear data.
Support vector machine menempatkan batas yang menjaga margin sebesar mungkin ke kedua kelas. Hanya titik bercincin — para support vector — yang menopang batas itu; titik lain boleh lenyap dan tak ada yang bergeser. Kernel melengkungkan margin di sekitar data non-linear.
DataData
Click to add point of classKlik untuk menambah titik kelas
ModelModel
Train accuracyAkurasi latih
–
Support vectorsSupport vector
–
SMO iterationsIterasi SMO
–
Low C = a wide, forgiving street that tolerates points inside the margin. High C = a strict street that bends to classify everything. With the RBF kernel, γ controls how local each support vector's influence is.
C rendah = jalan lebar dan pemaaf yang menoleransi titik di dalam margin. C tinggi = jalan ketat yang melengkung demi mengklasifikasi semuanya. Dengan kernel RBF, γ mengatur seberapa lokal pengaruh tiap support vector.
Decision boundary & marginBatas keputusan & margin
class +1kelas +1class −1kelas −1support vectorsupport vectorinside the margin (|f| < 1)di dalam margin (|f| < 1)
Ask yes/no questions until the classes separateAjukan pertanyaan ya/tidak sampai kelasnya terpisah
A decision tree carves the plane with axis-aligned cuts, each chosen to reduce impurity as much as possible. Grow it one split at a time and watch the map and the tree diagram evolve together — and notice how it struggles with diagonal boundaries it can only approximate with staircases.
Pohon keputusan mengukir bidang dengan potongan sejajar sumbu, masing-masing dipilih untuk mengurangi ketakmurnian sebanyak mungkin. Tumbuhkan satu pembelahan setiap kali dan lihat peta serta diagram pohon berevolusi bersama — dan perhatikan betapa ia kesulitan dengan batas diagonal yang hanya bisa didekati dengan tangga.
DataData
Click to add point of classKlik untuk menambah titik kelas
ModelModel
GrowingMenumbuhkan
DepthKedalaman
0
LeavesDaun
1
Train accuracyAkurasi latih
–
Partitioned planeBidang terpartisi
The tree itselfPohonnya sendiri
Model each class as a bell curve, then apply BayesModelkan tiap kelas sebagai kurva lonceng, lalu terapkan Bayes
Gaussian Naive Bayes fits an independent normal distribution to every feature of every class — the "naive" assumption. Classifying a point is just Bayes' rule: prior × likelihood, class with highest posterior wins. The whole model is a handful of means and variances.
Gaussian Naive Bayes mencocokkan distribusi normal independen ke tiap fitur tiap kelas — asumsi "naif" itu. Mengklasifikasi sebuah titik hanyalah aturan Bayes: prior × likelihood, kelas dengan posterior tertinggi menang. Seluruh modelnya hanya segenggam rerata dan ragam.
DataData
Click to add point of classKlik untuk menambah titik kelas
ModelModel
Train accuracyAkurasi latih
–
Priors P(class)Prior P(kelas)
–
Parameters learnedParameter dipelajari
–
Solid ellipse = 1σ of the fitted Gaussian, dashed = 2σ, cross = mean. Because features are assumed independent, ellipses are always axis-aligned — try the "different shapes" preset to see what that assumption buys and costs.
Elips penuh = 1σ dari Gaussian terfit, putus-putus = 2σ, silang = rerata. Karena fitur diasumsikan independen, elips selalu sejajar sumbu — coba praatur "bentuk berbeda" untuk melihat apa untung-ruginya asumsi itu.
Classify email by counting wordsKlasifikasi email dengan menghitung kata
The classic spam filter: count how often each word appears in spam vs. legitimate mail, then multiply those likelihoods together with Bayes' rule. Type a message and watch each word push the verdict one way or the other. Laplace smoothing keeps one unseen word from zeroing everything out.
Filter spam klasik: hitung seberapa sering tiap kata muncul di spam vs. surat sah, lalu kalikan likelihood-nya dengan aturan Bayes. Ketik sebuah pesan dan lihat tiap kata mendorong vonis ke satu arah atau lainnya. Laplace smoothing menjaga satu kata yang tak pernah dilihat agar tak menolkan semuanya.
Your messagePesanmu
Teach the filterAjari filternya
ModelModel
Training messagesPesan latih
–
Vocabulary sizeUkuran kosakata
–
P(spam | message)
–
Word-by-word evidence for your messageBukti kata-demi-kata untuk pesanmu
wordkata
seen in spammuncul di spam
seen in hammuncul di ham
pulls toward … (log-likelihood ratio)condong ke … (rasio log-likelihood)
Most telling words in the corpusKata paling menentukan di korpus