query-14a5c0852adec9c32671957bb9602628

rq turtle/ttl

But, unfortunately, it times out. It either (attempts to) load the entire tree of species, or the frequent bifurcations in both directions along the not-entirely-accurately-named "tree" make it grow too fast even for an optimized strategy. I got this to work, however:

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?homo ?homoLabel ?root ?rootLabel ?chicken ?chickenLabel
WHERE 
{
  ?homo wdt:P225 "Homo sapiens sapiens" .
  ?chicken wdt:P225 "Gorilla gorilla" .
  ?chicken wdt:P171?/wdt:P171?/wdt:P171 ?root .
  ?root ^wdt:P171+ ?homo .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v2("?chicken"):::projected v1("?homo"):::projected v3("?root"):::projected a1((" ")) a2((" ")) c6(["bd:serviceParam"]):::iri c2(["Homo sapiens sapiens"]):::literal c8(["#91;AUTO_LANGUAGE#93;,en"]):::literal c3(["Gorilla gorilla"]):::literal v1 --"wdt:P225"--> c2 v2 --"wdt:P225"--> c3 subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; v2 --"wdt:P171"--> a1 end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; end union0r <== or ==> union0l end subgraph union1[" Union "] subgraph union1l[" "] style union1l fill:#abf,stroke-dasharray: 3 3; a1 --"wdt:P171"--> a2 end subgraph union1r[" "] style union1r fill:#abf,stroke-dasharray: 3 3; end union1r <== or ==> union1l end a2 --"wdt:P171"--> v3 v1 --"wdt:P171"--> v3 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c6 --"wikibase:language"--> c8 end