NCATSTranslator / workflow-runner

1 stars 1 forks source link

No response from WFR, but query sent to aragorn returns results #67

Closed GregHydeDartmouth closed 10 months ago

GregHydeDartmouth commented 11 months ago

I'm attempting to send the following query to WFR:

{
    "workflow": [
        {
            "id": "lookup",
            "runner_parameters": {
                "allowlist": [
                    "infores:aragorn"
                ]
            }
        },
        {
            "id": "score"
        }
    ],
    "message": {
        "query_graph": {
            "nodes": {
                "n0": {
                    "categories": [
                        "biolink:Disease"
                    ],
                    "ids": [
                        "MONDO:0009061"
                    ]
                },
                "n1": {
                    "categories": [
                        "biolink:GrossAnatomicalStructure"
                    ]
                },
                "n2": {
                    "categories": [
                        "biolink:Gene"
                    ]
                }
            },
            "edges": {
                "e0": {
                    "subject": "n0",
                    "object": "n1",
                    "predicates": [
                        "biolink:located_in"
                    ]
                },
                "e1": {
                    "subject": "n1",
                    "object": "n2",
                    "predicates": [
                        "biolink:expresses"
                    ]
                }
            }
        }
    },
    "log_level": "DEBUG"
}

To submit the query I use:

r = requests.post('https://translator-workflow-runner.renci.org/query/', json=message, timeout=1000)
print(json.dumps(json.loads(r.content), indent=2))

However, WFR doesn't return any valid results from Aragorn: "error": "Failed to get a good response from Aragorn(Trapi v1.4.0), see the logs"

The strange thing is when I remove the workflow:

{
    "message": {
        "query_graph": {
            "nodes": {
                "n0": {
                    "categories": [
                        "biolink:Disease"
                    ],
                    "ids": [
                        "MONDO:0009061"
                    ]
                },
                "n1": {
                    "categories": [
                        "biolink:GrossAnatomicalStructure"
                    ]
                },
                "n2": {
                    "categories": [
                        "biolink:Gene"
                    ]
                }
            },
            "edges": {
                "e0": {
                    "subject": "n0",
                    "object": "n1",
                    "predicates": [
                        "biolink:located_in"
                    ]
                },
                "e1": {
                    "subject": "n1",
                    "object": "n2",
                    "predicates": [
                        "biolink:expresses"
                    ]
                }
            }
        }
    },
    "log_level": "DEBUG"
}

and submit directly to aragorn:

r = requests.post('https://aragorn.renci.org/aragorn/query', json=message, timeout=1000)
print(json.dumps(json.loads(r.content), indent=2))

I do get answers.

maximusunc commented 10 months ago

This is not an issue with either Aragorn or WFR, but an issue with Node Norm: https://github.com/TranslatorSRI/NodeNormalization/issues/229

GregHydeDartmouth commented 10 months ago

Appears to be working now as anticipated with changes in dev of Node Norm. Thanks!