Skip to content

02 – Verbs

Kira edited this page Apr 14, 2019 · 10 revisions

Adding a verb to a sentence

First, create the verb:

VPPhraseSpec verb = nlgFactory.createVerbPhrase("jagen");

Then, add the verb as main verb to the sentence:

sentence.setVerb(verb);

The following modifications can be applied to change the form of a verb:

Tenses

See the chapter 07 - Setting the tense of this Wiki on how to change the tense of your verb/sentence.

Passive

To realise a sentence with Stative Passive (Zustandspassiv), e.g. "Das Fahrrad ist abgeschlossen.", set

verb.setFeature(Feature.PASSIVE, true);.

To realise a sentence with Agentive Passive (Vorgangspassiv, e.g. "Das Fahrrad wird abgeschlossen.", set additionally

verb.setFeature(Feature.PROGRESSIVE, true);.

Passive is available in present and preterite tense.

Reflexive verbs

If you want a verb to be reflexive, add the reflexive pronoun before the verb in the VerbPhrase: VPPhraseSpec verb = nlgFactory.createVerbPhrase("sich entwickeln");

Modal verbs

Add the second verb as postModifier, e.g. "sollen" as verb, "kommen" as postModifier. Modal verbs are currently only available in present tense.

Separable verbs

A verb can be both separable and not separable for the same sentence, depending on the desired sense. Thus, the verb "überziehen" ("to cover") can be used as a separable ("Der Sturm zog über die Stadt.", "The storm passed over the city.") or as a non-separable verb ("Der Sturm überzog die Stadt.", "The storm covered the city."). You have to state which verb form is required. The non-separable version can be forced by setting setFeature(Feature.SEPARABLE_VERB, false);

Verbs in infinitive

If you want to use verbs in infinitive with "zu" ("to") before, e.g. in "Er versucht es zu schaffen" ("He tries to manage it"), indicate this as follows:

VPPhraseSpec verb = nlgFactory.createVerbPhrase("schaffen");
verb.addPreModifier("zu");

Past participle

Set setFeature(Feature.FORM, Form.PAST_PARTICIPLE); if you explicitly want a verb to be in past participle.