From 7aaf8116169c210ceda35c649b5b49fb65bbb740 Mon Sep 17 00:00:00 2001 From: Cristopher Hugo Olivares Del Real Date: Fri, 30 May 2025 14:55:06 -0700 Subject: [PATCH] fix: typos in documentation Copybara import of the project: -- db506da1c38f0a27df51b0e672ef78d62077af78 by Cristopher Hugo Olivares Del Real : fix: typos in documentation COPYBARA_INTEGRATE_REVIEW=https://github.com/google/adk-python/pull/840 from crissins:main 76a5e9bfbe73e7744b144010741a4e80425282a9 PiperOrigin-RevId: 765347788 --- src/google/adk/agents/invocation_context.py | 6 +++--- src/google/adk/agents/sequential_agent.py | 16 ++++++++-------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/google/adk/agents/invocation_context.py b/src/google/adk/agents/invocation_context.py index 46ec663..f703715 100644 --- a/src/google/adk/agents/invocation_context.py +++ b/src/google/adk/agents/invocation_context.py @@ -39,9 +39,9 @@ class LlmCallsLimitExceededError(Exception): class _InvocationCostManager(BaseModel): """A container to keep track of the cost of invocation. - While we don't expected the metrics captured here to be a direct - representatative of monetary cost incurred in executing the current - invocation, but they, in someways have an indirect affect. + While we don't expect the metrics captured here to be a direct + representative of monetary cost incurred in executing the current + invocation, they in some ways have an indirect effect. """ _number_of_llm_calls: int = 0 diff --git a/src/google/adk/agents/sequential_agent.py b/src/google/adk/agents/sequential_agent.py index 91b0013..845dd5a 100644 --- a/src/google/adk/agents/sequential_agent.py +++ b/src/google/adk/agents/sequential_agent.py @@ -27,7 +27,7 @@ from .llm_agent import LlmAgent class SequentialAgent(BaseAgent): - """A shell agent that run its sub-agents in sequence.""" + """A shell agent that runs its sub-agents in sequence.""" @override async def _run_async_impl( @@ -43,11 +43,11 @@ class SequentialAgent(BaseAgent): ) -> AsyncGenerator[Event, None]: """Implementation for live SequentialAgent. - Compared to non-live case, live agents process a continous streams of audio - or video, so it doesn't have a way to tell if it's finished and should pass - to next agent or not. So we introduce a task_completed() function so the + Compared to the non-live case, live agents process a continuous stream of audio + or video, so there is no way to tell if it's finished and should pass + to the next agent or not. So we introduce a task_completed() function so the model can call this function to signal that it's finished the task and we - can move on to next agent. + can move on to the next agent. Args: ctx: The invocation context of the agent. @@ -66,10 +66,10 @@ class SequentialAgent(BaseAgent): # Use function name to dedupe. if task_completed.__name__ not in sub_agent.tools: sub_agent.tools.append(task_completed) - sub_agent.instruction += f"""If you finished the user' request - according to its description, call {task_completed.__name__} function + sub_agent.instruction += f"""If you finished the user's request + according to its description, call the {task_completed.__name__} function to exit so the next agents can take over. When calling this function, - do not generate any text other than the function call.'""" + do not generate any text other than the function call.""" for sub_agent in self.sub_agents: async for event in sub_agent.run_live(ctx):