mirror of
https://github.com/microsoft/autogen.git
synced 2026-04-20 03:02:16 -04:00
Rename fields in agent metadata (#336)
* Rename fields in agent metadata * team one fixes * another fix
This commit is contained in:
@@ -23,7 +23,7 @@ class UserProxyAgent(TypeRoutedAgent):
|
||||
async def on_publish_now(self, message: PublishNow, cancellation_token: CancellationToken) -> None:
|
||||
"""Handle a publish now message. This method prompts the user for input, then publishes it."""
|
||||
user_input = await self.get_user_input(self._user_input_prompt)
|
||||
await self.publish_message(TextMessage(content=user_input, source=self.metadata["name"]))
|
||||
await self.publish_message(TextMessage(content=user_input, source=self.metadata["type"]))
|
||||
|
||||
async def get_user_input(self, prompt: str) -> str:
|
||||
"""Get user input from the console. Override this method to customize how user input is retrieved."""
|
||||
|
||||
Reference in New Issue
Block a user