As of today, I run into the following error for gemini-3-pro-preview and gemini-3.1-pro-preview when using the Vertex API. Prior to today, this functionality was working without issue.
- {
"error": {
"code": 400,
"message": "Unable to submit request because Logprobs is not supported for this model. Learn more:
",
"status": "INVALID_ARGUMENT"
}
}
Note that I query Gemini via the following:
vertexai.init(project=project, location="global")
model = GenerativeModel(model_name, system_instruction=_CLASSIFIER_SYSTEM_INSTRUCTION,)
config = GenerationConfig(temperature=0.0,response_logprobs=True,logprobs=5)
response = model.generate_content(prompt, generation_config=config)