microsoft / genaiscript

Generative AI Scripting
https://microsoft.github.io/genaiscript/
MIT License
81 stars 22 forks source link

better schema validation test #550

Closed pelikhan closed 2 weeks ago

pelikhan commented 2 weeks ago

generated by pr-describe

github-actions[bot] commented 2 weeks ago

The changes mostly seem to improve the error handling and enhance the readability of the code. Here are a few points that might be worth discussing:

  1. Error handling level was changed from error to warn in multiple places. This might not be an issue, but it is something to watch out for if error level logging is expected.

  2. The function applyRepairs now continues to work even after reaching maxDataRepairs, as opposed to throwing an error and halting execution. It might not be a problem if this is the intended behaviour, but it's something to keep in mind.

  3. The error message format has been updated in the applyRepairs function. The error message now includes data, schema, and error. It might be more helpful for debugging, but it might also break any existing log parsing or error handling that expects the old format.

In general, the changes look good and there don't seem to be any obvious functional issues introduced by the changes. Therefore, I would say:

LGTM :rocket:

generated by pr-review