package graph_queries import "fmt" func hierarchyEdgeQuery(edgeLimit int, includeBNodes bool) string { bnodeFilter := "" if !includeBNodes { bnodeFilter = "FILTER(!isBlank(?s) && !isBlank(?o))" } return fmt.Sprintf(` PREFIX rdfs: SELECT ?s ?p ?o WHERE { VALUES ?p { rdfs:subClassOf } ?s ?p ?o . FILTER(!isLiteral(?o)) %s } LIMIT %d `, bnodeFilter, edgeLimit) }