Skip to content

armgit / burr

Public Imported from GitHub
0

Build applications that make decisions (chatbots, agents, simulations, etc...). Monitor, trace, persist, and execute on your own infrastructure.

Update action.py to have correct streaming action example

Elijah ben Izzy2542811aa788
diff --git a/burr/core/action.py b/burr/core/action.py
index 5f35cfe6..5acabfe7 100644
--- a/burr/core/action.py
+++ b/burr/core/action.py
@@ -1085,7 +1085,7 @@ def streaming_action(
delta = chunk.choices[0].delta.content
buffer.append(delta)
# yield partial results
- yield {'response': delta}
+ yield {'response': delta}, None
full_response = ''.join(buffer)
# return the final result
return {'response': full_response}, state.update(response=full_response)