Stanford Core NLP how to get the probability & margin of error
Asked Answered
S

1

11

When using the parser or for the matter any of the Annotation in Core NLP, is there a way to access the probability or the margin of error?

To put my question into context, I am trying to understand if there is a way programmatically to detect a case of ambiguity. For instance in the sentence below the verb desire is detected as a noun. I would like to be able to know so kind of measure I can access or calculate from the Core NLP APi to tell me there could be an ambiguity.

(NP (NP (NNP Whereas)) (, ,) (NP (NNP users) (NN desire) (S (VP (TO to) (VP (VB sell)))))) 
Srini answered 22/3, 2013 at 16:9 Comment(0)
N
0

To get the probability and margin of error in Stanford CoreNLP, follow these steps:

Probability Scores: Use the Sentiment Annotator or similar models that output confidence scores. CoreNLP's machine learning models (e.g., for POS tagging, named entity recognition) often provide class probabilities, but you'll need to manually parse the output JSON to access them.

Margin of Error: Stanford CoreNLP doesn't natively provide the margin of error. You may need to compute this by aggregating results across multiple runs or using statistical methods post-processing.

Numbles answered 14/9 at 10:35 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.