-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Every now and then, the user will get a
We're sorry, something went wrong.
during the processing of a gene.
I managed to track one down and it's malformed JSON returned by OpenAI despite it having been given a responseFormat schema. Boo!
I think the only solution is to assume these are 1 in 50 events and have a retry strategy?
From the tomcat logs for VectorBase on watermelon
Caused by: java.lang.RuntimeException: Error parsing JSON response for dataset DS_047c56768c. Raw response string:
{"one_sentence_summary":"This gene is moderately expressed in <i>Anopheles gambiae</i> midguts and salivary glands infected with <i>Plasmodium falciparum</i>, showing a slightly h
igher expression in salivary glands.","biological_importance":3,"confidence":4,"notes":"Expression values indicate a slightly higher level in salivary gland samples compared to mi
dgut samples, and expression seems consistent across paired-end and single-end methodologies.","experiment_keywords":["mosquito tissues","midgut","salivary gland","Plasmodium falc
iparum infection","RNA-Seq"],"confidence":4}
at org.apidb.apicommon.model.report.ai.expression.Summarizer.lambda$describeExperiment$0(Summarizer.java:159)
Caused by: org.json.JSONException: Duplicate key "confidence" at 579 [character 580 line 1]
at org.json.JSONTokener.syntaxError(JSONTokener.java:536)
at org.json.JSONObject.<init>(JSONObject.java:259)
at org.json.JSONObject.<init>(JSONObject.java:481)
at org.json.JSONObject.<init>(JSONObject.java:458)
at org.apidb.apicommon.model.report.ai.expression.Summarizer.lambda$describeExperiment$0(Summarizer.java:150)
Parsing is here:
ApiCommonWebsite/Model/src/main/java/org/apidb/apicommon/model/report/ai/expression/Summarizer.java
Line 150 in 8c87e63
| JSONObject jsonObject = new JSONObject(jsonString); |
See also #263
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working