Template:ar-decl-noun/documentation

This template displays an inflection table for Arabic nouns. The parameters are largely the same as for the headword template, and in general it is possible to copy such a template, change its name to , and get an appropriate declension table. (Ideally, delete extraneous stuff such as the gender and args with no equivalents below, such as cons and f.)

See also.

Base parameters

 * 1
 * The stem used in the singular, including vowels, of one of the following forms:
 * most commonly, just, i.e. an Arabic stem where the transliteration automatically determined and the inflection type inferred from the stem (this inference is very accurate and rarely makes mistakes);
 * with manual transliteration supplied (use only when the automatic translit is wrong or can't be determined);
 * with an explicitly specified inflection type (see below);
 * with both manual transliteration and explicitly specified inflection;
 * to indicate an unknown singular (used more often the masculine plural of adjectives, and occasionally in nouns to specify an unknown dual);
 * for words without a singular (e.g. ).
 * Note that manual transliteration can also be specified using separate parameters, as with headword templates like.


 * head2, head3, ...
 * Additional singular stems.


 * tr, tr2, tr3, ...
 * Alternative way to specify manual transliteration for 1, head2, head3, ..., respectively, instead of using the  specification. Provided for compatibility with headword templates.


 * pl, pl2, ...
 * The stem(s) used in the plural, including vowels. Has the same forms as for the singular stem(s), with the addition that the value can be a raw inflection : e.g.   to infer a strong plural from the singular and its gender; ,   or   to construct a strong plural from the singular with a specified ending.


 * pltr, pl2tr, ...
 * Alternative way to specify manual transliteration for pl, pl2, ..., respectively, instead of using the  specification. Provided for compatibility with headword templates. Similar parameters are available for duals.


 * d, d2, ...
 * The stem(s) used in the dual, including vowels. Same form as for plurals. Doesn't need to be present in most cases as it's inferred from the singular. Can be  for words without a dual when it would otherwise appear (which happens when the noun has a plural specified); can be   to indicate that the dual exists but is unknown (e.g. it is currently used in ).


 * dtr, d2tr, ...
 * See pltr, pl2tr, ...


 * number
 * Explicitly control which numbers appear. The value is a comma-separated list of one of more of,  ,  . By default, the singular appears unless it is specified as  ; the dual appears when both the singular and plural appear; and the plural appears when at least one plural is given.


 * state
 * Explicitly control which states appear. The value is a comma-separated list of one of more of,  ,   (standing for indefinite, definite, construct). By default, all states appear. (Alternatively, the value can be  , for proper nouns that are syntactically definite but morphologically indefinite. This is equivalent to setting the value to   and adding ind.) Currently, non-"appearing" states are displayed with a dash in place of the appropriate declension members instead of not appearing at all.


 * basestate
 * Override the morphological state. The value is one of,   or  . This can be used e.g. with proper nouns, which are syntactically definite but morphologically indefinite; but using ind-def for this case is preferred.


 * omitarticle
 * If specified, omit the definite article that is otherwise automatically added in the definite state.


 * prefix
 * Specify a prefix to appear before the base word and before any definite article. This is typically a clitic such as or, but can be a separate word such as , in which a space is needed after the word and the whole thing, space and all, needs to be enclosed in quotes since leading and trailing spaces are normally removed in named template arguments.


 * nom_sg_ind, nom_sg_def, nom_sg_con, ...
 * Override particular forms. The param name is a combination of case ( where   is the informal form), number  and state . The value can have semicolons or commas (or Arabic equivalents) to separate distinct stems and a vertical bar to separate alternative spellings for a given stem (typically different possible hamza seats). When overrides are specified, the page will be placed in a category indicating irregular declension such as Category:Arabic irregular nouns (or Category:Arabic irregular pronouns, etc. depending on the part of speech), unless noirreg is given a value.


 * lemma
 * Override the lemma (displayed at the head of the declension table).


 * noirreg
 * If specified, don't place the page in an irregular-declension category when overrides are specified.


 * pos
 * Override the part of speech (displayed at the head of the declension table).

Modifier parameters

 * Stem: mod,modhead2,modhead3,...
 * Alternative manual translit params: modtr,modtr2, ...
 * Plural: modpl,modpl2,...
 * Alternative manual translit params: modpltr,modpl2tr, ...
 * Dual: modd,modd2,...
 * Alternative manual translit params: moddtr,modd2tr, ...
 * Nature of modifier, high-level (ʾiḍāfa or adjectival): idafa
 * Nature of modifier, low-level: modstate,modcase,modnumber,modidafa
 * Other: modomitarticle,modprefix
 * Specify another word that is declined separately as a modifier. Generally only mod is needed, but multiple heads can be given (modhead2, etc., which will be distributed over the base form(s)), as well as separate plural (modpl, etc.) and dual (modd, etc.) forms. All the forms for specifying a base stem, base plural stem, etc. are available in the corresponding modifier stems, and alternative manual translit params also exist. If the modifier has a fixed genitive case in an ʾiḍāfa construction, idafa should be specified, e.g. def for a definite-state singular ʾiḍāfa modifier. See the list below of possible values for this parameter, and the numerous examples below. It is also possible to manually specify the case, state and/or number of the modifier using the lower-level parameters modstate, modcase, modnumber, and/or modidafa possibly in conjunction with basestate, but this is rarely needed. (Underlyingly, the various values of idafa are implemented by setting these low-level parameters. idafa can be combine with the low-level parameters, with the explicitly-specified values overriding the values induced by idafa.)


 * mod2,mod2head2,mod2head3,...; mod2pl,mod2pl2,...; mod2d,mod2d2,...; etc. Also idafa2. Also mod2state,mod2tr, etc.
 * Specify a second modifying word. All parameters specific to the first modifying word have corresponding parameters for the second and higher modifying words. The values for idafa2 are the same as for idafa, but in addition it is necessary to specify e.g. adj-mod for an adjectival modifier that modifies a previous ʾiḍāfa modifier.


 * mod3,mod3head2,mod3head3,...; mod3pl,mod3pl2,...; mod3d,mod3d2,...; etc. Also idafa3. Also mod3state,mod3tr, etc.
 * Specify a third modifying word, etc. up to mod9.

Inflection types

 * Regular triptote.
 * Regular triptote.


 * Regular diptote.
 * Regular diptote.


 * Noun ending in -in, such as . This automatically selects the triptote or diptote variant according to the number (singular vs. plural) and the form of the noun.
 * Noun ending in -in, such as . This automatically selects the triptote or diptote variant according to the number (singular vs. plural) and the form of the noun.


 * Noun ending in -in, forcing the "triptote" variant (with indefinite accusative in -iyan).
 * Noun ending in -in, forcing the "triptote" variant (with indefinite accusative in -iyan).


 * Noun ending in -in, forcing the "diptote" variant (with indefinite accusative in -iya). Most but not all plural nouns use this variant. (Specifically, -iya is used with nouns whose pattern is analogous to a diptote pattern, such as and, which correspond to the diptote pattern CaCāCiC. The "singular" -iyan is used with plural nouns such as , which corresponds to the triptote pattern ʾaCCuC.)
 * Noun ending in -in, forcing the "diptote" variant (with indefinite accusative in -iya). Most but not all plural nouns use this variant. (Specifically, -iya is used with nouns whose pattern is analogous to a diptote pattern, such as and, which correspond to the diptote pattern CaCāCiC. The "singular" -iyan is used with plural nouns such as , which corresponds to the triptote pattern ʾaCCuC.)


 * Invariable declension, such as or . Typically ends in alif or alif maqṣūra, but this is not required. Such words will have sound feminine plurals in -ayāt and duals in -ayān.
 * Invariable declension, such as or . Typically ends in alif or alif maqṣūra, but this is not required. Such words will have sound feminine plurals in -ayāt and duals in -ayān.


 * Invariable declension, loanword-type. Always ends in tall alif. Such words will have sound feminine plurals in -āt and duals in -atān, as if the alif was a tāʾ marbūṭa.
 * Invariable declension, loanword-type. Always ends in tall alif. Such words will have sound feminine plurals in -āt and duals in -atān, as if the alif was a tāʾ marbūṭa.


 * Noun ending in -an, such as or.
 * Noun ending in -an, such as or.


 * Noun with a lengthened construct ending, such as with construct.
 * Noun with a lengthened construct ending, such as with construct.


 * Sound masculine plural in -ūn(a)/-īn(a).
 * Sound masculine plural in -ūn(a)/-īn(a).


 * Sound feminine plural in -āt-.
 * Sound feminine plural in -āt-.


 * Plural ending in -awn(a), esp. of adjectives, such as plural of.
 * Plural ending in -awn(a), esp. of adjectives, such as plural of.


 * Select the appropriate plural form if known, else a strong plural. Equivalent to  for feminines,   for masculines if the singular is of type ,   for other masculines.
 * Select the appropriate plural form if known, else a strong plural. Equivalent to  for feminines,   for masculines if the singular is of type ,   for other masculines.


 * Select the appropriate dual form.
 * Select the appropriate dual form.


 * Indicate that the declension is unknown. All inflections will appear as question marks.
 * Indicate that the declension is unknown. All inflections will appear as question marks.

ʾIdāfa parameter values

 * An ʾidāfa modifier that can exist in multiple states and is of the specified number, e.g. indefinite-state, with corresponding definite state.
 * An ʾidāfa modifier that can exist in multiple states and is of the specified number, e.g. indefinite-state, with corresponding definite state.


 * Same as.
 * Same as.


 * An ʾidāfa modifier that exists in a fixed state (,  or  ) and number ( ,   or  ).
 * An ʾidāfa modifier that exists in a fixed state (,  or  ) and number ( ,   or  ).


 * Same as.
 * Same as.


 * or
 * An adjectival modifier that modifies the base word. Unnecessary to specify; this is the default.


 * ,, etc.
 * An adjectival modifier that modifies a previous modifier word, which must be an ʾidāfa modifier.

A simple example
Normally, it is sufficient to copy the headword declaration for a noun and make minor changes, in particular changing the template name from  to   and removing the gender. For example, for the noun, the headword is declared as follows:

and a declension template can easily be declared by the above minor changes, yielding the following:

which produces the following:

Note that the plural is a diptote, and this is automatically determined by its shape. Generally, diptotes have a shape different from triptotes, and the code is very good at auto-detecting the declension.

A more complicated example
The same trick for generating declensions from headword templates usually works with more complex examples, as well, e.g. with. For this noun, the headword is declared as follows:

Removing the gender and changing the template name yields this:

which produces a correct declension table, even though there is an irregular dual and five broken plurals of three different declensions:

In general, the code is very good at figuring out the correct declension from the form of the stem, and almost always gets it right (but see the following section).

An example where the declension must be manually specified
The code is very good at guessing the declension of a noun or adjective based on its form, but sometimes it needs help. An example is off-shape diptotes, e.g. (also  and ), which needs an annotation like  :

which produces

Nisba nouns
Nisba nouns use special headword templates. A basic nisba noun headword template like this, for :

can be converted to a declension template as follows:

This produces

Note that it is necessary to specify the plural; otherwise the declension table will have only singular. However, it is unnecessary to write out the plural; it is enough to just specify the type (in this case  for sound plural), and the actual form will be inferred from the singular.

When the plural is overridden in the headword, conversion is even easier. An example is. The nisba noun headword template is:

This converts easily to a declension template:

producing

Definite proper nouns
Definite proper nouns like exist only in the definite state. This can be specified using def. The stem should be specified without the definite article, e.g.

which produces

Indefinite proper nouns
Proper nouns like or  or  are morphologically declined only in the indefinite state, but are syntactically definite, and are often diptote. This can be specified using ind-def and adding a diacritic after the stem if needed, e.g.

which produces

Note how the noun is declined as if it is indefinite, but is listed as definite. This would matter, for example, in that a modifying adjective would be in the definite state. (See below for the example of .)

Irregular nouns
Irregular nouns can be specified using overrides.

Irregular example 1
One complex example is the word, which exists only in the construct state and is somewhere between a noun and a demonstrative pronoun.

Its declension can be specified as follows:

yielding

Note that this declension uses a number of advanced features:


 * 1) The singular behaves as a long-construct noun, and is thus specified as , with an annotation indicating that it is a long-construct noun.
 * 2) The declension is restricted to be construct-state-only using con.
 * 3) The plural  is the construct state of a sound masculine plural noun, and hence it is given in the form it would occur if it existed in other states. Furthermore, the pronunciation is irregular, with the first vowel spelled long but pronounced short; as a result, the transliteration is explicitly given with a short vowel. Note that this is automatically declined as nominative, accusative/genitive , with the ending changed appropriately while keeping the stem of both the Arabic and explicit transliteration. (Note, the written-out transliteration of the hamza   appears backwards due to display issues. Underlyingly it is written correctly, as can be seen by editing this page to examine its source code.)

Irregular example 2
An even more complex irregular noun is, which has assimilation between stem and ending in the singular and a different stem in the definite state (both singular and dual). The declension is specified as follows:

Here we have to override the entire singular declension and the definite state of the dual declension in order to get the right forms. We specify the stem as so that the non-overridden part of the dual is correct, but that means we need to override the lemma to get the indefinite nominative singular as the lemma. We also have to explicitly specify the numbers we want to appear; otherwise only singular would appear.

Note that the dual, with ʾalif madda, is automatically constructed correctly from the stem. See below.

Hamza seats
It was noted above that the dual of the stem was correctly constructed as, with an ʾalif madda hamza seat. In general, the code has extensive knowledge of the rules regarding the correct hamza seat in various circumstances and should essentially always get this correct. An example of this knowledge at work is the declension of the words and, declared as follows:



and appearing as follows:

In the former case, the hamza-on-the-line automatically changes into  when the accusative and dual endings are added. In the latter case, the hamza at the end of the stem changes in various ways depending on the ending, e.g. becoming  before  and becoming  before. Before, there are two possible seats, yielding either or. Both forms are displayed in the declension table, separated by the second-level separator (a slash). (The first-level separator, a semicolon, separates distinct stems, especially in the plural.)

ʾiḍāfa construction #1
Some phrases appear as lemmas in Wiktionary. An example is the ʾiḍāfa construction or, both meaning Jerusalem (literally house of the holy place). This is composed of in the construct state, declined according to case, plus  or  in the definite state, genitive case. The declension for this phrase can be expressed as follows:

which produces

ʾiḍāfa construction #2
The previous example had a both head noun and modifier in the singular. However, they can disagree, in which case idafa should reflect the number of the modifier. An example is (literally "day of the two"), where  appears in the dual. The declension for this phrase can be expressed as follows:

which produces

Note that we express in the nominative case and without the definite article; the use of def-du will cause the correct case and state to be generated. We also need to code the modifier using modd to express the fact that it is a dual ( is   +   for "dual").

ʾiḍāfa construction #3
The previous examples had a head noun appearing only in the singular, and only in the definite state. However, many phrases using ʾiḍāfa can appear in all states (definite, indefinite and construct), according to the state of the modifying noun. For example, "bedroom" is, while "the bedroom" is and "her bedroom" is. It also exists in the plural and dual (. This can be expressed using sg, which does not constrain the state, as follows:

which produces

ʾiḍāfa construction #4
An example similar to the previous one but which uses a singulative noun is. is a singulative noun, so we use a singulative noun template. is in the singular; in this case, we have to use {para|idafa|sing}} since that's the closest we can get to a singular number. (For collective nouns we would use coll to indicate the singular.) The declension for this phrase can be expressed as follows:

which produces

As with the previous example, the value of idafa does not constrain the state; thus it will exist in the indefinite, the definite and the construct state.

Adjectival modifier #1
Things are different for adjectival modifiers, which do not need to have their case, state or number fixed. An example is the declension for, literally "strong storm". Both noun and adjective need to be declined for case, state and number. This can be expressed as follows:

which produces

Note the need to express the plural of both noun and modifier. The modifier happens to be the same in the plural as the singular, because inanimate plural nouns are treated as feminine singular; but the dual will be different. In this case there is no need for idafa because an adjectival modifier of the base word is the default.

Adjectival modifier #2
Another example is the declension for. This noun appears only in the definite state and in the plural. This can be expressed as follows:

which produces

Note the use of a  to indicate no singular, with both the main noun and modifier expressed as plurals, so that the declension table labels them as plural rather than singular.

Adjectival construction #3
A tricky example is. Despite appearances this is an adjectival construction, not an ʾiḍāfa construction. is actually a diptote proper noun, morphologically indefinite but syntactically definite, i.e. its declension is indefinite but it is treated grammatically as definite for the purposes of modifiers. This can be expressed using the lower-level parameters to override parts of what is normally generated by idafa (including in its default value of adj). The declension for this phrase can be expressed as follows:

which produces

In this case, we use undefined, which sets the overall state to definite, but declines the base noun as indefinite. (This is equivalent to using .) This is consistent with the fact that the expression is grammatically definite and its modifier will appear with the definite article. Note also that we need to write the modifier in its indefinite form ; the appropriate definite form is automatically generated.

Other similar examples are, and.

Prefix example #1
An example where prefix (actually modprefix) comes in handy is the phrase. The declension for this phrase can be expressed as follows:

which produces

Note the use of a prefix to handle the conjunction, and the automatic implementation of elision in the transliteration.

Another prefix example is found in the documentation for.

Prefix example #2
A similar example occurs with numbers, such as. The declension can be expressed as follows:

which produces

Multiple modifiers #1
Things get more complicated when multiple modifiers are involved, because there are various possibilities: Each of the modifiers can independently be adjectival or ʾidāfa, and a second or further-on adjectival modifier can modify an earlier ʾidāfa modifier rather than the base.

Perhaps the simplest case is when all modifiers are adjectival. An example is. This can appear in multiple states and numbers, e.g. definite plural. This can be expressed as follows:

which produces

Note that the non-personal plural of the feminine adjective happens to be the same as the singular since non-personal nouns take feminine singular agreement, but the modpl parameter still needs to be expressed; likewise for.

Multiple modifiers #2
Another example with entirely adjectival modifiers is, this time only in the definite singular. This can be expressed with a def parameter, as follows:

which produces

Multiple modifiers #3
Consider. has an ʾidāfa modifier and a second adjectival modifier  (the fact that this modifies  and not  is clear from the feminine gender of the adjective). The first, ʾidāfa modifier appears only in the definite state, which can be expressed by def, and the fact that the second adjectival modifier modifies the base noun could be expressed by adj, but this is the default and so can be omitted, as follows:

which produces

Multiple modifiers #4
Another example is. In this case is an ʾidāfa modifier of, and  modifies , meaning it will agree in case, number and state (in this case, fixed to genitive singular definite). This can be expressed as follows, with a parameter adj-mod indicating that the second modifier is an adjectival modifier of the first modifier:

which produces

Multiple modifiers #5
A similar example requiring ind-def is. In this case, is a proper noun, grammatically definite but morphologically indefinite (similar to, above), and  agrees with it, requiring the definite state. This is signalled using ind-def:

which produces

Multiple modifiers #6
An example with two ʾidāfa modifiers which can appear in various states and numbers is, declined as follows:

which produces

Multiple modifiers #7
A complex example with three modifiers is. The first modifier is an ʾidāfa; the second is adjectival, modifying the first, and the third is adjectival, modifying the base. This would be specified as follows:

which produces

ms:Templat:ar-dekl-kn