You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
set_model_response escape latin characters in final response #2936
When defining output_schema in a LlmAgent with other tools, output schema processor executes json.dumps with ensure_ascii = True, making the agent respond with escaped latin characters, and therefore presenting responses not human readable:
Following up on this issue, I've opened a Pull Request (#2937) with the proposed fix. The changes involve explicitly setting ensure_ascii=False in the json.dumps call, which I've tested locally to correctly handle Latin characters.
Please feel free to review it when you have a moment, and let me know if there's anything else I can do to help move this forward.
Activity
Fix: google#2936 - Prevent escaping of Latin characters in LLM response
amenegola commentedon Sep 13, 2025
Hello @seanzhou1023
Following up on this issue, I've opened a Pull Request (#2937) with the proposed fix. The changes involve explicitly setting
ensure_ascii=Falsein thejson.dumpscall, which I've tested locally to correctly handle Latin characters.Please feel free to review it when you have a moment, and let me know if there's anything else I can do to help move this forward.
Thanks for your time!
Fix: google#2936 - Prevent escaping of Latin characters in LLM response
fix: Prevent escaping of Latin characters in LLM response
fix: preserve non-ASCII characters in agent input
fix: Prevent escaping of Latin characters in LLM response
fix: preserve non-ASCII characters in agent input