Skip to content

fix: add missing region, profile, and title to YAML model schema#11970

Open
ewalsh wants to merge 1 commit intocontinuedev:mainfrom
ewalsh:fix/9297-yaml-schema-missing-provider-fields
Open

fix: add missing region, profile, and title to YAML model schema#11970
ewalsh wants to merge 1 commit intocontinuedev:mainfrom
ewalsh:fix/9297-yaml-schema-missing-provider-fields

Conversation

@ewalsh
Copy link
Copy Markdown

@ewalsh ewalsh commented Mar 30, 2026

The baseModelFields schema in packages/config-yaml/src/schemas/models.ts is missing
several fields that BaseLLM reads in its constructor, including region, profile,
and title. Because Zod objects use strict validation (additionalProperties: false),
these fields are silently stripped from config.yaml model entries before reaching
provider constructors.

This causes the Bedrock provider to fail with bedrock-runtime.undefined.amazonaws.com
and Credential should be scoped to a valid region errors.

Fixes #9297

Description

Added title, region, and profile as optional string fields to baseModelFields
in packages/config-yaml/src/schemas/models.ts. These fields are already read by
BaseLLM in core/llm/BaseLLM.ts but were not declared in the YAML schema.

AI Code Review

  • Team members only: AI review runs automatically when PR is opened or marked ready for review
  • Team members can also trigger a review by commenting @continue-review

Checklist

  • I've read the contributing guide
  • The relevant docs, if any, have been updated or created
  • The relevant tests, if any, have been updated or created

Screen recording or screenshot

Before fix: Bedrock model in config.yaml with region: eu-west-2 and profile: claude:

getaddrinfo ENOTFOUND bedrock-runtime.undefined.amazonaws.com

After fix: Fields pass through schema validation and Bedrock connects successfully.

Tests

No new tests added. Verified manually by configuring a Bedrock model in config.yaml
with region and profile fields — requests succeed after the change.


Summary by cubic

Pass provider-specific fields through the YAML model schema by adding them to baseModelFields. This stops strict validation from stripping config and fixes Bedrock region/profile errors; Azure and Vertex AI configs now work, and title is preserved.

  • Bug Fixes
    • In packages/config-yaml/src/schemas/models.ts, added optional fields to baseModelFields: title, region, profile, accountId, deployment, deploymentId, apiVersion, apiType, projectId, accessKeyId, secretAccessKey.

Written for commit 5a0de48. Summary will update on new commits.

The baseModelFields in the config-yaml schema does not include region, profile,
or title as allowed properties. Combined with Zod's strict object validation,
these fields are silently stripped before reaching provider constructors.

This breaks Bedrock (region/profile), Azure (deployment/apiVersion),
Vertex AI (projectId), and all providers (title).

Adds the missing optional fields to baseModelFields in
packages/config-yaml/src/schemas/models.ts.

Fixes continuedev#9297
@ewalsh ewalsh requested a review from a team as a code owner March 30, 2026 10:14
@ewalsh ewalsh requested review from sestinj and removed request for a team March 30, 2026 10:14
@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Mar 30, 2026
@github-actions
Copy link
Copy Markdown
Contributor


Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I hereby sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot.

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 1 file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S This PR changes 10-29 lines, ignoring generated files.

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

Bedrock models not working

1 participant