ngram-0.1.0.0: Ngram models for compressing and classifying text.

Safe HaskellSafe
LanguageHaskell2010

Codec.Compression.PPM.Utils

Synopsis

Documentation

lineToInstance :: Text -> (Text, [Char]) Source #

Splits a line of format IDTABLABELTABTEXT into a (label, document) tuple of (Text, [Char]).

revWindows :: Int -> [i] -> [[i]] Source #

Reverse-order windows of given length from input sequence. Includes shorter initial windows.