Created
February 6, 2019 05:29
-
-
Save mohdsanadzakirizvi/4cad767690af9e400017a1cd487e3dbc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#get the dependency parse of the first sentence | |
print('---') | |
print('dependency parse of first sentence') | |
dependency_parse = sentence.basicDependencies | |
print(dependency_parse) | |
# get the first token of the first sentence | |
print('---') | |
print('first token of first sentence') | |
token = sentence.token[0] | |
print(token) | |
# get the part-of-speech tag | |
print('---') | |
print('part of speech tag of token') | |
token.pos | |
print(token.pos) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment