Skip to content

Google Vertex OpenAI Models - Error 400 INVALID ARGUMENT #3333

@Mgczacki

Description

@Mgczacki

Initial Checks

Description

As of the latest versions of PydanticAI, using the "google-vertex:gpt-oss-120b-maas" model from Google Vertex's model garden is not possible due to this error:

google.genai.errors.ClientError: 400 INVALID_ARGUMENT. {'error': {'code': 400, 'message': 'Request contains an invalid argument.', 'status': 'INVALID_ARGUMENT'}}

Example Code

from pydantic_ai import Agent

a = Agent("google-vertex:gpt-oss-120b-maas")

await a.run("Hello, world!")

Python, Pydantic AI & LLM client version

Python 3.13
pydantic-ai==1.10.0
google-genai==1.48.0

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions