unfoldingWord-box3 / td

Gateway Language Database Prototype
https://td.readthedocs.io/
MIT License
0 stars 1 forks source link

Define Data Model for Languages in RTD System #5

Open timjore opened 7 years ago

timjore commented 7 years ago

this should be designed from the data currently in tD and exported from it into the YAML data for each language card.

jag3773 commented 7 years ago

Latest example may be seen in here. Essentially, each registered IETF language code will have a top level directory in the languages directory.

Inside each IETF language code folder will be the head language code entry and any private use or specific variations built off that language code. As an example:

languages/
    es/
        es.rst
        es-419.rst
    gaj/
        gaj.rst
        gaj-x-ymnk.rst

Potentially, in order to make importing updated data from other sources, we may want to split such data into separate files also. For example, data imported from Wikipedia for a particular language could show up in a [lang_code]_wikipedia.rst file in the directory for that language. Extra information about Spanish from Wikipedia would be in languages/es/es_wikipedia.rst. This data could be inlined (transcluded) into the main es.rst file for display.

Gateway language information will likely be included in the YAML for the other language. We will likely need a special script to process this information to generate mapping information (for #4 as an example).

jag3773 commented 7 years ago

Need to ensure that we are linking to other sites that provide language information by default. Should include at least:

jag3773 commented 7 years ago

The working model for this is http://td.readthedocs.io/en/latest/languages/ca/ca.html .

jag3773 commented 7 years ago

We probably want to use verbose field names to make it easier for people to understand. For example, use language_name instead of lang_name. Alternately, it may be appropriate to drop all "lang" prefixes as that is what the data is all about.