MCPcopy Create free account
hub / github.com/google/adk-python / _run_impl

Method _run_impl

src/google/adk/agents/base_agent.py:315–331  ·  view source on GitHub ↗

Runs the agent as a node.

(
      self,
      *,
      ctx: Context,
      node_input: Any,
  )

Source from the content-addressed store, hash-verified

313
314 @override
315 async def _run_impl(
316 self,
317 *,
318 ctx: Context,
319 node_input: Any,
320 ) -> AsyncGenerator[Any, None]:
321 """Runs the agent as a node."""
322 async for event in self.run_async(
323 parent_context=ctx.get_invocation_context()
324 ):
325 # Preserve author by setting it in context for NodeRunner
326 if event.author:
327 ctx.event_author = event.author
328
329 if not event.node_info.path and event.author == self.name:
330 event.node_info.path = ctx.node_path
331 yield event
332
333 @final
334 async def run_live(

Callers

nothing calls this directly

Calls 2

run_asyncMethod · 0.95

Tested by

no test coverage detected