KDE Core/OpenCodes: Difference between revisions

From KDE Community Wiki
(Created page with "The OpenCodes project is part of the KDE_Core/KDE_Open_Data KDE Open Data initiative seeking to develop a standard json file format for ISO Codes and to provide a set of d...")
 
No edit summary
Line 1: Line 1:
The OpenCodes project is part of the [[KDE_Core/KDE_Open_Data KDE Open Data]] initiative seeking to develop a standard json file format for ISO Codes and to provide a set of data files derived from Wikidata.
The OpenCodes project is part of the [[KDE_Core/KDE_Open_Data|KDE Open Data]] initiative seeking to develop a standard json file format for ISO Codes and to provide a set of data files derived from Wikidata.


== Architecture==
== Architecture==

Revision as of 13:57, 6 July 2014

The OpenCodes project is part of the KDE Open Data initiative seeking to develop a standard json file format for ISO Codes and to provide a set of data files derived from Wikidata.

Architecture

OpenCodes will be a single git repository containing a set of scripts to maintain the ISO Codes data as well as the data files themselves. The repo will not contain any code APIs to utilise the data, this is to ensure the project is completely standalone and can be utilised by as many other projects as possible.

A python script will use the Wikidata Query API once available (or other tools such as Autolists in the interim) to list all Items for the ISO code Property and then obtain all the required Properties for each Item instance. This data will then be merged with any extra fields OpenCodes requires and written to the base set of json files which will be committed to the repo.

A second python script will generate the payload files from the base files in a choice of formats:

  • Data as separate files for each ISO code instance or a single file containing all instances
  • Translations as .po files or JSON translation files (node.js format, and any others) or inline in data files


For Linux installs generated using 'make install' the base files will be installed to /usr/share/opencodes and .po translation files installed to /usr/locale/.

Translations will be sourced from both Wikidata and KDE. It is expected that Wikidata will have a greater number of languages supported than KDE so will be the preferred source, but KDE may have some languages unsupported in WIkidata so we need to cater for this. It is hoped KDE translators will submit translations directly to Wikidata, but we cannot automate this as Wikidata uses CC-0 licensing.

Country Code

JSON File Format

Wikidata Feed

The following Items will be used: