Instance Method

setGazetteers(_:for:)

Attaches gazetteers to a tag scheme, typically one gazetteer per language or one language-independent gazetteer.

Declaration

func setGazetteers(_ gazetteers: [NLGazetteer], for tagScheme: NLTagScheme)

Parameters

gazetteers

The gazetteers to attach to a tag scheme.

tagScheme

The tag scheme for the gazetteers.

See Also

Using Gazetteers with a Tagger

func gazetteers(for: NLTagScheme) -> [NLGazetteer]

Retrieves the gazetteers attached to a tag scheme.

class NLGazetteer

A collection of terms and their labels, which take precedence over a word tagger.