Skip to content

Dictionary: plant_genus

ShweataNHegde edited this page Feb 8, 2021 · 3 revisions

Dictionary Owner

Shweata N. Hegde

Dictionary Overview

SPARQL query

#Plant Genera
SELECT ?plant_genus ?plant_genusLabel ?GRINid ?plant_genusAltLabel
WHERE 
{
  ?plant_genus wdt:P31 wd:Q16521. # Give me all items which are instance of taxon
  ?plant_genus wdt:P105 wd:Q34740. # Give me all taxon with taxon rank 'genera'
  ?plant_genus wdt:P1421 ?GRINid. # genera with grin id 
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}

Click here to run the above SPARQL query on the Wikidata query service.

SPARQL Map - converting SPARQL output to ami-readable dictionary

amidict -vv --dictionary plant_genus --directory plant_genus_dictionary --input plant_genus_sparql.xml create --informat wikisparqlxml --sparqlmap wikidataURL=plant_genus,term=plant_genusLabel,GRINid=GRINid,wikidataURL=plant_genus --transformName wikidataID=EXTRACT(wikidataURL,.*/(.*)) --synonyms=wikidataAltLabel

SPARQL output

DATE: 2021-01-25

https://github.com/petermr/CEVOpen/blob/master/dictionary/plant_genus/plant_genus_sparql.xml

Initial Dictionary Commit

DATE: 2021-02-08

https://github.com/petermr/CEVOpen/blob/master/dictionary/plant_genus/plant_genus.xml
** Contains ~25,000 terms **

For more information read the .md file

https://github.com/petermr/CEVOpen/blob/master/dictionary/plant_genus/plant_genus.md

TO-DO

  • Add metadata
    • dictionary owner
    • date of creation
    • Restful URL of the query
  • Add property id to the dictionary (P1421)
Clone this wiki locally