@openclaw/gmi-provider 0.0.0 → 2026.6.9
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/README.md +13 -3
- package/dist/index.js +47 -0
- package/dist/models-CHdeYrhM.js +113 -0
- package/dist/models.js +2 -0
- package/dist/provider-catalog.js +11 -0
- package/npm-shrinkwrap.json +12 -0
- package/openclaw.plugin.json +164 -0
- package/package.json +44 -6
package/README.md
CHANGED
|
@@ -1,4 +1,14 @@
|
|
|
1
|
-
#
|
|
1
|
+
# OpenClaw GMI Cloud Provider
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
Official OpenClaw provider plugin for hosted GMI Cloud models through an
|
|
4
|
+
OpenAI-compatible API.
|
|
5
|
+
|
|
6
|
+
Install from OpenClaw:
|
|
7
|
+
|
|
8
|
+
```bash
|
|
9
|
+
openclaw plugins install @openclaw/gmi-provider
|
|
10
|
+
openclaw gateway restart
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Configure a GMI Cloud API key, then select models with refs such as
|
|
14
|
+
`gmi/google/gemini-3.1-flash-lite`.
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { n as GMI_DEFAULT_MODEL_REF } from "./models-CHdeYrhM.js";
|
|
2
|
+
import { buildGmiProvider } from "./provider-catalog.js";
|
|
3
|
+
import { readConfiguredProviderCatalogEntries } from "openclaw/plugin-sdk/provider-catalog-shared";
|
|
4
|
+
import { defineSingleProviderPluginEntry } from "openclaw/plugin-sdk/provider-entry";
|
|
5
|
+
import { buildProviderReplayFamilyHooks } from "openclaw/plugin-sdk/provider-model-shared";
|
|
6
|
+
import { buildProviderToolCompatFamilyHooks } from "openclaw/plugin-sdk/provider-tools";
|
|
7
|
+
//#region extensions/gmi/index.ts
|
|
8
|
+
const PROVIDER_ID = "gmi";
|
|
9
|
+
var gmi_default = defineSingleProviderPluginEntry({
|
|
10
|
+
id: PROVIDER_ID,
|
|
11
|
+
name: "GMI Cloud Provider",
|
|
12
|
+
description: "GMI Cloud provider plugin",
|
|
13
|
+
provider: {
|
|
14
|
+
label: "GMI Cloud",
|
|
15
|
+
docsPath: "/providers/gmi",
|
|
16
|
+
aliases: ["gmi-cloud", "gmicloud"],
|
|
17
|
+
envVars: ["GMI_API_KEY"],
|
|
18
|
+
auth: [{
|
|
19
|
+
methodId: "api-key",
|
|
20
|
+
label: "GMI Cloud API key",
|
|
21
|
+
hint: "OpenAI-compatible GMI Cloud endpoint",
|
|
22
|
+
optionKey: "gmiApiKey",
|
|
23
|
+
flagName: "--gmi-api-key",
|
|
24
|
+
envVar: "GMI_API_KEY",
|
|
25
|
+
promptMessage: "Enter GMI Cloud API key",
|
|
26
|
+
defaultModel: GMI_DEFAULT_MODEL_REF,
|
|
27
|
+
noteTitle: "GMI Cloud",
|
|
28
|
+
noteMessage: "Manage API keys at https://www.gmicloud.ai/"
|
|
29
|
+
}],
|
|
30
|
+
catalog: {
|
|
31
|
+
buildProvider: buildGmiProvider,
|
|
32
|
+
buildStaticProvider: buildGmiProvider,
|
|
33
|
+
allowExplicitBaseUrl: true
|
|
34
|
+
},
|
|
35
|
+
augmentModelCatalog: ({ config }) => readConfiguredProviderCatalogEntries({
|
|
36
|
+
config,
|
|
37
|
+
providerId: PROVIDER_ID
|
|
38
|
+
}),
|
|
39
|
+
...buildProviderReplayFamilyHooks({
|
|
40
|
+
family: "openai-compatible",
|
|
41
|
+
dropReasoningFromHistory: false
|
|
42
|
+
}),
|
|
43
|
+
...buildProviderToolCompatFamilyHooks("openai")
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
//#endregion
|
|
47
|
+
export { gmi_default as default };
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { buildManifestModelProviderConfig } from "openclaw/plugin-sdk/provider-catalog-shared";
|
|
2
|
+
//#endregion
|
|
3
|
+
//#region extensions/gmi/models.ts
|
|
4
|
+
const GMI_MANIFEST_PROVIDER = buildManifestModelProviderConfig({
|
|
5
|
+
providerId: "gmi",
|
|
6
|
+
catalog: {
|
|
7
|
+
"aliases": {
|
|
8
|
+
"gmi-cloud": { "provider": "gmi" },
|
|
9
|
+
"gmicloud": { "provider": "gmi" }
|
|
10
|
+
},
|
|
11
|
+
"providers": { "gmi": {
|
|
12
|
+
"baseUrl": "https://api.gmi-serving.com/v1",
|
|
13
|
+
"api": "openai-completions",
|
|
14
|
+
"models": [
|
|
15
|
+
{
|
|
16
|
+
"id": "zai-org/GLM-5.1-FP8",
|
|
17
|
+
"name": "GLM-5.1 FP8",
|
|
18
|
+
"reasoning": true,
|
|
19
|
+
"input": ["text"],
|
|
20
|
+
"contextWindow": 202752,
|
|
21
|
+
"maxTokens": 65536,
|
|
22
|
+
"cost": {
|
|
23
|
+
"input": 0,
|
|
24
|
+
"output": 0,
|
|
25
|
+
"cacheRead": 0,
|
|
26
|
+
"cacheWrite": 0
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"id": "deepseek-ai/DeepSeek-V3.2",
|
|
31
|
+
"name": "DeepSeek V3.2",
|
|
32
|
+
"reasoning": false,
|
|
33
|
+
"input": ["text"],
|
|
34
|
+
"contextWindow": 163840,
|
|
35
|
+
"maxTokens": 65536,
|
|
36
|
+
"cost": {
|
|
37
|
+
"input": 0,
|
|
38
|
+
"output": 0,
|
|
39
|
+
"cacheRead": 0,
|
|
40
|
+
"cacheWrite": 0
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"id": "moonshotai/Kimi-K2.5",
|
|
45
|
+
"name": "Kimi K2.5",
|
|
46
|
+
"reasoning": true,
|
|
47
|
+
"input": ["text", "image"],
|
|
48
|
+
"contextWindow": 262144,
|
|
49
|
+
"maxTokens": 65536,
|
|
50
|
+
"cost": {
|
|
51
|
+
"input": 0,
|
|
52
|
+
"output": 0,
|
|
53
|
+
"cacheRead": 0,
|
|
54
|
+
"cacheWrite": 0
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"id": "google/gemini-3.1-flash-lite",
|
|
59
|
+
"name": "Gemini 3.1 Flash Lite",
|
|
60
|
+
"reasoning": false,
|
|
61
|
+
"input": ["text", "image"],
|
|
62
|
+
"contextWindow": 1048576,
|
|
63
|
+
"maxTokens": 65536,
|
|
64
|
+
"cost": {
|
|
65
|
+
"input": 0,
|
|
66
|
+
"output": 0,
|
|
67
|
+
"cacheRead": 0,
|
|
68
|
+
"cacheWrite": 0
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"id": "anthropic/claude-sonnet-4.6",
|
|
73
|
+
"name": "Claude Sonnet 4.6",
|
|
74
|
+
"reasoning": false,
|
|
75
|
+
"input": ["text", "image"],
|
|
76
|
+
"contextWindow": 2e5,
|
|
77
|
+
"maxTokens": 64e3,
|
|
78
|
+
"cost": {
|
|
79
|
+
"input": 0,
|
|
80
|
+
"output": 0,
|
|
81
|
+
"cacheRead": 0,
|
|
82
|
+
"cacheWrite": 0
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"id": "openai/gpt-5.4",
|
|
87
|
+
"name": "GPT-5.4",
|
|
88
|
+
"reasoning": true,
|
|
89
|
+
"input": ["text", "image"],
|
|
90
|
+
"contextWindow": 4e5,
|
|
91
|
+
"maxTokens": 128e3,
|
|
92
|
+
"cost": {
|
|
93
|
+
"input": 0,
|
|
94
|
+
"output": 0,
|
|
95
|
+
"cacheRead": 0,
|
|
96
|
+
"cacheWrite": 0
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
]
|
|
100
|
+
} }
|
|
101
|
+
}.providers.gmi
|
|
102
|
+
});
|
|
103
|
+
const GMI_BASE_URL = GMI_MANIFEST_PROVIDER.baseUrl;
|
|
104
|
+
const GMI_MODEL_CATALOG = GMI_MANIFEST_PROVIDER.models;
|
|
105
|
+
const GMI_DEFAULT_MODEL_REF = "gmi/google/gemini-3.1-flash-lite";
|
|
106
|
+
function buildGmiModelDefinition(model) {
|
|
107
|
+
return {
|
|
108
|
+
...model,
|
|
109
|
+
api: "openai-completions"
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
//#endregion
|
|
113
|
+
export { buildGmiModelDefinition as i, GMI_DEFAULT_MODEL_REF as n, GMI_MODEL_CATALOG as r, GMI_BASE_URL as t };
|
package/dist/models.js
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { i as buildGmiModelDefinition, r as GMI_MODEL_CATALOG, t as GMI_BASE_URL } from "./models-CHdeYrhM.js";
|
|
2
|
+
//#region extensions/gmi/provider-catalog.ts
|
|
3
|
+
function buildGmiProvider() {
|
|
4
|
+
return {
|
|
5
|
+
baseUrl: GMI_BASE_URL,
|
|
6
|
+
api: "openai-completions",
|
|
7
|
+
models: GMI_MODEL_CATALOG.map(buildGmiModelDefinition)
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
export { buildGmiProvider };
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "gmi",
|
|
3
|
+
"name": "GMI Cloud",
|
|
4
|
+
"description": "OpenClaw GMI Cloud provider plugin.",
|
|
5
|
+
"activation": {
|
|
6
|
+
"onStartup": false
|
|
7
|
+
},
|
|
8
|
+
"enabledByDefault": true,
|
|
9
|
+
"providers": ["gmi", "gmi-cloud", "gmicloud"],
|
|
10
|
+
"providerAuthAliases": {
|
|
11
|
+
"gmi-cloud": "gmi",
|
|
12
|
+
"gmicloud": "gmi"
|
|
13
|
+
},
|
|
14
|
+
"providerEndpoints": [
|
|
15
|
+
{
|
|
16
|
+
"endpointClass": "gmi-native",
|
|
17
|
+
"hosts": ["api.gmi-serving.com"]
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"providerRequest": {
|
|
21
|
+
"providers": {
|
|
22
|
+
"gmi": {
|
|
23
|
+
"family": "gmi"
|
|
24
|
+
},
|
|
25
|
+
"gmi-cloud": {
|
|
26
|
+
"family": "gmi"
|
|
27
|
+
},
|
|
28
|
+
"gmicloud": {
|
|
29
|
+
"family": "gmi"
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"setup": {
|
|
34
|
+
"providers": [
|
|
35
|
+
{
|
|
36
|
+
"id": "gmi",
|
|
37
|
+
"envVars": ["GMI_API_KEY"]
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
"providerAuthChoices": [
|
|
42
|
+
{
|
|
43
|
+
"provider": "gmi",
|
|
44
|
+
"method": "api-key",
|
|
45
|
+
"choiceId": "gmi-api-key",
|
|
46
|
+
"choiceLabel": "GMI Cloud API key",
|
|
47
|
+
"choiceHint": "OpenAI-compatible GMI Cloud endpoint",
|
|
48
|
+
"groupId": "gmi",
|
|
49
|
+
"groupLabel": "GMI Cloud",
|
|
50
|
+
"groupHint": "OpenAI-compatible GMI Cloud endpoint",
|
|
51
|
+
"optionKey": "gmiApiKey",
|
|
52
|
+
"cliFlag": "--gmi-api-key",
|
|
53
|
+
"cliOption": "--gmi-api-key <key>",
|
|
54
|
+
"cliDescription": "GMI Cloud API key"
|
|
55
|
+
}
|
|
56
|
+
],
|
|
57
|
+
"configSchema": {
|
|
58
|
+
"type": "object",
|
|
59
|
+
"additionalProperties": false,
|
|
60
|
+
"properties": {}
|
|
61
|
+
},
|
|
62
|
+
"modelCatalog": {
|
|
63
|
+
"aliases": {
|
|
64
|
+
"gmi-cloud": {
|
|
65
|
+
"provider": "gmi"
|
|
66
|
+
},
|
|
67
|
+
"gmicloud": {
|
|
68
|
+
"provider": "gmi"
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
"providers": {
|
|
72
|
+
"gmi": {
|
|
73
|
+
"baseUrl": "https://api.gmi-serving.com/v1",
|
|
74
|
+
"api": "openai-completions",
|
|
75
|
+
"models": [
|
|
76
|
+
{
|
|
77
|
+
"id": "zai-org/GLM-5.1-FP8",
|
|
78
|
+
"name": "GLM-5.1 FP8",
|
|
79
|
+
"reasoning": true,
|
|
80
|
+
"input": ["text"],
|
|
81
|
+
"contextWindow": 202752,
|
|
82
|
+
"maxTokens": 65536,
|
|
83
|
+
"cost": {
|
|
84
|
+
"input": 0,
|
|
85
|
+
"output": 0,
|
|
86
|
+
"cacheRead": 0,
|
|
87
|
+
"cacheWrite": 0
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"id": "deepseek-ai/DeepSeek-V3.2",
|
|
92
|
+
"name": "DeepSeek V3.2",
|
|
93
|
+
"reasoning": false,
|
|
94
|
+
"input": ["text"],
|
|
95
|
+
"contextWindow": 163840,
|
|
96
|
+
"maxTokens": 65536,
|
|
97
|
+
"cost": {
|
|
98
|
+
"input": 0,
|
|
99
|
+
"output": 0,
|
|
100
|
+
"cacheRead": 0,
|
|
101
|
+
"cacheWrite": 0
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
"id": "moonshotai/Kimi-K2.5",
|
|
106
|
+
"name": "Kimi K2.5",
|
|
107
|
+
"reasoning": true,
|
|
108
|
+
"input": ["text", "image"],
|
|
109
|
+
"contextWindow": 262144,
|
|
110
|
+
"maxTokens": 65536,
|
|
111
|
+
"cost": {
|
|
112
|
+
"input": 0,
|
|
113
|
+
"output": 0,
|
|
114
|
+
"cacheRead": 0,
|
|
115
|
+
"cacheWrite": 0
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"id": "google/gemini-3.1-flash-lite",
|
|
120
|
+
"name": "Gemini 3.1 Flash Lite",
|
|
121
|
+
"reasoning": false,
|
|
122
|
+
"input": ["text", "image"],
|
|
123
|
+
"contextWindow": 1048576,
|
|
124
|
+
"maxTokens": 65536,
|
|
125
|
+
"cost": {
|
|
126
|
+
"input": 0,
|
|
127
|
+
"output": 0,
|
|
128
|
+
"cacheRead": 0,
|
|
129
|
+
"cacheWrite": 0
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
"id": "anthropic/claude-sonnet-4.6",
|
|
134
|
+
"name": "Claude Sonnet 4.6",
|
|
135
|
+
"reasoning": false,
|
|
136
|
+
"input": ["text", "image"],
|
|
137
|
+
"contextWindow": 200000,
|
|
138
|
+
"maxTokens": 64000,
|
|
139
|
+
"cost": {
|
|
140
|
+
"input": 0,
|
|
141
|
+
"output": 0,
|
|
142
|
+
"cacheRead": 0,
|
|
143
|
+
"cacheWrite": 0
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"id": "openai/gpt-5.4",
|
|
148
|
+
"name": "GPT-5.4",
|
|
149
|
+
"reasoning": true,
|
|
150
|
+
"input": ["text", "image"],
|
|
151
|
+
"contextWindow": 400000,
|
|
152
|
+
"maxTokens": 128000,
|
|
153
|
+
"cost": {
|
|
154
|
+
"input": 0,
|
|
155
|
+
"output": 0,
|
|
156
|
+
"cacheRead": 0,
|
|
157
|
+
"cacheWrite": 0
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
]
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
}
|
package/package.json
CHANGED
|
@@ -1,12 +1,50 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/gmi-provider",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "
|
|
5
|
-
"
|
|
3
|
+
"version": "2026.6.9",
|
|
4
|
+
"description": "OpenClaw GMI Cloud provider plugin.",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "https://github.com/openclaw/openclaw"
|
|
8
|
+
},
|
|
9
|
+
"type": "module",
|
|
10
|
+
"openclaw": {
|
|
11
|
+
"extensions": [
|
|
12
|
+
"./index.ts"
|
|
13
|
+
],
|
|
14
|
+
"install": {
|
|
15
|
+
"clawhubSpec": "clawhub:@openclaw/gmi-provider",
|
|
16
|
+
"npmSpec": "@openclaw/gmi-provider",
|
|
17
|
+
"defaultChoice": "npm",
|
|
18
|
+
"minHostVersion": ">=2026.6.8"
|
|
19
|
+
},
|
|
20
|
+
"compat": {
|
|
21
|
+
"pluginApi": ">=2026.6.9"
|
|
22
|
+
},
|
|
23
|
+
"build": {
|
|
24
|
+
"openclawVersion": "2026.6.9",
|
|
25
|
+
"bundledDist": false
|
|
26
|
+
},
|
|
27
|
+
"release": {
|
|
28
|
+
"publishToClawHub": true,
|
|
29
|
+
"publishToNpm": true
|
|
30
|
+
},
|
|
31
|
+
"runtimeExtensions": [
|
|
32
|
+
"./dist/index.js"
|
|
33
|
+
]
|
|
34
|
+
},
|
|
6
35
|
"files": [
|
|
36
|
+
"dist/**",
|
|
37
|
+
"openclaw.plugin.json",
|
|
38
|
+
"npm-shrinkwrap.json",
|
|
7
39
|
"README.md"
|
|
8
40
|
],
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
}
|
|
41
|
+
"peerDependencies": {
|
|
42
|
+
"openclaw": ">=2026.6.9"
|
|
43
|
+
},
|
|
44
|
+
"peerDependenciesMeta": {
|
|
45
|
+
"openclaw": {
|
|
46
|
+
"optional": true
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"bundledDependencies": []
|
|
12
50
|
}
|