Conditional random fields (CRFs) are probabilistic models that are used to analyze structured data. They are frequently used to label and segment sequential data. CRFs are discriminative models as opposed to HMMs, which are generative models. CRFs are used extensively to analyze sequences, stock, speech, words, and so on. In these models, given a particular labeled observation sequence, we define a conditional probability distribution over this sequence. This is in contrast to HMMs, where we define a joint distribution over the label and the observed sequence.
Building CRFs for sequential text data
Getting ready
In this recipe, we will use a library called pystruct to build and train CRFs. Make sure that you install this before...