@cleocode/cleo 2026.6.5 → 2026.6.6
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/cli/index.js +11 -23
- package/dist/cli/index.js.map +1 -1
- package/package.json +12 -12
package/dist/cli/index.js
CHANGED
|
@@ -1219,7 +1219,6 @@ var init_tree = __esm({
|
|
|
1219
1219
|
// packages/animations/src/render/index.ts
|
|
1220
1220
|
var init_render = __esm({
|
|
1221
1221
|
"packages/animations/src/render/index.ts"() {
|
|
1222
|
-
"use strict";
|
|
1223
1222
|
init_legend();
|
|
1224
1223
|
init_tree();
|
|
1225
1224
|
}
|
|
@@ -1337,6 +1336,7 @@ var init_spinner_handle = __esm({
|
|
|
1337
1336
|
var init_src = __esm({
|
|
1338
1337
|
"packages/animations/src/index.ts"() {
|
|
1339
1338
|
init_animate_context();
|
|
1339
|
+
init_render();
|
|
1340
1340
|
init_spinner_handle();
|
|
1341
1341
|
}
|
|
1342
1342
|
});
|
|
@@ -55800,13 +55800,7 @@ __export(llm_stream_exports, {
|
|
|
55800
55800
|
streamCommand: () => streamCommand
|
|
55801
55801
|
});
|
|
55802
55802
|
async function buildSession(provider, model) {
|
|
55803
|
-
const [
|
|
55804
|
-
{ resolveCredentials: resolveCredentials2 },
|
|
55805
|
-
{ ConcreteSession },
|
|
55806
|
-
{ AnthropicTransport },
|
|
55807
|
-
{ ChatCompletionsTransport },
|
|
55808
|
-
{ GeminiTransport }
|
|
55809
|
-
] = await Promise.all([
|
|
55803
|
+
const [{ resolveCredentials: resolveCredentials2 }, { ConcreteSession }, { ModelRunner }, { deriveApiWire }] = await Promise.all([
|
|
55810
55804
|
import(
|
|
55811
55805
|
/* webpackIgnore: true */
|
|
55812
55806
|
"@cleocode/core/llm/credentials.js"
|
|
@@ -55817,15 +55811,11 @@ async function buildSession(provider, model) {
|
|
|
55817
55811
|
),
|
|
55818
55812
|
import(
|
|
55819
55813
|
/* webpackIgnore: true */
|
|
55820
|
-
"@cleocode/core/llm/
|
|
55821
|
-
),
|
|
55822
|
-
import(
|
|
55823
|
-
/* webpackIgnore: true */
|
|
55824
|
-
"@cleocode/core/llm/transports/chat-completions.js"
|
|
55814
|
+
"@cleocode/core/llm/model-runner.js"
|
|
55825
55815
|
),
|
|
55826
55816
|
import(
|
|
55827
55817
|
/* webpackIgnore: true */
|
|
55828
|
-
"@cleocode/core/llm/
|
|
55818
|
+
"@cleocode/core/llm/api-mode.js"
|
|
55829
55819
|
)
|
|
55830
55820
|
]);
|
|
55831
55821
|
const cred = resolveCredentials2(provider);
|
|
@@ -55834,14 +55824,7 @@ async function buildSession(provider, model) {
|
|
|
55834
55824
|
`No credential found for provider '${provider}'. Set the appropriate environment variable or run 'cleo llm add ${provider}'.`
|
|
55835
55825
|
);
|
|
55836
55826
|
}
|
|
55837
|
-
|
|
55838
|
-
if (provider === "anthropic") {
|
|
55839
|
-
transport = cred.authType === "oauth" ? new AnthropicTransport({ authToken: cred.apiKey }) : new AnthropicTransport({ apiKey: cred.apiKey });
|
|
55840
|
-
} else if (provider === "gemini") {
|
|
55841
|
-
transport = new GeminiTransport({ apiKey: cred.apiKey });
|
|
55842
|
-
} else {
|
|
55843
|
-
transport = new ChatCompletionsTransport({ provider, apiKey: cred.apiKey });
|
|
55844
|
-
}
|
|
55827
|
+
const wire = deriveApiWire(provider, cred.authType);
|
|
55845
55828
|
const resolvedCredential = {
|
|
55846
55829
|
provider,
|
|
55847
55830
|
label: "default",
|
|
@@ -55850,9 +55833,14 @@ async function buildSession(provider, model) {
|
|
|
55850
55833
|
expiresAt: null,
|
|
55851
55834
|
refreshToken: null,
|
|
55852
55835
|
extraHeaders: {},
|
|
55853
|
-
baseUrl:
|
|
55836
|
+
baseUrl: wire.baseUrl,
|
|
55854
55837
|
awsProfile: null
|
|
55855
55838
|
};
|
|
55839
|
+
const transport = ModelRunner.buildTransportFromCredential(
|
|
55840
|
+
provider,
|
|
55841
|
+
resolvedCredential,
|
|
55842
|
+
wire.apiMode
|
|
55843
|
+
);
|
|
55856
55844
|
return new ConcreteSession({ transport, model, credential: resolvedCredential });
|
|
55857
55845
|
}
|
|
55858
55846
|
async function getComputeCost() {
|