docs(skills): remove companions claim; make --all -g the supported install path

This commit is contained in:
clh02467605
2026-08-05 10:27:39 +08:00
parent 17b13de162
commit 8cdd54cf7a
18 changed files with 87 additions and 108 deletions
+19 -19
View File
@@ -35,7 +35,7 @@ packages/core/src/auth/ # apiKey / console credential 解析与落盘
packages/core/src/client/ # HTTP client / endpoints / console gateway
```
Skill / 命令手册随 `skills/bailian-*/` 经 `npx skills add modelstudioai/cli` 安装。共享协议在 `skills/bailian-protocol/`;业务 skill(`bailian-cli` / `bailian-gen` / `bailian-finetune` / `bailian-managed-agent`)依赖它作为 companion。`tools/generate-reference.ts` 从 **`packages/cli/src/commands.ts`** 按一级命令归属表分流写入各 `skills/<skill>/reference/`(纳入 git);`tools/sync-skill-metadata.ts` 从 `packages/cli/package.json` 同步各 `skills/*/SKILL.md` 的 `metadata.version`。两者由根脚本 `pnpm run sync:skill-assets` 和 `.vite-hooks/pre-commit` 执行。hub `bailian-cli` 的路由表不复述领域命令明细;SKILL 文案 / companion / hand-off 约定见 [docs/agents/skill-change.md](docs/agents/skill-change.md)。
Skill / 命令手册随 `skills/bailian-*/` 经 `npx skills add modelstudioai/cli --all -g` 安装(整包装齐,含共享协议 `bailian-protocol`)。业务 skill(`bailian-cli` / `bailian-gen` / `bailian-finetune` / `bailian-managed-agent`)执行前读 `skills/bailian-protocol/`;不要依赖 frontmatter `companions`(安装器不强制)。`tools/generate-reference.ts` 从 **`packages/cli/src/commands.ts`** 按一级命令归属表分流写入各 `skills/<skill>/reference/`(纳入 git);`tools/sync-skill-metadata.ts` 从 `packages/cli/package.json` 同步各 `skills/*/SKILL.md` 的 `metadata.version`。两者由根脚本 `pnpm run sync:skill-assets` 和 `.vite-hooks/pre-commit` 执行。hub `bailian-cli` 的路由表不复述领域命令明细;SKILL 文案 / 安装约定 / hand-off 见 [docs/agents/skill-change.md](docs/agents/skill-change.md)。
约定:
@@ -56,24 +56,24 @@ Skill / 命令手册随 `skills/bailian-*/` 经 `npx skills add modelstudioai/cl
按当前任务从下表挑一条进入对应文档:
| 场景 | 何时进入 | 详见 |
| ----------------- | ------------------------------------------------ | ---------------------------------------------------------------------------- |
| 命令增删改 | 增加 / 删除 / 重命名 `bl xxx` 或入口命令路径 | [docs/agents/command-add-remove.md](docs/agents/command-add-remove.md) |
| E2E 测试维护 | 新增/改命令或 e2e 用例、补 help/缺参/dry-run | [docs/agents/cli-e2e-tests.md](docs/agents/cli-e2e-tests.md) |
| 批量压测 | 改/跑多能力并发压测、`test:stress`、fixtures | [docs/agents/stress-batch-tests.md](docs/agents/stress-batch-tests.md) |
| 选项变更 | 给已有命令加 `--flag` 或改默认值 | [docs/agents/command-flag-change.md](docs/agents/command-flag-change.md) |
| 模型上下架 | 增加新模型 / 改默认模型 / 废弃旧模型 | [docs/agents/model-add-remove.md](docs/agents/model-add-remove.md) |
| Skill 文案 / 路由 | 改 SKILL 路由、companion、hand-off、hub/领域边界 | [docs/agents/skill-change.md](docs/agents/skill-change.md) |
| 错误文案变更 | 改 `BailianError` 的 message 或 hint | [docs/agents/error-hint-change.md](docs/agents/error-hint-change.md) |
| URL / 渠道变更 | 控制台域名 / 文档站 / 追踪参数 | [docs/agents/url-change.md](docs/agents/url-change.md) |
| 鉴权扩展 | 加 OAuth / SSO / 换 token 来源 | [docs/agents/auth-change.md](docs/agents/auth-change.md) |
| 配置项扩展 | 新 env var 或 `~/.bailian/config.json` 字段 | [docs/agents/config-add.md](docs/agents/config-add.md) |
| Profile / 激活 | 改命名 Profile、预设或 `active_config` | [docs/agents/config-profile-change.md](docs/agents/config-profile-change.md) |
| 安装文档 | 改安装、鉴权、验证流程或线上 install 页面 | [docs/agents/install-doc-change.md](docs/agents/install-doc-change.md) |
| 发布 | channel / stable 发布到 npm(CI 驱动) | [docs/agents/publish.md](docs/agents/publish.md) |
| Change Log | 发版说明 / 历史版本说明 | [docs/agents/changelog-write.md](docs/agents/changelog-write.md) |
| 工具链调整 | lint 规则 / 构建配置 / 依赖升级 | [docs/agents/lint-toolchain.md](docs/agents/lint-toolchain.md) |
| Command Pack | 扩展包 / 白名单 / plugin 管理命令 | [docs/agents/command-pack.md](docs/agents/command-pack.md) |
| 场景 | 何时进入 | 详见 |
| ----------------- | ----------------------------------------------- | ---------------------------------------------------------------------------- |
| 命令增删改 | 增加 / 删除 / 重命名 `bl xxx` 或入口命令路径 | [docs/agents/command-add-remove.md](docs/agents/command-add-remove.md) |
| E2E 测试维护 | 新增/改命令或 e2e 用例、补 help/缺参/dry-run | [docs/agents/cli-e2e-tests.md](docs/agents/cli-e2e-tests.md) |
| 批量压测 | 改/跑多能力并发压测、`test:stress`、fixtures | [docs/agents/stress-batch-tests.md](docs/agents/stress-batch-tests.md) |
| 选项变更 | 给已有命令加 `--flag` 或改默认值 | [docs/agents/command-flag-change.md](docs/agents/command-flag-change.md) |
| 模型上下架 | 增加新模型 / 改默认模型 / 废弃旧模型 | [docs/agents/model-add-remove.md](docs/agents/model-add-remove.md) |
| Skill 文案 / 路由 | 改 SKILL 路由、安装约定、hand-off、hub/领域边界 | [docs/agents/skill-change.md](docs/agents/skill-change.md) |
| 错误文案变更 | 改 `BailianError` 的 message 或 hint | [docs/agents/error-hint-change.md](docs/agents/error-hint-change.md) |
| URL / 渠道变更 | 控制台域名 / 文档站 / 追踪参数 | [docs/agents/url-change.md](docs/agents/url-change.md) |
| 鉴权扩展 | 加 OAuth / SSO / 换 token 来源 | [docs/agents/auth-change.md](docs/agents/auth-change.md) |
| 配置项扩展 | 新 env var 或 `~/.bailian/config.json` 字段 | [docs/agents/config-add.md](docs/agents/config-add.md) |
| Profile / 激活 | 改命名 Profile、预设或 `active_config` | [docs/agents/config-profile-change.md](docs/agents/config-profile-change.md) |
| 安装文档 | 改安装、鉴权、验证流程或线上 install 页面 | [docs/agents/install-doc-change.md](docs/agents/install-doc-change.md) |
| 发布 | channel / stable 发布到 npm(CI 驱动) | [docs/agents/publish.md](docs/agents/publish.md) |
| Change Log | 发版说明 / 历史版本说明 | [docs/agents/changelog-write.md](docs/agents/changelog-write.md) |
| 工具链调整 | lint 规则 / 构建配置 / 依赖升级 | [docs/agents/lint-toolchain.md](docs/agents/lint-toolchain.md) |
| Command Pack | 扩展包 / 白名单 / plugin 管理命令 | [docs/agents/command-pack.md](docs/agents/command-pack.md) |
如果当前任务无法对应任何场景,先按经验完成,然后**回来评估这是不是一类新场景** —— 是就新增 `docs/agents/<scenario>.md`,把清单沉淀下来。
+4 -1
View File
@@ -53,9 +53,12 @@ CLI 校验通过后,在本机终端执行:
npx skills add modelstudioai/cli --all -g
```
推荐 `--all`(含 companion `bailian-protocol`)。若只装单个业务 skill,必须同时带上 `bailian-protocol`,例如:
**Supported:** 始终使用 `--all -g`,一次装齐整套 `bailian-*`(含共享协议 `bailian-protocol`)。Agent Skills / `npx skills` **不会**按 metadata 自动拉依赖。
**Advanced / 不推荐:** 子集 `-s` 时 skills CLI 不会自动带上 `bailian-protocol`;若坚持子集,必须手动同时指定,例如:
```bash
# Advanced: you MUST include bailian-protocol yourself — installer does not pull it
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
```
+2 -7
View File
@@ -78,16 +78,11 @@ No timeline scrubbing. No frame-by-frame editing. Just one sentence → one vide
```bash
npm install -g bailian-cli
# Recommended: full bailian-* skill family (includes companion bailian-protocol)
# Recommended: full bailian-* skill family (includes bailian-protocol)
npx skills add modelstudioai/cli --all -g
```
Subset install — always include companion `bailian-protocol` with any business skill:
```bash
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-cli
```
> Supported install is `--all -g`. The skills CLI does **not** auto-install skill dependencies. Subset `-s` installs are advanced / not recommended; if you use them, you must include `bailian-protocol` yourself (e.g. `-s bailian-protocol -s bailian-gen`).
> Requires Node.js >= 18.17.
+2 -7
View File
@@ -76,16 +76,11 @@ _专为 AI Agent 打造,每个命令均可作为结构化工具调用。_
```bash
npm install -g bailian-cli
# 推荐:安装完整 bailian-* skill 家族(含 companion bailian-protocol)
# 推荐:安装完整 bailian-* skill 家族(含 bailian-protocol)
npx skills add modelstudioai/cli --all -g
```
子集安装时,业务 skill 必须同时带上 companion `bailian-protocol`:
```bash
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-cli
```
> 官方支持路径为 `--all -g`。`npx skills` **不会**按 metadata 自动安装依赖。子集 `-s` 为高级用法 / 不推荐;若坚持子集,须自行带上 `bailian-protocol`(例如 `-s bailian-protocol -s bailian-gen`)。
> 需要预先安装 Node.js >= 18.17。
+19 -10
View File
@@ -1,20 +1,27 @@
# Skill 文案 / 路由 / companion
# Skill 文案 / 路由 / 安装约定
## 触发条件
- 改 `skills/*/SKILL.md` 的 description、路由表、consent、安全闸、hand-off、references 落款
- 调整 companion(`bailian-protocol`)或业务 skill 之间的软 hand-off 约定
- 调整 `bailian-protocol` 与业务 skill 的关系,或业务 skill 之间的软 hand-off 约定
- 新增 / 拆分 / 合并 `bailian-*` 业务 skill,或改 `tools/generate-reference.ts` 的 `GROUP_OWNER_SKILL` 归属(与命令增删改交叉时两边都看)
- 给业务 skill 补安装说明、README,或统一「勿猜 flag → `reference/`」类约定
纯改生成物 `skills/*/reference/*.md`(由命令 metadata 驱动)→ 走 [command-add-remove.md](command-add-remove.md) / [command-flag-change.md](command-flag-change.md),**不要手改 reference**。
## 统一口径(安装)
1. **Supported install:** `npx skills add modelstudioai/cli --all -g`(整包装齐,含 `bailian-protocol`)
2. **`bailian-protocol` 是共享协议 skill**,业务 skill 执行前应 Read 它;Agent Skills / `npx skills` **不会**按 frontmatter 自动拉依赖
3. **不要**在 frontmatter 写 `companions`,也不要对外说「companions = 安装器硬依赖」
4. 子集安装(`-s`)为 **advanced / 不推荐**:skills CLI 不会自动带上 protocol;漏装会导致相对路径 Read 失败
## 概念图
```text
bailian-protocol ← companion(硬依赖;consent / 鉴权 / 版本 / 错误上报)
▲
│ companions: ["bailian-protocol"]
bailian-protocol ← 共享协议(consent / 鉴权 / 版本 / 错误上报)
▲ 靠 --all -g 与业务 skill 同装;非安装器强制 companions
│
┌───────┴────────┬────────────────┬──────────────────┐
bailian-gen bailian-finetune bailian-managed-agent
(领域路由表) (领域工作流) (IaC 安全闸)
@@ -30,17 +37,18 @@ bailian-gen bailian-finetune bailian-managed-agent
### A. 分层边界
- [ ] **Companion(硬依赖)**:业务 skill frontmatter 保留 `companions: ["bailian-protocol"]`;CRITICAL / references 可链 `../bailian-protocol/…`
- [ ] **软 hand-off**:兄弟业务 skill **只写 skill 名**;已安装则 Read,未安装则 `bl … --help` 或提示 `-s bailian-protocol -s <skill>`;**不要**把 `../bailian-gen/…` 等写成执行前提
- [ ] **整包装齐**:安装/升级文案主推 `--all -g`;业务 skill **不**声明 `companions`
- [ ] **协议读取**:CRITICAL / references 可链 `../bailian-protocol/…`;若读不到 → 停止执行 `bl`,提示 `npx skills add modelstudioai/cli --all -g`
- [ ] **软 hand-off**:兄弟业务 skill **只写 skill 名**;已安装则 Read,未安装则 `bl … --help` 或提示整包安装;**不要**把 `../bailian-gen/…` 等写成执行前提
- [ ] **Hub vs 领域**:`bailian-cli` 的「When to use which command」只列 hub 拥有的意图;媒体 / 精调 / managed-agent 各留 hand-off 行,**不抄**领域默认模型与子命令明细
- [ ] **渐进披露**:SKILL 写意图路由与领域硬规则;flags / usage / examples 以 `reference/` 或 `bl <command> --help` 为准,表后保留「勿猜 flag」指向句
### B. 文案与落款一致性
- [ ] 领域 skill(gen / finetune / managed-agent)路由或命令表后有指向 `reference/` 的句;文末 `## references`(protocol + reference)与家族对齐
- [ ] description 含 WHAT + WHEN + 反触发 + companion 必装说明;与正文路由不打架
- [ ] description 含 WHAT + WHEN + 反触发;安装说明指向 `--all -g`,不写 companions 必装
- [ ] Quick examples 只演示本 skill 职责(hub 不示范 `bl image` / `bl video` 等)
- [ ] 若改了安装方式:同步 `README.md` / `README.zh.md` / `INSTALL.md` / `skills/*/README*` 中的 `npx skills add …` 示例
- [ ] 若改了安装方式:同步 `README.md` / `README.zh.md` / `INSTALL.md` / `skills/*/README*` / `skills/bailian-protocol/assets/setup.md` 中的 `npx skills add …` 示例(改 `INSTALL.md` 时按 [install-doc-change.md](install-doc-change.md) 同步静态页)
### C. 归属与生成
@@ -56,11 +64,12 @@ pnpm run sync:skill-assets
npx skills add "$(pwd)" --all -g -y
```
抽查:打开 `skills/bailian-cli/SKILL.md` 确认无领域子命令明细表;打开对应领域 skill 确认有「勿猜 flag」与 hand-off。
抽查:打开 `skills/bailian-cli/SKILL.md` 确认无领域子命令明细表、无 `companions`;打开对应领域 skill 确认有「勿猜 flag」与 hand-off。
## 常见漏点
- ✗ hub 路由表再次抄回 image / video / finetune / managed-agent 明细 → token 膨胀且与领域 skill 双份漂移
- ✗ 重新加回 `companions` 并宣称安装器硬依赖 → 与 Agent Skills / `npx skills` 合同不符
- ✗ 软 hand-off 写成硬路径 `../bailian-*/SKILL.md` 当执行前提 → 子集安装断链
- ✗ 只改 SKILL、忘改 `GROUP_OWNER_SKILL` → reference 落错 skill
- ✗ 手改 `skills/*/reference/*.md` → 下次 generate 被覆盖
+2 -7
View File
@@ -78,16 +78,11 @@ No timeline scrubbing. No frame-by-frame editing. Just one sentence → one vide
```bash
npm install -g bailian-cli
# Recommended: full bailian-* skill family (includes companion bailian-protocol)
# Recommended: full bailian-* skill family (includes bailian-protocol)
npx skills add modelstudioai/cli --all -g
```
Subset install — always include companion `bailian-protocol` with any business skill:
```bash
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-cli
```
> Supported install is `--all -g`. The skills CLI does **not** auto-install skill dependencies. Subset `-s` installs are advanced / not recommended; if you use them, you must include `bailian-protocol` yourself (e.g. `-s bailian-protocol -s bailian-gen`).
> Requires Node.js >= 18.17.
+2 -7
View File
@@ -76,16 +76,11 @@ _专为 AI Agent 打造,每个命令均可作为结构化工具调用。_
```bash
npm install -g bailian-cli
# 推荐:安装完整 bailian-* skill 家族(含 companion bailian-protocol)
# 推荐:安装完整 bailian-* skill 家族(含 bailian-protocol)
npx skills add modelstudioai/cli --all -g
```
子集安装时,业务 skill 必须同时带上 companion `bailian-protocol`:
```bash
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-cli
```
> 官方支持路径为 `--all -g`。`npx skills` **不会**按 metadata 自动安装依赖。子集 `-s` 为高级用法 / 不推荐;若坚持子集,须自行带上 `bailian-protocol`(例如 `-s bailian-protocol -s bailian-gen`)。
> 需要预先安装 Node.js >= 18.17。
+1 -2
View File
@@ -4,12 +4,11 @@
Agent skill for **Alibaba Cloud Model Studio CLI** (`bl`) resource hub — apps, memory, RAG, usage/quota, MCP, and hub `reference/`.
- Companion (required): `bailian-protocol` (`requires.bins: ["bl"]`, `companions: ["bailian-protocol"]`)
- Shared protocol: `bailian-protocol` (install via `--all -g`)
- Soft hand-offs (optional skills): `bailian-gen` · `bailian-finetune` · `bailian-managed-agent`
```bash
npx skills add modelstudioai/cli --all -g
# or: npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-cli
```
For CLI installation, authentication, and examples, see the [main README](../../README.md).
+1 -2
View File
@@ -4,12 +4,11 @@
**阿里云百炼 CLI**(`bl`)的资源管理 Agent 技能 — 应用、记忆、RAG、用量/额度、MCP,以及 hub `reference/`。
- Companion(必装):`bailian-protocol`(`requires.bins: ["bl"]`,`companions: ["bailian-protocol"]`)
- 共享协议:`bailian-protocol`(通过 `--all -g` 与整家族同装)
- 软 hand-off(可选):`bailian-gen` · `bailian-finetune` · `bailian-managed-agent`
```bash
npx skills add modelstudioai/cli --all -g
# 或:npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-cli
```
CLI 的安装、认证和使用示例请查看[主 README](../../README.zh.md)。
+7 -8
View File
@@ -4,14 +4,13 @@ metadata:
version: "1.13.1"
requires:
bins: ["bl"]
companions: ["bailian-protocol"]
description: >-
阿里云百炼 / Aliyun Bailian / DashScope 资源管理与 `bl` CLI hub:
应用调用(bl app)、应用记忆、知识库检索、模型目录/模型列表、用量/额度/配额、免费额度、
工作空间、MCP 市场、pipeline、文件上传、console API、登录鉴权与配置、
Agent skill 安装/列表/更新/卸载(bl skill add|list|update|remove,百炼 skill registry)。
用户点名百炼 / DashScope / `bl`,或继续既有 `bl` 工作流时直接使用。
共享协议(consent / 版本预检 / 鉴权 / 错误上报)在 bailian-protocol;安装本 skill 时必须同时安装 companion bailian-protocol。
共享协议(consent / 版本预检 / 鉴权 / 错误上报)在 bailian-protocol;官方安装 `npx skills add modelstudioai/cli --all -g`。
家族路由:生图/生视频/配音/语音合成/转写 → bailian-gen;精调/微调/训练/数据集 → bailian-finetune;
agents.yaml 托管 Agent → bailian-managed-agent。
不要用于普通问答、编程、写作、翻译、摘要、泛搜索,或图片理解等宿主自己能做的任务(普通问答、编程、写作、翻译、摘要、泛搜索不触发)。
@@ -20,14 +19,14 @@ description: >-
# Aliyun Model Studio CLI (`bl`)
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Provider selection and consent, Version & updates (pre-flight checklist), Setup & auth, and CLI errors: report an issue.**
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Provider selection and consent, Version & updates (pre-flight checklist), Setup & auth, and CLI errors: report an issue. If that protocol file is missing, stop and run `npx skills add modelstudioai/cli --all -g`; do not guess auth/consent.**
> **Family hub** — This skill owns Bailian resource commands and the hub `reference/` (apps, knowledge, usage, auth, config, …).
> Shared protocol (companion) → [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md).
> Soft hand-offs by skill name (Read if installed; else `bl … --help` / install with `bailian-protocol`): `bailian-gen` (media) · `bailian-finetune` (training) · `bailian-managed-agent` (agents.yaml IaC).
> Shared protocol → [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md) (install the full family with `--all -g`).
> Soft hand-offs by skill name (Read if installed; else `bl … --help` / prompt `npx skills add modelstudioai/cli --all -g`): `bailian-gen` (media) · `bailian-finetune` (training) · `bailian-managed-agent` (agents.yaml IaC).
> Do not invoke it for ordinary reasoning, coding, writing, translation, summarization, generic research, or image understanding the host agent can complete directly.
>
> **Companion:** always install with `bailian-protocol` (`npx skills add modelstudioai/cli --all -g`, or `-s bailian-protocol -s bailian-cli`).
> **Install (supported):** `npx skills add modelstudioai/cli --all -g`
## Command reference (authoritative)
@@ -114,11 +113,11 @@ schema-export commands.
## Routing reminders
- Image/video/audio generation or editing → skill `bailian-gen` (class 3 consent from companion `bailian-protocol`). Fine-tuning / datasets / deployments → `bailian-finetune`. agents.yaml IaC → `bailian-managed-agent`. Soft hand-off: Read sibling skill if installed; else `bl … --help` or prompt install with `bailian-protocol`. Image understanding the host agent can do → host-first; use `bl vision` / `bl omni` only when the user names a Bailian model or the media (video/audio files) exceeds host capability.
- Image/video/audio generation or editing → skill `bailian-gen` (class 3 consent from `bailian-protocol`). Fine-tuning / datasets / deployments → `bailian-finetune`. agents.yaml IaC → `bailian-managed-agent`. Soft hand-off: Read sibling skill if installed; else `bl … --help` or prompt `npx skills add modelstudioai/cli --all -g`. Image understanding the host agent can do → host-first; use `bl vision` / `bl omni` only when the user names a Bailian model or the media (video/audio files) exceeds host capability.
- Answer ordinary reasoning, coding, writing, translation, summarization, and generic research with the host agent's native capabilities; do not bounce them through `bl text chat` or `bl search web`.
- Usage / quota / credits questions that do not name a product → ask which product (Bailian or another AI service) first; run `bl usage` / `bl quota` only after the user picks Bailian or Bailian context is already established.
- "Remember this" and memory requests default to the host agent's own memory; `bl memory *` is only for Bailian app memory resources.
- `bl file upload` and `bl pipeline run` are steps inside a Bailian workflow; do not use them to capture generic "upload this file" or "run a pipeline" requests.
- `bl managed-agent apply` / `destroy` mutate remote resources and only execute with `--yes`; run `plan` first and show the diff before confirming a mutation.
- When a matched `bl` command accepts a file URL, pass local paths directly; never require the user to host the file first.
- Console login → always `--console-site domestic|international`; see companion [`../bailian-protocol/assets/setup.md`](../bailian-protocol/assets/setup.md#console-site-selection).
- Console login → always `--console-site domestic|international`; see [`../bailian-protocol/assets/setup.md`](../bailian-protocol/assets/setup.md#console-site-selection).
+4 -5
View File
@@ -4,7 +4,6 @@ metadata:
version: "1.13.1"
requires:
bins: ["bl"]
companions: ["bailian-protocol"]
description: >-
阿里云百炼模型精调训练入口:用户要精调、微调、训练自己的模型(fine-tune,支持 SFT / SFT-LoRA / DPO / DPO-LoRA / CPT,
覆盖文本、语音、图像)、校验或上传训练数据集、看训练进度和日志、挑 checkpoint、导出精调产物、
@@ -12,12 +11,12 @@ description: >-
upload 拿 file-id → finetune create 建任务 → watch 看进度 → export 导出 → deploy 上线,需要 API key;
写操作先用 `--dry-run` 预览。反触发:用户点名火山方舟/ark 的精调不走本 skill;只是要选哪个模型走
bailian-model-recommend;用现成模型生图生视频走 bailian-gen;百炼其他资源管理走 bailian-cli。
安装本 skill 时必须同时安装 companion bailian-protocol。
官方安装:`npx skills add modelstudioai/cli --all -g`(与共享协议 bailian-protocol 同装)。
---
# Bailian fine-tuning pipeline (`bl dataset` / `bl finetune` / `bl deploy`)
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Version & updates (pre-flight checklist), Setup & auth, and CLI errors: report an issue. Command details are authoritative in [`reference/`](reference/index.md) (dataset / finetune / deploy) and `bl <command> --help` — do not guess flags. The whole pipeline requires an API key. Companion: install with `bailian-protocol`.**
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Version & updates (pre-flight checklist), Setup & auth, and CLI errors: report an issue. Command details are authoritative in [`reference/`](reference/index.md) (dataset / finetune / deploy) and `bl <command> --help` — do not guess flags. The whole pipeline requires an API key. If that protocol file is missing, stop and run `npx skills add modelstudioai/cli --all -g`; do not guess auth/consent.**
## End-to-end workflow (follow in order)
@@ -64,7 +63,7 @@ bl deploy text create --model my-qwen-sft --name my-svc
## Common hand-offs
软 hand-off(按 skill **名**;已安装则 Read,否则 `--help` / 提示安装该 skill + companion `bailian-protocol`):
软 hand-off(按 skill **名**;已安装则 Read,否则 `--help` / 提示 `npx skills add modelstudioai/cli --all -g`):
- After deployment, try the model or generate content → skill `bailian-gen` (media) or `bl text chat` (fallback: `bl image\|video\|text --help`).
- Unsure which base model to pick → `bailian-model-recommend` / `bl advisor recommend`.
@@ -72,5 +71,5 @@ bl deploy text create --model my-qwen-sft --name my-svc
## references
- [bailian-protocol](../bailian-protocol/SKILL.md) — authentication and global parameters (mandatory)
- [bailian-protocol](../bailian-protocol/SKILL.md) — shared protocol (install via `--all -g`)
- [reference/](reference/index.md) — command details
+5 -6
View File
@@ -4,7 +4,6 @@ metadata:
version: "1.13.1"
requires:
bins: ["bl"]
companions: ["bailian-protocol"]
description: >-
阿里云百炼图片/视频/语音生成入口(**默认生成技能**):用户要生图、画图、生成照片、生成图片、AI 绘画、海报、头像、插画、
文生图(text-to-image)、图生图、改图、修图、多图合成、生成视频、文生视频、图生视频、参考生视频、视频编辑、风格转换、
@@ -14,12 +13,12 @@ description: >-
图片和语音同步返回并落地本地文件,视频是异步任务、用 `--download` 或轮询取回;本地文件直接传路径,CLI 自动上传。
反触发:宿主自己能做的图片理解、普通问答、编程、写作、翻译不走本技能;百炼应用/知识库/用量/额度走 bailian-cli;
精调训练走 bailian-finetune。
安装本 skill 时必须同时安装 companion bailian-protocol。
官方安装:`npx skills add modelstudioai/cli --all -g`(与共享协议 bailian-protocol 同装)。
---
# Bailian media generation (`bl image` / `bl video` / `bl speech` / `bl omni`)
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Provider selection and consent (one-time ask templates), Version & updates (pre-flight checklist), and CLI errors: report an issue. Command details are authoritative in [`reference/`](reference/index.md) and `bl <command> --help` — do not guess flags. Companion: install with `bailian-protocol`.**
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Provider selection and consent (one-time ask templates), Version & updates (pre-flight checklist), and CLI errors: report an issue. Command details are authoritative in [`reference/`](reference/index.md) and `bl <command> --help` — do not guess flags. If that protocol file is missing, stop and run `npx skills add modelstudioai/cli --all -g`; do not guess auth/consent.**
## Consent (short version; full rules in bailian-protocol)
@@ -77,13 +76,13 @@ If one or more `bl` commands actually ran, proactively add a one-line summary in
## Common hand-offs
软 hand-off(按 skill **名**;已安装则 Read,否则 `--help` / 提示安装该 skill + companion `bailian-protocol`):
软 hand-off(按 skill **名**;已安装则 Read,否则 `--help` / 提示 `npx skills add modelstudioai/cli --all -g`):
- Generation failed and it is not a usage/auth/content-filter issue → follow the issue-reporting flow in companion `bailian-protocol` ([`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md#cli-errors-report-an-issue)) and ask once whether to report.
- Generation failed and it is not a usage/auth/content-filter issue → follow the issue-reporting flow in `bailian-protocol` ([`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md#cli-errors-report-an-issue)) and ask once whether to report.
- Managing Bailian apps / knowledge bases / usage → skill `bailian-cli` (fallback: `bl app\|knowledge\|usage --help`).
- Train a dedicated model on user data → skill `bailian-finetune` (fallback: `bl dataset\|finetune\|deploy --help`).
## references
- [bailian-protocol](../bailian-protocol/SKILL.md) — authentication and global parameters (mandatory)
- [bailian-protocol](../bailian-protocol/SKILL.md) — shared protocol (install via `--all -g`)
- [reference/](reference/index.md) — command details
+4 -5
View File
@@ -4,7 +4,6 @@ metadata:
version: "1.13.1"
requires:
bins: ["bl"]
companions: ["bailian-protocol"]
description: >-
阿里云百炼托管 Agent 声明式基础设施入口:用户要创建agent、初始化 agents.yaml、校验或预览 agent 配置变更、
创建/更新/销毁百炼托管 Agent、和托管 agent 对话、查会话事件历史、导入或取消跟踪远端资源时使用
@@ -12,12 +11,12 @@ description: >-
apply / destroy 变更远端资源且必须带 `--yes`,务必先 plan 给用户看 diff 再让其确认。
反触发:调用已上线的百炼应用/智能体走 bailian-app-call 或 `bl app`;宿主 agent 自身的记忆、技能、
子代理不走本 skill;生图生视频走 bailian-gen。
安装本 skill 时必须同时安装 companion bailian-protocol。
官方安装:`npx skills add modelstudioai/cli --all -g`(与共享协议 bailian-protocol 同装)。
---
# Bailian managed agent IaC (`bl managed-agent`)
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Version & updates (pre-flight checklist) and CLI errors: report an issue. Command details are authoritative in [`reference/managed-agent.md`](reference/managed-agent.md) and `bl managed-agent --help` — do not guess flags. Companion: install with `bailian-protocol`.**
**CRITICAL — Before executing, MUST read the shared protocol in [`../bailian-protocol/SKILL.md`](../bailian-protocol/SKILL.md): Version & updates (pre-flight checklist) and CLI errors: report an issue. Command details are authoritative in [`reference/managed-agent.md`](reference/managed-agent.md) and `bl managed-agent --help` — do not guess flags. If that protocol file is missing, stop and run `npx skills add modelstudioai/cli --all -g`; do not guess auth/consent.**
## Safety guardrail (the most important rule)
@@ -61,7 +60,7 @@ Flags, usage, and examples: see [`reference/`](reference/index.md) or `bl <comma
## Common hand-offs
软 hand-off(按 skill **名**;已安装则 Read,否则 `--help` / 提示安装该 skill + companion `bailian-protocol`):
软 hand-off(按 skill **名**;已安装则 Read,否则 `--help` / 提示 `npx skills add modelstudioai/cli --all -g`):
- Call an already published Bailian app/assistant → `bailian-app-call`, or skill `bailian-cli` (`bl app list` / `call`; fallback: `bl app --help`).
- Choosing the model referenced in agents.yaml → `bailian-model-recommend`.
@@ -69,5 +68,5 @@ Flags, usage, and examples: see [`reference/`](reference/index.md) or `bl <comma
## references
- [bailian-protocol](../bailian-protocol/SKILL.md) — authentication and global parameters (mandatory)
- [bailian-protocol](../bailian-protocol/SKILL.md) — shared protocol (install via `--all -g`)
- [reference/](reference/index.md) — command details
+2 -6
View File
@@ -2,17 +2,13 @@
Shared execution protocol for the **bailian-\*** Agent Skill family (consent, versioning, setup/auth, issue reporting).
Business skills (`bailian-cli`, `bailian-gen`, `bailian-finetune`, `bailian-managed-agent`) depend on this skill as a **companion**. Prefer:
Business skills (`bailian-cli`, `bailian-gen`, `bailian-finetune`, `bailian-managed-agent`) read this skill before running `bl`. **Supported install** is the full family:
```bash
npx skills add modelstudioai/cli --all -g
```
Or install a subset with `bailian-protocol` included, e.g.:
```bash
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
```
The Agent Skills / `npx skills` installer does **not** auto-resolve skill dependencies. Prefer `--all -g` over subset `-s` installs.
For CLI installation and command examples, see the [main README](../../README.md).
+2 -6
View File
@@ -2,17 +2,13 @@
**bailian-\*** Agent 技能家族的共享执行协议(consent、版本预检、安装/鉴权、错误上报)。
业务 skill(`bailian-cli` / `bailian-gen` / `bailian-finetune` / `bailian-managed-agent`)都依赖本 skill 作为 **companion**。推荐:
业务 skill(`bailian-cli` / `bailian-gen` / `bailian-finetune` / `bailian-managed-agent`)在跑 `bl` 前应读取本 skill。**官方安装**为整包:
```bash
npx skills add modelstudioai/cli --all -g
```
若只装子集,必须同时带上 `bailian-protocol`,例如:
```bash
npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
```
Agent Skills / `npx skills` **不会**自动解析 skill 依赖。请优先使用 `--all -g`,避免只装单个业务 skill。
CLI 安装与命令示例见[主 README](../../README.zh.md)。
+9 -8
View File
@@ -8,19 +8,20 @@ description: >-
阿里云百炼 `bl` 家族共享执行协议(consent 确认、版本预检、鉴权/安装、错误上报、本地文件与输出约定)。
不是面向用户意图的业务入口;当任一 bailian-* 业务 skill(bailian-cli / bailian-gen /
bailian-finetune / bailian-managed-agent)执行前需要公共上下文,或用户首次安装/鉴权/`bl` 报错需上报时读取本 skill。
本 skill 无 companions;业务 skill 必须在 frontmatter 声明 companions: ["bailian-protocol"] 并成对安装。
官方安装为整包:`npx skills add modelstudioai/cli --all -g`(与业务 skill 同装);Agent Skills / `npx skills` 不会按 metadata 自动拉依赖。
---
# Bailian shared protocol (`bailian-protocol`)
本 skill 是 `bailian-*` 家族的统一执行协议。所有业务 skill 在跑 `bl` 前都应先读本文件。
> **Companion 约定**:`bailian-gen` / `bailian-finetune` / `bailian-managed-agent` / `bailian-cli` 都依赖本 skill。
> 推荐 `npx skills add modelstudioai/cli --all -g`;若只装子集,必须同时带上 `bailian-protocol`,例如:
> **Install(supported):** 整包装齐,含本 skill 与全部业务 skill:
>
> ```bash
> npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
> npx skills add modelstudioai/cli --all -g
> ```
>
> Agent Skills / `npx skills` **不会**解析 frontmatter 依赖字段。子集 `-s` 为 advanced / 不推荐;若坚持子集,必须**手动**同时带上 `bailian-protocol`,否则业务 skill 的相对路径 Read 会失败。
## Provider selection and consent
@@ -42,8 +43,8 @@ After approval, treat Bailian as selected for the current task. Do not ask again
## Family routing & hand-offs
业务路由(**软 hand-off**:按 skill **名**路由;已安装则 Read 其 `SKILL.md`,未安装则用 `bl <cmd> --help`,或提示
`npx skills add modelstudioai/cli -g -s bailian-protocol -s <skill>`):
业务路由(**软 hand-off**:按 skill **名**路由;已安装则 Read 其 `SKILL.md`,未安装则用 `bl <cmd> --help`,或提示整包安装
`npx skills add modelstudioai/cli --all -g`):
| Intent | Skill | Fallback |
| ------------------------------------- | ----------------------- | ----------------------------------------------- |
@@ -52,9 +53,9 @@ After approval, treat Bailian as selected for the current task. Do not ask again
| agents.yaml IaC | `bailian-managed-agent` | `bl managed-agent --help` |
| 应用 / 知识库 / 用量 / 鉴权配置等资源 | `bailian-cli` | `bl app\|knowledge\|usage\|auth\|config --help` |
**硬依赖(companion)** vs **软 hand-off**:
**共享协议** vs **软 hand-off**:
- Companion(`bailian-protocol`):业务 skill frontmatter 的 `companions` 必装;CRITICAL 可用相对路径 `../bailian-protocol/…`。
- `bailian-protocol`:靠 `--all -g` 与业务 skill 同装;CRITICAL 可用相对路径 `../bailian-protocol/…`。读不到则停止跑 `bl`,提示整包安装。
- 其它 bailian-\* 业务 skill:只按名字提及,**不要**写死 `../bailian-*/SKILL.md` 当执行前提。
## Version & updates (after provider selection, before the first `bl` command)
+1 -1
View File
@@ -16,7 +16,7 @@ npm install -g bailian-cli
# Recommended: install the full bailian-* skill family (includes bailian-protocol)
npx skills add modelstudioai/cli --all -g
# Subset install: always include companion bailian-protocol with any business skill
# Advanced / not recommended: skills CLI does not auto-pull bailian-protocol
# npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-gen
# npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-finetune
# npx skills add modelstudioai/cli -g -s bailian-protocol -s bailian-managed-agent
+1 -1
View File
@@ -42,7 +42,7 @@ npm install -g bailian-cli
npx skills add modelstudioai/cli --all -g
```
If you only need one business skill, still install companion `bailian-protocol` with it (see [SKILL.md companion note](../SKILL.md)).
Do not install a single business skill alone — use `--all -g` so `bailian-protocol` is present.
## Mention it in the task summary