Closed sidsvash26 closed 3 years ago
The problem was that for some reason there were no complex and transe embeddings for Q17156448, but there was a text embeddings. Because of that topsim computed an empty set of candidates which broke one of the methods. This is fixed now in a0f84bc868b85631a5eae814d30ea7d7e7428fb1. In general that node seems very unconnected since all the other measures except text return 0. Once the service is restarted, the problem should go away.
There is a further issue that we have a heterogeneous return type on the post response, where errors return JSON dicts but successful responses return JSON strings. I didn't want to fix that at this point, since people's access code might have already factored that in.
@sidsvash26 The deployed similarity API will be updated in 1-2 days.
Thank you, both!
@chalypso As of today, I'm still receiving the same error. A workaround I have been following is fetching only a single pair at a time, and if it throws an error, I skip it. But that approach doesn't allow me to fetch a batch list of Qnode pairs as even if a single pair is faulty, the API request is not successful. This is making the process of fetching similarities very slow.
Another pair that threw an error: ('Q170212', 'Q5658542')
@sidsvash26 if you still have the issue after updating the latest release of kgtk, please reopen it
Updating the service now, it'll stop working meanwhile
Should be back up now with the fix
The example Python code works fine for me for the given pairs of nodes in the example. And it works in general with a new set of examples. However, once in a while, some Qnode pairs throw an error.
For instance, I have the following Qnode pairs file:
When I use the example Python code to send this file to the API it gives me the following error:
On investigating further, I found that it is the 3rd pair in the above file which is causing the issue --
(Q17156448, Q17502905)
When I remove the 3rd pair, the API works fine. I checked on WIkidata that both of the Qnodes are valid existing Q nodes.
Could you please help why this is happening?