Repository navigation
fix!: forward the same model.parameters keys as the Python SDK - #118
Merged
Merged
Conversation
Contributor
Author
|
bugbot run |
Contributor
Author
|
bugbot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 0e963d3. Configure here.
apucacao
force-pushed
the
fix/forwarding-parity
branch
from
October 21, 2026 22:06
0e963d3 to
5f9835d
Compare
…meters Stop forwarding container, inference_geo and metadata, so the handler forwards the same model.parameters keys as the Python SDK. Drop a thinking, tool_choice, cache_control or output_config value of the wrong shape instead of sending it.
…meters Stop forwarding context_management, include, instructions, metadata, moderation, prompt_cache_retention, safety_identifier, store, truncation and user, so invoke and stream forward the same keys as the Python SDK. reasoning keeps only effort and summary, and a malformed reasoning or tool_choice is dropped instead of sent. max_tool_calls is on the shared list but not on ResponseCreateParamsBase in the installed openai package, so it is not forwarded.
Stop forwarding context_management, prompt_cache_retention, store and truncation into ModelSettings, in the handler and the native graph, so they match the Python SDK. A tool_choice that is not a string is now dropped instead of passed on.
Narrow the ChatOpenAI, ChatAnthropic and ChatBedrockConverse allowlists, used by both LangChain packages and the LangGraph native graph's default model, to the lists the Python SDK forwards. This stops forwarding LangChain wiring and logging settings (tags, metadata, verbose, streaming, stream_usage, disable_streaming, output_version), settings that switch ChatOpenAI to the Responses API (reasoning, use_responses_api), data location and retention settings (inference_geo, prompt_cache_retention, zdr_enabled), and audio, modalities, user, context_management, guardrail_config and supports_tool_choice_values. ChatAnthropic now also takes stop as stopSequences and max_tokens_to_sample as maxTokens, since it has neither field under those names. A malformed thinking, output_config, logit_bias or performance_config is dropped instead of passed on.
…K list The list itself is unchanged. The new test proves invoke and stream add exactly those query options and nothing else.
The Python ChatOpenAI has no such field, so the cross-SDK list cuts it for both SDKs. OpenAI Messages still forwards it to the Responses API.
store is data retention, which is never forwarded. The OpenAI Agents handler already dropped it, but the LiteLLM Agents list was copied from the old OpenAI Agents list and still carried it, and the Chat Completions model really sends it to the proxy. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Agents SDK's ModelSettings types tool_choice as a string (auto,
required, none, or a tool name). An object such as {"type": "auto"},
which other handlers' configs use, is now dropped instead of passed on,
the same way the OpenAI Agents handler already handles it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Chat Completions model the proxy is reached through sends reasoning.effort as reasoning_effort and drops reasoning.summary without a word, so forwarding summary did nothing. The Python LiteLLM Agents model drops it too, and logs a warning on every call that sets it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The AI SDK reads any tool_choice that is not a string as a forced call
to value.toolName. An object in another provider's shape, such as
{"type": "auto"} or {"type": "function", "name": "f"}, therefore became a
forced call to a tool named undefined. Both Vercel handlers now drop a
tool_choice that is not a string, as the Agents handlers do.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The AI SDK's reasoning option is a string, but configs written for the
OpenAI handlers carry reasoning as {"effort": "low"}, and that object was
passed to the AI SDK as written. Both Vercel handlers now read effort out
of a reasoning object and drop any other value that is not a string. A
reasoning_effort still fills in when reasoning gives no effort.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Commit 5f9835d cut prompt_cache_key only because the Python ChatOpenAI has no such field. The spec now keeps a key that one language's library cannot take and marks it not supported there, so this SDK forwards it again in both LangChain packages, and it leaves the never-forwarded test bag. Checked against @langchain/openai 1.4.7 in node_modules: promptCacheKey is a constructor field (dist/chat_models/base.js reads fields.promptCacheKey), the Chat Completions request sends it as prompt_cache_key (dist/chat_models/completions.js), and it is not one of the keys that _useResponsesApi switches on (dist/chat_models/index.js), so the handler still reads a Chat Completions reply. vitest in langchain-agents (159 passed) and langchain-messages (123 passed), tsc --noEmit and biome check clean in both. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…thout a known type
These were kept when they were objects with any string type, so
{ type: 'enabled' } with no budget_tokens, { type: 'tool' } with no name, or
an unknown type reached the request and the Anthropic API rejected it.
Each one is now rebuilt from the variants the Anthropic SDK declares
(ThinkingConfigParam, ToolChoice, CacheControlEphemeral): it is dropped
unless its type is one of those variants and it has that variant's required
sub-keys, and any other sub-key is removed. The shape table is checked
against the SDK types at compile time. The Python SDK makes the same check.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
thinking was kept whenever it had a string type. The Claude Agent SDK ignores a type it does not know, and runs an enabled thinking without budgetTokens as adaptive, so a config could ask for a fixed budget and silently get adaptive thinking. The Python SDK raises on the same config. thinking is now dropped unless its type is adaptive, enabled or disabled (the SDK's ThinkingConfig, checked at compile time), and an enabled thinking is dropped without a numeric budget. display is kept only for a type that takes it and only with a value the SDK knows. Both SDKs now treat each of these configs the same way. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ChatAnthropic sends thinking to the Messages API as written, and the check
accepted any object with a string type, so { type: 'enabled' } with no
budget_tokens, or an unknown type, reached the API and was rejected there.
thinking is now rebuilt from the variants the Messages API takes (enabled
with budget_tokens, adaptive, disabled), keeping only their sub-keys, the
same shapes the Claude Messages handler uses in both SDKs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The comment said reasoning control waits until both SDKs can set it without switching APIs. The Python SDK now forwards the Chat Completions reasoning_effort, and the spec marks it not supported in TypeScript because the TypeScript ChatOpenAI takes it only per call. The comment now says that, and that a reasoning with a summary switches ChatOpenAI to the Responses API. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
apucacao
force-pushed
the
fix/forwarding-parity
branch
from
October 22, 2026 20:49
bd2fc38 to
7dce38d
Compare
apucacao
marked this pull request as ready for review
October 22, 2026 20:58
jeffdupont
requested changes
Oct 22, 2026
jeffdupont
left a comment
Contributor
There was a problem hiding this comment.
The allowlists look right. Every list matches its §1.12 table, minus the keys marked not supported in TypeScript, and credentials, hosts and headers can't reach any provider call. A few things before merging:
output_config.formatgets through (claude-messages/src/handler.ts:461-467, and the LangChain ChatAnthropicmodel-parameters.ts).output_configis checked only for being an object, so Anthropic's structured-outputformatreaches the API. If a config setsoutputFormatto schema A andoutput_config.formatto schema B,invokeasks for A and the API enforces B. Onstream, which normally returns free text, it returns JSON shaped like B. I've asked in mono#42 foroutput_configto keep onlyeffort. Once that lands, rebuild it as{effort}and flip the tests that assert it passes through. py#107 has the same issue.- The §1.12 required tests are missing for LiteLLM Messages, LiteLLM Agents (handler and native graph), and TypeSafe. They have no list-equals-table probe, no full never-forward bag and no invoke/stream agreement test. TypeSafe has no test that it forwards nothing. The
never-forwarded.tsand "cross-SDK allowlist" pattern from openai-agents would carry over. - Several never-forward bags leave out keys the spec names, for example
user,metadata,inference_geoandcontainerin claude-agents, openai-agents and vercel. The allowlists are fine today, so this is only coverage. One shared key list would keep the bags from drifting. - The PR description is out of date.
prompt_cache_keyis still forwarded for ChatOpenAI,max_tool_callsis marked not supported in TypeScript rather than cut for both SDKs, Claude Agents and Vercel did change, and the LiteLLM Agents changes aren't mentioned.
output_config.format is Anthropic structured output, which the handlers own
through outputFormat. Forwarding it let a config ask for one schema in
outputFormat while the API enforced another, and made stream return JSON.
Claude Messages and LangChain ChatAnthropic now rebuild output_config as
{ effort } and drop it when there is no string effort.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Structured output belongs to the config's outputFormat, which the handler applies itself. A schema in model.parameters would only fight it, so it is no longer forwarded to query(), from the handler or the native graph. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The per-package bags had drifted and left out keys the spec names, such as user, metadata, inference_geo and container. The key list from every never-forward category now lives in client/src/__tests__, and each package's never-forwarded.ts adds only the keys its own table leaves out. Tests where the handler sets system or instructions itself mark them as handler-owned; the deep value check still proves the config's value never lands there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
LiteLLM Messages and LiteLLM Agents (handler and native graph) had no test that the forwarded keys equal the spec table, no full never-forward bag, and no check that invoke and stream forward the same settings. They now have all three, using the shared never-forward key list. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The spec's TypeSafe table is empty: a Jev call takes the judge state, the questions and the model name. The new test puts the full never-forward bag plus sampling keys in model.parameters and asserts the client and the Jev request carry none of them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
@jeffdupont all four addressed:
|
jeffdupont
approved these changes
Oct 23, 2026
Merged
jeffdupont
pushed a commit
that referenced
this pull request
Oct 26, 2026
🤖 I have created a release *beep* *boop* --- <details><summary>@launchdarkly/ai-claude-agents: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-claude-agents-0.4.0...@launchdarkly/ai-claude-agents-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **claude-agents:** accept trusted cwd and settingSources options, and load no host settings by default ([#135](#135)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) * **claude-agents:** accept trusted cwd and settingSources options, and load no host settings by default ([#135](#135)) ([6acd53d](6acd53d)) ### Bug Fixes * **AIC-3571:** visit every child before its parent in reverseTraverse ([#147](#147)) ([a17a2ce](a17a2ce)) * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **claude-agents:** fail the run when the CLI reports an API error as success ([#138](#138)) ([4637958](4637958)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) * give native graph spans their LaunchDarkly identity ([#101](#101)) ([4d97cfa](4d97cfa)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-claude-messages: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-claude-messages-0.4.0...@launchdarkly/ai-claude-messages-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-langchain-agents: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-langchain-agents-0.4.0...@launchdarkly/ai-langchain-agents-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) * give native graph spans their LaunchDarkly identity ([#101](#101)) ([4d97cfa](4d97cfa)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-langchain-messages: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-langchain-messages-0.4.0...@launchdarkly/ai-langchain-messages-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-litellm-agents: 0.2.0</summary> ## [0.2.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-litellm-agents-0.1.0...@launchdarkly/ai-litellm-agents-0.2.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) ### Features * add LiteLLM messages and agents integrations ([#75](#75)) ([127f156](127f156)) ### Bug Fixes * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-litellm-messages: 0.2.0</summary> ## [0.2.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-litellm-messages-0.1.0...@launchdarkly/ai-litellm-messages-0.2.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) ### Features * add LiteLLM messages and agents integrations ([#75](#75)) ([127f156](127f156)) ### Bug Fixes * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-node: 0.4.0</summary> ## [0.4.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-node-0.3.0...@launchdarkly/ai-node-0.4.0) (2026-10-26) ### ⚠ BREAKING CHANGES * **skills:** promote Agent Skills to core ([#159](#159)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **skills:** promote Agent Skills to core ([#159](#159)) ([c7135cd](c7135cd)) ### Bug Fixes * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-openai-agents: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-openai-agents-0.4.0...@launchdarkly/ai-openai-agents-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * **AIC-3571:** visit every child before its parent in reverseTraverse ([#147](#147)) ([a17a2ce](a17a2ce)) * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **AIC-3586:** propagate tool handler errors instead of sending them to the model ([#139](#139)) ([1f31e85](1f31e85)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) * give native graph spans their LaunchDarkly identity ([#101](#101)) ([4d97cfa](4d97cfa)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-openai-messages: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-openai-messages-0.4.0...@launchdarkly/ai-openai-messages-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-otel: 0.3.0</summary> ## [0.3.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-otel-0.2.0...@launchdarkly/ai-otel-0.3.0) (2026-10-26) ### ⚠ BREAKING CHANGES * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Bug Fixes * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) </details> <details><summary>@launchdarkly/ai-server: 0.5.0</summary> ## [0.5.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-server-0.4.0...@launchdarkly/ai-server-0.5.0) (2026-10-26) ### ⚠ BREAKING CHANGES * **skills:** promote Agent Skills to core ([#159](#159)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) * **client:** the client no longer loads .env. Add import 'dotenv/config' to your entrypoint (and install dotenv) if you relied on it. ### Experimental * **evaluations:** hash eventId and contentHash as RFC 8785 canonical JSON, the same in every SDK ([c971649](c971649)) * **evaluations:** Set JSON as standard for output to pass to judge ([#152](#152)) ([330da44](330da44)) ### Features * **AIC-3534:** add a TypeSafe Jev judge handler ([#122](#122)) ([0c1d6b7](0c1d6b7)) * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) * **skills:** promote Agent Skills to core ([#159](#159)) ([c7135cd](c7135cd)) ### Bug Fixes * **AIC-3541:** accept a node-server-sdk client in initClient() without a cast ([#128](#128)) ([5819449](5819449)) * **AIC-3570:** re-resolve graph flags on every invoke and stream ([#145](#145)) ([ce4f72e](ce4f72e)) * **AIC-3571:** visit every child before its parent in reverseTraverse ([#147](#147)) ([a17a2ce](a17a2ce)) * **AIC-3576:** record deferred judge scores under the evaluated config ([#148](#148)) ([d9fbee6](d9fbee6)) * **AIC-3577:** send object tool results to the model as JSON ([#146](#146)) ([be41d87](be41d87)) * **AIC-3596:** point the missing-OTel warning and docs at @launchdarkly/ai-otel ([#144](#144)) ([9b5f32e](9b5f32e)) * **client:** show a judge an output of 0, false, {} or [] ([c971649](c971649)) * **client:** stop loading dotenv from library code ([#69](#69)) ([fea34f3](fea34f3)) * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) * give native graph spans their LaunchDarkly identity ([#101](#101)) ([4d97cfa](4d97cfa)) * **judges:** a judge config's outputFormat must not reach the provider ([#56](#56)) ([8c6f4d2](8c6f4d2)) * **skills:** Correct the HTTP 403 advice now that server-side FDv2 is available to every account ([#141](#141)) ([5b7b732](5b7b732)) * **skills:** default FDv2SkillStore endpoints from LD_BASE_URI and LD_STREAM_URI ([#134](#134)) ([05f77d9](05f77d9)) </details> <details><summary>@launchdarkly/ai-typesafe: 0.2.0</summary> ## [0.2.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-typesafe-0.1.0...@launchdarkly/ai-typesafe-0.2.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) ### Features * **AIC-3534:** add a TypeSafe Jev judge handler ([#122](#122)) ([0c1d6b7](0c1d6b7)) * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-vercel-agents: 0.3.0</summary> ## [0.3.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-vercel-agents-0.2.0...@launchdarkly/ai-vercel-agents-0.3.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) * give native graph spans their LaunchDarkly identity ([#101](#101)) ([4d97cfa](4d97cfa)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> <details><summary>@launchdarkly/ai-vercel-messages: 0.3.0</summary> ## [0.3.0](https://github.com/launchdarkly/js-ai-sdk/compare/@launchdarkly/ai-vercel-messages-0.2.0...@launchdarkly/ai-vercel-messages-0.3.0) (2026-10-26) ### ⚠ BREAKING CHANGES * forward the same model.parameters keys as the Python SDK ([#118](#118)) ### Features * **AIC-3623:** evals from code ([#143](#143)) ([dc74b48](dc74b48)) ### Bug Fixes * forward the same model.parameters keys as the Python SDK ([#118](#118)) ([f7883ce](f7883ce)) ### Dependencies * The following workspace dependencies were updated * dependencies * @launchdarkly/ai-server bumped from ^0.4.0 to ^0.5.0 </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Overview** > This is a **Release Please** cut that bumps published versions across the monorepo and records what ships in each package—there is no application source in the diff beyond `LD_AI_PACKAGE_VERSION` strings and dependency pins. > > **@launchdarkly/ai-server** goes to **0.5.0**; provider packages move to **0.5.0** (or **0.4.0** / **0.3.0** / **0.2.0** where applicable), `.release-please-manifest.json` is updated, and every adapter’s `package.json` now depends on **`@launchdarkly/ai-server` ^0.5.0**. New **CHANGELOG** sections document the release notes already merged on `main`. > > Reviewers should treat this as publishing **breaking** behavior called out in those changelogs: libraries no longer auto-load **`.env`** (apps need `import 'dotenv/config'` if they relied on it), **`model.parameters`** forwarding is aligned with the Python SDK, **Agent Skills** are promoted from experimental to core, plus features/fixes such as **evals from code**, TypeSafe judge handler, and **claude-agents** defaulting to no host settings unless `cwd` / `settingSources` are passed. > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 8c6546c. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY --> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.
The JS and Python SDKs have to forward the same
model.parameterskeys before 1.0. Jeff's review of launchdarkly/python-ai-sdk#107 found that the lists from #73 differ from Python's. The shared lists are now in the cross-SDK spec (launchdarkly/ai-sdks-monorepo#42, TESTING.md §1.12), and Python is moving to them too. This PR makes each JS handler forward exactly those lists, minus the keys the spec marks as not supported in TypeScript.What changed:
container,inference_geoandmetadata.output_configkeeps onlyeffort(a top-leveleffortstill moves into it, and an explicitoutput_config.effortwins).output_config.formatis dropped, because structured output belongs to the config'soutputFormat: forwarding it let a config ask for one schema inoutputFormatwhile the API enforced another, and madestreamreturn JSON.context_management,include,instructions,metadata,moderation,prompt_cache_retention,safety_identifier,store,truncationanduser, on both invoke and stream.max_tool_callsis not forwarded: the spec marks it not supported in TypeScript, because theopenaipackage'sresponses.createhas no such parameter.context_management,prompt_cache_retention,storeandtruncation.tool_choiceis forwarded only as a string.store.reasoningkeeps onlyeffort, because the Chat Completions model sends it asreasoning_effortand has no field forsummary.tool_choiceis forwarded only as a string.output_format, for the same reason asoutput_config.format: the handler applies the config'soutputFormatitself.thinkingis kept only with a type the Claude Agent SDK knows, anenabledthinking needs a numeric budget, anddisplayis kept only assummarizedoromitted.reasoningobject is read as itseffort, and any other non-stringreasoningis dropped.tool_choiceis forwarded only as a string, since the AI SDK reads any other value as a call to a named tool.audio,disable_streaming,metadata,modalities,output_version,prompt_cache_retention,reasoning,stream_usage,streaming,tags,use_responses_api,user,verboseandzdr_enabled.prompt_cache_keyis still forwarded: the spec marks it not supported in Python only, whereChatOpenAIhas no such field.context_management,disable_streaming,inference_geo,metadata,output_version,stream_usage,streaming,tagsandverbose. It now takesstopasstopSequencesandmax_tokens_to_sampleasmaxTokens, becauseChatAnthropichas neither field under those names.outputConfigkeeps onlyeffort, as in Claude Messages.disable_streaming,guardrail_config,metadata,output_version,stream_usage,streaming,supports_tool_choice_values,tagsandverbose.model.parameterskey.Following the spec, nested values with the wrong shape are dropped instead of sent. Examples are a
thinkingwithout atype, areasoningthat is not an object, atool_choiceof the wrong type, or anoutput_configwithout a stringeffort. OpenAI Messagesreasoningkeeps onlyeffortandsummary, as OpenAI Agents already did.Testing:
model.parameterskey at all.packages/client/src/__tests__/never-forwarded-keys.ts, which covers every never-forward category in the spec, includinguser,metadata,inference_geoandcontainer. Each package's__tests__/never-forwarded.tsadds only the keys its own table leaves out, so the bags can't drift apart.output_config.formaton invoke and stream, andoutput_formatin Claude Agents.tsc --noEmit, andbiome check ., pass locally.Note
Overview
Aligns every JS provider handler with TESTING.md §1.12 so
model.parametersforwards the same generation-related keys as the Python SDK, and drops everything else (credentials, retention, metadata, wiring, etc.).Allowlists are tightened across packages: OpenAI Messages/Agents stop forwarding retention and attribution fields (
store,user,context_management, …); Claude Messages keepsoutput_configto{ effort }only and stripsformat; Claude Agents no longer forwardsoutput_format(structured output stays on configoutputFormat); LangChain constructors lose base-model wiring keys and narrow ChatAnthropicoutputConfig; LiteLLM/Vercel agents dropstoreand non-stringtool_choice; Vercel maps objectreasoningto a stringeffort. Malformed nested values (thinking,tool_choice,reasoning, typed Anthropic objects) are dropped instead of passed through.Tests: Shared
createNeverForwarded()inpackages/clientreplaces duplicated never-forward lists; each handler/native graph gets §1.12 canonical-key tests and invoke/stream parity checks where applicable.Reviewed by Cursor Bugbot for commit 0dd95ab. Bugbot is set up for automated code reviews on this repo. Configure here.