pombase / pombase-chado

PomBase code for accessing Chado
MIT License
5 stars 3 forks source link

Send data to APICURON (placeholder issue) #1013

Open kimrutherford opened 2 years ago

kimrutherford commented 2 years ago

I don't think we have an issue specifically for this: we need to send curation data to APICURON.

While implementing pombase/website#525, I wrote the code to collect the basic curation stats for the annotation from Canto. So that's a start.

We now need to:

We need to add more detail to that list. :-)

ValWood commented 2 years ago

Yes we will speak with them again at some point soon -ish. MAybe OCt/Nov ish. Let's get other stuff out of the way first.

kimrutherford commented 1 year ago

I've just emailed them to ask how to make "Terms" on apicuron.org as described in the "Defining your Terms" section of the docs. I can't find the dialog on the dev site.

kimrutherford commented 1 year ago

I've just emailed them to ask how to make "Terms"

Turns out there was a bug that they've helped me work around.

kimrutherford commented 1 year ago

I've changed the nightly Chado processing code to make a file for testing the APICURON API. After a few false starts I've been able to submit the file to the dev APICURON server.

The test file contains a record for each time a user has managed to get a publication/session approved. Each record looks like:

    {
      "activity_term": "publication_curated",
      "timestamp": "2022-02-24T11:54:36.000Z",
      "curator_orcid": "0000-0003-4148-4606",
      "entity_uri": "https://www.pombase.org/reference/PMID:15964794"
    }

Let's talk about this on Zoom/Skype. I'd like to see what happens when you try to log in to the dev server.


Note to self, example of how to post Curl using:

curl -X 'POST' \
  'https://dev.apicuron.org/api/reports/bulk' \
  -H 'accept: */*' \
  -H 'version: 2' \
  -H 'authorization: bearer ...' \
  -H 'Content-Type: multipart/form-data' \
  -F 'delete_all=pombase' \                                   
  -F 'reports=@apicuron_data.json;type=application/json' 
kimrutherford commented 1 year ago

Current status (2023-10-09): I've reported a few bugs via the APICURON Slack (on 2023-10-5) and I'm waiting for replies.

kimrutherford commented 1 year ago

Current status (2023-10-09): I've reported a few bugs via the APICURON Slack (on 2023-10-5) and I'm waiting for replies.

Those bugs are fixed.

kimrutherford commented 1 year ago

As an experiment, I've added a command at the very end of the nightly load script to attempt to send our latest data to APICURON. I've put it at the end of the script so that if there are any problems it won't cause other load steps to be missed.

I'll check on Wednesday to see if that works OK.

Note that the data is still very minimal: just records of which ORCID curated which paper.

Val, when you have time (maybe next week?) we should try to get you logged in on the dev APICURON server to see how it looks to you.

ValWood commented 1 year ago

Yes, let's do this next week.

kimrutherford commented 1 year ago

I've put it at the end of the script so that if there are any problems it won't cause other load steps to be missed.

The load script fell over just before trying to upload to APICURON because I made a typo implementing pombase/pombase-chado#886. It's fixed now and I'll check the APICURON upload on Thursday morning.

kimrutherford commented 1 year ago

I've put it at the end of the script so that if there are any problems it won't cause other load steps to be missed.

That's working now so the PomBase data in the dev APICURON is now updated nightly.

kimrutherford commented 1 year ago

APICURON gives has a graph of contributions:

image

kimrutherford commented 1 year ago

I've added a second APICURON "Activity Term" for when a user submits a HTP dataset. I want to see how it looks in the interface if a user has two different types of record. I've changed the code the generates the JSON too.

The new term ID is "provided_dataset". The existing term ID is "publication_curated". These are just terms for testing on the dev server. When we move other to the main apicuron.org we can rename or replace them.

kimrutherford commented 1 year ago

From the call last week:

(Edit) See also:

kimrutherford commented 1 year ago

export the a new type approved_session so that admins get some recognition

The approver records are now sent to the dev APICURON too. We now have three "activity terms":

I think that's quite a good set for this project.