Implemented Part of speech tagging and OCR using variable elimination and viterbi algorithm on Hidden Markov Models