@openclaw/kilocode-provider 2026.7.2-beta.3 → 2026.7.2-beta.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.js +61 -10
- package/dist/provider-models.js +2 -1
- package/package.json +4 -5
- package/npm-shrinkwrap.json +0 -12
package/dist/index.js
CHANGED
|
@@ -5,26 +5,77 @@ import { wrapKilocodeProviderStream } from "./stream.js";
|
|
|
5
5
|
import { readConfiguredProviderCatalogEntries } from "openclaw/plugin-sdk/provider-catalog-shared";
|
|
6
6
|
import { defineSingleProviderPluginEntry } from "openclaw/plugin-sdk/provider-entry";
|
|
7
7
|
import { buildProviderReplayFamilyHooks } from "openclaw/plugin-sdk/provider-model-shared";
|
|
8
|
+
//#region extensions/kilocode/openclaw.plugin.json
|
|
9
|
+
var openclaw_plugin_default = {
|
|
10
|
+
id: "kilocode",
|
|
11
|
+
activation: { "onStartup": false },
|
|
12
|
+
enabledByDefault: true,
|
|
13
|
+
providers: ["kilocode"],
|
|
14
|
+
modelPricing: { "providers": { "kilocode": {
|
|
15
|
+
"openRouter": { "passthroughProviderModel": true },
|
|
16
|
+
"liteLLM": { "passthroughProviderModel": true }
|
|
17
|
+
} } },
|
|
18
|
+
setup: { "providers": [{
|
|
19
|
+
"id": "kilocode",
|
|
20
|
+
"envVars": ["KILOCODE_API_KEY"]
|
|
21
|
+
}] },
|
|
22
|
+
providerAuthChoices: [{
|
|
23
|
+
"provider": "kilocode",
|
|
24
|
+
"method": "api-key",
|
|
25
|
+
"choiceId": "kilocode-api-key",
|
|
26
|
+
"appGuidedSecret": true,
|
|
27
|
+
"choiceLabel": "Kilo Gateway API key",
|
|
28
|
+
"choiceHint": "API key (OpenRouter-compatible)",
|
|
29
|
+
"groupId": "kilocode",
|
|
30
|
+
"groupLabel": "Kilo Gateway",
|
|
31
|
+
"groupHint": "API key (OpenRouter-compatible)",
|
|
32
|
+
"optionKey": "kilocodeApiKey",
|
|
33
|
+
"cliFlag": "--kilocode-api-key",
|
|
34
|
+
"cliOption": "--kilocode-api-key <key>",
|
|
35
|
+
"cliDescription": "Kilo Gateway API key"
|
|
36
|
+
}],
|
|
37
|
+
configSchema: {
|
|
38
|
+
"type": "object",
|
|
39
|
+
"additionalProperties": false,
|
|
40
|
+
"properties": {}
|
|
41
|
+
},
|
|
42
|
+
modelCatalog: {
|
|
43
|
+
"providers": { "kilocode": {
|
|
44
|
+
"baseUrl": "https://api.kilo.ai/api/gateway/",
|
|
45
|
+
"api": "openai-completions",
|
|
46
|
+
"models": [{
|
|
47
|
+
"id": "kilo-auto/balanced",
|
|
48
|
+
"name": "Auto Balanced",
|
|
49
|
+
"reasoning": true,
|
|
50
|
+
"input": ["text", "image"],
|
|
51
|
+
"cost": {
|
|
52
|
+
"input": .325,
|
|
53
|
+
"output": 1.95,
|
|
54
|
+
"cacheRead": .0325,
|
|
55
|
+
"cacheWrite": .40625
|
|
56
|
+
},
|
|
57
|
+
"contextWindow": 1e6,
|
|
58
|
+
"maxTokens": 65536
|
|
59
|
+
}]
|
|
60
|
+
} },
|
|
61
|
+
"discovery": { "kilocode": "refreshable" }
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
//#endregion
|
|
8
65
|
//#region extensions/kilocode/index.ts
|
|
9
66
|
const PROVIDER_ID = "kilocode";
|
|
10
67
|
var kilocode_default = defineSingleProviderPluginEntry({
|
|
11
68
|
id: PROVIDER_ID,
|
|
12
69
|
name: "Kilo Gateway Provider",
|
|
13
70
|
description: "Bundled Kilo Gateway provider plugin",
|
|
71
|
+
manifest: openclaw_plugin_default,
|
|
14
72
|
provider: {
|
|
15
73
|
label: "Kilo Gateway",
|
|
16
74
|
docsPath: "/providers/kilocode",
|
|
17
|
-
|
|
18
|
-
methodId: "api-key",
|
|
19
|
-
label: "Kilo Gateway API key",
|
|
20
|
-
hint: "API key (OpenRouter-compatible)",
|
|
21
|
-
optionKey: "kilocodeApiKey",
|
|
22
|
-
flagName: "--kilocode-api-key",
|
|
23
|
-
envVar: "KILOCODE_API_KEY",
|
|
24
|
-
promptMessage: "Enter Kilo Gateway API key",
|
|
75
|
+
manifestAuth: {
|
|
25
76
|
defaultModel: KILOCODE_DEFAULT_MODEL_REF,
|
|
26
|
-
applyConfig:
|
|
27
|
-
}
|
|
77
|
+
applyConfig: applyKilocodeConfig
|
|
78
|
+
},
|
|
28
79
|
catalog: {
|
|
29
80
|
buildProvider: buildKilocodeProviderWithDiscovery,
|
|
30
81
|
buildStaticProvider: buildKilocodeProvider
|
package/dist/provider-models.js
CHANGED
|
@@ -90,6 +90,7 @@ async function discoverKilocodeModels() {
|
|
|
90
90
|
});
|
|
91
91
|
try {
|
|
92
92
|
if (!response.ok) {
|
|
93
|
+
await response.body?.cancel().catch(() => void 0);
|
|
93
94
|
log.warn(`Failed to discover models: HTTP ${response.status}, using static catalog`);
|
|
94
95
|
return buildStaticCatalog();
|
|
95
96
|
}
|
|
@@ -104,7 +105,7 @@ async function discoverKilocodeModels() {
|
|
|
104
105
|
const id = readGatewayModelId(rawEntry);
|
|
105
106
|
try {
|
|
106
107
|
const entry = asGatewayModelEntry(rawEntry);
|
|
107
|
-
if (!id || discoveredIds.has(id)) continue;
|
|
108
|
+
if (!id || discoveredIds.has(id) || entry.architecture?.output_modalities?.includes("image")) continue;
|
|
108
109
|
models.push(toModelDefinition(entry));
|
|
109
110
|
discoveredIds.add(id);
|
|
110
111
|
} catch (e) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/kilocode-provider",
|
|
3
|
-
"version": "2026.7.2-beta.
|
|
3
|
+
"version": "2026.7.2-beta.5",
|
|
4
4
|
"description": "OpenClaw Kilo Gateway provider plugin.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
"minHostVersion": ">=2026.6.8"
|
|
19
19
|
},
|
|
20
20
|
"compat": {
|
|
21
|
-
"pluginApi": ">=2026.7.2-beta.
|
|
21
|
+
"pluginApi": ">=2026.7.2-beta.5"
|
|
22
22
|
},
|
|
23
23
|
"build": {
|
|
24
|
-
"openclawVersion": "2026.7.2-beta.
|
|
24
|
+
"openclawVersion": "2026.7.2-beta.5",
|
|
25
25
|
"bundledDist": false
|
|
26
26
|
},
|
|
27
27
|
"release": {
|
|
@@ -35,11 +35,10 @@
|
|
|
35
35
|
"files": [
|
|
36
36
|
"dist/**",
|
|
37
37
|
"openclaw.plugin.json",
|
|
38
|
-
"npm-shrinkwrap.json",
|
|
39
38
|
"README.md"
|
|
40
39
|
],
|
|
41
40
|
"peerDependencies": {
|
|
42
|
-
"openclaw": ">=2026.7.2-beta.
|
|
41
|
+
"openclaw": ">=2026.7.2-beta.5"
|
|
43
42
|
},
|
|
44
43
|
"peerDependenciesMeta": {
|
|
45
44
|
"openclaw": {
|
package/npm-shrinkwrap.json
DELETED