How to handle with long-tail classification I have a long tailed distribution with many classes,
and the num of samples per class is
[38K, 12K, 8K, 6k, 4K,4K, 2K, 800, 600, 400,400,300,280,180,180,120, 85, 70, 60, 60, 60, 60, 50]

I tried to train a multiclass classifier and got pretty good results AUC for the 3 largest class, but very poor results for all the other classes.
How can I address this type of classification?
Thanks!

Use a multiclass probabilistic prediction method, i.e., one that outputs a predicted probability for a new instance to belong to each class. Assess these using proper scoring rules.
In your situation, usually these probabilities will be high for the first few classes and low for the others (unless there are predictors that clearly indicate that an instance belongs to one of the rarer classes, e.g., a biopsy result from a cancer test). And that is precisely as it should be: even conditional on predictors, an instance simply has a higher probability of belonging to a majority class, rather than to a minority one.
Subsequent to this, you can leverage these probabilistic predictions together with costs to come to decisions, by adjusting thresholds. These decisions should take the predictions into account, but also the wider context. If there is a low-but-still-elevated probability for an instance to belong to a particular minority class, this may be a reason for one action (e.g., a deeper analysis, or a background check), even if the highest probability is for one of the majority classes. Similarly, if an instance has high predicted probabilities for two majority classes, you might want to treat it differently from an instance that has a high prediction for only one class. And so on.
