Skip to content

feat: support gpt-5.4 and gemini-3.1 model families#22

Open
AlexMetsai wants to merge 3 commits into
mainfrom
feat/extend_supported_models
Open

feat: support gpt-5.4 and gemini-3.1 model families#22
AlexMetsai wants to merge 3 commits into
mainfrom
feat/extend_supported_models

Conversation

@AlexMetsai
Copy link
Copy Markdown
Contributor

No description provided.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for two new model families across the type registry, model factory, orchestrator graph routing, and frontend selector: the Azure OpenAI gpt-5.4-mini/gpt-5.4-nano models and the Google Vertex AI gemini-3.1-flash-lite-preview model. The existing gemini-3-pro-preview entry in _MODEL_METADATA is also renamed to gemini-3.1-pro-preview and its supported thinking levels expanded from low/high to low/medium/high, mirrored in the frontend's getAvailableThinkingLevels filter.

Changes:

  • Register gpt-5.4-mini, gpt-5.4-nano, and gemini-3.1-flash-lite-preview in the ModelType literal, _MODEL_METADATA, and the per-provider config dicts in model_factory.py; route them in create_model() for Gemini.
  • Wire the new models into orchestrator response-format/strategy routing and Gemini built-in tool injection in graph_factory.py.
  • Add the new options to the frontend MODEL_OPTIONS list and update the Gemini 3.1 Pro thinking-level filter to include medium.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
packages/agent-common/agent_common/models/base.py Adds three new entries to the ModelType literal.
packages/agent-common/agent_common/core/model_factory.py Adds metadata + provider configs for the new models; renames Gemini Pro key to 3.1 and updates thinking levels; routes flash-lite through the Gemini branch.
packages/orchestrator-agent/app/core/graph_factory.py Includes the new GPT-5.4 models in the ToolStrategy branch and the new Gemini in the Gemini response/tools branches.
packages/console-frontend/src/config/models.ts Adds the three new models to MODEL_OPTIONS and broadens Gemini 3.1 Pro's allowed thinking levels to include medium.
Comments suppressed due to low confidence (1)

packages/agent-common/agent_common/core/model_factory.py:143

  • The new gemini-3.1-flash-lite-preview entry is missing the location, display_name, and description fields that the other Gemini entries (gemini-3.1-pro-preview, gemini-3-flash-preview) define. Two concrete consequences:
  1. In create_model() at line 470, gcp_location = model_config.get("location") or os.getenv("GCP_LOCATION", "europe-west4") — without "location": "global" this model will be routed to the env-configured region (or europe-west4) rather than global like its siblings. If that is intentional, it should be made explicit; otherwise the omission will cause routing differences from the other Gemini 3.x models.
  2. _get_models_prompt_text() (lines 353-358) will emit - gemini-3.1-flash-lite-preview (gemini-3.1-flash-lite-preview): with an empty description, so the agent-creator prompt won't describe this model.

Please add the missing keys consistent with the other Gemini entries (or explicitly document why location is omitted).

    "gemini-3.1-flash-lite-preview": {
        "model_id": "gemini-3.1-flash-lite-preview",
        "input_modes": ["text", "image", "audio", "video", "file"],
        "backend": "google",
    },

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +82 to +95
"gpt-5.4-mini": {
"api_version": "2025-01-01-preview",
"deployment": "gpt-5.4-mini",
"model_name": "gpt-5.4-mini",
"input_modes": ["text", "image"],
"backend": "azure_openai",
},
"gpt-5.4-nano": {
"api_version": "2025-01-01-preview",
"deployment": "gpt-5.4-nano",
"model_name": "gpt-5.4-nano",
"input_modes": ["text", "image"],
"backend": "azure_openai",
},
Comment on lines +45 to 49
"gemini-3.1-flash-lite-preview": {
"label": "Gemini 3.1 Flash Lite Preview",
"provider": "Google Vertex AI",
"supports_thinking": True,
"thinking_levels": ["low", "high"],
},
Comment on lines +12 to +18
"gpt-5.4-mini",
"gpt-5.4-nano",
"claude-sonnet-4.5",
"claude-sonnet-4.6",
"claude-haiku-4-5",
"gemini-3.1-pro-preview",
"gemini-3.1-flash-lite-preview",
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants