SparqFest stores all site content in a “dictionary” that maps placeholders in our site templates to translations in our supported languages (the article Languages and Localization discusses language support in detail). We allow you to customize any text by editing this dictionary.
Leveraging this customization feature, you can alter SparqFest terminology to match that of your festival or tweak translations that you don't like.
Searching the Dictionary
The dictionary can be found in “Settings” > “Web Site” on the “Dictionary” tab. You originally configured the languages your site supports on this tab. Below the language configuration area is a field you can use to search the dictionary:
Note: the above video shows an older user interface. This same interface is now available in “Settings” > “Web Site” > “Dictionary”.
In the above video, the user is navigating to the dictionary tab and then searching for the text “trailer”. Every place the word “trailer” appears on the web site or in SparqFest-generated emails then shows up the search results.
Each dictionary entry contains the following:
- “Word” - a translation key to identify the word across all languages
- “Dictionary” - the dictionary in which it appears (commonly, “public” or “email”)
- “Language” - the language that matched your search terms
- “Matching Text” - the full text matching your search terms with your search terms highlighted in bold blue
We chose this example because it is one where a festival that showcases TikToks might want to alter the term “trailer” to be “promotional video”. Now that they have found every instance of “trailer”, the director of this festival can now make the change.
Customizing Text and Translations
There are two core reasons you would want to edit the dictionary:
- SparqFest terminology does not match yours
- You don't like a translation for a specific term or phrase
Customize Text Only Where Necessary
Just because you can do something does not mean you should! Customizing text is very time consuming with little real benefit to a festival staff who is likely already overtaxed with tasks in preparation for the festival. The TikTok example above is one situation where there is a solid payoff.
To edit a particular dictionary term, click on that term and an editor will appear:
The dialog presents all translations for that translation key in the languages you configured for your site. You can change a single translation or all of them. If you would like a machine translation done for a certain language, clear it out and SparqFest will perform a machine translation when you save.
Beware the Word “Trailer”
Trailer is a word that does not translate well into the languages using machine translation. You will likely end up with the thing that gets hitched to the back of a truck!
Formatted Content and Pluralization
When reviewing translations, you may encounter things that appear to be nonsense like “Title in {0}” or “{0} selections,{1} selection,{*} selections”. These are examples of formatted content and plurals.
As a general rule, the translation key for plurals starts with PLURAL_. Everything else that has a {0} or {1} is formatted content. The numbers in the braces are placeholders for other content.
Formatted Content
The placeholder for “Title in {0}” enables more complex translations for expressions like “Title in English”. Where SparqFest needs to construct more complex expressions from simpler expressions and the word order can vary from language to language, we use these formatted content expressions. The {0} simply represents “the first replacement term”. A more complex format might be “Put {0} in {1}”. In that case, the {0} is the first replacement term and the {1} the second replacement term.
Pluralization
If you know languages outside the Germanic and Romance context, then you are aware that plurals can sometimes be much more complex than “0 dogs, 1 dog, 2 dogs, 5 dogs”. In Russian, for example, the pluralization is “0 собак, 1 собака, 2 собаки, 5 собак”. One, two through four, and five+ are three different plural forms. Hawaiʻian, on the other hand, rarely changes the noun form and simply indicates plural based on the article.
In spite of the fact that SparqFest currently supports no languages with this kind of pluralization complexity, our translation engine does support it. The format is a comma-separated list of numbers and the plural form of the translated term:
- {0} children, {1} child, {*} children
- {0} Kindern, {1} Kind, {*} Kindern
- {0} enfants, {1} enfant, {*} enfants
It's the same for every language we currently support. {0} for the plural form of 0 items, {1} for the plural form of 1 item, and {*} for anything not captured by a specific number.
For completeness sake (in case we add support for a language like Russian without updating this document), more complex plurals can be shown this way:
{#0} собак, {#1} собака, {#2-4} собаки, {#11-14} собак, {*} собак
The use of the # before the number indicates that the plural form for {#1} applies not only to 1, but to any number ending in 1. In other words, in Russian, it's 21 собака but 25 собак. And, yes, 11-14 break this rule.