Full name: projects.locations.generateLossClusters
Generates loss clusters from evaluation results. This is a statelss API method that would not modify the EvaluationSet resource.
Endpoint
posthttps://{service-endpoint}/v1beta1/{location}:generateLossClusters
Where {endpoint} is one of the supported service endpoints.
Path parameters
locationstring
Required. The resource name of the Location. Format: projects/{project}/locations/{location}
Request body
The request body contains data with the following structure:
Required. Configuration for the analysis algorithm. Analysis for multiple metrics and multiple candidates could be specified.
sourceUnion type
source can be only one of the following:evaluationSetstring
Reference to a persisted EvaluationSet. The service will read items from this set.
Inline evaluation results. Useful for ephemeral analysis in notebooks/SDKs where data isn't persisted.
Response body
If successful, the response body contains an instance of Operation.
EvaluationResultList
This type has no fields.
A wrapper to allow providing a list of items inline.
LossAnalysisConfig
Configuration for the loss analysis job.
metricstring
Required. The metric to analyze (e.g., "tool_use_quality"). This filters the EvaluationItems in the EvalSet to only those where EvaluationResult.metric matches this value.
candidatestring
Required. The candidate model/agent to analyze (e.g., "gemini-3.0-pro"). This targets the specific CandidateResult within the EvaluationResult.
| JSON representation |
|---|
{ "metric": string, "candidate": string } |