Skip to content
Discussion options

You must be logged in to vote

Sentences aren't internally stored as a list, so providing an index in the doc is not straightforward and implementing a function like this would not be efficient.

What you could do though, is loop through all the sentences in list(doc.sents) once, set a custom extension to the corresponding Span, and use that in your other functions.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by ines
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat / doc Feature: Doc, Span and Token objects
2 participants