Skip to main content
Glama

write_data_driven_optimize_config

Creates and uploads a JSON configuration to Google Cloud Storage for data-driven prompt optimization, supporting methods like VAPO or Gemini Nano.

Instructions

Constructs a JSON configuration for Data-Driven Optimize and uploads it to GCS.

This tool generates a JSON configuration file based on the provided parameters and uploads it to the specified Google Cloud Storage URI. This configuration file is required to run data-driven prompt optimization.

Args: gcs_config_uri: The GCS URI where the generated VAPO config JSON file will be saved (e.g., 'gs://my-bucket/vapo/config.json'). prompt_optimizer_method: The method for prompt optimization. Either 'VAPO' or 'OPTIMIZATION_TARGET_GEMINI_NANO'. target_model_endpoint_url: The custom endpoint URL for the target model. Required for Gemini Nano target. base_config: Optional. A dictionary representing the base configuration. modifications: Optional. A dictionary representing the modifications to apply to the base config. base_config_path: Optional. Path to a base config file. If provided and base_config is None, this config will be loaded.

Returns: A string containing a success message and details about the uploaded configuration file, including a link to the Vertex AI console.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
base_configNo
modificationsNo
gcs_config_uriYes
base_config_pathNo
prompt_optimizer_methodYes
target_model_endpoint_urlNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses that the tool generates JSON and uploads to GCS, and mentions the return value. With no annotations, it provides moderate behavioral context but lacks details on side effects like overwriting, permissions, or rate limits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is somewhat verbose with a docstring format including Args and Returns. It is front-loaded with the main action but could be more concise.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and an output schema (though not shown), the description adequately explains the tool's actions, parameters, and return value. It covers the essentials for a config-generation tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description includes a detailed docstring explaining each parameter (gcs_config_uri, prompt_optimizer_method, etc.). This adds significant meaning beyond the schema's titles.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool constructs a JSON configuration for Data-Driven Optimize and uploads it to GCS. It distinguishes itself from siblings like run_data_driven_optimize and analyze_data_driven_optimize_results by focusing on config generation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description does not specify when to use this tool versus alternatives, nor does it explain prerequisites or that this must precede run_data_driven_optimize. No guidance on when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hzy9981/vertex-ai-mcp-bridge'

If you have feedback or need assistance with the MCP directory API, please join our Discord server