mirror of https://github.com/explosion/spaCy.git
parent
5081f8a2b4
commit
5cbe913b6f
|
@ -341,13 +341,14 @@ cdef class Token:
|
|||
|
||||
property sent_start:
|
||||
def __get__(self):
|
||||
util.deprecated(
|
||||
"Token.sent_start is now deprecated. Use Token.is_sent_start "
|
||||
"instead, which returns a boolean value or None if the answer "
|
||||
"is unknown – instead of a misleading 0 for False and 1 for "
|
||||
"True. It also fixes a quirk in the old logic that would "
|
||||
"always set the property to 0 for the first word of the "
|
||||
"document.")
|
||||
# Raising a deprecation warning causes errors for autocomplete
|
||||
#util.deprecated(
|
||||
# "Token.sent_start is now deprecated. Use Token.is_sent_start "
|
||||
# "instead, which returns a boolean value or None if the answer "
|
||||
# "is unknown – instead of a misleading 0 for False and 1 for "
|
||||
# "True. It also fixes a quirk in the old logic that would "
|
||||
# "always set the property to 0 for the first word of the "
|
||||
# "document.")
|
||||
# Handle broken backwards compatibility case: doc[0].sent_start
|
||||
# was False.
|
||||
if self.i == 0:
|
||||
|
|
Loading…
Reference in New Issue