soshial / xdxf_makedict

XDXF — an open and free dictionary format, that stores word articles in a structural and semantic way. The most convertible format
227 stars 54 forks source link

[feature request] Dictionary of synonyms - too many key phrases #33

Open nikita-moor opened 5 years ago

nikita-moor commented 5 years ago

I am compiling a dictionary of synonyms and some articles have too many keys. So, my problem is "how to show them in DS (particulary GoldenDict)?" I have tried several styles, like densed line-space or headers joined in a flat list "key1; key2; key3; …", but still feel they consume to much space.

I am working on a dictionary of Latin words. There is no "official" spelling rules, so some words have spelling variants (e.g., pellex, pelex, paelex). All these variants are "correct" and are not conjugation/declension forms, so hunspell can't bring them to one lemma. Also, it is very common among Latin dictionaries to include Greek words.

Could we add more keys for search (look up), but do not show them to users? The problem is partialy about visual design, but spelling variants and optional keys (Greek in my case) should be handled some way by the dictionary format. #30 proposes <spelling> tag, I think about <k type="hidden">. Or maybe in place of showing all keywords we would include a predefined header for DS?

Below attached is a sample article from my dictionary. It already has 11 keywords (all about mental disease), and I would like to add 9 more but doubt that the exceedingly long list of keys will be usefull.

screenshot

k-sl commented 5 years ago

If I understood correctly, the issue is that since Latin has no standard spelling, it's common for words to be written in different ways. I see two ways to represent this in the current iteration of XDXF:

I agree the ideal would be to add an attribute to to the k element, but not hidden which is visual description. What I would propose is something like vspelling for variant spelling (or altspelling for alternative spelling, etc.), so your example could be semantically defined as <k vspelling="pelex paelex">pellex</k>. This should allow the DS to index all valid spellings as headwords but display only the chosen one in the article.

(Note: this is very different from what I was proposing with the <spelling> element, with was an element for a list of historical spellings, like the OED has [e.g.: eorold, wuruld, worold, uoruld, wiarald,etc. for ”world“]. This is quite rare, and maybe would be better described by an element such as histspellings for historical spellings. These spellings are not in use anywhere in the wuruld and don't need to be indexed.)

nikita-moor commented 5 years ago

Stub articles redirecting to the target is a good idea, not user friendly but working right now.

soshial commented 5 years ago

I think that the middle-ground proposal could be this one.

  1. put all spelling variants as <k> one after another (they would be shown in a list):
    <k>pellex</k>
    <k>paellex</k>
    <k>paelloex</k>
  2. All other strings, by which this article will be indexed. So when user enteres "insanus", DS shows this article as well.

This proposal might help in both cases: pinyin in Chinese and synonym dictionaries.