[freedict] Re: freedicts - REST and GraphQL APIs

  • From: Francisco Mondaca <f.mondaca@xxxxxxxxxxxx>
  • To: freedict@xxxxxxxxxxxxx
  • Date: Fri, 01 Nov 2019 20:48:47 +0100

Hi Piotr,

Super news, thanks!

You are welcome! I am always happy to help if I can.

Your setup for the Rigveda sounds wicked, and the interface is so
sleek, 
have you thought of submitting a paper or poster to the upcoming TEI 
conference? (Unfortunately, it's going to take place across the
Atlantic 
in 2020, in Lincoln, Nebraska). The submission deadlines are usually
in 
April, AFAIR.


Thanks! My colleague Borge Kiss (cc) is responsible for the App. He is
also the developer behind the VedaWeb REST API: 
https://vedaweb.uni-koeln.de/rigveda/swagger-ui.html

We did present the project already, but as posters: DHD2018 Cologne,
EADH2018 Galway. Indirectly with a short poster at DH2019 Utrecht. I
presented Kosh in the last TEI conference in Graz (
https://gams.uni-graz.at/o:tei2019.158/sdef:TEI/get?context=context:tei2019.papers
). I am afraid that I will not attend the next TEI conference. The next
months I need to focus on a project and I wil try to stay in Cologne.

Is your glossing solution also TEI-based? 

Yes. We have our TEI data here: 
https://github.com/cceh/c-salt_vedaweb_tei. There are some things
missing from the files, e.g. TEI headers and metrical data. So, the
data that you see in the App should be almost the same that you see in
those files. We are still doing some changes with the data, so this is
not the last version of our TEI files. I am thankful for any comments
for improving the structure. 

I recall a recent wave of 
discussions on glossing on the TEI mailing list, it's a hot topic for
some.

Thanks for the advice, I just joined out the mailing list (TEI-
LINGUISTICS and public dicussion). Until now I have had a glimpse at
the TEIC/TEI GitHub repo. 

Best,

Francisco



Best,

    Piotr

On 10/29/19 2:54 PM, Francisco Mondaca wrote:
Hi Sebastian,


Is there any  chance that you would set things up and maintain
this
for
FreeDict? At freedict.org, there should be space left for such
experiments. I
would be more than happy to assist.


Yes, I could take care of it. For the moment we have 82 freedicts
running on a virtual machine at the University of Cologne. Here a
list
of the current freedict APIs:

https://docs.google.com/spreadsheets/d/1xZIoE90QOESVy85ECYasWk8lGov1unWT-yeWB5jtZNg/edit#gid=0

The setup that I would recommend would be to deploy Kosh with
docker.
We also have a container (https://github.com/cceh/kosh_sync) that
executes pull requests from a git repo at a certain time lapse. For
instance, we could set it up, to 'pull' each 24 hours from the main
git
repo. As Kosh reindexes each dataset (dict), if it notices that the
related files are modified, the whole process of updating the git
repo
in the freedict server and the reindexation of the entries would be
fully automatic.


I think that a after all the JSON configuration files provide
a
detailed description of the respective datasets (of each
dictionary),
the APIs could be employed for multiple purposes.

What other purposes other than word lookup would come to mind?

We use Kosh for our Sanskrit dictionaries encoded in TEI:
https://cceh.github.io/c-salt_sanskrit_data/
In the VedaWeb project (https://vedaweb.uni-koeln.de/rigveda) we
link
each token of the Rigveda, a Vedic text, with entries from a
dictionary
that was specially compiled for it (Grassmann's dictionary). The
dictionary entries that you see in the bottom of each text are
provided
by the Grassmann GraphQL API. If you click in one of the entries,
you
can also see its related scanned image.

In this case, we did save the ID of the entry at a preprocessing
stage.
We saved it in the TEI file where we modelled the Rigveda with its
versions, annotations and translations. Later, we saved this
information in mongoDB and indexed it in elasticsearch.

The web applicaton that you see calls a REST API (
https://vedaweb.uni-koeln.de/rigveda/swagger-ui.html) for
displaying
texts associated with a stanza, and the GraphQL Grassmann API (
https://api.c-salt.uni-koeln.de/dicts/gra/graphql) for displaying
the
lemmata for each entry. We don't execute a 'proper' lookup here. We
do
not search. We just get the entry from the API based on its ID.

Best,

Francisco






-- 
FreeDict — Free And Open Dictionaries
Manage your subscription at //www.freelists.org/list/freedict
Wiki: https://github.com/freedict/fd-dictionaries/wiki
Web: http://freedict.org

Other related posts: