Model Atlas · Probabilistic models

Naive Bayes

Uses Bayes rule with conditional independence assumptions for fast classification.

core mathematical viewP(y|x)∝P(y)∏P(xᵢ|y)
Mental model

Understand it before memorizing it.

Combine how likely each feature is under each class then compare posteriors.

Best fit

Where this model earns its place

Text classification

Start with a simpler baseline then compare this model using the same evaluation split and operational constraints.

Small datasets

Start with a simpler baseline then compare this model using the same evaluation split and operational constraints.

Baseline models

Start with a simpler baseline then compare this model using the same evaluation split and operational constraints.

Strengths and limits

Trade-offs matter more than popularity.

Strengths

✓ Very fast

✓ Works well with sparse text

Limitations

△ Independence assumption is strong

Evaluation

Metrics to watch

F1Interpret with the product objective and error cost.
Log lossInterpret with the product objective and error cost.
CalibrationInterpret with the product objective and error cost.
Production checklist

Before it reaches real users

  1. 01

    Choose correct variant

    Document the assumption and instrument the condition so regressions can be detected.

  2. 02

    Smooth probabilities

    Document the assumption and instrument the condition so regressions can be detected.

  3. 03

    Inspect calibration

    Document the assumption and instrument the condition so regressions can be detected.