Skip to content

feat(provider): add Holver - #7434

Open
zenttzy wants to merge 2 commits into
anomalyco:devfrom
zenttzy:feat/provider-holver
Open

zenttzy wants to merge 2 commits into
anomalyco:devfrom
zenttzy:feat/provider-holver

Conversation

@zenttzy

@zenttzy zenttzy commented Sep 18, 2026

Copy link
Copy Markdown

Holver (https://holver.id) is an OpenAI-compatible AI model gateway. This PR registers it as a native provider so OpenCode users get it via /connect.

Endpoint & auth

  • Base URL: https://api.holver.id/v1 (verified: public docs app BASE_URL, nginx api.holver.id, live GET /v1/models returns 401 without key with OpenAI-style error)
  • Auth: Authorization: Bearer $HOLVER_API_KEY
  • Adapter: @ai-sdk/openai-compatible (/v1/chat/completions, /v1/responses, /v1/messages; streaming, tools/tool_choice, response_format, reasoning_effort passthrough)
  • Docs: https://holver.id/docs · Catalog: https://holver.id/models

Model mapping (19 models, all base_model override-only)
Anthropic (fable-5, fable-5.1, haiku-4.5, opus-4-8, opus-5), DeepSeek (4.1-flash, v4-pro), Google (3.1-pro via preview lab entry — no GA lab file exists yet, noted in header — 3.7/3.8-flash), Zhipu (glm-5.3-flash), OpenAI (5.6-luna/sol/terra, 6.0-astra, oss-120b), MiniMax (m3), Meta (muse-spark-1.3-contributor), Alibaba (qwen-3.8-max). Reasoning controls mirror each lab's first-party API.

Pricing
No fabricated pricing: Holver bills via IDR credit packages, not per-model USD rates, so cost is intentionally omitted (same precedent as agentrouter).

Testing

  • bun validate → exit 0
  • Built catalog contains holver with 19 models + logo
  • OpenCode with local catalog: /connect flow shows Holver, /models lists 19 holver/* IDs
  • Live inference holver/deepseek-4.1-flash via OpenCode returns exact reply; SSE streaming ([DONE]) and tool_calls (function + JSON args) verified against production

@github-actions

Copy link
Copy Markdown
Contributor

Action items

  • [medium] [violation] providers/holver/models/deepseek-4.1-flash.toml:133 - Check: Every toggle must have a leading top-of-file wire-path comment. Why: deepseek-4.1-flash, deepseek-v4-pro, minimax-m3, and qwen-3.8-max set { type = "toggle" } but only generic catalog/cost notes—no exact Holver request field (e.g. thinking.type, enable_thinking). Clients cannot know how to turn reasoning off/on on this host. Action: Add a leading # Toggle: … (and effort/budget wire notes where used) naming the real Holver request path for each of those four files.
  • [medium] [possible mistake] providers/holver/models/claude-haiku-4.5.toml:96 - Check: budget_tokens only when this host exposes a real reasoning-budget field; do not treat Anthropic Messages and OpenAI chat-completions as the same surface. Why: Holver is registered as @ai-sdk/openai-compatible and the PR documents reasoning_effort passthrough, while Haiku’s lab/Anthropic control is thinking.budget_tokens. Same-surface peers often use toggle/effort, not budget, unless an Anthropic Messages path is verified. Action: Confirm Holver accepts a reasoning budget on the path clients will use; if not, replace with the controls Holver actually forwards (e.g. effort/toggle) or document the Messages wire path that makes budget valid.

…ible surface

Holver forwards only the OpenAI-style top-level `reasoning_effort` field to
the routed upstream (chat-completions whitelist). `thinking`,
`enable_thinking`, and `thinking_budget` are not forwarded, and the
/v1/messages translation drops Anthropic `thinking` before forwarding, so
Anthropic-native `budget_tokens` is not reachable either.

- Drop toggle/budget_tokens from deepseek-4.1-flash, deepseek-v4-pro,
  minimax-m3, qwen-3.8-max, and claude-haiku-4.5.
- minimax-m3: no caller-facing effort tiers on this surface -> [].
- Add a leading top-of-file wire-path comment to every reasoning model
  naming the real Holver request field.

bun validate: PASS
@zenttzy

zenttzy commented Sep 18, 2026

Copy link
Copy Markdown
Author

Both points addressed in 6f1bae8. Verified against the Holver deployment source, not assumed:

Wire path (reasoning_effort only). Holver's OpenAI-compatible adapter sanitizes the request body against an allowlist (apps/api/src/gateway/adapters/ninerouter.js). reasoning_effort is in it; thinking, enable_thinking, and thinking_budget are not — they are dropped before anything reaches the routed upstream. So the lab toggle/budget controls flagged on deepseek-4.1-flash, deepseek-v4-pro, minimax-m3, and qwen-3.8-max were not reachable through this API. Those files are now effort-only, and minimax-m3 is [] (no caller-facing tiers on this surface). Every reasoning model now carries a leading top-of-file comment naming reasoning_effort as the actual Holver request field.

Haiku budget_tokens. You're right that this was inferred from the Anthropic surface rather than this host. Holver's /v1/messages translator builds the OpenAI body from an explicit field list (anthropicTranslate.jsbuildOpenAIBody) that never includes thinking; on the chat path the allowlist above excludes it too. So budget_tokens was never forwarded. Replaced with the effort ladder, matching the same-surface OpenAI-compatible relay peer providers/daoxe/models/claude-haiku-4-5-20251001.toml.

Also confirmed empirically: thinking/enable_thinking sent to POST /v1/chat/completions are accepted with HTTP 200 and silently ignored (no error, no reasoning change), consistent with the strip-before-forward behavior.

bun validate passes (19 models).

@github-actions

Copy link
Copy Markdown
Contributor

No actionable findings.

@github-actions github-actions Bot added the reviewer: ready Automated review found no actionable items label Sep 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

reviewer: ready Automated review found no actionable items

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant