Conversation
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.
Summary
This PR introduces configurable provider instances, allowing the same coding-agent provider to be added multiple times with different launch configurations.
Each instance has:
For example, multiple Codex instances can use different
CODEX_HOMEvalues, allowing separate accounts and configurations to coexist without changing Waku's process-wide environment.Motivation
Some coding agents use environment variables to select their configuration or account. Codex, for example, resolves configuration, authentication, sessions, and skills through
CODEX_HOME.Previously, Waku modeled each coding agent as a single global provider. Supporting multiple configurations would therefore require switching the environment outside Waku or duplicating provider-specific logic.
Provider instances keep the existing
ProviderKindresponsible for driver behavior and capabilities, while making launch configuration instance-specific. This also makes the feature usable by providers other than Codex.Changes
ProviderInstanceconfiguration with a stable ID, custom name, provider kind, enabled state, binary override, and environment.Backward compatibility
Existing settings and sessions continue to use the built-in provider instance whose ID matches the provider ID.
The existing
disabled_providersandprovider_binary_overridessettings remain supported, so no configuration migration is required.Custom instances cannot shadow built-in IDs, and legacy sessions without an explicit provider instance ID fall back to their original provider.
Testing
cargo test --libcargo check --bin wakubun test apps/web/srcbun run --cwd apps/web typecheckcargo run -p waku-protocol --bin export_types -- --check