Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In connecting to NLP service,While using sentences annotation getting null value #94

Closed
jgazelle opened this issue Mar 12, 2019 · 2 comments

Comments

@jgazelle
Copy link

I used the code from the below link
https://sergey-tihon.github.io/Stanford.NLP.NET//samples/CoreNLP.Server.html
Here sentences returns null
var sentences = document.get(sentencesAnnotationClass) as java.util.AbstractList;

@jgazelle
Copy link
Author

If i use 'tokenize' and ssplit it is not returning null.When I add 'pos' then sentences above is giving null

@sergey-tihon
Copy link
Owner

Sample is fixed and updated in docs

        var sentencesAnnotationClass = GetAnnotationClass<CoreAnnotations.SentencesAnnotation>();
        var sentences = sentencesAnnotationClass.getClasses().Select(document.get).ToList();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants