haskell-conll-0.1.0.2: Core Types for NLP

Safe HaskellNone
LanguageHaskell2010

Data.ConllToken

Synopsis

Documentation

data ConllToken cpos fpos ger feats lemma Source #

Basic data type to work witn CoNLL data format

Constructors

ConllToken 

Fields

  • _tnId :: Int

    Index number

  • _tnWord :: Text

    Parsed word or punctuation symbol

  • _tnLemma :: lemma

    Lemma or stem

  • _tnPosCG :: cpos

    Part-of-Speech (POS) coarse-grained (PRON, VERB, DET, NOUN, etc)

  • _tnPosFG :: fpos

    Part-of-Speech (POS) fine-grained (PRP, VBD, DT, NN etc.)

  • _tnFeats :: feats

    Unordered set of syntactic and/or morphological features.

  • _tnHead :: Int

    Head of the current token, which is either a value of ID or '0'.

  • _tnRel :: ger

    grammatical relationships between different words in the sentence, alined with Head

  • _tnHeadProj :: Text

    Projective head of current token.

  • _tnRelProj :: Text

    Dependency relation to the PHEAD.

Instances
Functor (ConllToken cpos fpos ger feats) Source # 
Instance details

Defined in Data.ConllToken

Methods

fmap :: (a -> b) -> ConllToken cpos fpos ger feats a -> ConllToken cpos fpos ger feats b #

(<$) :: a -> ConllToken cpos fpos ger feats b -> ConllToken cpos fpos ger feats a #

(Eq lemma, Eq cpos, Eq fpos, Eq feats, Eq ger) => Eq (ConllToken cpos fpos ger feats lemma) Source # 
Instance details

Defined in Data.ConllToken

Methods

(==) :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Bool #

(/=) :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Bool #

(Ord lemma, Ord cpos, Ord fpos, Ord feats, Ord ger) => Ord (ConllToken cpos fpos ger feats lemma) Source # 
Instance details

Defined in Data.ConllToken

Methods

compare :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Ordering #

(<) :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Bool #

(<=) :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Bool #

(>) :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Bool #

(>=) :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> Bool #

max :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma #

min :: ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma -> ConllToken cpos fpos ger feats lemma #

(Read lemma, Read cpos, Read fpos, Read feats, Read ger) => Read (ConllToken cpos fpos ger feats lemma) Source # 
Instance details

Defined in Data.ConllToken

Methods

readsPrec :: Int -> ReadS (ConllToken cpos fpos ger feats lemma) #

readList :: ReadS [ConllToken cpos fpos ger feats lemma] #

readPrec :: ReadPrec (ConllToken cpos fpos ger feats lemma) #

readListPrec :: ReadPrec [ConllToken cpos fpos ger feats lemma] #

(Show lemma, Show cpos, Show fpos, Show feats, Show ger) => Show (ConllToken cpos fpos ger feats lemma) Source # 
Instance details

Defined in Data.ConllToken

Methods

showsPrec :: Int -> ConllToken cpos fpos ger feats lemma -> ShowS #

show :: ConllToken cpos fpos ger feats lemma -> String #

showList :: [ConllToken cpos fpos ger feats lemma] -> ShowS #

Generic (ConllToken cpos fpos ger feats lemma) Source # 
Instance details

Defined in Data.ConllToken

Associated Types

type Rep (ConllToken cpos fpos ger feats lemma) :: Type -> Type #

Methods

from :: ConllToken cpos fpos ger feats lemma -> Rep (ConllToken cpos fpos ger feats lemma) x #

to :: Rep (ConllToken cpos fpos ger feats lemma) x -> ConllToken cpos fpos ger feats lemma #

type Rep (ConllToken cpos fpos ger feats lemma) Source # 
Instance details

Defined in Data.ConllToken

tnWord :: forall cpos fpos ger feats lemma. Lens' (ConllToken cpos fpos ger feats lemma) Text Source #

tnRelProj :: forall cpos fpos ger feats lemma. Lens' (ConllToken cpos fpos ger feats lemma) Text Source #

tnRel :: forall cpos fpos ger feats lemma ger. Lens (ConllToken cpos fpos ger feats lemma) (ConllToken cpos fpos ger feats lemma) ger ger Source #

tnPosFG :: forall cpos fpos ger feats lemma fpos. Lens (ConllToken cpos fpos ger feats lemma) (ConllToken cpos fpos ger feats lemma) fpos fpos Source #

tnPosCG :: forall cpos fpos ger feats lemma cpos. Lens (ConllToken cpos fpos ger feats lemma) (ConllToken cpos fpos ger feats lemma) cpos cpos Source #

tnLemma :: forall cpos fpos ger feats lemma lemma. Lens (ConllToken cpos fpos ger feats lemma) (ConllToken cpos fpos ger feats lemma) lemma lemma Source #

tnId :: forall cpos fpos ger feats lemma. Lens' (ConllToken cpos fpos ger feats lemma) Int Source #

tnHeadProj :: forall cpos fpos ger feats lemma. Lens' (ConllToken cpos fpos ger feats lemma) Text Source #

tnHead :: forall cpos fpos ger feats lemma. Lens' (ConllToken cpos fpos ger feats lemma) Int Source #

tnFeats :: forall cpos fpos ger feats lemma feats. Lens (ConllToken cpos fpos ger feats lemma) (ConllToken cpos fpos ger feats lemma) feats feats Source #