The llama.cpp project released build b11138, which updates the Jinja template parser to handle unary plus and minus operators before variables.

  • The lexer now emits unary_operator tokens for expressions like -n or +n, allowing them to be parsed at multiplicative precedence.
  • This change enables correct evaluation of slices such as items[:-n] and GigaChat indent[:-indent_factor].
  • Unary +/- are constrained to bind only the primary or postfix operand, ensuring that -n|abs evaluates as (-n)|abs rather than -(n|abs).
  • The release includes binaries for macOS (Apple Silicon and Intel), iOS, Linux (CPU, Vulkan, CUDA 12/13, ROCm, OpenVINO, SYCL, Snapdragon), Android, Windows, and openEuler.

This update ensures that template logic involving negative indexing or signed variables functions correctly within llama.cpp's Jinja implementation.