clawd-models 1.0.0 → 1.0.2
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 +15 -3
- package/bin/clawd-models.js +3 -2
- package/package.json +9 -2
package/README.md
CHANGED
|
@@ -2,16 +2,28 @@
|
|
|
2
2
|
|
|
3
3
|
CLI tool to manage OpenClaw model configurations.
|
|
4
4
|
|
|
5
|
+
## Prerequisite
|
|
6
|
+
Install and Setup `openclaw` firstly, refer to https://github.com/openclaw/openclaw
|
|
7
|
+
```
|
|
8
|
+
# setup openclaw
|
|
9
|
+
openclaw setup
|
|
10
|
+
|
|
11
|
+
# or configure it interactively
|
|
12
|
+
|
|
13
|
+
openclaw configure
|
|
14
|
+
```
|
|
15
|
+
|
|
5
16
|
## Installation
|
|
6
17
|
|
|
7
18
|
```bash
|
|
8
|
-
npm
|
|
19
|
+
npm i -g clawd-models
|
|
9
20
|
```
|
|
10
21
|
|
|
11
22
|
## Usage
|
|
12
23
|
|
|
13
24
|
```bash
|
|
14
|
-
|
|
25
|
+
clawd-models <command>
|
|
26
|
+
# clawd-models help
|
|
15
27
|
```
|
|
16
28
|
|
|
17
29
|
## Commands
|
|
@@ -28,7 +40,7 @@ node bin/clawd-models.js <command>
|
|
|
28
40
|
### Provider Management
|
|
29
41
|
| Command | Description |
|
|
30
42
|
|---------|-------------|
|
|
31
|
-
| `providers:add -n <name> -u <url
|
|
43
|
+
| `providers:add -n <name> -u <url> [-k <api-key>]` | Add a new model provider |
|
|
32
44
|
| `providers:remove -n <name>` | Remove a model provider |
|
|
33
45
|
| `providers:list` | List all configured providers |
|
|
34
46
|
|
package/bin/clawd-models.js
CHANGED
|
@@ -12,7 +12,8 @@ const CURRENT_VERSION = '2026.2.1';
|
|
|
12
12
|
program
|
|
13
13
|
.name('clawd-models')
|
|
14
14
|
.description('CLI tool to manage OpenClaw model configurations')
|
|
15
|
-
.version('1.0.
|
|
15
|
+
.version('1.0.2')
|
|
16
|
+
.showHelpAfterError();
|
|
16
17
|
|
|
17
18
|
// ============ Core Commands ============
|
|
18
19
|
|
|
@@ -111,9 +112,9 @@ program
|
|
|
111
112
|
.description('Add a new model provider')
|
|
112
113
|
.requiredOption('-n, --name <name>', 'Provider name (e.g., qiniu, minimax)')
|
|
113
114
|
.requiredOption('-u, --base-url <url>', 'Base API URL')
|
|
115
|
+
.option('-k, --api-key <key>', 'API Key for the provider endpoint')
|
|
114
116
|
.option('--api <api-type>', 'API type (e.g., openai-completions, anthropic-messages)', 'openai-completions')
|
|
115
117
|
.option('--auth <auth-type>', 'Auth method (e.g., api-key, bearer)', 'api-key')
|
|
116
|
-
.option('--api-key <key>', 'API key for the provider')
|
|
117
118
|
.action((options) => {
|
|
118
119
|
const config = loadConfig();
|
|
119
120
|
config.models.providers = config.models.providers || {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clawd-models",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "CLI tool to manage OpenClaw model configurations",
|
|
5
5
|
"main": "bin/clawd-models.js",
|
|
6
6
|
"bin": {
|
|
@@ -9,7 +9,14 @@
|
|
|
9
9
|
"scripts": {
|
|
10
10
|
"test": "echo \"Error: no test specified\" && exit 1"
|
|
11
11
|
},
|
|
12
|
-
"keywords": [
|
|
12
|
+
"keywords": [
|
|
13
|
+
"openclaw",
|
|
14
|
+
"models",
|
|
15
|
+
"third-party",
|
|
16
|
+
"providers",
|
|
17
|
+
"configuration",
|
|
18
|
+
"cli"
|
|
19
|
+
],
|
|
13
20
|
"engines": {
|
|
14
21
|
"node": ">=22"
|
|
15
22
|
},
|