Skip to content

Commit 7eedc05

Browse files
committed
docs: Modify the preferred installation method
1 parent 4ec0f68 commit 7eedc05

3 files changed

Lines changed: 64 additions & 38 deletions

File tree

INSTALL.md

Lines changed: 34 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,38 @@
11
# 阿里云百炼CLI 安装说明(供 AI Agent 阅读)
22

3-
本文档面向 **AI Agent**:按下列步骤为用户安装并校验 **阿里云百炼CLI**(命令 `bl` / `bailian`)。**优先**使用二进制一键安装(无需 Node);若环境已有 Node / 需要 Command Pack,再用 npm。不要臆造版本号或路径;以用户环境为准。
3+
本文档面向 **AI Agent**:按下列步骤为用户安装并校验 **阿里云百炼CLI**(命令 `bl` / `bailian`)。**优先**在已有 Node.js(**≥ 18.17.0**)的环境用 npm 安装;若没有可用 Node / npm,再走二进制一键安装。不要臆造版本号或路径;以用户环境为准。
44

5-
## 1. 推荐:二进制安装(无需 Node)
5+
## 1. 推荐:npm 安装(要求 **≥ 18.17.0**
6+
7+
1. `node -v` 确认版本 ≥ 18.17.0。
8+
2. `npm -v` 确认可用(**仅允许 npm** 全局安装,不要用 pnpm/yarn)。
9+
3. 执行:
10+
11+
```bash
12+
npm install -g bailian-cli
13+
```
14+
15+
4. 校验:`bl --version`
16+
17+
安装 skills(CLI 内置,无需 Git / npx skills):
18+
19+
```bash
20+
bl skill init
21+
```
22+
23+
**Supported:** `bl skill init` 一次装齐 registry 中全部 `bailian-*`(含共享协议 `bailian-protocol`)。
24+
25+
**Advanced / 按需子集:**
26+
27+
```bash
28+
bl skill add --name bailian-protocol,bailian-gen
29+
```
30+
31+
安装成功后,用中文简要说明已安装的 skills 及用户可做什么。
32+
33+
## 2. 备选:二进制安装(无需 Node)
34+
35+
当环境没有 Node / npm,或 Node 版本过低无法走 npm 时,使用二进制安装脚本。脚本安装 CLI 成功后会自动执行 `bl skill init`
636

737
```bash
838
curl -fsSL https://bailian.aliyun.com/cli/install.sh | bash
@@ -37,35 +67,9 @@ bl --version
3767
which bl # Windows: where.exe bl
3868
```
3969

40-
> CDN / GitHub Release 未就绪或下载失败时,回退到下方 npm 安装。
41-
42-
## 2. 备选:npm 安装(要求 **≥ 18.17.0**
43-
44-
1. `node -v` 确认版本。
45-
2. `npm -v` 确认可用(**仅允许 npm** 全局安装,不要用 pnpm/yarn)。
46-
3. 执行:
47-
48-
```bash
49-
npm install -g bailian-cli
50-
```
51-
52-
4. 校验:`bl --version`
53-
54-
安装 skills(CLI 内置,无需 Git / npx skills):
55-
56-
```bash
57-
bl skill init
58-
```
59-
60-
**Supported:** `bl skill init` 一次装齐 registry 中全部 `bailian-*`(含共享协议 `bailian-protocol`)。
70+
若自动 skill 安装失败,再手动执行:`bl skill init`
6171

62-
**Advanced / 按需子集:**
63-
64-
```bash
65-
bl skill add --name bailian-protocol,bailian-gen
66-
```
67-
68-
安装成功后,用中文简要说明已安装的 skills 及用户可做什么。
72+
> CDN / GitHub Release 未就绪或下载失败时,若本机已有合格 Node,回退到上方 npm 安装。
6973
7074
---
7175

skills/bailian-protocol/assets/setup.md

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,33 @@ inspect config keys. Day-to-day command routing lives in the business skills
1111

1212
## Install
1313

14+
**prefer npm** (Node.js **≥ 18.17.0**); use the binary installer only when Node/npm is unavailable.
15+
16+
### 1. Recommended: npm
17+
1418
```bash
15-
# Recommended binary install (no Node), or: npm install -g bailian-cli
16-
curl -fsSL https://bailian.aliyun.com/cli/install.sh | bash
17-
# Install the full bailian-* skill family (includes bailian-protocol)
19+
# node -v ≥ 18.17.0; global install via npm only (do not use pnpm/yarn)
20+
npm install -g bailian-cli
1821
bl skill init
22+
```
23+
24+
### 2. Fallback: binary (no Node)
25+
26+
When there is no usable Node/npm, or Node is too old for the npm path:
27+
28+
```bash
29+
curl -fsSL https://bailian.aliyun.com/cli/install.sh | bash
30+
# The script runs bl skill init after installing the CLI; if that fails, run it manually
31+
```
32+
33+
Windows PowerShell: `irm https://bailian.aliyun.com/cli/install.ps1 | iex`
1934

20-
# Advanced / subset (comma-separated names; include bailian-protocol when needed)
35+
### Skills
36+
37+
- **Supported:** `bl skill init` (installs every `bailian-*`, including `bailian-protocol`)
38+
- **Advanced / subset** (include protocol when needed):
39+
40+
```bash
2141
# bl skill add --name bailian-protocol,bailian-gen
2242
# bl skill add --name bailian-protocol,bailian-finetune
2343
# bl skill add --name bailian-protocol,bailian-managed-agent

skills/bailian-protocol/assets/versioning.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,15 @@
3535
3636
## Missing `bl`
3737
38-
If `bl --version` fails, install the CLI and skills:
38+
If `bl --version` fails, install the CLI and skills (same order as [setup.md → Install](setup.md#install) / root `INSTALL.md`: **npm first**):
3939
4040
```bash
41-
# Recommended — no Node required
42-
curl -fsSL https://bailian.aliyun.com/cli/install.sh | bash
43-
# Or: npm install -g bailian-cli
41+
# Recommended — Node.js ≥ 18.17.0; npm only (do not use pnpm/yarn)
42+
npm install -g bailian-cli
4443
bl skill init
44+
45+
# Fallback — no usable Node/npm:
46+
# curl -fsSL https://bailian.aliyun.com/cli/install.sh | bash
4547
```
4648
4749
Do not install a single business skill alone — use `bl skill init` so `bailian-protocol` is present.

0 commit comments

Comments
 (0)