b9656
📦 llama-cppView on GitHub →
✨ 2 features🐛 2 fixes🔧 3 symbols
Summary
This release hardens peg-native tool call parsing to better handle OpenAI style tool calls and improves error reporting when parsing fails. Malformed tool call arguments are now handled more gracefully during prompt rendering.
✨ New Features
- Tool call parsing now accepts an optional leading {"type": "function"} field in `build_json_tools_flat_keys` to support OpenAI style tool calls.
- Tool call parsing leniency for {"type": "function"} is now gated by the `openai_wrapper_trigger` analysis flag.
🐛 Bug Fixes
- Peg-native parse failures now return a clean error and log the unparsed fragment instead of throwing raw parser position and input, preventing silent failures with empty assistant turns.
- When arguments string is not valid JSON during prompt rendering, the raw arguments string is kept in `func_args_not_string` instead of aborting the render.