Skip to content

Reconciling tokens with NE spans #213

@rlvoyer

Description

@rlvoyer

I'm curious if there's a built-in mechanism for traversing a view of a sentence or a document with knowledge of both named entities as well as tokens. For example, say I'd like to iterate over a sentence yielding the lemma of each non-stopword token, unless it's part of a named entity span, in which case I'd like to yield the surface form of the NE span, and then continuing on to the token immediately following the NE span. Is there a built-in way to handle this? I can't find any relevant examples in the documentation. Thanks for your help.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions