Characteristics of the Portuguese language in AX Semantics
In Portuguese, you need to know the gender of the noun in order to form the accompanying determiners, adjectives, and numerals correctly.
Portuguese has two genders for nouns: masculine and feminine. There are two numbers: singular and plural. Additionally, it only has 1 case for nouns: nominative. But for personal pronouns, Portuguese has additionally accusative and dative.
|gender||masculine||o porto azul (the blue port)|
|feminine||a cadeira azul (the blue chair)|
|number||singular||uma casa vermelha (a red house)|
|plural||duas casas vermelhas (two red houses)|
|cases (noun)||nominative||o cão (the dog)|
|cases (pronoun)||nominative||Mário constrói uma casa. Ele constrói uma casa. |
(Mario builds a house. He builds a house.)
|accusative||Mario constrói uma casa. Mario la constrói. |
(Maria builds a house. Maria builds it.)
|dative||Maria dá um livro a Luigi. Maria lhe dá um livro. |
(Maria gives Luigi a book. Maria gives him a book.)
|adjectives (noun)||after-noun||o telefone preto (the black phone)|
|before-noun||o excelente produto (the excellent product)|
|verb tenses||present||ele escreve (he writes)|
|past (preterite)||ele escreveu (He wrote)|
|imperfect||ele escrevia (He wrote)|
|future||ele escreverá (He will write)|
The standard order of a noun phrase in Portuguese is the following:
preposition + determiner + numeral + noun + adjective.
See for example:
com estes três livros populares with these three books[pl] popular PREP DET NUM NOUN ADJ "with these three popular books"
For Portuguese nouns, the LEXICON needs to encode gender and determiner changes. If the lexicon entry is missing, the NLG platform tries to find the most probable gender based on heuristics. The plural forms should be added to the lexicon if they are not regular.
Lexicon entries for nouns may also be necessary for inflecting determiners, adjectives and pronouns correctly. They are omitted, if a lexicon entry is required, but missing.
The basic lexicon entry for casa (house) contains:
- gender: f
- inflection table for case and number:
If you need lexicon entries for countries, write to the support about that and you will get them for Portuguese with automatic handling of determiners.
In the lexicon the inflection table for gender and number can be encoded, as well as the adjective position (before the noun or after the noun).
For adjective position, the default is "after noun". Certain adjectives should stay before the noun. In that case, "before noun" has to be selected in the lexicon. For instance, some adjectives like bom ("good") or belo ("nice") often precede the noun:
o bom livro (the good book)
The most common verbs are encoded in our software. If a verb inflects the wrong way, you should add it to the lexicon.
The noun will automatically agree with the numeral number when a numeral variable is used. Four types of numerals are possible on the AX NLG platform: cardinal, cardinal as digit, ordinal, and ordinal as digit.
|o nono dia|
(the ninth day)
|o 9º dia|
(the 9th day)
For Portuguese, both cardinal and ordinal numerals are written out until 12, otherwise (above 12) the output is in digit form. Take cardinal numerals for example,
doze automóveis (twelve cars) 13 automóveis (13 cars)
Prepositions and determiners: contractions
If users configure prepositions and determiners in the container, they are automatically adapted, when phonetic assimilation needs to happen. For instance, the preposition
em is contracted with the definite determiner
na cozinha (in the kitchen)
Determiners can be switched depending on the noun.
In the sentence
Eles viajaram de Berlim para Cuba. (They travelled from Berlin to Cuba.)
the settings for the container for
case="nominative". Here a determiner switch happens from
The AX NLG platform offers 2 variants of the Portuguese language:
- Portugal (Standard)
The differences between these variants are mostly lexical. The grammatical difference shows in the forms of the possessive determiners: for example
my book is
o meu livro in Portugal, but
meu livro in Brazil.