Skip to content

Commit 1900592

Browse files
committed
fix: Apply pyink formatting and isort to fix CI checks
1 parent 1effca5 commit 1900592

File tree

3 files changed

+16
-20
lines changed

3 files changed

+16
-20
lines changed

contributing/samples/gepa/experiment.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@
4343
from tau_bench.types import EnvRunResult
4444
from tau_bench.types import RunConfig
4545
import tau_bench_agent as tau_bench_agent_lib
46-
4746
import utils
4847

4948

contributing/samples/gepa/run_experiment.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@
2525
from absl import flags
2626
import experiment
2727
from google.genai import types
28-
2928
import utils
3029

3130
_OUTPUT_DIR = flags.DEFINE_string(

src/google/adk/models/lite_llm.py

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1962,24 +1962,22 @@ async def generate_content_async(
19621962
),
19631963
)
19641964
)
1965-
aggregated_llm_response_with_tool_call = (
1966-
_message_to_generate_content_response(
1967-
ChatCompletionAssistantMessage(
1968-
role="assistant",
1969-
# FIX: Set content=None for tool-only messages to avoid duplication
1970-
# and follow OpenAI/LiteLLM conventions. Planning/reasoning text is
1971-
# already streamed (lines 1288-1296) and preserved in thought_parts
1972-
# (line 1357). Including it again in content causes duplication and
1973-
# violates API specifications for tool-call messages.
1974-
# See: https://github.com/google/adk-python/issues/3697
1975-
content=None,
1976-
tool_calls=tool_calls,
1977-
),
1978-
model_version=part.model,
1979-
thought_parts=list(reasoning_parts)
1980-
if reasoning_parts
1981-
else None,
1982-
)
1965+
aggregated_llm_response_with_tool_call = _message_to_generate_content_response(
1966+
ChatCompletionAssistantMessage(
1967+
role="assistant",
1968+
# FIX: Set content=None for tool-only messages to avoid duplication
1969+
# and follow OpenAI/LiteLLM conventions. Planning/reasoning text is
1970+
# already streamed (lines 1288-1296) and preserved in thought_parts
1971+
# (line 1357). Including it again in content causes duplication and
1972+
# violates API specifications for tool-call messages.
1973+
# See: https://github.com/google/adk-python/issues/3697
1974+
content=None,
1975+
tool_calls=tool_calls,
1976+
),
1977+
model_version=part.model,
1978+
thought_parts=list(reasoning_parts)
1979+
if reasoning_parts
1980+
else None,
19831981
)
19841982
aggregated_llm_response_with_tool_call.finish_reason = (
19851983
_map_finish_reason(finish_reason)

0 commit comments

Comments
 (0)