Browse Source

Issue #122 Documentation: need to know how verb/noun indicators are calculated

master
Valdis Vitolins 9 years ago
parent
commit
0176852375
1 changed files with 25 additions and 20 deletions
  1. 25
    20
      docs/dictionary.md

+ 25
- 20
docs/dictionary.md View File

@@ -307,18 +307,13 @@ brackets, because the two parts are considered as separate words.
|----------------------|-------------|
| `_^_<language code>` | Translate using a different language. See explanation above. |

### 3 Flags
### Flags

A word (or group of words) may be given one or more flags, either
instead of, or as well as, the phonetic translation.

| Symbol | Description |
|----------------------|-------------|
| `$u` | The word is unstressed. In the case of a multi-syllable word, a slight stress is applied according to the default stress rules. |
| `$u1` | The word is unstressed, with a slight stress on its 1st syllable. |
| `$u2` | The word is unstressed, with a slight stress on its 2nd syllable. |
| `$u3` | The word is unstressed, with a slight stress on its 3rd syllable. |
| `$u+ $u1+ $u2+ $u3+` | As above, but the word has full stress if it's at the end of a clause. |
| `$1` | Primary stress on the 1st syllable. |
| `$2` | Primary stress on the 2nd syllable. |
| `$3` | Primary stress on the 3rd syllable. |
@@ -326,33 +321,43 @@ instead of, or as well as, the phonetic translation.
| `$5` | Primary stress on the 5th syllable. |
| `$6` | Primary stress on the 6th syllable. |
| `$7` | Primary stress on the 7th syllable. |
| `$u` | The word is unstressed. In the case of a multi-syllable word, a slight stress is applied according to the default stress rules. |
| `$u1` | The word is unstressed, with a slight stress on its 1st syllable. |
| `$u2` | The word is unstressed, with a slight stress on its 2nd syllable. |
| `$u3` | The word is unstressed, with a slight stress on its 3rd syllable. |
| `$u+ $u1+ $u2+ $u3+` | As above, but the word has full stress if it's at the end of a clause. |
| `$pause` | Ensure a short pause before this word (eg. for conjunctions such as "and", some prepositions, etc). |
| `$brk` | Ensure a very short pause before this word, shorter than $pause (eg. for some prepositions, etc). |
| `$only` | The rule does not apply if a prefix or suffix has already been removed. |
| `$onlys` | As $only, except that a standard plural ending is allowed. |
| `$stem` | The rule only applies if a suffix has already been removed. |
| `$onlys` | As `$only`, except that a standard plural ending is allowed. |
| `$stem` | The rule only applies if a suffix has already been removed (i.e. word had to have suffix before). |
| `$strend` | Word is fully stressed if it's at the end of a clause. |
| `$strend2` | As $strend, but the word is also stressed if followed only by unstressed word(s). |
| `$unstressend` | Word is unstressed if it's at the end of a clause. |
| `$atend` | Use this pronunciation if it's at the end of a clause. |
| `$double` | Cause a doubling of the initial consonant of the following word (used for Italian). |
| `$capital` | Use this pronunciation if the word has initial capital letter (eg. polish v Polish). |
| `$allcaps` | Use this pronunciation if the word is all capitals. |
| `$dot` | Ignore a `.` after this word even when followed by a capital letter (e.g. `Mr.` and `Dr.`). |
| `$hasdot` | Use this pronunciation if the word is followed by a dot. (This attribute also implies `$dot`). |
| `$sentence` | The rule only applies if the clause includes end-of-sentence (i.e. it is not terminated by a comma). For example, `$atend $sentence` means that the rule only applies at the end of a sentence. |
| `$abbrev` | This has two meanings. If there is no phoneme string: Speak the word as individual letters, even if it contains a vowel (eg. "abc" should be spoken as "a" "b" "c"). If there is a phoneme string: This word is capitalized because it is an abbreviation and capitalization does not indicate emphasis (if the "emphasize all-caps" is on). |
| `$accent` | Used for the pronunciation of a single alphabetic character. The character name is spoken as the base-letter name plus the accent (diacritic) name. eg. It can be used to specify that "â" is spoken as "a" "circumflex". |
| `$double` | Cause a doubling of the initial consonant of the following word (used e.g. for Italian and Finnish). |
| `$alt $alt2 .. $alt7`| These 7 groups are language specific. Their use should be described in the language's `*_list` file. `$alt` and `$alt1` are synonyms.|
| `$combine` | This word is treated as though it is combined with the following word with a hyphen. This may be subject to further conditions for certain languages. |
| `$alt $alt2 $alt3` | These are language specific. Their use should be described in the language's `*_list` file. |
| `$verb` | Use this pronunciation if it's a verb. |
| `$noun` | Use this pronunciation if it's a noun. |
| `$past` | Use this pronunciation if it's past tense. |
| `$dot` | Ignore a `.` after this word even when followed by a capital letter (e.g. `Mr.` and `Dr.`). |
| `$hasdot` | Use this pronunciation if the word is followed by a dot. (This attribute also implies `$dot`). |
| `$max3` | Limit to 3 repetitions in pronunciation.|
| `$text` | Word translates to replacement text, not phonemes.|
| `$verbf` | The following word is probably is a verb. |
| `$verbsf` | The following word is probably is a if it has an "s" suffix. |
| `$nounf` | The following word is probably not a verb. |
| `$pastf` | The following word is probably past tense. |
| `$verb` | Use this pronunciation if it's a verb, i.e. previously processed word had `$verbf` or `$verbsf` set.|
| `$noun` | Use this pronunciation if it's a noun, i.e. previously processed word had `$nounf` set.|
| `$past` | Use this pronunciation if it's past tense, i.e. previously processed word had `$pastf` set.|
| `$verbextend` | Extend the influence of `$verbf` and `$verbsf`. |
| `$capital` | Use this pronunciation if the word has initial capital letter (eg. polish v Polish). |
| `$allcaps` | Use this pronunciation if the word is all capitals. |
| `$accent` | Used for the pronunciation of a single alphabetic character. The character name is spoken as the base-letter name plus the accent (diacritic) name. e.g. It can be used to specify that "â" is spoken as "a" "circumflex". |
| `$accent_before` | used with accent names, say this accent name before the letter name. |
| `$atstart` | Use this pronunciation if it's at the start of a clause. |
| `$atend` | Use this pronunciation if it's at the end of a clause. |
| `$sentence` | The rule only applies if the clause includes end-of-sentence (i.e. terminator is {. ? !} not {, ; :}). For example, `$atend $sentence` means that the rule only applies at the end of a sentence. |
| `$native` | Not used, if switched to other translation. |

The last group are probably English specific, but something similar may
be useful in other languages. They are a crude attempt to improve the

Loading…
Cancel
Save