This algorithm trains itself to identify the language of a document, growing more accurate with every sample used to train it.