crf-chain1-0.2.3: First-order, linear-chain conditional random fields

Data.CRF.Chain1.Inference

Synopsis

# Documentation

tag :: Model -> Xs -> [Lb] Source #

Determine the most probable label sequence given the context of the CRF model and the sentence.

marginals :: Model -> Xs -> [[(Lb, LogFloat)]] Source #

Tag probabilities with respect to marginal distributions.

accuracy :: Model -> [(Xs, Ys)] -> Double Source #

Compute the accuracy of the model with respect to the labeled dataset.

expectedFeaturesIn :: Model -> Xs -> [(FeatIx, LogFloat)] Source #

A list of features (represented by feature indices) defined within the context of the sentence accompanied by expected probabilities determined on the basis of the model.

One feature can occur multiple times in the output list.

zx :: Model -> Xs -> LogFloat Source #

Normalization factor computed for the Xs sentence using the backward computation.

Normalization factor computed for the Xs sentence using the forward computation.