RobokopU24 / Feedback

Feedback on the ROBOKOP project
https://robokop.renci.org
0 stars 0 forks source link

Sort and/or filter results by node type #180

Open karafecho opened 11 months ago

karafecho commented 11 months ago

This issue is to suggest that the UI supports the ability for users to sort and/or filter by node type (Biolink category). For example, the query below returns 5000 answers (n2 = NamedThing), but I'd like to sort and/or filter by the Biolink categories associated with n2. Now, I can always run additional queries to change n2 to MolecularActivity, for example, but it would be helpful to be able to sort and/or filter the results in order to quickly explore the space.

{
  "message": {
    "query_graph": {
      "nodes": {
        "n0": {
          "name": "Clofibric acid",
          "categories": [
            "biolink:SmallMolecule",
            "biolink:MolecularEntity",
            "biolink:ChemicalEntity",
            "biolink:NamedThing",
            "biolink:Entity",
            "biolink:PhysicalEssence",
            "biolink:ChemicalOrDrugOrTreatment",
            "biolink:ChemicalEntityOrGeneOrGeneProduct",
            "biolink:ChemicalEntityOrProteinOrPolypeptide",
            "biolink:PhysicalEssenceOrOccurrent"
          ],
          "ids": [
            "PUBCHEM.COMPOUND:2797"
          ]
        },
        "n1": {
          "name": "PPARA",
          "categories": [
            "biolink:Gene",
            "biolink:BiologicalEntity",
            "biolink:NamedThing",
            "biolink:Entity",
            "biolink:GeneOrGeneProduct",
            "biolink:GenomicEntity",
            "biolink:ChemicalEntityOrGeneOrGeneProduct",
            "biolink:PhysicalEssence",
            "biolink:OntologyClass",
            "biolink:ThingWithTaxon",
            "biolink:PhysicalEssenceOrOccurrent",
            "biolink:MacromolecularMachineMixin",
            "biolink:Protein",
            "biolink:Polypeptide",
            "biolink:GeneProductMixin",
            "biolink:ChemicalEntityOrProteinOrPolypeptide"
          ],
          "ids": [
            "NCBIGene:5465"
          ]
        },
        "n2": {
          "categories": [
            "biolink:NamedThing"
          ],
          "name": "Named Thing"
        }
      },
      "edges": {
        "e0": {
          "subject": "n0",
          "object": "n1",
          "predicates": [
            "biolink:related_to"
          ]
        },
        "e1": {
          "subject": "n1",
          "object": "n2",
          "predicates": [
            "biolink:related_to"
          ]
        }
      }
    }
  }
}