Azure is configurable from the settings window - #21
Merged
Merged
Conversation
Owner report from the Windows dev build (2026-08-03): "I don't see azure in the setting". The backend existed only for hand-edited config.toml entries — which §17 does not consider an onboarding flow, and on a fresh machine there is nothing to hand-edit from. The provider draft gains an Azure row: resource endpoint, API key, and a deployments field prefilled with the model-named defaults the portal itself suggests (each name becomes a model in the picker; the entry is written with `models = [...]` on the v1 surface). Saving stores the credential, writes the `[[providers]]` entry, and rebuilds the engine — and because dictation discovers its endpoint from that same entry, saving the card is also the entire Azure STT setup.
There was a problem hiding this comment.
Pull request overview
This PR makes the Azure backend configurable from the Settings → Providers UI by adding an Azure provider option and wiring the settings “Save” action through to credential storage and config.toml provider entries (including an Azure models = [...] catalogue for the Azure v1 surface).
Changes:
- Add
Backend::Azureto the Settings provider picker and render Azure-specific fields (endpoint + deployments). - Persist Azure deployments as a
models = [...]list in the[[providers]]config entry and plumb that list through the UI→runtime bridge. - Add EN/JA i18n placeholder text for the new deployments field.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
src/main.rs |
Extends provider config splicing/upserting to optionally write models = [...], and plumbs models through set_provider_key. |
crates/aibo-ui/src/settings.rs |
Adds Azure backend to the UI picker and provider draft, including an Azure deployments field. |
crates/aibo-ui/src/i18n.rs |
Adds EN/JA placeholder strings for the Azure deployments field. |
crates/aibo-ui/src/bridge.rs |
Extends UiRequest::SetProviderKey to carry a models list. |
crates/aibo-ui/src/app.rs |
Handles draft updates for the deployments field and sends parsed deployments to the runtime on save. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+2762
to
+2770
| // Azure only: the comma-separated deployments become the picker | ||
| // catalogue. Other backends never show the field, so it is empty. | ||
| let models: Vec<String> = draft | ||
| .models | ||
| .split(',') | ||
| .map(str::trim) | ||
| .filter(|model| !model.is_empty()) | ||
| .map(str::to_owned) | ||
| .collect(); |
Comment on lines
+504
to
+508
| match self.backend { | ||
| Backend::Custom => !(self.base_url.trim().is_empty() || self.id.trim().is_empty()), | ||
| Backend::Azure => !self.base_url.trim().is_empty(), | ||
| _ => true, | ||
| } |
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.
Follow-up to the Windows dev-build report: Azure was config.toml-only, invisible in Settings → Providers.
Backend::Azurejoins the provider draft picker ("Azure OpenAI / Foundry").gpt-5.6-luna, gpt-5.6-terra, gpt-5.6-sol(the portal's model-named-deployment convention; each becomes a picker model via thev1surface'smodels = [...]).[[providers]]entry written (now withmodels) + engine rebuild. Dictation's Azure backend discovers its endpoint from the same entry, so one card configures chat and STT.splice_provider/upsert_providercarry the models list with tests updated.Gates green: fmt, clippy
-D warnings, all 22 test suites, msvc cross-check.