Fix backend JSON extractors and fallbacks for nested schema#154
Conversation
…ted schema
- Improve `optimisticRepairJson` inside `parsers.js` to correctly escape quotes and safely encode newlines/control characters without mangling nested JSON structures.
- Update fallback JSON responses inside `RoutingService.js` and `ProxyController.js` to rigorously conform to the new `{ final_evaluation, logic_trace }` nested schema when handling standard and streaming HTTP errors.
- Ensure `OllamaService.js` chunks accumulate cleanly and avoid premature parsing mid-stream to guarantee stability under larger, verbose text payloads.
Co-authored-by: iwas108 <64204327+iwas108@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
Refactored proxy controller and internal parser utilities to successfully route and validate deeply nested LLM generated schemas, satisfying phase 2 backend requirements.
PR created automatically by Jules for task 17011637913980895718 started by @iwas108