Difference between revisions of "Afrikaans and English"

From Apertium
Jump to navigation Jump to search
Line 22: Line 22:


Adjectives that are like 'foo', 'fooer', 'fooest' should be translated as 'foo', 'more foo', 'the most foo' sometimes in both directions.
Adjectives that are like 'foo', 'fooer', 'fooest' should be translated as 'foo', 'more foo', 'the most foo' sometimes in both directions.

==== Automatically deriving adjectives from past participles ====

In both English and Afrikaans, many past participles can act as adjectives. If this property is exploited, both the Afrikaans and English dictionaries should shrink.


=== Afrikaans to English ===
=== Afrikaans to English ===

Revision as of 20:37, 9 November 2007

This file contains some observations and a general "TODO" list / discussion.

# Afrikaans
: lit. English
@ English

* Solutions?

Tagger

A tagger needs to be generated. Currently both en-af.prob and af-en.prob are copies of the de-en.prob

Transfer

Both directions

Synthetic to analytic adjectives

Adjectives that are like 'foo', 'fooer', 'fooest' should be translated as 'foo', 'more foo', 'the most foo' sometimes in both directions.

Automatically deriving adjectives from past participles

In both English and Afrikaans, many past participles can act as adjectives. If this property is exploited, both the Afrikaans and English dictionaries should shrink.

Afrikaans to English

SOV to SVO transfer

Example 1
# nie een van hulle die taal     kan praat nie.
: not one of  them  the language can speak not.
  NP                NP           V 

@ [not one of them] [can  speak not] [the language] 
   NP                V                NP
Example 4
# Ek dink  hulle sal  hulp waardeer   van mense  wat Afrikaans ken
: I        think   they     will   help appreciate of   people who   Afrikaans know

  <prpers> <vblex> <prpers> <vaux> <n>  <vblex>    <pr> <n>    <rel> <n>       <vblex>

  NP       VBLEX   NP       VAUX   NP   VBLEX      PR   NP     REL   NP        VBLEX                      

  I  think they  [will help appreciate] of people [who Afrikaans know]
  
  I  think they  [will appreciate help] of people who Afrikaans know

  I  think they  will appreciate help of people [who know Afrikaans]

@ I think they will appreciate help of people who know Afrikaans.
  • <rel> <n> <vblex> -> <rel> <vblex> <n>
  • <vaux> <n> <vblex> -> <vaux> <vblex> <n>
Example 3
# Sterrekundiges kondig   die ontdekking aan van Gliese 581 c, 'n Aarde-agtige planeet buite   ons sonnestelsel wat  lewe mag     onderhou
: Astronomers    announce the discovery      of  Gliese 581 c, an Earth-like   planet  outside our solar system that life may     sustain
Astronomers    announce the discovery      of  Gliese 581 c, an Earth-like   planet  outside our solar system [that life may     sustain]

@ Astronomers    announce the discovery      of  Gliese 581 c, an Earth-like   planet  outside our solar system [that may  sustain life]
  • <dem><n><vaux><vblex> -> <dem><vaux><vblex><n>


Example 5
# Sy het   later badkamer  toe    gevlug nadat   sy  hulle sonder  sukses  gevra het   om te bedaar.
: She had [later bathroom  toward fled   after] [she them  without success asked had ] to    calm down.
           ADV   N         PR     VBLEX  PR      PRN PRN   PR      N       V     V

           ADV   VBLEX PR     N          PR      PRN V     PR      N       V     PRN     
: She had [later fled  toward bathroom   after] [she had   without success asked them] to    calm down.

@ She had later fled toward bathroom after she had without success asked them to calm down.

or 

@ She had later fled toward bathroom after she had asked him to calm down without success.

Double negatives

# nie een van hulle die taal kan praat nie.
: not one of them the language can speak not.

@ [not one of them] [can speak] [the language]

One solution:

  • <vaux><vblex>nie --> <vaux><vblex>

Or... basically drop the extra negative at the end of all sentences (well, at the full stop).

  • nie<sent> --> <sent>
Example 1
# Ek is nie so bekend   met   presies hoe die opstelling werk  nie
: I  am not so familiar with  exactly how the setup      works not 

@ I  am not so familiar with  exactly how the setup      works

Constructions with 'do'

# Nee, ek het  ook  nie       'n idee wat  dit beteken nie

No,  I [have also not]      an idea what it  means   not

No,  I [also have not]      an idea what it  means

No,  I [also do   not have] an idea what it  means

No,  I [also don't    have] an idea what it  means

@ No, I don't have an idea what it means either

Tenses

The ge<verb> construction
Fixed — If broken, report a bug!

The past tense is formed regularly by adding the prefix ge- to the verb's infinitive/present form.

  • Ek breek - I break
  • Ek het gebreek - I broke, I have broken, I had broken
het               gebreek
^het<vaux><pres>$ ^ge<past><prefix>+breek<vblex><inf>$

= breek<vblex><past>

= break<vblex><past>

Separable verbs

Main article: Separable verbs
  • Ek tree op as verteenwoordiger"
  • I act as representative"
  tree op
  op+tree
  optree

= act or perform

  • Sterrekundiges kondig [die ontdekking] aan.
  • Astronomers announce [the discovery].
  konding <NP> aan
  aan+kondig
  aankondig

= announce.


Other examples

e.g. terugkry, oopmaak, weghardloop, teruggebring, aankondig, afkondig, verkondig, opgedaag, aangerand, aangesê, teëgekom, weggekom, uitgeklim

For example:

teruggekry
terug+ge+kry

back+PAST+get

= got back

List of prepositions: terug, oop, op, weg, aan, af, ver, teë, uit, ...

More examples: that don't work!!!

aangery
aan+ge+ry

lit. on+PAST+ride = rode on

= drove
grootgeword
groot+ge+word

lit. big+PAST+become = became big

= grew up

Multi-prepositions

  • om met
  • om uit
  • oor te
  • om in
  • toe om
  • nou dat -> now that
  • uiteindelik -> at last
  • ... list more here ...

Generating correct tense forms

  • Ek gaan ... verbind -> I will connect
  • Ek het gaan verbind -> I have gone to connect

The problem is that we have to wait until interchunk to find out if the verb is next to 'gaan' or not.


English to Afrikaans

Adjective inflection

Fixed — If broken, report a bug!

Attributive = before noun Predicative = after noun

Adjectives in Afrikaans sometimes change depending on their position. Adjectives in the attributive position often morph. e.g.[1]

Die blompot is goud. > Die goue   blompot.
The vase    is gold. > The golden vase.

goud -> goue

This    man is     most famous   , this    is the most famous   man
Hierdie man is die meeste beroemd, hierdie is die mees beroemde man

Rule that says:

  • <adj><noun> -> <adj><attr><noun>
  • <noun><adj> -> <noun><adj><pred>

Determiners

His dog is red.
Sy hond is rooi.

This is his dog, the dog is his = 
Dit is sy hond,  die hond is syne.

Verbs

That was a nice = Dit was lekker, Dit was lekker gewees

It was a good poem = Dit was 'n goeie gedig, dit was 'n goeie gedig gewees

It will be a good poem = dit sal 'n goeie gedig wees

It would have been a good poem = Dit sou 'n goeie gedig gewees het.

it would have been a good idea = dit sou 'n goeie idee wees, dit sou 'n goeie idee gewees het (both correct)

it would have been a good poem = dit sou 'n goeie gedig gewees het (only this form is correct)

Separable verbs

afskei, oplaai, inkoop, aftel

Ek het  dit op   die kar gelaai.
I  have it  into the car loaded.

I loaded it onto the car

Present progressive

to be + verb gerund -> verb present + tans

Note, this is not perfect because many times English uses the present progressive (e.g. I am writing a letter) where Afrikaans would use the present indicative (e.g. I write a letter).

Examples
"The highest point is     currently being debated"
 Die hoogste punt  word   huidiglik       gedebatteer
`The highest point become currently       debated'
"The boy  is being    selfish"
 Die seun is besig om selfsugtig te wees
`The boy  is busy  ** selfish    to be'
"I am eating"
 Ek   eet
`I    eat'

Passive sentence structure

Passive
  • [In other countries] [trade unions] are actively suppressed [by political or military regimes]
  • [In ander lande] word [vakbonde] aktief onderdruk [deur politieke en militêre regimes]
*         [trade unions] are    actively suppressed [by regimes]
*          NP            VBSER  ADV      VBLEX+PAST  PR NP
* word    [vakbonde]            aktief   onderdruk  [deur regimes]
* BECOME   NP                   ADV      VBLEX       PR   NP

* NP VBSER ADV VBLEX+PAST PR NP -> VBLEX NP ADV VBLEX PR NP

Perhaps we need to have a separate tag for "to become" ?

"word" ("ge-") vb. (copula) become, get (angry, cold, dark, drunk, late, tired); grow (old); go (blind, mad); turn (grey, pale, Democrat); fall (due, dumb, silent, ill, in love); (pass. auxiliary) is, are, (infml.) get;


Active
  • [In other countries political or military regimes] actively suppress [trade unions]
  • [In ander lande] onderdruk [politieke en militêre regimes] [vakbonde] aktief

Double helpwerkwoorde

<Anrie> "was die kodenaam het gegee" = "was die kodenaam gegee" (no "het")
<Anrie> I think in this instance there is no "het", because we already have "was" 
<Anrie> Thus: I saw him - Ek het hom gesien, but He was seen - Hy was gesien

Infinitives

another preposition: "to" do something = "om" iets "te" doen, thus it's not 

"sy missie: na behaal", but 

"sy missie: om te behaal" 

(of course, this isn't strictly correct, since the verb should come at 
 the end, but I assume we're leaving those type of errors for now)

Roadmap

apertium-en-af 0.1

  • 5,000 of the highest frequency words in each dictionary.
  • Rules dealing with basic verb tenses (past, present, future)
  • "cheaty" prepositions using <pr><vblex> -> <vblex> <pr>
  • Basic word re-ordering for simple phrases.
  • Word error rate (WER) ~20%
Aims and uses
  • For a non-native speaker to be able to discern the topic of a general news item.
  • To be able to identify who said what to who.
  • To be able to distinguish is a particular item is interesting enough to be translated properly.
  • Sentences of up to 5 words should be translated reasonably well in both directions.
  • To give better translations than interpret.co.za.

apertium-en-af 0.3

  • Clean up.
  • Arrange the dictionaries in a more sane manner, check sections.
Aims and uses
  • No new features.

apertium-en-af 0.5

  • Correct dealing with detachable prepositions.
  • Correct translation of active/passive.
  • Word error rate (WER) ~20% - ~15%
Aims and uses
  • Post-editing translation made by Apertium should be slightly faster than translating from scratch.
  • Sentences of up to 7 words should be translated reasonably well in both directions.

apertium-en-af 1.0

  • 10,000 of the highest frequency words in each dictionary.
  • Compound noun identification and translation.
  • Rules dealing with
Aims and uses
  • Post-editing should be markedly faster than translating from scratch.
  • Sentences of up to 12 words should be translated reasonably well in both directions.

Evaluation material

Main article: Evaluation material for English to Afrikaans

The link above gives apertium output and post-editted apertium output that can be used to calculate the WER or PER for the apertium-en-af pair.

Dictionaries

Competing products

Apertium output to compare in green

interpret.co.za

Vir elke Engelse woord moet jy een Afrikaanse woord kies en dis nie altyd so duidelik wat om te kies nie.
"for each english word must you one afrikaans word choose and it's not always so clear that/what to select not."
"For each English word you must choose one Afrikaans word and it is not always so clear wat to choose ."
Hierdie man is die meeste beroemd, hierdie is die mees beroemde man
"this man is the most famous , this is the most renowned man ..."
"This man are the most famous, #this are the #most famous man"
Die polisie het hom geboei en agter in die bakkie gesit. By Mimosa is hy laat gaan. Hy het glo nie sy selfoon teruggekry nie. Nel het na bewering ook weggehardloop en in 'n boom geskuil.
"the police have him handcuffed and behind in the bakkie sat down . at mimosa is he allow goes . he has believe not she/his selfoon teruggekry not . nel have allegedly also weggehardloop and in a tree geskuil. ..."
"The police had him handcuffed and after put in the truck. At Mimosa are he allows go. He had believe not got #back #his mobile phone . Nel had allegedly also ran away and hid in a tree."
Mnr. Prince Mbiza van die Mpumalanga-nooddienste was een van die eerste paramedici op die toneel. Hy het gister gesê Matthysen is klaarblyklik dood weens “ernstige kopbeserings”.
"mr . prince mbiza of the mpumalanga-nooddienste has been one of the first paramedici on the scenic . he has yesterday being said matthysen is evidently dead on account of “ernstige kopbeserings”."
"Mr. Prince Mbiza of the Mpumalanga-emergency services were one of the first paramedics on the scene. He had yesterday said Matthysen are evidently dead owing to “serious head injuries”."

Literary Afrikaans

Listed below are the first two pages of Ons is nie almal so nie by Jeanne Goosen. I decided a few days ago that it might be beneficial to focus on more than just academic Afrikaans, which is why I have listed the translations below of the first two pages from the original Afrikaans text to the English translation made by Apertium. If you decide to pursue the advancement/development of literary Afrikaans along with academic Afrikaans, I can post more excerpts (tspier2).

My ma en ant Mavis hou langs die hoenderhok stil met my pa se Plymouth. Hulle raas en lag so dat ou mrs Haasbroek se hond oorkant die straat begin blaf. "Sjoes!" skree ant Mavis. Hulle kom by die agterdeur in. "Was my kind soet?" vra my ma. Sy haal 'n pakkie uit haar sak, hou dit teen die lig en lees: "Which twin has the Tony ..." Ant Mavis sit die water op vir tee. "Ag, ou Doris," sê sy, "jy gaan mos 'n goeie job maak van my perm, nè?" "Don't fear when Doris is near," lag my ma. "Gertie," sê sy vir my, "gaan haal vir ons bordjies." Sy haal drie doughnuts uit 'n kardoes. Ant Mavis kry die koppies reg en my ma sit 'n doughnut op elke bordjie. Ons gaan sit by die kombuistafel. "Nothing to beat die Homepride se doughnuts," sê ant Mavis met 'n vol mond. "Eet my kind lekker?" vra my ma. Sy buk vooroor en soen my.

My mother and ant Mavis keep next to the hoenderhok stil with my father's Plymouth. They raas and lag so that old mrs Haasbroek 's dog oorkant the street underway blaf. "Sjoes!" skree ant Mavis. They come at the agterdeur in. "Were my soet child?" ask my mother. She fetch a packet from her sack, keep it at the light and read: "Which twin has the Tony ..." Ant Mavis put the water on for tee. "Deem, old Doris," say her, "you go moss a good job make of my perm, nè?" "Don't fear when Doris are near," lag my mother. "Gertie," say she for my, "go fetch for us bordjies." She fetch three doughnuts from a kardoes. Ant Mavis get the cups right and my mother put a doughnut on each bordjie. We go put at the kombuistafel. "Nothing to beat the Homepride 's doughnuts," say ant Mavis with a full mouth. "Eat my child lekker?" ask my mother. His buk vooroor and soen my.

Ant Mavis kap saggies op my kop met haar teelepel. "Ou, blou-oog!" Ek lag. My ma en ant Mavis kan partykeer so snaaks wees. "Gertie," sê my ma, "gaan haal gou vir ons die lang spieel in Ma-hulle se kamer, dan gaan sit jy soet op die vloer met jou puzzle. Ons gaan ant Mavis se hare perm." Sy vat-vat aan haar eie hare, maak haar oë groot. "Ou Tank gaan sy girl nie ken as hy haar vanaand sien nie. Skoon seesiek gaan hy word van al die waves." Ant Mavis en my ma werk in die aande en een Saterdagmiddag in die maand met die matinées in Parow se Victoria bioscope. Hulle is usherettes. Ant Mavis is my ma se beste vriendin. Sy en my ma dra swart skirts en wit blouse as hulle gan usher. Hulle dra ook 'n ronde, plat hoedjie agter op hul koppe wat met hairpins vasgesteek word. Eintlik is dit nie 'n hoed nie. Dit lyk meer soos die ronde pannetjies waarin my ma koek bak vir wanneer my oupa kom kuier. Net dieper. Ant Mavis is vet en jolly. Sy blaas rook deur haar neus wanneer sy 'n Cavalla aansteek.Sy kuier omtrent elke môre by ons. Partykeer sit sy en my ma op die voorhuisvloer en speel plate op ons Pilot. Hulle hou van musicals soos "Showboat" en "Naughty Marietta." My ma het al Jeanette MacDonald en Nelson Eddy se plate. Elke keer wanneer my ma "Maytime" speel, sing sy en ant Mavis saam wanneer Jeanette MacDonald by die stuk kom waar sy "Sweetheart, sweetheart" sing. Hulle oë word dan vol trane.

Ant Mavis kap saggies on my kop with her teelepel. "Old, blue-eye!" I lag. My mother and ant Mavis can partykeer so snaaks be. "Gertie," say my mother, "go fetch quickly for us the long spieel in adj>-they 's room, then go put you soet on the vloer with your puzzle. We go ant Mavis 's hair perm." She seizes-seize to her own hair, make her large eyes. "Old Tank go his girl not know as he adj> vanaand see . Clean seesiek go he becomes of already the waves." Ant Mavis and my adj> work in the evenings and one Saturday midday in the month with the matinées in Parow 's Victoria bioscope. They are usherettes. Ant Mavis are my mother's best vriendin. She and my mother carry black skirts and white blouse as them gan usher. They carry also a ronde, plat hoedjie after on their koppe what with hairpins vasgesteek become. To tell the truth are it not a hoed . It looks more like the ronde pannetjies wherein my adj> koek bak for when my oupa come visit. Only deeper. Ant Mavis are adj> and jolly. His blaas smoke by her neus when she a Cavalla aansteek.She visits almost each môre at us. Partykeer put her and my mother on the voorhuisvloer and play records on us Pilot. They keep of musicals like "Showboat" and "Naughty Marietta." My mother have already Jeanette MacDonald and Nelson Eddy 's records. Each time when my adj> "Maytime" play, sing her and ant Mavis together when Jeanette MacDonald at the stuk come where she "Sweetheart, sweetheart" sing. Them become eyes then full tears.