[{"data":1,"prerenderedAt":124},["ShallowReactive",2],{"term-c\u002Fclassification":3,"related-c\u002Fclassification":104},{"id":4,"title":5,"acronym":6,"body":7,"category":83,"description":84,"difficulty":85,"extension":86,"letter":87,"meta":88,"navigation":89,"path":90,"related":91,"seo":98,"sitemap":99,"stem":102,"subcategory":6,"__hash__":103},"terms\u002Fterms\u002Fc\u002Fclassification.md","Classification",null,{"type":8,"value":9,"toc":77},"minimark",[10,15,19,23,26,30,66,70,73],[11,12,14],"h2",{"id":13},"eli5-the-vibe-check","ELI5 — The Vibe Check",[16,17,18],"p",{},"Classification is teaching an AI to sort things into categories. Is this email spam or not? Is this image a cat, dog, or bird? Is this customer likely to churn? The AI learns to put each input into one of several predefined boxes. It's one of the most common ML tasks.",[11,20,22],{"id":21},"real-talk","Real Talk",[16,24,25],{},"Classification is a supervised learning task where the model learns to assign inputs to one of a discrete set of categories. Binary classification has two classes; multiclass has more. Key algorithms include logistic regression, decision trees, SVMs, and neural networks. Performance is measured with accuracy, precision, recall, and F1 score.",[11,27,29],{"id":28},"show-me-the-code","Show Me The Code",[31,32,37],"pre",{"className":33,"code":34,"language":35,"meta":36,"style":36},"language-python shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","from sklearn.ensemble import RandomForestClassifier\nmodel = RandomForestClassifier(n_estimators=100)\nmodel.fit(X_train, y_train)\npredictions = model.predict(X_test)  # outputs class labels\n","python","",[38,39,40,48,54,60],"code",{"__ignoreMap":36},[41,42,45],"span",{"class":43,"line":44},"line",1,[41,46,47],{},"from sklearn.ensemble import RandomForestClassifier\n",[41,49,51],{"class":43,"line":50},2,[41,52,53],{},"model = RandomForestClassifier(n_estimators=100)\n",[41,55,57],{"class":43,"line":56},3,[41,58,59],{},"model.fit(X_train, y_train)\n",[41,61,63],{"class":43,"line":62},4,[41,64,65],{},"predictions = model.predict(X_test)  # outputs class labels\n",[11,67,69],{"id":68},"when-youll-hear-this","When You'll Hear This",[16,71,72],{},"\"Spam detection is a classification problem.\" \u002F \"Is this a binary or multi-class classification task?\"",[74,75,76],"style",{},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":36,"searchDepth":50,"depth":50,"links":78},[79,80,81,82],{"id":13,"depth":50,"text":14},{"id":21,"depth":50,"text":22},{"id":28,"depth":50,"text":29},{"id":68,"depth":50,"text":69},"ai","Classification is teaching an AI to sort things into categories. Is this email spam or not? Is this image a cat, dog, or bird?","beginner","md","c",{},true,"\u002Fterms\u002Fc\u002Fclassification",[92,93,94,95,96,97],"Regression","Clustering","Accuracy","Precision","Recall","F1 Score",{"title":5,"description":84},{"changefreq":100,"priority":101},"weekly",0.7,"terms\u002Fc\u002Fclassification","wMEfoKAqQ4EzB4B6QZeeLPKXrmrQ_bOM8tfBtAlghC0",[105,108,112,115,118,121],{"title":94,"path":106,"acronym":6,"category":83,"difficulty":85,"description":107},"\u002Fterms\u002Fa\u002Faccuracy","Accuracy is the simplest way to score a model — what percentage of predictions were correct.",{"title":93,"path":109,"acronym":6,"category":83,"difficulty":110,"description":111},"\u002Fterms\u002Fc\u002Fclustering","intermediate","Clustering is teaching an AI to find groups in data WITHOUT being told what the groups are.",{"title":97,"path":113,"acronym":6,"category":83,"difficulty":110,"description":114},"\u002Fterms\u002Ff\u002Ff1-score","The F1 Score is the balanced average of precision and recall — a single number that captures both.",{"title":95,"path":116,"acronym":6,"category":83,"difficulty":110,"description":117},"\u002Fterms\u002Fp\u002Fprecision","Precision asks: 'Of all the times the AI said YES, how often was it actually right?",{"title":96,"path":119,"acronym":6,"category":83,"difficulty":110,"description":120},"\u002Fterms\u002Fr\u002Frecall","Recall asks: 'Of all the actual YES cases in the world, how many did the AI catch?' High recall means the model finds almost everything it should.",{"title":92,"path":122,"acronym":6,"category":83,"difficulty":85,"description":123},"\u002Fterms\u002Fr\u002Fregression","Regression is like classification but instead of sorting things into categories, you're predicting a number. What will this house sell for?",1776518265400]