@bitfab/sdk 0.28.4 → 0.28.5

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.
@@ -13,7 +13,7 @@ import {
13
13
  } from "./chunk-SAGZ674W.js";
14
14
 
15
15
  // src/version.generated.ts
16
- var __version__ = "0.28.4";
16
+ var __version__ = "0.28.5";
17
17
 
18
18
  // src/constants.ts
19
19
  var DEFAULT_SERVICE_URL = "https://bitfab.ai";
@@ -1097,17 +1097,24 @@ function generateClientDefinitions(providers) {
1097
1097
  for (const providerDef of providers) {
1098
1098
  for (const model of providerDef.models) {
1099
1099
  const clientName = getClientName(providerDef.provider, model.model);
1100
+ const temperatureOption = supportsTemperatureZero(
1101
+ providerDef.provider,
1102
+ model.model
1103
+ ) ? "\n temperature 0" : "";
1100
1104
  definitions.push(`client<llm> ${clientName} {
1101
1105
  provider ${providerDef.provider}
1102
1106
  options {
1103
1107
  model "${model.model}"
1104
- api_key env.${providerDef.apiKeyEnv}
1108
+ api_key env.${providerDef.apiKeyEnv}${temperatureOption}
1105
1109
  }
1106
1110
  }`);
1107
1111
  }
1108
1112
  }
1109
1113
  return definitions.join("\n\n");
1110
1114
  }
1115
+ function supportsTemperatureZero(provider, model) {
1116
+ return provider === "openai" && (model.startsWith("gpt-4.1") || model.startsWith("gpt-4o"));
1117
+ }
1111
1118
  function withDefaultClients(bamlSource, providers) {
1112
1119
  const hasDefaultClient = bamlSource.includes("client<llm> OpenAI_");
1113
1120
  if (hasDefaultClient) {
@@ -3860,4 +3867,4 @@ export {
3860
3867
  BitfabFunction,
3861
3868
  finalizers
3862
3869
  };
3863
- //# sourceMappingURL=chunk-3F46BMPM.js.map
3870
+ //# sourceMappingURL=chunk-7UU5L64L.js.map