Skip to content

v2.5.0

Latest

Choose a tag to compare

@github-actions github-actions released this 08 Aug 15:54

What's Changed

  • fix: only parse marked output as chat messages by @masci in #78

Breaking changes

  • Building messages by rendering JSON from data (e.g. {% for m in history %}{{ m | tojson }}{% endfor %}) no longer produces messages — the JSON is returned as literal text. Use {% chat %} blocks instead.
  • The image, audio, video, document, cache_control and tool filters now take the Jinja render context as their first argument. Templates are unaffected; only direct Python calls need updating.
  • banks.types.CONTENT_BLOCK_REGEX is removed, replaced by content_block_start(sentinel) and CONTENT_BLOCK_END.
  • chat_message_from_text() gained a sentinel keyword argument; without it, content blocks are no longer parsed.

Prompt.text() output and the chat_messages() API are unchanged.

Full Changelog: v2.4.5...v2.5.0