docs: codify the binding rule for PROVIDER_ID; refresh stale sections - #85
Open
pofallon wants to merge 1 commit into
Open
docs: codify the binding rule for PROVIDER_ID; refresh stale sections#85pofallon wants to merge 1 commit into
pofallon wants to merge 1 commit into
Conversation
The rule for minting a PROVIDER_ID was implicit — recoverable only by reading the reserved-ID list and inferring why `anthropic` and `claude` are separate. Written down: an ID identifies a (wire protocol, endpoint, auth mechanism, feature surface) binding, not a vendor and not a framework. The reserved list is evidence for this, since every reserved pair splits one vendor across two IDs; `openrouter` / `opencode-zen` / `opencode-go` sharing OpenAICompatibleRuntime rules out the framework reading. Includes the two mechanisms that break when an ID straddles bindings (extras-gated discovery, the SUPPORTED_FEATURES manifest), a concrete test for whether something warrants a new ID, and the naming corollary that produced `kimi` rather than `moonshot`. Also records the credential-scoping invariant from the ClaudeCodeRuntime fix as a general obligation on any adapter with an overridable base URL. Stale content refreshed against the code: - Kimi is described as a shipped adapter; it was removed. Now listed as a reserved ID with the reason. - examples/probe_kimi.py went with it; the probe list named it. - The protocol was described as five methods; it exposes ten public members. - Phasing said v0.3.0 / Phase 0, that ProviderOptions were empty scaffolding, and that only STRUCTURED_OUTPUT_JSON_SCHEMA returned True. The repo is 0.9.1, ClaudeOptions has three fields, and coverage runs 12-22 features depending on binding. Replaced the enumeration with a pointer to probe_supports.py so it can't drift the same way. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UBTr6Q6kTGUMQiwwBHcdMj
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.
Groundwork for the
zai-anthropicadapter — writes down the rule that says it deserves its own ID rather than being a config flag onclaude.The rule
An ID identifies a (wire protocol, endpoint, auth mechanism, feature surface) binding — not a vendor, not a framework.
The reserved-ID list was already evidence for this, but the reasoning was never stated. Every reserved pair splits one vendor across two IDs (
anthropic/claude,moonshot/kimi,bedrock/bedrock-agents), andopenrouter/opencode-zen/opencode-gosharingOpenAICompatibleRuntimerules out the framework reading. Neither axis fits; the binding does.Also documents the two mechanisms that break if an ID straddles bindings — extras-gated
list_providers, andSUPPORTED_FEATURESas a single honest capability manifest — plus a concrete test for whether something warrants a new ID, and the naming corollary that producedkimirather thanmoonshot.Adds the credential-scoping invariant from #84 as a general obligation on any adapter with an overridable base URL, so the next one doesn't have to rediscover it.
Stale content refreshed
Checked against the code rather than edited by eye:
kimi-clipinned transitivemcp<1.17); now listed as reserved with the reasonexamples/probe_kimi.pysession,count_tokens,supported_native_toolssince)ProviderOptionsare "empty scaffolding"ClaudeOptionshas three fieldsSTRUCTURED_OUTPUT_JSON_SCHEMAreturnsTrue"claudeimplements 22 of 27 features; others 12–15The last one is replaced with a pointer to
probe_supports.pyrather than a fresh enumeration, so it can't drift the same way again.Docs only — no code touched.
🤖 Generated with Claude Code
https://claude.ai/code/session_01UBTr6Q6kTGUMQiwwBHcdMj