Task tool 'opus' model parameter resolves to claude-opus-4-1 instead of claude-opus-4-6

Resolved 💬 5 comments Opened Feb 13, 2026 by pablo-alonso-arista Closed Apr 14, 2026

Bug Description

When spawning subagents via the Task tool with model: "opus", it resolves to claude-opus-4-1 instead of claude-opus-4-6. This causes failures on organizations that have allowlisted claude-opus-4-6 but not claude-opus-4-1 in their Vertex AI organization policy.

Expected Behavior

The "opus" model parameter should resolve to claude-opus-4-6 (the latest Opus model), or should respect the "model": "claude-opus-4-6" setting in ~/.claude/settings.json.

Actual Behavior

API Error: 400 Organization Policy constraint constraints/vertexai.allowedModels violated 
for projects/XXXXX attempting to use a disallowed Gen AI model claude-opus-4-1. 
Please contact your organization administrator to fix this violation by adding 
publishers/anthropic/models/claude-opus-4-1:predict to the allowed values.

Environment

  • Claude Code main session model: claude-opus-4-6 (set in ~/.claude/settings.json)
  • Platform: macOS (Darwin 25.2.0)
  • Provider: Vertex AI (Google Cloud)
  • Org policy: constraints/vertexai.allowedModels allows claude-opus-4-6 but not claude-opus-4-1

Steps to Reproduce

  1. Set "model": "claude-opus-4-6" in ~/.claude/settings.json
  2. Have org policy that allows claude-opus-4-6 but blocks claude-opus-4-1
  3. Use Task tool with model: "opus" parameter
  4. Subagent fails with 400 error referencing claude-opus-4-1

Suggested Fix

Either:

  1. Have the "opus" enum resolve to claude-opus-4-6 (the current latest)
  2. Inherit the parent session's model when model: "opus" is specified and the parent is already running opus
  3. Support a configuration option (env var or settings.json) to control which specific model ID the "opus" alias maps to for subagents

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗