feat: normalized config schema with PersonaRecord.provider and SPROUT_AGENT_MODEL#794
Draft
wpfleger96 wants to merge 1 commit into
Draft
Conversation
…_AGENT_MODEL sprout-agent personas all failed because the desktop never injected SPROUT_AGENT_PROVIDER or model env vars at spawn time, and the goose config fallback only understood the old flat format. Extract goose config compat into an isolated submodule, add support for the newer active_provider + nested providers format, and wire a normalized config schema so Sprout injects the right env vars for any runtime. Key changes: - PersonaRecord.provider captures the LLM provider independently - SPROUT_AGENT_MODEL works as a universal model fallback - provider_env_var and model_env_var always injected at spawn time - Pack import now stores resolved env vars (was always empty) - runtime_env_vars() emits runtime-appropriate vars (SPROUT_AGENT_* vs GOOSE_*)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Wes's 24 sprout-agent personas all failed with
SPROUT_AGENT_PROVIDER requiredeven though Databricks was configured — because the desktop never injected provider/model env vars at spawn time, the goose config fallback only understood the old flat format, and pack import always stored an emptyenv_varsmap. This PR fixes all three structural gaps.sprout-agent gets a universal
SPROUT_AGENT_MODELenv var so a single model value works regardless of which LLM provider is active.GooseDatabricksConfigis extracted into an isolatedgoose_compatsubmodule and extended to parse the neweractive_provider+ nestedproviders:format Wes's config uses.PersonaRecordgains a first-classproviderfield alongsideruntimeandmodel, completing the normalized config schema, andKnownAcpRuntimemetadata is now fully wired into the spawn path.SPROUT_AGENT_MODELadded as universal model fallback inConfig::from_env()for all three provider arms;KnownAcpRuntimefor sprout-agent updated tomodel_env_var: Some("SPROUT_AGENT_MODEL")provider_env_varinjection wired intospawn_agent_child()respectingprovider_locked;!supports_acp_model_switchingguard removed (conflation of bootstrap vs. post-session model switching)runtime_env_vars()extended to emitSPROUT_AGENT_MODEL/SPROUT_AGENT_PROVIDERfor sprout-agent personas vs.GOOSE_MODEL/GOOSE_PROVIDERfor goose; pack import now populatesPersonaRecord.env_vars(was always empty) andPersonaRecord.providerPersonaDialogfor manual persona creation