Meanwhile, for storing multi-lingual values of a "Wikidata Item" in DM 4:
For text values i now use a foursome of values, defined in a custom wikidata composite as "org.deepamehta.wikidata.entity_value" of which an item can have _many_. "Label, Alias and Description" are the three values (half the part of an ItemDescription in Wikidata) which correspond with a "ISO Language Code". The drawback is, as described here earlie, now I have to load all child topics of this composite type and can not filter for (select just) those with the child-topic value set to e.g. "en". Just wanted to let you know about the developments, for more see (or details of the complete model i currently wrap wikidata), e.g. line 65 https://github.com/mukil/dm4-wikidata-toolkit/blob/geo-fronts/src/main/resources/migrations/migration3.json Cheers! On Wed, 25 Mar 2015 20:55:55 +0100, <[email protected]> wrote: > hey there, > > i was thinking about how to best model multi-lingual (composite) values > for, e.g. "ingredients" of a "recipe" [1] in deepamehta4. > > Optimal would be, querying wise, from any given topic id i can load _just_ > the child-topics (of e.g. valueTypeUrI) related via a specific > language-code. > > The requirements i see are twofold: > 1 loading just those related topics given an addtional (iso-language-code) > key > e.g. 'topic.getRelatedTopics("..aggregation", "..default", "..default", > valueTypeUri, "DE")' > background: loading child-topic values for 200 languages instead of the > 1 needed seems very much overhead > > 2 staying flexible: introducing new iso-language-codes to query as they > come by / are created. > > Am i correct that (currently) the only way to fetch the child-topics > (related to my topic via a specific "language-code"/value) is modelling > this "language code value" as a facet type (which then relate to my > valueTypeUri)? > > And what would you think about the going for the other option, to extend > the query-power by a 'getRelatedTopicsByChildTopicValue()' topic api call > (similar to the one sketched above) in contrast to building on the facet > api for multi-lingual values? > > > Thanks for your thoughts & Cheers! > > > > -- > [1] schema could be relatively simple, similar as found in "Recipe" at > http://json-ld.org/playground/ -- devel mailing list [email protected] http://lists.deepamehta.de/mailman/listinfo/devel-lists.deepamehta.de
