NOINDEX, NOFOLLOW for selected namespaces and revisions
Some of the namespaces doesn't need to be indexed as they are just duplicate content, templates for example.
Especially true for revisions. If someone wants revisions to be public, they should be NOINDEX,NOFOLLOW as they are all duplicate content by nature. If someone wants to let anonymous edit their wiki and they get spammers editing an article, they would then revert the article, but the spam links is still there in the revisions if they choose to make those public, and they would link to bad neighborhoods/spammer if search engine bots indexes the revisions.
NOINDEX,NOFOLLOW for anything but article content would take care of that.
Special pages, recent changes should also be noindex, nofollow, there's no reason for search bots to spend time crawling those instead of crawling the real articles.
wikipedia has been doing this for a while if you look at the source for anything that's not an article, not sure when they started, but it's been there for as long as I can remember.