3.5-1106 not returning valid JSON

    response_format: { type: "json_object" },
    temperature,
    top_p: 1,
    frequency_penalty: 0,
    presence_penalty: 0,
  });
  return response;

I understand this is an azure client its the same thing so don’t boot me.

I have the response format as set to JSON but i keep returning this…

json'''
{"description":"Moderate Self-Esteem Indicators", 
"reasoning":"The conversation transcript reveals a mix of positive and negative self-statements. The individual expresses anxiety and guilt related to taking time off work to care for their sick child, indicating self-doubt and concern about their performance as a mother and employee. However, they also demonstrate moments of confidence, such as acknowledging that they did everything they had to do to care for their child and rating themselves as an 8 out of 10 as a mother. The individual seeks external validation by expressing concern about their employer's reaction to their absences and seeks reassurance about their performance as a mother. Overall, the conversation reflects a moderate level of self-esteem, with a balance of positive and negative self-statements.
", "score":"5"}'''

Im getting this weird ‘json’ at the beginning of each JSON that obviously isnt JSON.

I think I saw seomeone else saying something about this earlier wondering if anyone solved it

response.content = response.content.replace(/```json\n?|```/g, '');

:smile:

1 Like