bitfab 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.
package/dist/index.cjs CHANGED
@@ -668,7 +668,7 @@ __export(index_exports, {
668
668
  module.exports = __toCommonJS(index_exports);
669
669
 
670
670
  // src/version.generated.ts
671
- var __version__ = "0.28.4";
671
+ var __version__ = "0.28.5";
672
672
 
673
673
  // src/constants.ts
674
674
  var DEFAULT_SERVICE_URL = "https://bitfab.ai";
@@ -1763,17 +1763,24 @@ function generateClientDefinitions(providers) {
1763
1763
  for (const providerDef of providers) {
1764
1764
  for (const model of providerDef.models) {
1765
1765
  const clientName = getClientName(providerDef.provider, model.model);
1766
+ const temperatureOption = supportsTemperatureZero(
1767
+ providerDef.provider,
1768
+ model.model
1769
+ ) ? "\n temperature 0" : "";
1766
1770
  definitions.push(`client<llm> ${clientName} {
1767
1771
  provider ${providerDef.provider}
1768
1772
  options {
1769
1773
  model "${model.model}"
1770
- api_key env.${providerDef.apiKeyEnv}
1774
+ api_key env.${providerDef.apiKeyEnv}${temperatureOption}
1771
1775
  }
1772
1776
  }`);
1773
1777
  }
1774
1778
  }
1775
1779
  return definitions.join("\n\n");
1776
1780
  }
1781
+ function supportsTemperatureZero(provider, model) {
1782
+ return provider === "openai" && (model.startsWith("gpt-4.1") || model.startsWith("gpt-4o"));
1783
+ }
1777
1784
  function withDefaultClients(bamlSource, providers) {
1778
1785
  const hasDefaultClient = bamlSource.includes("client<llm> OpenAI_");
1779
1786
  if (hasDefaultClient) {