Probabilistic context-free grammar is grammar defined using a series of rules. Context-free refers to the idea that a rule can be applied without regard to its context. The application of a rule is assigned a probability. This type of grammar is useful for natural languages and has been used to study RNA molecular sequences.
Using probabilistic context-free grammar to parse text
Getting ready
To prepare, we need to do the following:
- Create a new Maven project
- Add the following dependency to the POM file:
<dependency>
<groupId>edu.stanford.nlp</groupId>
<artifactId>stanford-corenlp</artifactId>
<version>3.9.2</version>
</dependency>
In the browser, perform the following...