Safe Haskell | None |
---|
- data FeatGen o t f = FeatGen {}
- type FeatSel o t f = FeatGen o t f -> Xs o t -> Ys t -> [f]
- selectPresent :: FeatSel o t f
- selectHidden :: FeatSel o t f
- data Model m o t f = Model {}
- mkModel :: (Ord f, FeatMap m f) => FeatGen o t f -> FeatSel o t f -> [(Xs o t, Ys t)] -> Model m o t f
- data Core m f = Core {}
- core :: Model m o t f -> Core m f
- withCore :: Core m f -> FeatGen o t f -> Model m o t f
- phi :: FeatMap m f => Model m o t f -> f -> LogFloat
- index :: FeatMap m f => Model m o t f -> f -> Maybe FeatIx
- presentFeats :: FeatGen o t f -> Xs o t -> Ys t -> [(f, LogFloat)]
- hiddenFeats :: FeatGen o t f -> Xs o t -> [f]
- obFeatsOn :: FeatGen o t f -> Xs o t -> Int -> LbIx -> [f]
- trFeatsOn :: FeatGen o t f -> Xs o t -> Int -> LbIx -> LbIx -> LbIx -> [f]
- onWord :: FeatMap m f => Model m o t f -> Xs o t -> Int -> LbIx -> LogFloat
- onTransition :: FeatMap m f => Model m o t f -> Xs o t -> Int -> LbIx -> LbIx -> LbIx -> LogFloat
- lbNum :: Xs o t -> Int -> Int
- lbOn :: Xs o t -> Int -> LbIx -> Maybe t
- lbIxs :: Xs o t -> Int -> [LbIx]
Documentation
Feature generation specification.
selectPresent :: FeatSel o t fSource
The presentFeats
adapted to fit feature selection specs.
selectHidden :: FeatSel o t fSource
The hiddenFeats
adapted to fit feature selection specs.
A conditional random field.
mkModel :: (Ord f, FeatMap m f) => FeatGen o t f -> FeatSel o t f -> [(Xs o t, Ys t)] -> Model m o t fSource
A core of the model with no feature generation function.
Unlike the Model
, the core can be serialized.
withCore :: Core m f -> FeatGen o t f -> Model m o t fSource
Construct model with the given core and feature generation function.
phi :: FeatMap m f => Model m o t f -> f -> LogFloatSource
Potential assigned to the feature -- exponential of the corresonding parameter.
presentFeats :: FeatGen o t f -> Xs o t -> Ys t -> [(f, LogFloat)]Source
Features present in the dataset element together with corresponding occurence probabilities.
hiddenFeats :: FeatGen o t f -> Xs o t -> [f]Source
Features hidden in the dataset element.
onTransition :: FeatMap m f => Model m o t f -> Xs o t -> Int -> LbIx -> LbIx -> LbIx -> LogFloatSource
lbNum :: Xs o t -> Int -> IntSource
Number of potential labels at the given position of the sentence. Function extended to indices outside the positions' domain.