You've already forked adk-python
mirror of
https://github.com/encounter/adk-python.git
synced 2026-03-30 10:57:20 -07:00
fix: Support project-based gemini model path to use google_search_tool
PiperOrigin-RevId: 770858301
This commit is contained in:
committed by
Copybara-Service
parent
29e4ca9152
commit
b2fc7740b3
@@ -76,8 +76,8 @@ class VertexAiSearchTool(BaseTool):
|
||||
tool_context: ToolContext,
|
||||
llm_request: LlmRequest,
|
||||
) -> None:
|
||||
if llm_request.model and llm_request.model.startswith('gemini-'):
|
||||
if llm_request.model.startswith('gemini-1') and llm_request.config.tools:
|
||||
if llm_request.model and 'gemini-' in llm_request.model:
|
||||
if 'gemini-1' in llm_request.model and llm_request.config.tools:
|
||||
raise ValueError(
|
||||
'Vertex AI search tool can not be used with other tools in Gemini'
|
||||
' 1.x.'
|
||||
|
||||
Reference in New Issue
Block a user