Naive Bayes counts rather than optimises, which is why it is so fast.
It works out how often each feature turns up with each class.
Then it multiplies those numbers together to score a new example.
The naive part is assuming the features are unrelated to each other.
In text that is obviously false, since words arrive in phrases.
It still works, because the ranking often survives the wrong assumption.
It needs very little data before it becomes useful.
That makes it sensible when examples are scarce.
A word never seen with a class would give a probability of zero.
One zero wipes out the whole product, so a small count is added everywhere.
Its probabilities are usually badly calibrated and far too confident.
Use the ranking it gives you, not the number itself.
It trains almost instantly, even on very large collections of text.
It stays a reasonable baseline for spam filtering and topic sorting.
If it beats your neural network, your neural network has a problem.