Building AI agents, atomically
Undo changes to async & streaming
KennyVaneetveldee85965cc8c38
diff --git a/atomic-agents/atomic_agents/agents/base_agent.py b/atomic-agents/atomic_agents/agents/base_agent.pyindex a7509d1..98b68c9 100644--- a/atomic-agents/atomic_agents/agents/base_agent.py+++ b/atomic-agents/atomic_agents/agents/base_agent.py@@ -205,7 +205,7 @@ class BaseAgent:stream=True,)- for partial_response in response_stream:+ async for partial_response in response_stream:yield partial_responsefull_response_content = self.output_schema(**partial_response.model_dump())diff --git a/atomic-agents/tests/agents/test_base_agent.py b/atomic-agents/tests/agents/test_base_agent.pyindex 7c3550e..40a3d28 100644--- a/atomic-agents/tests/agents/test_base_agent.py+++ b/atomic-agents/tests/agents/test_base_agent.py@@ -230,7 +230,7 @@ async def test_stream_response_async(agent, mock_memory, mock_instructor, mock_sBaseAgentOutputSchema(chat_message="Final response"),]- def mock_create_partial(*args, **kwargs):+ async def mock_create_partial(*args, **kwargs):for response in partial_responses:yield response