@browser-ai/web-llm 2.1.1 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1118,7 +1118,8 @@ var WebLLMLanguageModel = class {
1118
1118
  responseFormat,
1119
1119
  seed,
1120
1120
  tools,
1121
- toolChoice
1121
+ toolChoice,
1122
+ providerOptions
1122
1123
  }) {
1123
1124
  const warnings = [];
1124
1125
  const functionTools = (tools ?? []).filter(isFunctionTool).map((tool) => ({
@@ -1185,6 +1186,12 @@ var WebLLMLanguageModel = class {
1185
1186
  top_p: topP,
1186
1187
  seed
1187
1188
  };
1189
+ if (providerOptions?.extra_body) {
1190
+ requestOptions.extra_body = {
1191
+ enable_thinking: providerOptions.extra_body.enable_thinking,
1192
+ enable_latency_breakdown: providerOptions.extra_body.enable_latency_breakdown
1193
+ };
1194
+ }
1188
1195
  if (responseFormat?.type === "json") {
1189
1196
  requestOptions.response_format = {
1190
1197
  type: "json_object",