Add preferred runtime onboarding (#2040)

Signed-off-by: Wes <wesbillman@users.noreply.github.com>
Co-authored-by: Pinky <44b8e82baa6e0e254e0208d68f335c283c94e7b78dd1fa10d5a49d3f13dd0435@sprout-oss.stage.blox.sqprod.co>
This commit is contained in:
Wes
2026-07-17 14:19:29 -06:00
committed by GitHub
parent 68e670e001
commit c19e0ce2d4
26 changed files with 1072 additions and 60 deletions

View File

@@ -63,6 +63,10 @@ pub struct GlobalAgentConfig {
/// a model. `None` = no global default.
#[serde(default)]
pub model: Option<String>,
/// Preferred ACP runtime for definitions without an explicit runtime.
#[serde(default)]
pub preferred_runtime: Option<String>,
}
/// Validate a `GlobalAgentConfig` before persisting it.

View File

@@ -266,6 +266,7 @@ fn roundtrip_serialization() {
env_vars: BTreeMap::from([("ANTHROPIC_API_KEY".to_string(), "sk-test".to_string())]),
provider: Some("anthropic".to_string()),
model: Some("claude-opus-4".to_string()),
preferred_runtime: Some("claude".to_string()),
};
let json = serde_json::to_string(&config).expect("serialize");
let back: GlobalAgentConfig = serde_json::from_str(&json).expect("deserialize");
@@ -582,6 +583,7 @@ fn populated_global_config_round_trips() {
.collect(),
provider: Some("anthropic".to_string()),
model: Some("claude-opus-4-5".to_string()),
preferred_runtime: None,
};
let json = serde_json::to_string(&original).expect("serialization must not fail");
let decoded: GlobalAgentConfig =