Json output for different models varies
🐛 Describe the bug
Some models output json response that starts with ```
This doesn't get loaded in json.loads() and throws an error.
A better prompt could solve it for now, but we should look for model specific prompt solutions.
IMO this 'flaw' could be useful for parsing generated JSON and code, especially when there is some inconsistency between model output. Personally I can see a lot of benefit using the triple backtick as a flag for something to be parsed, seeing as these models arent designed explicitly to output parsable data. even better when the model uses correct MD syntax and lists the content type after the opening ticks. This could make finding data tokens in outputs easier and (hopefully) less likely to be parsed incorrectly when read. i.e, if closing ticks arent found, the block could be disregarded as it is unlikely to contain valid data.
Duplicate -> #1854
Closing this issue as it's duplicate and fixed.