petermr / openVirus

aggregation of scholarly publications and extracted knowledge on viruses and epidemics.
The Unlicense
67 stars 17 forks source link

amidict syntax : input file is taken as <dictionary title> #81

Closed Priya-Jk-15 closed 4 years ago

Priya-Jk-15 commented 4 years ago

I am a Windows 10 user. I am using AMIDict to create disease dictionary. I used the https://github.com/petermr/ami3/packages/ package and the syntax

amidict -vv --dictionary disease --directory dictionary --input disease_multi create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,name=wikidataLabel,term=wikidataLabel,description=wikidataDescription,ICD-10_code=ICD_10,Hindi=hindiLabel,Hindi_description=hindi,Hindi_altName=hindiAltLabel,Tami=tamiLabel,Tamil_description=tamil,Tamil_altName=tamilAltLabel --transformname=EXTRACT(wikipediaURL,.*(.*)) --synonyms=wikidataAltLabel

to create the dictionary. But the dictionary created was not containing the dictionary name disease as dictionary title but the input name disease_multi. The input was downloaded using the sparql query (https://w.wiki/ZCr) and downloaded as file named disease_multi. The output dictionary created is at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/disease_multi.xml . @petermr Kindly verify.

I, then, changed the file name as disease and the syntax as

amidict -vv --dictionary disease --directory dictionary --input disease create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,name=wikidataLabel,term=wikidataLabel,description=wikidataDescription,ICD-10_code=ICD_10,Hindi=hindiLabel,Hindi_description=hindi,Hindi_altName=hindiAltLabel,Tami=tamiLabel,Tamil_description=tamil,Tamil_altName=tamilAltLabel --transformname=EXTRACT(wikipediaURL,.*(.*)) --synonyms=wikidataAltLabel

The file name of the output dictionary was, then, changed as disease_lang and is at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/disease_lang.xml

petermr commented 4 years ago

Thanks very much. This is exactly how to do it.

My strategy will be to create a Test with your input parameters and run it in Eclipse. (AMIDictCreateTest). When I have got an output I'll try to diagnose problems.

On Thu, Aug 13, 2020 at 7:11 AM Lakshmi Devi Priya notifications@github.com wrote:

I am a Windows 10 user. I am using AMIDict to create disease dictionary. I used the https://github.com/petermr/ami3/packages/ http://latest package and the syntax

amidict -vv --dictionary disease --directory dictionary --input disease_multi create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,name=wikidataLabel,term=wikidataLabel,description=wikidataDescription,ICD-10_code=ICD_10,Hindi=hindiLabel,Hindi_description=hindi,Hindi_altName=hindiAltLabel,Tami=tamiLabel,Tamil_description=tamil,Tamil_altName=tamilAltLabel --transformname=EXTRACT(wikipediaURL,.(.)) --synonyms=wikidataAltLabel

to create the dictionary. But the dictionary created was not containing the dictionary name disease as dictionary title but the input name disease_multi. The input was downloaded using the sparql query (https://w.wiki/ZCr) and downloaded as file named disease_multi. The output dictionary created is at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/disease_multi.xml . @petermr https://github.com/petermr Kindly verify.

I, then, changed the file name as disease and the syntax as

amidict -vv --dictionary disease --directory dictionary --input disease create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,name=wikidataLabel,term=wikidataLabel,description=wikidataDescription,ICD-10_code=ICD_10,Hindi=hindiLabel,Hindi_description=hindi,Hindi_altName=hindiAltLabel,Tami=tamiLabel,Tamil_description=tamil,Tamil_altName=tamilAltLabel --transformname=EXTRACT(wikipediaURL,.(.)) --synonyms=wikidataAltLabel

The file name of the output dictionary was, then, changed as disease_lang and is at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/disease_lang.xml

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/petermr/openVirus/issues/81, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFTCS5RSFIXLRNF3PGGX5LSAN7X7ANCNFSM4P53UNCA .

-- Peter Murray-Rust Founder ContentMine.org and Reader Emeritus in Molecular Informatics Dept. Of Chemistry, University of Cambridge, CB2 1EW, UK

petermr commented 4 years ago

I have created a (failing) test: AMIDictCrestTest.java , testMultipleLanguage . will commit soon.

I have taken your inout and run it in Eclipse. This is Java , but it's very simple.

Tell Eclipse (and Maven) that this is a Test.

    @Test

The method name. It should tell us what the method tests.

    public void testMultipleLanguage() {

create the command. Note we remove the amidict .

        String cmd = ""
//              + "amidict".      // not needed for Eclipse
                + " -vv "
                + " --dictionary disease"
                + " --directory dictionary"
                + " --input disease_multi"
                + " create"
                + " --informat wikisparqlxml"
                + " --sparqlmap "
                + " wikidataURL=wikidata,"
                + "wikipediaURL=wikipedia,"
                + "name=wikidataLabel,"
                + "term=wikidataLabel,"
                + "description=wikidataDescription,"
                + "ICD-10_code=ICD_10,"
                + "Hindi=hindiLabel,"
                + "Hindi_description=hindi,"
                + "Hindi_altName=hindiAltLabel,"
                + "Tami=tamiLabel,"
                + "Tamil_description=tamil,"
                + "Tamil_altName=tamilAltLabel"
                + ""
                + " --transformname=EXTRACT(wikipediaURL,.*(.*))"
                + " --synonyms=wikidataAltLabel"
                ;

and run the command:

        AMIDict.execute(cmd);
    }

and here's the output:

Unknown option: '--transformname=EXTRACT(wikipediaURL,.*(.*))'
Possible solutions: --transformName
Usage: amidict create [-hV] [--query[=query]] [--directory=<directory>]
                      [-i=FILE] [--informat=input format] [--linkcol=<linkCol>]
                      [--sparqlquery=<sparqlQueryFile>] [--termcol=<termCol>]
                      [--termfile=<termfile>] [--testString=<testString>]
                      [--wptype=<wptype>] [--sparqlmap=<String=String>[,
                      <String=String>...]]... [--synonyms=<synonymList>]...
                      [--transformName=<String=String>[@<String=String>...]]...
                      [--wikilinks[=<wikiLinks>[,<wikiLinks>...]...]]...
                      [--namecol=<nameCol>...] [-d=<dictionaryList>[,
                      <dictionaryList>...]...]... [--datacols=datacol[,
                      datacol...]...]... [--hrefcols=hrefcol[,
                      hrefcol...]...]... [-L=PATH...]... [--outformats=output
                      format[,output format...]...]...
                      [--template=<templateNames>...]... [--terms=<terms>[,
                      <terms>...]...]...
Try 'amidict create --help' for more information.

picocli is clever. It's case-sensitive and suggests the right option name. I'll correct and rerun.

petermr commented 4 years ago

The Test code is at: https://github.com/petermr/ami3/blob/master/src/test/java/org/contentmine/ami/dictionary/AMIDictCreateTest.java - about line 1250. I'll use line numbers (but these will change slightly with commits)

Changed input to:

                + " --transformName=EXTRACT(wikipediaURL,.*(.*))"

and re-run. Now get the error:

Value for option option '--transformName' (<String=String>) should be in KEY=VALUE[@KEY=VALUE]... format but was EXTRACT(wikipediaURL,.*(.*))
Usage: amidict create [-hV] [--query[=query]] [--directory=<directory>]
                      [-i=FILE] [--informat=input format] [--linkcol=<linkCol>]
                      [--sparqlquery=<sparqlQueryFile>] [--termcol=<termCol>]
                      [--termfile=<termfile>] [--testString=<testString>]
                      [--wptype=<wptype>] [--sparqlmap=<String=String>[,
                      <String=String>...]]... [--synonyms=<synonymList>]...
                      [--transformName=<String=String>[@<String=String>...]]...
                      [--wikilinks[=<wikiLinks>[,<wikiLinks>...]...]]...
                      [--namecol=<nameCol>...] [-d=<dictionaryList>[,
                      <dictionaryList>...]...]... [--datacols=datacol[,
                      datacol...]...]... [--hrefcols=hrefcol[,
                      hrefcol...]...]... [-L=PATH...]... [--outformats=output
                      format[,output format...]...]...
                      [--template=<templateNames>...]... [--terms=<terms>[,
                      <terms>...]...]...
Try 'amidict create --help' for more information.

picocli suggests there is an error in the input. Assume it's right because it's been developed and tested over years. Error messages often take practice to interpret. Here it wants the value to be in the format "KEY=VALUE". This is not well documented on the wiki so try to find another test that works:

Value for option option '--transformName' (<String=String>) should be in KEY=VALUE[@KEY=VALUE]... format but was EXTRACT(wikipediaURL,.*(.*))

we find method: testCreateFromWikidataQueryMapTransform() which contains:

                + " --transformName wikidataID=EXTRACT(wikidataURL,.*/(.*))"

So the syntax needs correcting. People learn in different ways. Some like formal rules and like picoclis output. Others prefer examples. But the rules are always the basis.

so rerun...

petermr commented 4 years ago

rerunning with the correction above gives:

Version: 

Generic values (DictionaryCreationTool)
================================
--testString        : d      null
--wikilinks         : d [Lorg.contentmine.ami.tools.AbstractAMIDictTool$WikiLink;@f1da57d
--datacols          : d      null
--hrefcols          : d      null
--informat          : m wikisparqlxml
--linkcol           : d      null
--namecol           : d      null
--outformats        : d [Lorg.contentmine.ami.tools.AbstractAMIDictTool$DictionaryFileFormat;@4007f65e
--query             : d      null
--sparqlmap         : m {wikidataURL=wikidata, wikipediaURL=wikipedia, name=wikidataLabel, term=wikidataLabel, description=wikidataDescription, ICD-10_code=ICD_10, Hindi=hindiLabel, Hindi_description=hindi, Hindi_altName=hindiAltLabel, Tami=tamiLabel, Tamil_description=tamil, Tamil_altName=tamilAltLabel}
--sparqlquery       : d      null
--synonyms          : m [wikidataAltLabel]
--template          : d      null
--termcol           : d      null
--termfile          : d      null
--terms             : d      null
--transformName     : m {wikipediaID=EXTRACT(wikipediaURL,.*/(.*))}
--wptype            : d      null
--input             : d      null
--inputnamelist     : d      null
--help              : d     false
--version           : d     false
--dictionary        : d [disease]
--directory         : d dictionary

so picocli can't find any errors. And amidict tabulates the input parameters. They look good. More (repeated output)

Specific values (DictionaryCreationTool)
================================
{hindiLabel=[Hindi], wikidataLabel=[name, term], hindiAltLabel=[Hindi_altName], tamilAltLabel=[Tamil_altName], wikidataDescription=[description], tamiLabel=[Tami], tamil=[Tamil_description], ICD_10=[ICD-10_code], hindi=[Hindi_description], wikipedia=[wikipediaURL], wikidata=[wikidataURL]}

Now we get a different type of failure - a "stack trace". They also need practice to understand, but here the first line is clear. PMR does not have the right input (which is on Priya's machine). I need the SPARQL output....

java.lang.RuntimeException: inputFile does not exist: /Users/pm286/workspace/cmdev/ami3/disease_multi
    at org.contentmine.ami.tools.AbstractAMIDictTool.openInputStream(AbstractAMIDictTool.java:483)
    at org.contentmine.ami.tools.dictionary.DictionaryCreationTool.openInputStream(DictionaryCreationTool.java:542)
    at org.contentmine.ami.tools.dictionary.DictionaryCreationTool.getInputStreamFromFile(DictionaryCreationTool.java:462)
    at org.contentmine.ami.tools.dictionary.DictionaryCreationTool.createAndWriteDictionary(DictionaryCreationTool.java:380)
... 20 lines snipped...

If @Priya has committed it I'll use a copy... More later.

petermr commented 4 years ago

@Priya-Jk-15 and @dheerajdhingani have committed their multilingual dictionary. I have copied a small section of this to ami3 src/test/resources/org/contentmine/ami/dictionary/disease.multi.sparql.xml

<?xml version="1.0" encoding="UTF-8"?>
<dictionary title="disease_multi">
 <desc>Created from SPARQL query</desc>
 <entry Hindi="सर्पदंश" ICD-10_code="T63.0" Tamil="பாம்புக் கடி" 
 altNames="snake bite, snake bites, snake envenomation, snake envenoming" 
 decription="injury caused by a bite from a snake" name="snakebite" term="snakebite" 
 wikidataURL="http://www.wikidata.org/entity/Q68854" 
 wikipediaURL="https://en.wikipedia.org/wiki/Snakebite" wikidataID="Q68854">
  <synonym>snake bite</synonym>
  <synonym>snake bites</synonym>
  <synonym>snake envenomation</synonym>
  <synonym>snake envenoming</synonym>
 </entry>
 <entry Hindi="Q72000" Tamil="Q72000" altNames="Lemierre syndrome, acute sore throat, human necrobacillosis, postanginal sepsis" decription="Human disease: infectious thrombophlebitis of the internal jugular vein" name="Lemierre's syndrome" term="Lemierre's syndrome" wikidataURL="http://www.wikidata.org/entity/Q72000" wikipediaURL="https://en.wikipedia.org/wiki/Lemierre%27s_syndrome" wikidataID="Q72000">
  <synonym>Lemierre syndrome</synonym>
  <synonym>acute sore throat</synonym>
  <synonym>human necrobacillosis</synonym>
  <synonym>postanginal sepsis</synonym>
 </entry>
 <entry Hindi="Q73518" ICD-10_code="I38" Tamil="Q73518" 
 altNames="non-bacterial thrombotic endocarditis, non-infective endocarditis, nonbacterial thrombotic endocarditis" 
 decription="endocarditis that results from the deposition of small sterile vegetations on valve leaflets" 
 name="marantic endocarditis" term="marantic endocarditis" 
 wikidataURL="http://www.wikidata.org/entity/Q73518" 
 wikipediaURL="https://en.wikipedia.org/wiki/Nonbacterial_thrombotic_endocarditis"
  wikidataID="Q73518">
  <synonym>non-bacterial thrombotic endocarditis</synonym>
  <synonym>non-infective endocarditis</synonym>
  <synonym>nonbacterial thrombotic endocarditis</synonym>
 </entry>
 <entry Hindi="Q73828" ICD-10_code="G24.4" Tamil="Q73828" 
     decription="focal dystonia that is characterized by distortions of the mouth and tongue." 
     name="oromandibular dystonia" term="oromandibular dystonia" 
     wikidataURL="http://www.wikidata.org/entity/Q73828" 
     wikipediaURL="https://en.wikipedia.org/wiki/Oromandibular_dystonia" 
     wikidataID="Q73828"/>
 <entry Hindi="Q76973" Tamil="Q76973" 
 altNames="bouba, Endemic treponematoses, frambesia, frambesia tropica, frambosie, polypapilloma tropicum, thymosis, Treponema pertenue infection" 
 decription="Human disease: tropical infection of the skin, bones and joints caused by the spirochete bacterium Treponema pallidum pertenue" 
 name="yaws" term="yaws" wikidataURL="http://www.wikidata.org/entity/Q76973" 
 wikipediaURL="https://en.wikipedia.org/wiki/Yaws" wikidataID="Q76973">
  <synonym>bouba</synonym>
  <synonym>Endemic treponematoses</synonym>
  <synonym>frambesia</synonym>
  <synonym>frambesia tropica</synonym>
  <synonym>frambosie</synonym>
  <synonym>polypapilloma tropicum</synonym>
  <synonym>thymosis</synonym>
  <synonym>Treponema pertenue infection</synonym>
 </entry>
 <entry Hindi="निकटदृष्टि" Tamil="கிட்டப்பார்வை" 
    altNames="near vision, near-sightedness, short-sightedness" 
    decription="problem with distance vision" name="myopia" term="myopia" 
    wikidataURL="http://www.wikidata.org/entity/Q168403"
     wikipediaURL="https://en.wikipedia.org/wiki/Near-sightedness" wikidataID="Q168403">
  <synonym>near vision</synonym>
  <synonym>near-sightedness</synonym>
  <synonym>short-sightedness</synonym>
 </entry>
 <entry Hindi="मनोविक्षिप्ति" Hindi_description="सचीज़ोफ्रेनिया के बारे में मेरा विचार" 
 ICD-10_code="F20" Tamil="Q170082" altNames="mental or behavioural disorder, psychotic disorder, psychotic disorders" 
 decription="abnormal condition of the mind that involves a loss of contact with reality" 
 name="psychosis" term="psychosis" wikidataURL="http://www.wikidata.org/entity/Q170082" 
 wikipediaURL="https://en.wikipedia.org/wiki/Psychosis" wikidataID="Q170082">
  <synonym>mental or behavioural disorder</synonym>
  <synonym>psychotic disorder</synonym>
  <synonym>psychotic disorders</synonym>
 </entry>
 <entry Hindi="मनोविक्षिप्ति" Hindi_description="सचीज़ोफ्रेनिया के बारे में मेरा विचार" 
 ICD-10_code="F21" Tamil="Q170082" 
 altNames="mental or behavioural disorder, psychotic disorder, psychotic disorders" 
 decription="abnormal condition of the mind that involves a loss of contact with reality" 
 name="psychosis" term="psychosis" wikidataURL="http://www.wikidata.org/entity/Q170082" 
 wikipediaURL="https://en.wikipedia.org/wiki/Psychosis" wikidataID="Q170082">
  <synonym>mental or behavioural disorder</synonym>
  <synonym>psychotic disorder</synonym>
  <synonym>psychotic disorders</synonym>
 </entry>
 <entry Hindi="मनोविक्षिप्ति" Hindi_description="सचीज़ोफ्रेनिया के बारे में मेरा विचार" 
 ICD-10_code="F22" Tamil="Q170082" 
 altNames="mental or behavioural disorder, psychotic disorder, psychotic disorders" 
 decription="abnormal condition of the mind that involves a loss of contact with reality" 
 name="psychosis" term="psychosis" wikidataURL="http://www.wikidata.org/entity/Q170082" 
 wikipediaURL="https://en.wikipedia.org/wiki/Psychosis" wikidataID="Q170082">
  <synonym>mental or behavioural disorder</synonym>
  <synonym>psychotic disorder</synonym>
  <synonym>psychotic disorders</synonym>
 </entry>
</dictionary> 

There are several important issues here, some new.

Priya-Jk-15 commented 4 years ago

@petermr The syntax mentioned above has a mistake. Please try with this one

amidict -vv --dictionary disease --directory dictionary --input disease_multi create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,name=wikidataLabel,term=wikidataLabel,description=wikidataDescription,ICD-10_code=ICD_10,Hindi=hindiLabel,Hindi_description=hindi,Hindi_altName=hindiAltLabel,Tamil=tamilLabel,Tamil_description=tamil,Tamil_altName=tamilAltLabel --transformname=EXTRACT(wikipediaURL,.*(.*)) --synonyms=wikidataAltLabel
Priya-Jk-15 commented 4 years ago

Sorry, about the input file. I have committed the whole sparql file at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/disease_multi_sparql . I hope now it helps.

petermr commented 4 years ago

Don't worry! We all make mistakes. The important thing is to recognize why and try to correct our practice and build systems that prevent them. So I spotted the typo decription instead of description. The amidict display --validate command may help to identify these. Suggest you run this and see what it detects. It is NOT complete yet!

Also it may be worth making small test files to reduce output.

Priya-Jk-15 commented 4 years ago

I have created a disease dictionary with 10 entries at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/issue/disease_icd.xml from the sparql input named disease_icd using the syntax

amidict -vv --dictionary disease --directory dic --input disease_icd create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,wikidataAltNames=wikidataAltLabel,name=wikidataLabel,term=wikidataLabel,Description=wikidataDescription,ICD-10_codes=ICD_10 --transformName wikidataID=EXTRACT(wikidataURL,.*/(.*)) --synonyms=wikidataAltLabel

I thought the multilingual dictionary can be dealt later. Here, though I used --dictionary disease, the output file in dictionary has dictionary title disease_icd which was the input file's name. @petermr Please check these.

petermr commented 4 years ago

Thank you. This is a good report. I will create a Test, which will fail, and then mend the code. I will try to record as much as possible on the ami3 wiki.

On Fri, Aug 14, 2020 at 12:04 PM Lakshmi Devi Priya < notifications@github.com> wrote:

I have created a disease dictionary with 10 entries at https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/issue/disease_icd.xml from the sparql input named disease_icd https://github.com/petermr/openVirus/blob/master/dictionaries/diseases/issue/disease_icd using the syntax

amidict -vv --dictionary disease --directory dic --input disease_icd create --informat wikisparqlxml --sparqlmap wikidataURL=wikidata,wikipediaURL=wikipedia,wikidataAltNames=wikidataAltLabel,name=wikidataLabel,term=wikidataLabel,Description=wikidataDescription,ICD-10_codes=ICD_10 --transformName wikidataID=EXTRACT(wikidataURL,./(.)) --synonyms=wikidataAltLabel

I thought the multilingual dictionary can be dealt later. Here, though I used --dictionary disease, the output file in dictionary has dictionary title disease_icd which was the input file's name. @petermr https://github.com/petermr Please check these.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/petermr/openVirus/issues/81#issuecomment-674021042, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFTCS5Q6UI6CUKXTEL6AC3SAUK5XANCNFSM4P53UNCA .

-- Peter Murray-Rust Founder ContentMine.org and Reader Emeritus in Molecular Informatics Dept. Of Chemistry, University of Cambridge, CB2 1EW, UK

petermr commented 4 years ago

Have found a bug and hopefully corrected it and committed the code. Current output from

        File disease_icd = new File(DICTIONARY_DIR, "disease_icd.sparql.xml");

console output

Version: 

Generic values (DictionaryCreationTool)
================================
--testString        : d      null
--wikilinks         : d [Lorg.contentmine.ami.tools.AbstractAMIDictTool$WikiLink;@f1da57d
--datacols          : d      null
--hrefcols          : d      null
--informat          : m wikisparqlxml
--linkcol           : d      null
--namecol           : d      null
--outformats        : d [Lorg.contentmine.ami.tools.AbstractAMIDictTool$DictionaryFileFormat;@4007f65e
--query             : d      null
--sparqlmap         : m {wikidataURL=wikidata, wikipediaURL=wikipedia, wikidataAltNames=wikidataAltLabel, name=wikidataLabel, term=wikidataLabel, Description=wikidataDescription, ICD-10_codes=ICD_10}
--sparqlquery       : d      null
--synonyms          : m [wikidataAltLabel]
--template          : d      null
--termcol           : d      null
--termfile          : d      null
--terms             : d      null
--transformName     : m {wikidataID=EXTRACT(wikidataURL,.*/(.*))}
--wptype            : d      null
--inputnamelist     : d      null
--input             : d      null
--help              : d     false
--version           : d     false
--dictionary        : d [disease]
--directory         : d target/dictionary/create

Specific values (DictionaryCreationTool)
================================
dictionaryName: disease
{wikidataLabel=[name, term], wikidataDescription=[Description], ICD_10=[ICD-10_codes], wikipedia=[wikipediaURL], wikidata=[wikidataURL], wikidataAltLabel=[wikidataAltNames]}
WS>[Description, name, term, wikidataURL, ICD-10_codes, wikidataAltNames, wikipediaURL]
sparqlMap SHOULD contain key: description
sparqlMap SHOULD contain key: wikidata
sparqlMap SHOULD contain key: wikipedia
unknown ami name: Description
unknown ami name: ICD-10_codes
unknown ami name: wikidataAltNames
unknown ami name: wikidataURL
unknown ami name: wikipediaURL
sparql names [wikidata, wikidataLabel, wikipedia, wikidataAltLabel, wikidataDescription, ICD_10]
results 10
dicc> cannot find binding: ICD_10
dicc> cannot find binding: ICD_10
dicc> cannot find binding: ICD_10
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: wikidataAltLabel
dicc> cannot find binding: ICD_10
FIX OUTPUT
<entry Description="type of inflammatory bowel disease" name="Crohn's disease" term="Crohn's disease" wikidataAltNames="Crohn disease, Crohn, Crohn's disease of colon, Crohn's disease of colon (disorder), Crohn's disease of large bowel, Granulomatous Colitis, Pediatric Crohn's disease, regional colitis, regional enteritis, regional enteritis of small intestine with large intestine, regional enteritis of the large bowel, regional Ileitis, regional ileocolitis" wikidataURL="http://www.wikidata.org/entity/Q1472" wikipediaURL="https://en.wikipedia.org/wiki/Crohn%27s_disease" wikidataID="Q1472"><synonym>Crohn disease</synonym><synonym>Crohn</synonym><synonym>Crohn's disease of colon</synonym><synonym>Crohn's disease of colon (disorder)</synonym><synonym>Crohn's disease of large bowel</synonym><synonym>Granulomatous Colitis</synonym><synonym>Pediatric Crohn's disease</synonym><synonym>regional colitis</synonym><synonym>regional enteritis</synonym><synonym>regional enteritis of small intestine with large intestine</synonym><synonym>regional enteritis of the large bowel</synonym><synonym>regional Ileitis</synonym><synonym>regional ileocolitis</synonym></entry>
<entry Description="inflammatory bowel disease that causes ulcers in the colon" name="ulcerative colitis" term="ulcerative colitis" wikidataAltNames="Ulcerative colitis, Ulcerative Colitis, Colitis Ulcerative, hemorrhagic colitis, Left-sided ulcerative colitis" wikidataURL="http://www.wikidata.org/entity/Q1477" wikipediaURL="https://en.wikipedia.org/wiki/Ulcerative_colitis" wikidataID="Q1477"><synonym>Ulcerative colitis</synonym><synonym>Ulcerative Colitis</synonym><synonym>Colitis Ulcerative</synonym><synonym>hemorrhagic colitis</synonym><synonym>Left-sided ulcerative colitis</synonym></entry>
<entry Description="inflammation of connective tissue marked by skin rashes, joint pain and swelling, inflammation of the kidneys and inflammation of the tissue surrounding the heart." name="systemic lupus erythematosus" term="systemic lupus erythematosus" wikidataAltNames="SLE, Systemic lupus erythematosus, lupus, disseminated lupus erythematosus, Lupus Erythematosus, systemic, SLE - Lupus Erythematosus, systemic" wikidataURL="http://www.wikidata.org/entity/Q1485" wikipediaURL="https://en.wikipedia.org/wiki/Lupus" wikidataID="Q1485"><synonym>SLE</synonym><synonym>Systemic lupus erythematosus</synonym><synonym>lupus</synonym><synonym>disseminated lupus erythematosus</synonym><synonym>Lupus Erythematosus</synonym><synonym>systemic</synonym><synonym>SLE - Lupus Erythematosus</synonym><synonym>systemic</synonym></entry>
<entry Description="inability to use spoken language" ICD-10_codes="F80.0" name="aphasia" term="aphasia" wikidataURL="http://www.wikidata.org/entity/Q2836" wikipediaURL="https://en.wikipedia.org/wiki/Aphasia" wikidataID="Q2836" />
<entry Description="inability to use spoken language" ICD-10_codes="F80.1" name="aphasia" term="aphasia" wikidataURL="http://www.wikidata.org/entity/Q2836" wikipediaURL="https://en.wikipedia.org/wiki/Aphasia" wikidataID="Q2836" />
<entry Description="inability to use spoken language" ICD-10_codes="F80.2" name="aphasia" term="aphasia" wikidataURL="http://www.wikidata.org/entity/Q2836" wikipediaURL="https://en.wikipedia.org/wiki/Aphasia" wikidataID="Q2836" />
<entry Description="inability to use spoken language" ICD-10_codes="R47.0" name="aphasia" term="aphasia" wikidataURL="http://www.wikidata.org/entity/Q2836" wikipediaURL="https://en.wikipedia.org/wiki/Aphasia" wikidataID="Q2836" />
<entry Description="decrease in number of red blood cells" name="anemia" term="anemia" wikidataAltNames="anaemia" wikidataURL="http://www.wikidata.org/entity/Q5445" wikipediaURL="https://en.wikipedia.org/wiki/Anemia" wikidataID="Q5445"><synonym>anaemia</synonym></entry>
<entry Description="human viral infection" ICD-10_codes="B16" name="hepatitis B" term="hepatitis B" wikidataAltNames="Hepatitis B, hepatitis B infection, hepatitis type B, serum hepatitis, Viral Hepatitis B" wikidataURL="http://www.wikidata.org/entity/Q6853" wikipediaURL="https://en.wikipedia.org/wiki/Hepatitis_B" wikidataID="Q6853"><synonym>Hepatitis B</synonym><synonym>hepatitis B infection</synonym><synonym>hepatitis type B</synonym><synonym>serum hepatitis</synonym><synonym>Viral Hepatitis B</synonym></entry>
<entry Description="human viral infection" ICD-10_codes="B18.0" name="hepatitis B" term="hepatitis B" wikidataAltNames="Hepatitis B, hepatitis B infection, hepatitis type B, serum hepatitis, Viral Hepatitis B" wikidataURL="http://www.wikidata.org/entity/Q6853" wikipediaURL="https://en.wikipedia.org/wiki/Hepatitis_B" wikidataID="Q6853"><synonym>Hepatitis B</synonym><synonym>hepatitis B infection</synonym><synonym>hepatitis type B</synonym><synonym>serum hepatitis</synonym><synonym>Viral Hepatitis B</synonym></entry>
writing dictionary to /Users/pm286/workspace/cmdev/ami3/target/dictionary/create/disease.xml
petermr commented 4 years ago

There are some separate issues with naming of ami names which might be picked up by a validator.

Priya-Jk-15 commented 4 years ago

PMR : Have committed a new version of amidict . Please pull and retry. (This is not a release - it aims to fix the dictionary bug).

If PACKAGE is downloaded, clone ami3 repo and retry with the amidict syntax.

This issue is solved and the desired output as above was obtained with the syntax mentioned.