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/{chunk-3F46BMPM.js → chunk-7UU5L64L.js} +10 -3
- package/dist/chunk-7UU5L64L.js.map +1 -0
- package/dist/index.cjs +9 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/node.cjs +9 -2
- package/dist/node.cjs.map +1 -1
- package/dist/node.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-3F46BMPM.js.map +0 -1
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.
|
|
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) {
|