[Feat]: Trigger microagents on agent keywords (#7516)

This commit is contained in:
Rohit Malhotra
2025-03-27 13:58:37 -04:00
committed by GitHub
parent 26b420a01d
commit 76c992e2df
3 changed files with 76 additions and 5 deletions

View File

@@ -98,11 +98,14 @@ class Memory:
return
# Handle knowledge recall (triggered microagents)
# Allow triggering from both user and agent messages
elif (
event.source == EventSource.USER
and event.recall_type == RecallType.KNOWLEDGE
):
logger.debug('Microagent knowledge recall')
or event.source == EventSource.AGENT
) and event.recall_type == RecallType.KNOWLEDGE:
logger.debug(
f'Microagent knowledge recall from {event.source} message'
)
microagent_obs: RecallObservation | NullObservation | None = None
microagent_obs = self._on_microagent_recall(event)
if microagent_obs is None: