| Modifier and Type | Method and Description |
|---|---|
NLGElement |
AggregationRule.apply(NLGElement phrase)
Perform aggregation on a single phrase.
|
NLGElement |
ForwardConjunctionReductionRule.apply(NLGElement previous,
NLGElement next)
Applies forward conjunction reduction to two NLGElements e1 and e2,
succeeding only if they are clauses (that is, e1.getCategory() ==
e2.getCategory ==
PhraseCategory.CLAUSE) and
the clauses are not passive. |
abstract NLGElement |
AggregationRule.apply(NLGElement sentence1,
NLGElement sentence2)
Performs aggregation on a pair of sentences.
|
NLGElement |
ClauseCoordinationRule.apply(NLGElement previous,
NLGElement next)
Applies aggregation to two NLGElements e1 and e2, succeeding only if they
are clauses (that is, e1.getCategory() == e2.getCategory ==
PhraseCategory.CLAUSE). |
NLGElement |
BackwardConjunctionReductionRule.apply(NLGElement previous,
NLGElement next)
Applies backward conjunction reduction to two NLGElements e1 and e2,
succeeding only if they are clauses (that is, e1.getCategory() ==
e2.getCategory ==
PhraseCategory.CLAUSE). |
NLGElement |
Aggregator.realise(NLGElement element)
Apply aggregation to a single phrase.
|
NLGElement |
NewAggregator.realise(NLGElement element) |
NLGElement |
NewAggregator.realise(NLGElement phrase1,
NLGElement phrase2) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
AggregationRule.apply(List<NLGElement> phrases)
Performs aggregation on an arbitrary number of elements in a list.
|
List<NLGElement> |
FunctionalSet.getComponents() |
List<NLGElement> |
Aggregator.realise(List<NLGElement> elements)
Apply aggregation to a list of elements.
|
List<NLGElement> |
NewAggregator.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
void |
PhraseSet.addPhrase(NLGElement phrase)
Add a phrase
|
static boolean |
PhraseChecker.allActive(NLGElement... sentences)
Check whether all sentences are active
|
static boolean |
PhraseChecker.allPassive(NLGElement... sentences)
Check whether all sentences are passive
|
NLGElement |
AggregationRule.apply(NLGElement phrase)
Perform aggregation on a single phrase.
|
NLGElement |
ForwardConjunctionReductionRule.apply(NLGElement previous,
NLGElement next)
Applies forward conjunction reduction to two NLGElements e1 and e2,
succeeding only if they are clauses (that is, e1.getCategory() ==
e2.getCategory ==
PhraseCategory.CLAUSE) and
the clauses are not passive. |
abstract NLGElement |
AggregationRule.apply(NLGElement sentence1,
NLGElement sentence2)
Performs aggregation on a pair of sentences.
|
NLGElement |
ClauseCoordinationRule.apply(NLGElement previous,
NLGElement next)
Applies aggregation to two NLGElements e1 and e2, succeeding only if they
are clauses (that is, e1.getCategory() == e2.getCategory ==
PhraseCategory.CLAUSE). |
NLGElement |
BackwardConjunctionReductionRule.apply(NLGElement previous,
NLGElement next)
Applies backward conjunction reduction to two NLGElements e1 and e2,
succeeding only if they are clauses (that is, e1.getCategory() ==
e2.getCategory ==
PhraseCategory.CLAUSE). |
static List<FunctionalSet> |
AggregationHelper.collectFunctionalPairs(NLGElement phrase1,
NLGElement phrase2) |
static boolean |
PhraseChecker.expletiveSubjects(NLGElement... sentences)
Check whether these sentences have expletive subjects (there, it etc)
|
static boolean |
PhraseChecker.haveSameVoice(NLGElement... sentences)
Check that the sentences supplied are either all active or all passive.
|
static List<PhraseSet> |
PhraseChecker.leftPeriphery(NLGElement... sentences)
Collect a list of pairs of constituents with the same syntactic function
from the left periphery of two sentences.
|
static FunctionalSet |
FunctionalSet.newInstance(DiscourseFunction func,
ElementCategory category,
Periphery periphery,
NLGElement... components) |
static boolean |
PhraseChecker.nonePassive(NLGElement... sentences)
Check that no element of a give array of sentences is passive.
|
NLGElement |
Aggregator.realise(NLGElement element)
Apply aggregation to a single phrase.
|
NLGElement |
NewAggregator.realise(NLGElement element) |
NLGElement |
NewAggregator.realise(NLGElement phrase1,
NLGElement phrase2) |
static List<PhraseSet> |
PhraseChecker.rightPeriphery(NLGElement... sentences)
Collect a list of pairs of constituents with the same syntactic function
from the right periphery of two sentences.
|
static boolean |
PhraseChecker.sameFrontMods(NLGElement... sentences)
Check that the sentences supplied have identical front modifiers
|
static boolean |
PhraseChecker.samePostMods(NLGElement... sentences)
Check that some phrases have the same postmodifiers
|
static boolean |
PhraseChecker.sameSentences(NLGElement... sentences)
Check that the sentences supplied are identical
|
static boolean |
PhraseChecker.sameSubjects(NLGElement... sentences)
Check that the sentences supplied have identical subjects
|
static boolean |
PhraseChecker.sameSurfaceSubjects(NLGElement... sentences)
Check whether the sentences have the same surface subjects, that
is, they are either all active and have the same subjects, or all passive
and have the same passive raising subjects.
|
static boolean |
PhraseChecker.sameVP(NLGElement... sentences)
Check that the sentences supplied have identical verb phrases
|
static boolean |
PhraseChecker.sameVPArgs(NLGElement... sentences)
Check that the sentences supplied have the same complements at VP level.
|
static boolean |
PhraseChecker.sameVPHead(NLGElement... sentences)
Check that a list of sentences have the same verb
|
static boolean |
PhraseChecker.sameVPModifiers(NLGElement... sentences)
check that the phrases supplied are sentences and have the same VP
premodifiers and postmodifiers
|
| Modifier and Type | Method and Description |
|---|---|
void |
PhraseSet.addPhrases(Collection<NLGElement> phrases)
Add a collection of phrases.
|
List<NLGElement> |
AggregationRule.apply(List<NLGElement> phrases)
Performs aggregation on an arbitrary number of elements in a list.
|
List<NLGElement> |
Aggregator.realise(List<NLGElement> elements)
Apply aggregation to a list of elements.
|
List<NLGElement> |
NewAggregator.realise(List<NLGElement> elements) |
| Constructor and Description |
|---|
PhraseSet(DiscourseFunction function,
NLGElement... phrases)
Construct a set of compatible phrases and their function
|
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
HTMLFormatter.realise(NLGElement element) |
NLGElement |
TextFormatter.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
HTMLFormatter.realise(List<NLGElement> elements) |
List<NLGElement> |
TextFormatter.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
HTMLFormatter.realise(NLGElement element) |
NLGElement |
TextFormatter.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
HTMLFormatter.realise(List<NLGElement> elements) |
List<NLGElement> |
TextFormatter.realise(List<NLGElement> elements) |
| Modifier and Type | Class and Description |
|---|---|
class |
CoordinatedPhraseElement
This class defines coordination between two or more phrases.
|
class |
DocumentElement
DocumentElement is a convenient extension of the base
NLGElement class. |
class |
InflectedWordElement
This class defines the
NLGElement that is used to represent an
word that requires inflection by the morphology. |
class |
ListElement
ListElement is used to define elements that can be grouped
together and treated in a similar manner. |
class |
PhraseElement
This class defines a phrase.
|
class |
StringElement
This class defines an element for representing canned text within the
SimpleNLG library.
|
class |
WordElement
This is the class for a lexical entry (ie, a word).
|
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
NLGFactory.createInflectedWord(Object word,
LexicalCategory category)
Create an inflected word element.
|
NLGElement |
NLGFactory.createNLGElement(Object element)
create an NLGElement from the element, no default lexical category
|
NLGElement |
NLGFactory.createNLGElement(Object element,
LexicalCategory category)
this method creates an NLGElement from an object If object is null,
return null If the object is already an NLGElement, it is returned
unchanged Exception: if it is an InflectedWordElement, return underlying
WordElement If it is a String which matches a lexicon entry or pronoun,
the relevant WordElement is returned If it is a different String, a
wordElement is created if the string is a single word Otherwise a
StringElement is returned Otherwise throw an exception
|
NLGElement |
NLGFactory.createStringElement()
Creates a blank canned text phrase with no text.
|
NLGElement |
NLGFactory.createStringElement(String text)
Creates a canned text phrase with the given text.
|
NLGElement |
NLGFactory.createWord(Object word,
LexicalCategory category)
Creates a new element representing a word.
|
NLGElement |
NLGElement.getFeatureAsElement(String featureName)
Retrieves the value of the feature as a
NLGElement. |
NLGElement |
ListElement.getFirst()
Retrieves the first component in the list.
|
NLGElement |
PhraseElement.getHead()
Retrieves the current head of this phrase.
|
NLGElement |
CoordinatedPhraseElement.getLastCoordinate()
A convenience method for retrieving the last coordinate in this
coordination.
|
NLGElement |
NLGElement.getParent()
Retrieves the parent of this element.
|
abstract NLGElement |
NLGModule.realise(NLGElement element)
Realises the given element.
|
| Modifier and Type | Method and Description |
|---|---|
abstract List<NLGElement> |
NLGElement.getChildren()
Retrieves the children for this element.
|
List<NLGElement> |
StringElement.getChildren()
The string element contains no children so this method will always return
an empty list.
|
List<NLGElement> |
PhraseElement.getChildren()
This method retrieves the child components of this phrase.
|
List<NLGElement> |
CoordinatedPhraseElement.getChildren() |
List<NLGElement> |
WordElement.getChildren()
This method returns an empty
List as words do not have child
elements. |
List<NLGElement> |
InflectedWordElement.getChildren()
This method returns null as the inflected word has no child components.
|
List<NLGElement> |
DocumentElement.getChildren()
Child elements of a
DocumentElement are the components. |
List<NLGElement> |
ListElement.getChildren() |
List<NLGElement> |
CoordinatedPhraseElement.getComplements()
Retrieves the list of complements currently associated with this
coordination.
|
List<NLGElement> |
DocumentElement.getComponents()
Retrieves the child components of this element.
|
List<NLGElement> |
NLGElement.getFeatureAsElementList(String featureName)
Retrieves the value of the feature as a list of elements.
|
List<NLGElement> |
PhraseElement.getFrontModifiers()
Retrieves the current list of frony modifiers for the phrase.
|
List<NLGElement> |
PhraseElement.getPostModifiers()
Retrieves the current list of post modifiers for the phrase.
|
List<NLGElement> |
CoordinatedPhraseElement.getPostModifiers()
Retrieves the list of post-modifiers currently associated with this
coordination.
|
List<NLGElement> |
PhraseElement.getPreModifiers()
Retrieves the current list of pre-modifiers for the phrase.
|
List<NLGElement> |
CoordinatedPhraseElement.getPreModifiers()
Retrieves the list of pre-modifiers currently associated with this
coordination.
|
abstract List<NLGElement> |
NLGModule.realise(List<NLGElement> elements)
Realises a
List of NLGElements usually by
iteratively calling the realise(NLGElement) method on each
element in the list and adding the result into a new a List |
| Modifier and Type | Method and Description |
|---|---|
void |
PhraseElement.addComplement(NLGElement newComplement)
Adds a new complement to the phrase element.
|
void |
CoordinatedPhraseElement.addComplement(NLGElement newComplement)
Adds a new complement to the phrase element.
|
void |
DocumentElement.addComponent(NLGElement element)
Add a single child component to the current list of child components.
|
void |
ListElement.addComponent(NLGElement newComponent)
Adds the given component to the list element.
|
void |
PhraseElement.addFrontModifier(NLGElement newFrontModifier)
Adds a new front modifier to the phrase element.
|
void |
PhraseElement.addPostModifier(NLGElement newPostModifier)
Adds a new post-modifier to the phrase element.
|
void |
CoordinatedPhraseElement.addPostModifier(NLGElement newPostModifier)
Adds a new post-modifier to the phrase element.
|
void |
PhraseElement.addPreModifier(NLGElement newPreModifier)
Adds a new pre-modifier to the phrase element.
|
void |
CoordinatedPhraseElement.addPreModifier(NLGElement newPreModifier)
Adds a new pre-modifier to the phrase element.
|
DocumentElement |
NLGFactory.createDocument(String title,
NLGElement component)
Creates a new document element with the given title and adds the given
component.
|
DocumentElement |
NLGFactory.createEnumeratedList(NLGElement component)
Creates a new section element with the given title and adds the given
component.
|
DocumentElement |
NLGFactory.createList(NLGElement component)
Creates a new section element with the given title and adds the given
component.
|
DocumentElement |
NLGFactory.createListItem(NLGElement component)
Creates a list item for adding to a list element.
|
DocumentElement |
NLGFactory.createParagraph(NLGElement component)
Creates a new paragraph element and adds the given component
|
DocumentElement |
NLGFactory.createSection(String title,
NLGElement component)
Creates a new section element with the given title and adds the given
component.
|
DocumentElement |
NLGFactory.createSentence(NLGElement components)
Creates a new sentence element
|
abstract NLGElement |
NLGModule.realise(NLGElement element)
Realises the given element.
|
boolean |
DocumentElement.removeComponent(NLGElement textComponent)
Removes the specified component from the list of child components.
|
void |
PhraseElement.setComplement(NLGElement newComplement)
Sets a complement of the phrase element.
|
void |
PhraseElement.setFrontModifier(NLGElement newFrontModifier)
Set the front modifier for this phrase.
|
void |
NLGElement.setParent(NLGElement newParent)
Sets the parent element of this element.
|
void |
PhraseElement.setPostModifier(NLGElement newPostModifier)
Set the postmodifier for this phrase.
|
void |
PhraseElement.setPreModifier(NLGElement newPreModifier)
Set the premodifier for this phrase.
|
| Modifier and Type | Method and Description |
|---|---|
void |
ListElement.addComponents(List<NLGElement> newComponents)
Adds the given components to the list element.
|
DocumentElement |
NLGFactory.createSentence(List<NLGElement> components)
Creates a new sentence element and adds all of the given components.
|
abstract List<NLGElement> |
NLGModule.realise(List<NLGElement> elements)
Realises a
List of NLGElements usually by
iteratively calling the realise(NLGElement) method on each
element in the list and adding the result into a new a List |
void |
DocumentElement.setComponents(List<NLGElement> components)
Replaces the existing components with the supplied list of components.
|
void |
ListElement.setComponents(List<NLGElement> newComponents)
Replaces the current components in the list element with the given list.
|
| Constructor and Description |
|---|
ListElement(NLGElement newComponent)
Creates a new list element containing the given component.
|
| Constructor and Description |
|---|
ListElement(List<NLGElement> components)
Creates a new list element containing the given components.
|
| Modifier and Type | Method and Description |
|---|---|
static NLGElement |
MorphologyRules.doAdjectiveMorphology(InflectedWordElement element,
WordElement baseWord)
This method performs the morphology for adjectives.
|
static NLGElement |
MorphologyRules.doAdverbMorphology(InflectedWordElement element,
WordElement baseWord)
This method performs the morphology for adverbs.
|
static NLGElement |
MorphologyRules.doPronounMorphology(InflectedWordElement element)
This method performs the morphology for pronouns.
|
protected static NLGElement |
MorphologyRules.doVerbMorphology(InflectedWordElement element,
WordElement baseWord)
This method performs the morphology for verbs.
|
NLGElement |
MorphologyProcessor.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
MorphologyProcessor.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
static void |
MorphologyRules.doDeterminerMorphology(NLGElement determiner,
String realisation)
This method performs the morphology for determiners.
|
NLGElement |
MorphologyProcessor.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
MorphologyProcessor.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
OrthographyProcessor.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
OrthographyProcessor.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
OrthographyProcessor.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
OrthographyProcessor.realise(List<NLGElement> elements) |
| Modifier and Type | Class and Description |
|---|---|
class |
AdjPhraseSpec
This class defines a adjective phrase.
|
class |
AdvPhraseSpec
This class defines a adverbial phrase.
|
class |
NPPhraseSpec
This class defines a noun phrase.
|
class |
PPPhraseSpec
This class defines a prepositional phrase.
|
class |
SPhraseSpec
This class defines a clause (sentence-like phrase).
|
class |
VPPhraseSpec
This class defines a verb phrase.
|
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
AdjPhraseSpec.getAdjective() |
NLGElement |
AdvPhraseSpec.getAdverb() |
NLGElement |
NPPhraseSpec.getDeterminer()
getDeterminer - Convenience method for when a person tries to get a
determiner (e.g.
|
NLGElement |
VPPhraseSpec.getIndirectObject()
Returns the indirect object of a clause (assumes there is only one)
|
NLGElement |
SPhraseSpec.getIndirectObject()
Returns the indirect object of a clause (assumes there is only one)
|
NLGElement |
NPPhraseSpec.getNoun() |
NLGElement |
VPPhraseSpec.getObject()
Returns the direct object of a clause (assumes there is only one)
|
NLGElement |
PPPhraseSpec.getObject() |
NLGElement |
SPhraseSpec.getObject()
Returns the direct object of a clause (assumes there is only one)
|
NLGElement |
PPPhraseSpec.getPreposition() |
NLGElement |
NPPhraseSpec.getSpecifier() |
NLGElement |
SPhraseSpec.getSubject()
Returns the subject of a clause (assumes there is only one)
|
NLGElement |
VPPhraseSpec.getVerb() |
NLGElement |
SPhraseSpec.getVerb()
Returns the verb of a clause
|
NLGElement |
SPhraseSpec.getVerbPhrase() |
| Modifier and Type | Method and Description |
|---|---|
void |
SPhraseSpec.addComplement(NLGElement complement) |
void |
SPhraseSpec.addPreModifier(NLGElement newPreModifier) |
void |
SPhraseSpec.setVerbPhrase(NLGElement vp) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
Realiser.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
Realiser.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
Realiser.realise(NLGElement element) |
String |
Realiser.realiseSentence(NLGElement element)
Convenience class to realise any NLGElement as a sentence
|
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
Realiser.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
SyntaxProcessor.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
SyntaxProcessor.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
SyntaxProcessor.realise(NLGElement element) |
| Modifier and Type | Method and Description |
|---|---|
List<NLGElement> |
SyntaxProcessor.realise(List<NLGElement> elements) |
| Modifier and Type | Method and Description |
|---|---|
NLGElement |
UnWrapper.UnwrapCoordinatePhraseSpec(XmlNLGElement wps)
Unwraps a coordinate phrase.
|
NLGElement |
UnWrapper.UnwrapNLGElement(XmlNLGElement wps)
Unwrap a
simplenlg.xmlrealiser.wrapper.NLGElement and map it
to a simplenlg.framework.NLGElement |
Copyright © 2020. All Rights Reserved.