unique_toolkit 2026.28.0.dev8__py3-none-any.whl → 2026.28.0.dev9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,8 +2,15 @@
2
2
 
3
3
  Single responsibility: owns every ``unique_sdk.Message.modify_async`` call
4
4
  related to a streaming response (``startedStreamingAt``, incremental text
5
- + references, ``stoppedStreamingAt``, ``completedAt``), plus the
6
- ``content_chunks`` used to filter references down to what was actually cited.
5
+ + references, and ``stoppedStreamingAt``), plus the ``content_chunks`` used
6
+ to filter references down to what was actually cited.
7
+
8
+ The same message is streamed into once per agent round, and this subscriber
9
+ only sees per-request boundaries (never end-of-turn). It therefore stamps
10
+ ``stoppedStreamingAt`` only on rounds that produced answer text; tool-call
11
+ rounds (empty text) leave it null so the message stays in the streaming
12
+ state. ``completedAt`` is intentionally **not** written here — the
13
+ orchestrator marks completion at end-of-turn via ``set_completed_at``.
7
14
 
8
15
  Attach by calling :meth:`register` once on the owned bus:
9
16
 
@@ -162,6 +169,10 @@ class MessagePersistingSubscriber:
162
169
  if event.appendices:
163
170
  final_text = final_text + "".join(event.appendices)
164
171
 
172
+ # Only mark streaming stopped on the answer round; tool-call rounds have
173
+ # empty text and must stay "streaming" so the frontend keeps the steps.
174
+ stopped_streaming_at = now_iso if final_text else None
175
+
165
176
  await unique_sdk.Message.modify_async(
166
177
  id=event.message_id,
167
178
  chatId=event.chat_id,
@@ -173,6 +184,5 @@ class MessagePersistingSubscriber:
173
184
  # Chat completions persist their request as a JSON array; the SDK type is narrower.
174
185
  gptRequest=event.gpt_request, # pyright: ignore[reportArgumentType]
175
186
  debugInfo=event.debug_info,
176
- stoppedStreamingAt=cast(Any, now_iso),
177
- completedAt=cast(Any, now_iso),
187
+ stoppedStreamingAt=cast(Any, stopped_streaming_at),
178
188
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: unique-toolkit
3
- Version: 2026.28.0.dev8
3
+ Version: 2026.28.0.dev9
4
4
  Summary:
5
5
  Author: Cedric Klinkert, Martin Fadler, Sadique Sheik, Fabian Schläpfer, Pascal Hauri, Ejiroghene Oki-Peter, Rami Azouz, Ricardo Visini, Sanzio Monti
6
6
  Author-email: Cedric Klinkert <cedric.klinkert@unique.ch>, Martin Fadler <martin.fadler@unique.ch>, Sadique Sheik <sadique@unique.ch>, Fabian Schläpfer <fabian@unique.ch>, Pascal Hauri <pascal@unique.ch>, Ejiroghene Oki-Peter <oki-peter.ejiroghene@unique.ai>, Rami Azouz <rami.ext@unique.ch>, Ricardo Visini <ricardo.visini@unique.ch>, Sanzio Monti <sanzio.monti@unique.ai>
@@ -336,7 +336,7 @@ unique_toolkit/experimental/integrations/openai/streaming/event_routing/response
336
336
  unique_toolkit/experimental/integrations/openai/streaming/event_routing/responses/text_delta_event_handler.py,sha256=JB-7W89K4pT6K8A9Z_f_Pow5p-EIGwLoLUSb9BI3qW4,3634
337
337
  unique_toolkit/experimental/integrations/openai/streaming/event_routing/responses/tool_call_event_handler.py,sha256=iELT-H3-u6eG3D3X9Qz0QfTlDj-IfHBAq7bWYR7Dd5U,3198
338
338
  unique_toolkit/experimental/integrations/openai/streaming/event_routing/subscribers/__init__.py,sha256=4wpUt9kzfPzncO9tlKcvOQUzQG5e6kVp5AKZI5grxOk,276
339
- unique_toolkit/experimental/integrations/openai/streaming/event_routing/subscribers/message_persister.py,sha256=nHh2vQWF6YWurdkijof6UXhTMFzllj_4eSdr8nm9aDI,8016
339
+ unique_toolkit/experimental/integrations/openai/streaming/event_routing/subscribers/message_persister.py,sha256=cqwDI6PLLiocaBUBL6VPLqgucH_Y_wKTdN3HdadFq6k,8635
340
340
  unique_toolkit/experimental/integrations/openai/streaming/event_routing/subscribers/progress_log_persister.py,sha256=VCYGZY3WSpI7mvVs2gO89-M0JenakW01BGfBfFkPDrw,3499
341
341
  unique_toolkit/experimental/resources/__init__.py,sha256=KdMPaaneY0twZ-JBfwImRjXZaWT68NVuOIeqdNXFh_Y,3377
342
342
  unique_toolkit/experimental/resources/content_folder/__init__.py,sha256=c5MUj1xIP10L7tcM4-hG2m1_yUMVfKr_jHAncUXVNvo,2492
@@ -406,6 +406,6 @@ unique_toolkit/short_term_memory/service.py,sha256=2JMBEBn6GoyK-a0xvdcWpPft-3C74
406
406
  unique_toolkit/smart_rules/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
407
407
  unique_toolkit/smart_rules/compile.py,sha256=vRe0aMJWuVIK-VsqomgxQImzke7MDmwgSxxJfYCa7zw,1386
408
408
  unique_toolkit/test_utilities/events.py,sha256=FLrhMh0A_mQutAUjoD0FdMcVQ4Gq31r35OVGzRjvLro,6760
409
- unique_toolkit-2026.28.0.dev8.dist-info/WHEEL,sha256=eh7sammvW2TypMMMGKgsM83HyA_3qQ5Lgg3ynoecH3M,79
410
- unique_toolkit-2026.28.0.dev8.dist-info/METADATA,sha256=v9-siqdK8nGyMVGx7bXMB2dX4Z3RTGeS7KZZd4v069U,7427
411
- unique_toolkit-2026.28.0.dev8.dist-info/RECORD,,
409
+ unique_toolkit-2026.28.0.dev9.dist-info/WHEEL,sha256=eh7sammvW2TypMMMGKgsM83HyA_3qQ5Lgg3ynoecH3M,79
410
+ unique_toolkit-2026.28.0.dev9.dist-info/METADATA,sha256=qXosj8SbRg2-BNbpviYvDe9xj98kVKyr0_KLcJFvYvs,7427
411
+ unique_toolkit-2026.28.0.dev9.dist-info/RECORD,,