Skip to content

Commit

Permalink
Allow Executor to search for code in multimodal messages. (#285)
Browse files Browse the repository at this point in the history
  • Loading branch information
afourney authored Jul 26, 2024
1 parent cf2bcd3 commit 99b5355
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/teams/team-one/src/team_one/agents/coder.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
)
from agnext.core import CancellationToken

from ..utils import message_content_to_str
from ..messages import UserContent
from .base_agent import BaseAgent

Expand Down Expand Up @@ -77,8 +78,7 @@ async def _generate_reply(self, cancellation_token: CancellationToken) -> Tuple[
continue

# Extract code block from the message.
assert isinstance(message.content, str)
code = self._extract_execution_request(message.content)
code = self._extract_execution_request(message_content_to_str(message.content))
if code is not None:
execution_requests = [CodeBlock(code=code, language="python")]
future = asyncio.get_event_loop().run_in_executor(
Expand Down

0 comments on commit 99b5355

Please sign in to comment.