Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[bioontology-support] Getting CUI and TUI in annotations

Leyla Jael García Castro leylajael at gmail.com
Mon Mar 11 10:44:26 PDT 2019


Hi Clement,

That is what I am looking for, thanks for the links. I have not played
enough with the service but it looks like, programmatically, options could
be different from those supported by the NCBO annotator.

I tried, in Python
    requestURL = 'http://data.bioontology.org/annotator'
    #requestURL = 'http://services.bioportal.lirmm.fr/ncbo_annotatorplus'
    payload = {
        'apikey': 'a valid api key here',
        'stop_words': stop, @this comes from a text variable
        'minimum_match_length': 3,
        'ontologies': ontos, #list of ontology ids
        'text': data['text'], #this is coming from a json variable
        'format': 'json'
    }
    resp = requests.post(requestURL, data=payload)

    if resp.ok:
        annData = resp.json()
        with open('PMC5833734_annotations.json', 'w') as outfile:
            json.dump(annData, outfile)

With the regular NCBO annotator I get the response, but with the Annotator+
I get an error
[{"error": "Mandatory parameter 'text' missing"}]

Any suggestions on what I am doing wrong here? I will go again to the
documentation you shared to try and figure out what I am missing.

Regards,

On Wed, Mar 6, 2019 at 8:32 PM Clement Jonquet <jonquet.lirmm at gmail.com>
wrote:

> Hello Leyla
>
> See
> https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5972606/
> To use  the NCBO Annotator +
> This is currently another server but Stanford is working on offering this
> directly on their box.
>
> We have a format that return tabbed results with CUIs.
> See also
>
> https://bmcbioinformatics.biomedcentral.com/articles/10.1186/s12859-018-2429-2
>
> Clement Jonquet
> Asst. Prof., Univ.  of Montpellier, LIRMM
>
>
> Le 6 mars 2019 à 21:25, Leyla Jael García Castro <leylajael at gmail.com> a
> écrit :
>
> Dear all,
>
> Is there any how to get CUI and TUI from the annotation service?
>
> I am using your example
> http://data.bioontology.org/annotator?text=Melanoma+is+a+malignant+tumor+of+melanocytes+which+are+found+predominantly+in+skin+but+also+in+the+bowel+and+the+eye
> .
>
> Melanoma is annotated with OMIM which includes CUI  C0025202  and TUI
> T191. Is it possible to get that information form the annotation service? I
> tried  expand_mappings =true but did not work.
>
> Kind regards,
> lj
>
> _______________________________________________
> bioontology-support mailing list
> bioontology-support at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/bioontology-support
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/bioontology-support/attachments/20190311/8f81eb83/attachment.html>


More information about the bioontology-support mailing list