Project

General

Profile

Idea #15071

Updated by Lucas Di Pentima almost 5 years ago

Based on our previous format, for example: 

 <pre> 
 { 
     "strict": false, 
     "tags": { 
         "fruit": { 
             "values": ["pineapple", "tomato", "orange", "banana", "advocado", "lemon", "apple", "peach", "strawberry"], 
             "strict": true 
         }, 
         "comments": {}, 
         "importance": { 
             "values": ["critical", "important", "low priority"] 
         } 
     } 
 } 
 </pre> 

 ...where @strict: false@ was needed to be able to express when the user is permitted to add arbitrary text on keys and/or values, we now need to support multiple labels for a single concept, and the possibility to add translations too, the proposed format would be: 

 <pre> 
 { 
     "strict_tags": false, 
     "preferred_lang": "en-US", 
     "tags": { 
         "ID1234567890": { 
             "strict": true, 
             "labels": { 
                 "en-US": ["fruit", "Fruit"], 
                 "es-ES": ["fruta", "Fruta"], 
                 "zh-CN": ["水果", "果"] 
             }, 
             "values": { 
                 "VAL123345": { 
                     "en-US": ["pineapple"], "pineapple",  
                     "es-ES": ["piña"], "piña", 
                     "es-AR": ["piña", "ananá"], "ananá", 
                     "zh-CN": ["菠萝"] "菠萝" 
                 }, 
                 ... 
             } 
         }, 
         "ID1234567891": { 
             "labels": { 
                 "en-US": ["comment", "suggestion"] 
             } 
         }, 
     } 
 } 
 </pre> 

 Of course, this would be useful as a "forward-index", enabling the UI to show the correct data. The UI should be creating a reverse index for data input.

Back