VertexAI - "UNEXPECTED_TOOL_CALL" Error message not available for Gemini model calls
Client
https://pkg.go.dev/cloud.google.com/go/[email protected]
Expected behavior
UNEXPECTED_TOOL_CALL error message should be available
Actual behavior
The error message is not available within the client.
Additional Context:
Gemini now provides an "UNEXPECTED_TOOL_CALL" message but it doesn't appear to be available yet in this Go client.
https://pkg.go.dev/cloud.google.com/go/vertexai/genai#FinishReason
Additional context: https://cloud.google.com/vertex-ai/generative-ai/docs/reference/rpc/google.cloud.aiplatform.v1#finishreason
This issue is related to the cloud.google.com/go/vertexai/genai package. Please note that as of June 24, 2025, this package is deprecated and will be removed on June 24, 2026, with the exception of cloud.google.com/go/vertexai/genai/tokenizer.
New users are encouraged to use the Google GenAI Go SDK, which is available at google.golang.org/genai. For migration information, please refer to the Vertex AI SDK migration guide.
Given the deprecation of the affected package, I will be closing this issue. If you encounter similar problems with the new Google GenAI Go SDK, please open a new issue there.