sanskrit-lexicon / COLOGNE

Development of http://www.sanskrit-lexicon.uni-koeln.de/
18 stars 3 forks source link

Documenting downstream CDSL applications #412

Open drdhaval2785 opened 1 year ago

drdhaval2785 commented 1 year ago

Ref - https://github.com/sanskrit-lexicon/LRV/issues/15#issuecomment-1509879739

This comment raised an issue about noting the APIs the downstream applications depend on. currently I am aware about two such applications.

  1. PyCDSL - a python wrapper, REPL and a command line wrapper.
  2. stardict files - for stardict viewers

I will try to document how both use CDSL data.

drdhaval2785 commented 1 year ago

PyCDSL

https://pycdsl.readthedocs.io/en/latest/?version=latest

PyCDSL downloads web.zip folder for requested dictionaries from download section, and uses that data.

drdhaval2785 commented 1 year ago

stardict-sanskrit

https://github.com/sanskrit-lexicon/cologne-stardict/blob/master/make_babylon.py

generates .babylon files from csl-orig/v02/xxx/xxx.txt file. These babylon files are used to generate stardict files.

Bablyon file structure is quite easy.

Vertical bar separated headwords Definition BLANK_LINE

gasyoun commented 1 year ago

These babylon files are used to generate stardict files.

Where are they stored? How frequently regenerated?

drdhaval2785 commented 1 year ago

They are kept at https://github.com/sanskrit-lexicon/cologne-stardict and regenerated on whims and fancies of Dhaval. After regeneration, they are put at https://github.com/indic-dict/stardict-sanskrit from where downstream stardict application uses data.