jackwener/maka-agent

fix(runtime): use camelCase OpenAI-compatible provider option keys

Geschlossen

#1.430 geöffnet am 24.07.2026

 (3 Kommentare) (0 Reaktionen) (1 zugewiesene Person)TypeScript (0 Forks)github user discovery
good first issuehelp wanted

Repository-Metriken

Stars
 (1 Stern)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Problem

After the AI SDK v7 upgrade in #1198, requests to Z.AI Coding Plan emit repeated deprecation warnings:

AI SDK Warning (zai-coding-plan.chat / glm-5.2): Deprecated: "providerOptions key 'zai-coding-plan'". Use 'zaiCodingPlan' instead.

The request still works because @ai-sdk/openai-compatible@3.0.12 currently accepts both forms, but it emits one warning for every model invocation. Agent/tool loops therefore produce the warning repeatedly.

Cause

buildProviderOptions currently emits the raw provider name as the options namespace:

{ 'zai-coding-plan': { reasoningEffort: 'high' } }

@ai-sdk/openai-compatible now expects camelCase provider option keys:

{ zaiCodingPlan: { reasoningEffort: 'high' } }

The current regression test explicitly pins the deprecated dashed namespace:

  • packages/runtime/src/model-factory.ts
  • packages/runtime/src/__tests__/model-factory-thinking.test.ts

This may also affect other OpenAI-compatible providers whose configured names contain hyphens.

Expected behavior

OpenAI-compatible provider options use the SDK's current camelCase namespace without changing the provider ID, model routing, or wire-level request fields.

Acceptance criteria

  • zai-coding-plan provider options are emitted under zaiCodingPlan.
  • reasoningEffort still reaches the request as reasoning_effort.
  • Dashed OpenAI-compatible provider names are handled consistently rather than special-casing only Z.AI.
  • Regression coverage exercises the current AI SDK parsing path and confirms that no deprecation warning is produced.

Contributor Guide