query: #defaultView:Graph
  select ?topSubclass ?parent ?parentLabel ?topSubclassLabel
  with {
    select ?bottomSuperclass  {
        bind ( wd:Q142 as ?bottom) .
        ?bottom wdt:P31/wdt:P279* ?bottomSuperclass. 
    }
  } as %superclasses
  
  with {
    select (?bottomSuperclass as ?topSubclass) ?top {
      include %superclasses
        bind ( <http://www.wikidata.org/entity/Q17334923> as ?top) .
        ?bottomSuperclass wdt:P279* ?top.
    }
  } as %subclasses
  {
    include %subclasses .
    ?topSubclass wdt:P279 ?parent filter exists { { select (?topSubclass as ?class ){ include %subclasses} } filter (?class = ?parent) }
     SERVICE wikibase:label { bd:serviceParam wikibase:language "fr,en,[AUTO_LANGUAGE],en". }
  }
  