Hello Werner,

> While you can press a button in most web browsers to translate English
> pages on the fly, due to the many musical and LilyPond-specific
> technical terms there are inevitably flaws, that make the results
> misleading.  Such online translations also don't give you translated
> PDF manuals.
> 
> I thus wonder whether a guy with LLM experience could help with
> updating the German translation of the Notation Reference – or rather,
> generating a complete translation from scratch, since the German
> translation is severely outdated.  Today, websites like Google
> Translate provide translations (both German-to-English and
> English-to-German) that are nearly perfect even for quite complicated
> grammatical structures, which still amazes me.
> 
> This is intended as an experiment that could start with a few
> chapters, say, to find out whether such an approach is feasible.  Of
> course, we would have to discuss the conditions for the LLM to get a
> good result.  In spite of the grammatical quality I expect that a lot
> of technical terms will be mistranslated; we thus have to proofread
> the results (I volunteer for that).
> 
> What do you think?

I don’t thinks this solves the underlying problem. I think the problem here 
stems
from having individual independent documentation files, which induces a massive
workload to contributors and translators for keeping up with changes and sync 
them to translations.

And I think even if we were to use LLMs to automatically translate the 
documentation — we‘ll still need
to keep documentation synced, so someone would need to realize: Translation is 
not up to date, so
trigger the LLM, check output, update translation. I suppose if LLMs were 100% 
reliable we could get
rid of the localisations in the first place and translate docs on the fly, 
which would solve this. But
that is not realistic.

But then, the Documentations are filled with texts that are more or less 
trivial to translate, where
probably the effort of updating the translation is not more than checking the 
output of the LLM
and potentially correcting that. The main issue in translation is keeping all 
changes synced up.

It would rather be thinkable have the english documentation as a master document
and use automated tooling to create the localizations from diffs — recognizing 
outdated blocks on the
fly and potentially falling back to the original English text, as is done in 
pretty much any concept of
software localization out there.

And this would be fairly easy: Our documentation is naturally made up of nodes 
looking like

```
@node Title
... content ...
```

Rather than replicating this for translations we could translate things by 
node, that is to say,
have a script collect all nodes in the main documentation, looking at the 
translation pool for a
translation for the same node which would have a fingerprint of the original 
node annotated,
check the fingerprint, and if it matches replace the content of the node, else 
issue a warning
and use the original node.

E.g. for

```
@node Text
@chapter Text

@lilypondfile[quote]{snippets/text-headword.ly}

This section explains how to include text (with various
formatting) in music scores.


@node Writing text
@section Writing text

This section introduces different ways of adding text to a score.

@cindex text, other languages
@warning{To write accented and special text (such as characters
from other languages), simply insert the characters directly into
the LilyPond file.  The file must be saved as UTF-8.  For more
information, see @ref{Text encoding}.}
```

the translation could specify

```
@ignore
    source-commit: e5a609e373eae846857f9a6d70a402a3d42b7d94
    source-sha256: 
c746ad20e3ba4ddde5e132499c2e85a432fe0dadb875bee03b0a3980782a0edc
@end ignore
@node Text
@chapter Text

@lilypondfile[quote]{snippets/text-headword.ly}

Dieser Abschnitt erklärt, wie man Text (mit vielfältiger
Formatierung) in Partituren einfügt.

@noindent
Einige Textelemente, die hier nicht behandelt werden, finden sich
in anderen Abschnitten: @ref{Vocal music}, @ref{Titles and headers}.


@ignore
    source-commit: e5a609e373eae846857f9a6d70a402a3d42b7d94
    source-sha256: 
bb4896a713969c135ecd1eda8a477dcb2582291e47742cd50def8455d58c552b
@end ignore
@node Writing text
@section Text eingeben

Dieser Abschnitt zeigt verschiedene Arten, wie Text in die Partitur
eingefügt werden kann.

@cindex Text, andere Sprachen

@warning{Wenn man Zeichen mit Akzenten und Umlaute oder besondere
Zeichen (wie etwa Text mit anderen Alphabeten) eingeben möchte,
kann man die Zeichen einfach direkt in die Datei einfügen.  Die
Datei muss als UTF-8 gespeichert werden.  Für mehr Information
siehe @ref{Text encoding}.}
```

So now a script would take the node “Text” in the original, find the 
translation node “Text”,
would check if the hash matches, and if so replace the original node by the 
translation node.

If the translation node does not exist it would issue a warning: "Translation 
of node `xyz` does not exists",
similar if the hash does not match it would issue a warning: "Translation of 
node `xyz` is outdated".
Additionally the script could identify translation nodes that are no longer 
needed.

Then the translators would get a precise pinpoint where they need to update 
things and at any
point (even if parts of the translation are outdated) the content of the 
translation is up to date.

At least for me this would make translation much easier. The biggest blocker 
for me to just invest
a bit of time to fix up the German docs is that my brain is completely 
overwhelmed by syncing
the structure.

Not saying LLMs cannot be helpful in assisting translation, especially when you 
don’t speak
a language perfectly and have issues finding the right words.

Cheers,
Tina

P.S.: Translating this small part of the notation reference via chatGPT gives

```
@node Text
@chapter Text

@lilypondfile[quote]{snippets/text-headword.ly}

In diesem Abschnitt wird erläutert, wie Text (mit verschiedenen
Formatierungen) in Notensätze eingefügt werden kann.

@node Text schreiben
@section Text schreiben

Dieser Abschnitt stellt verschiedene Möglichkeiten vor, Text zu einem
Notensatz hinzuzufügen.

@cindex Text, andere Sprachen
@warning{Um Zeichen mit Akzenten oder andere Sonderzeichen (z. B.
Zeichen aus anderen Sprachen) zu schreiben, fügen Sie diese einfach
direkt in die LilyPond-Datei ein. Die Datei muss im UTF-8-Format
gespeichert werden. Weitere Informationen finden Sie unter
@ref{Textkodierung}.}
```

which is ... well, okay, but not very well written German. Yes, by additional 
prompt we could
get it to be more idiomatic. But still this shows that the output from 
something like chatGPT
is just a machine translation.

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to