Repository navigation
models: add model sources to agent catalogs - #543
Open
TylerLeonhardt wants to merge 6 commits into
Open
TylerLeonhardt wants to merge 6 commits into
TylerLeonhardt wants to merge 6 commits into
Conversation
Add per-harness model-provider catalogs and mutually gated exact model selections while preserving legacy unqualified behavior. Specify safe catalog projection, fail-closed routing requirements, and durable automation ownership using existing protocol surfaces. Regenerate client/schema mirrors and add shared conformance coverage. Preserve Go empty-object capability markers and document the associated source migration and native validation requirements. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use model-source terminology for the unreleased catalog, qualifier and mutual capability marker to distinguish model access from the owning harness and model vendor. Update normative docs, examples, changelog fragment and shared fixtures; regenerate all client/schema mirrors. Preserve existing provider harness fields, vendor metadata, raw model IDs and exact-selection behavior. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
TylerLeonhardt
marked this pull request as ready for review
October 23, 2026 04:11
TylerLeonhardt
requested review from
Connor Peet (connor4312) and
roblourens
as code owners
October 23, 2026 04:11
roblourens
reviewed
Oct 27, 2026
This was referenced Nov 19, 2026
Open
Generated clients and schemas were resolved by regenerating with `npm run generate`. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Logan Ramos (lramos15)
added a commit
that referenced
this pull request
Nov 20, 2026
Rename the proposed customization from ModelProvider to ModelSource so it uses the term #543 already settled on, and rename the file to match. Follow #543's direction after review: model IDs are unique in the session's catalog, a selection is just a model `id`, and neither the agent nor the client advertises a capability. Withdrawn models still fail rather than fall back, now justified on their own. Refs #619 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep model sources as labels and groups for pickers and select models by `id` alone. - Keep `ModelSourceInfo`, `AgentInfo.modelSources`, and `SessionModelInfo.modelSourceId`. Model IDs are unique within an agent's `models`; the host gives each source its own ID for a shared upstream model. - Remove `ModelSelection.modelSourceId` and the client and agent `modelSourceSelection` capabilities, along with legacy projection, exact-pair failure rules, preservation tables, and automation ownership rules. - Restore "agent provider" wording and shorten the JSDoc and the root-channel section. - Replace the qualified-selection fixtures with one catalog round-trip and one `mcpApps` presence round-trip for the Go capability fix. - Use a plain slice for Go `AgentInfo.ModelSources`. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Logan Ramos (lramos15)
added a commit
that referenced
this pull request
Nov 23, 2026
Propose a docs-only design for #619: clients register bring-your-own-key model sources with an agent host. Registrations live in root state with a host-reported status, a sharing policy, and a retention policy. Clients add and remove them with client-dispatchable root actions, deliver keys through `authenticate` with a `modelSource` target, and select their models from #543's agent catalog by `id`. A host-wide registry lets automations and long-running headless sessions keep using a source after its client disconnects, and shows the models before any session exists. No `types/` changes, so no regeneration and no changelog fragment. Refs #619 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep both sides' round-trip type imports, and renumber this branch's fixtures to 101 and 102 after main's new 100. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This branch has not been deployed
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
Lets an agent group its models by source, such as different services or subscriptions, so clients can label and group them in a model picker.
ModelSourceInfo { id, displayName }and an optionalAgentInfo.modelSources. A source can have no models.SessionModelInfo.modelSourceId, which must match an entry in the same agent'smodelSources.SessionModelInfo.idis unique within an agent'smodels. When two sources serve the same upstream model, the host gives each entry its own ID and maps it to the upstream model.ModelSelectionis unchanged:idplusconfig.See Model sources.
Also fixes the Go generator so optional empty-object capability flags (
ClientCapabilities.McpApps,ChangesetCapabilities.Review,AhpMcpUiHostCapabilities.Logging) keep{}on the wire. They are now pointer-to-map fields, which is a source change for Go callers. See the Go README.No protocol version bump.
Changes after review
ModelSelection.modelSourceId. A selection isidplusconfig.AgentCapabilities.modelSourceSelectionandClientCapabilities.modelSourceSelection.SessionModelInfo.idunique within an agent'smodels.chat-channel.md,automation-channel.md, andversioning.md.100-model-source-catalogand101-client-capabilities-mcp-apps-presence. The second one fails without the Go fix.main. Generated files were regenerated, not hand-merged.Validation
npm install && npm run generate, run twicenpm testcd clients/typescript && npm ci && npm run typecheck && npm test && npm run buildcd clients/rust && cargo fmt --all -- --check && cargo clippy --workspace -- -D warnings && cargo test --workspacecd clients/go && go build ./... && gofmt -l . && go vet ./... && go test ./...docker run --rm -e GRADLE_USER_HOME=/tmp/gradle-home -v "$PWD":/workspace -w /workspace/clients/kotlin docker.io/library/eclipse-temurin:17-jdk ./gradlew build --no-daemon --console=plainswift build && swift teston macOS with Xcodedotnetjobnpm run generate:docs && npm run docs:versions && npx vitepress build docs78323520