Enable incremental tool declarations by default for GCP (#60848)

## What changed

- Add the stable `incremental_tools_legacy_gcp` feature, enabled by default, to control incremental tool declarations on regular GCP Responses independently of Amazon Bedrock.
- Mark `incremental_tools_legacy` stable and keep it disabled by default for Amazon Bedrock.
- Expose the new flag in the configuration schema.

## Testing

Update integration coverage for GCP defaults and opt-out, independent provider flags, and incremental tool declarations during remote compaction.

GitOrigin-RevId: 7acf085789d44122fd2a5da97932a8b9e93e240e
This commit is contained in:
Alex Kira
2026-11-11 19:18:14 +00:00
committed by copyberry
parent 367c675602
commit b117b2d6fe
6 changed files with 49 additions and 25 deletions
+7 -5
View File
@@ -62,11 +62,13 @@ impl StepContext {
if self.settings.model_info.use_responses_lite {
Some(Feature::IncrementalTools)
} else {
matches!(
self.turn.config.model_provider_id.as_str(),
AMAZON_BEDROCK_PROVIDER_ID | AMAZON_BEDROCK_RUNTIME_PROVIDER_ID | GCP_PROVIDER_ID
)
.then_some(Feature::IncrementalToolsLegacy)
match self.turn.config.model_provider_id.as_str() {
AMAZON_BEDROCK_PROVIDER_ID | AMAZON_BEDROCK_RUNTIME_PROVIDER_ID => {
Some(Feature::IncrementalToolsLegacy)
}
GCP_PROVIDER_ID => Some(Feature::IncrementalToolsLegacyGcp),
_ => None,
}
}
}