dev_fix: set environment variables for Google GenAI Client to use Vertex AI
This commit is contained in:
@@ -16,11 +16,17 @@
|
|||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
import os
|
||||||
|
|
||||||
from google.adk.agents.llm_agent import Agent
|
from google.adk.agents.llm_agent import Agent
|
||||||
|
|
||||||
from .config_helper import settings
|
from .config_helper import settings
|
||||||
from .vector_search_tool import VectorSearchTool
|
from .vector_search_tool import VectorSearchTool
|
||||||
|
|
||||||
|
# Set environment variables for Google GenAI Client to use Vertex AI
|
||||||
|
os.environ["GOOGLE_CLOUD_PROJECT"] = settings.project_id
|
||||||
|
os.environ["GOOGLE_CLOUD_LOCATION"] = settings.location
|
||||||
|
|
||||||
# Create vector search tool with configuration
|
# Create vector search tool with configuration
|
||||||
vector_search_tool = VectorSearchTool(
|
vector_search_tool = VectorSearchTool(
|
||||||
name='conocimiento',
|
name='conocimiento',
|
||||||
|
|||||||
Reference in New Issue
Block a user