feat: add Claude Code subscription provider (default for the kit)

KeiSeiKit installs into Claude Code, but the wizard offered no Claude under
`subscription` (only OpenAI Codex) — a Claude user picking subscription got no
Claude. Add provider `claude-code` (transport=subscription, endpoint=
local:claude-cli, auth_env=_, no API key) + 3 claude-code models (sonnet
default, opus, haiku), mirroring the codex subscription convention. Listed
before codex so it's the default pick under subscription.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
KeiSei84 2026-05-22 12:41:16 +08:00
parent c5590658ee
commit b90499311e
2 changed files with 62 additions and 0 deletions

View file

@ -58,6 +58,55 @@ verified_at = "2026-04-30"
deprecated_at = "" deprecated_at = ""
notes = "Architecture, novel reasoning, math derivation. Tokenizer overhead 1.35x vs Sonnet." notes = "Architecture, novel reasoning, math derivation. Tokenizer overhead 1.35x vs Sonnet."
# ─── Claude Code (subscription) ──────────────────────────────────────────
# Same Claude models, reached via the `claude` CLI under the user's plan.
# Subscription billing → per-token cost 0 (mirrors the codex convention).
[[model]]
provider_ref = "claude-code"
id = "claude-sonnet-4-6"
slug = "sonnet"
display_name = "Claude Sonnet 4.6 (Claude Code)"
context_window = 1000000
cost_input_per_mtok_micro = 0 # subscription, not per-token
cost_output_per_mtok_micro = 0
cache_write_5m_per_mtok_micro = 0
cache_write_1h_per_mtok_micro = 0
cache_read_per_mtok_micro = 0
verified_at = "2026-05-22"
deprecated_at = ""
notes = "Default model. Balanced; RULE 0.20 default for code-implementer-* / researcher-*."
[[model]]
provider_ref = "claude-code"
id = "claude-opus-4-7"
slug = "opus"
display_name = "Claude Opus 4.7 (Claude Code)"
context_window = 1000000
cost_input_per_mtok_micro = 0 # subscription, not per-token
cost_output_per_mtok_micro = 0
cache_write_5m_per_mtok_micro = 0
cache_write_1h_per_mtok_micro = 0
cache_read_per_mtok_micro = 0
verified_at = "2026-05-22"
deprecated_at = ""
notes = "Architecture, novel reasoning, math derivation."
[[model]]
provider_ref = "claude-code"
id = "claude-haiku-4-5-20251001"
slug = "haiku"
display_name = "Claude Haiku 4.5 (Claude Code)"
context_window = 200000
cost_input_per_mtok_micro = 0 # subscription, not per-token
cost_output_per_mtok_micro = 0
cache_write_5m_per_mtok_micro = 0
cache_write_1h_per_mtok_micro = 0
cache_read_per_mtok_micro = 0
verified_at = "2026-05-22"
deprecated_at = ""
notes = "Cheapest Claude. Single-edit, formatting, lookup."
# ─── OpenAI ──────────────────────────────────────────────────────────── # ─── OpenAI ────────────────────────────────────────────────────────────
[[model]] [[model]]

View file

@ -73,6 +73,19 @@ rate_limit_rpm = 0 # per-deployment quota; see Azure portal
billing_currency = "USD-azure" billing_currency = "USD-azure"
notes = "OpenAI через Azure — для enterprise с Azure-биллингом. Нужны resource+deployment." notes = "OpenAI через Azure — для enterprise с Azure-биллингом. Нужны resource+deployment."
[[provider]]
id = "claude-code"
display_name = "Claude Code (subscription — your claude CLI, no API key)"
transport = "subscription"
endpoint = "local:claude-cli" # invoked via the `claude` CLI (Claude Code), not HTTP
auth_scheme = "oauth-subscription"
auth_env = "_" # no env — Claude Code handles auth (claude.ai Max / Pro)
retry_max = 1
retry_backoff_ms = 0
rate_limit_rpm = 60 # Claude subscription quota
billing_currency = "USD-subscription"
notes = "Default for the Claude-Code-native kit. Uses ambient `claude` CLI OAuth; no API key needed."
[[provider]] [[provider]]
id = "codex" id = "codex"
display_name = "OpenAI Codex (ChatGPT OAuth)" display_name = "OpenAI Codex (ChatGPT OAuth)"