Sentences for English

This is the documentation for 4.2.0 version, which is not the latest version. Consider upgrading to 4.3.0.

Examples

will generate:

  • The gardener gave apples to the neighbor.

  • He gave them to her.

  • He gave apples to her.

  • He gave them to the neighbor.

Features and Usage

The generation order between DIRECT and INDIRECT respects the declared order.

Use negative: true to generate a negative form, like he didn’t give…​. In the negative form, you can also use:

  • contractNegation to indicate whether do use the contracted form (e.g. did not ⇒ didn’t). Default is false (no contraction).

  • when the verb is have, you can add negationNoDo: true to remove to do and use the negative form of have: e.g. she does not have itshe hasn’t it. Please note that contraction is always on in this case: she has not it is not valid.

In subjectGroup, use person to generate a personal subject pronoun (I, you, we, you, they, etc.). Possible values are 1S (1st person, singular ⇒ I), 2S (you), 1P (we), 2P (2nd person, plural ⇒ you) and 3P (they) as possible values. 3S is not allowed as we would not know whether to generate he or she. When using person parameter, subject property is ignored.

will generate: The neighbor does not have a chocolate bar. She does not have it. She hasn’t it.