diff --git a/CHANGELOG.md b/CHANGELOG.md index 9ca304fd..8118925e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and ### Added -- **Global `--biz-source` flag**: All commands accept `--biz-source ` so callers (skills/agents/products) can declare their business source. The normalized label is reported to AEM as a dedicated flat column `c6` (plus `ext`), enabling per-source PV/UV analysis of command usage (e.g. `flow-agent`). Absent → omitted; blank/invalid → `unknown`. +- **Global `--biz-from` flag**: All commands accept `--biz-from ` so callers (skills/agents/products) can declare their business source, enabling per-source usage analysis (PV/UV) of command calls (e.g. `flow-agent`). ## [2.10.5] - 2026-11-23 diff --git a/CHANGELOG.zh.md b/CHANGELOG.zh.md index ee51185e..8a86734e 100644 --- a/CHANGELOG.zh.md +++ b/CHANGELOG.zh.md @@ -10,7 +10,7 @@ ### 新增 -- **全局 `--biz-source` 参数**:所有命令支持 `--biz-source `,调用方(skill/agent/产品)可声明业务来源。归一化后的来源上报到 AEM 专用扁平列 `c6`(及 `ext`),支持按来源统计命令调用(如 `flow-agent`)的 PV/UV。缺省省略;空白/非法 → `unknown`。 +- **全局 `--biz-from` 参数**:所有命令支持 `--biz-from `,调用方(skill/agent/产品)可声明业务来源,便于按来源统计命令调用(如 `flow-agent`)的 PV/UV。 ## [2.10.5] - 2026-11-23 diff --git a/docs/agents/telemetry-change.md b/docs/agents/telemetry-change.md index 66508046..1d8867b5 100644 --- a/docs/agents/telemetry-change.md +++ b/docs/agents/telemetry-change.md @@ -99,11 +99,11 @@ source-config 只用于百炼 / DashScope API 侧消费,不发送到通用网 - `authMethod` - `callerType`(必填:`agent` | `script` | `unknown`) - `callerName`:`agent` 与 `script` 时发送(缺省/非法 → `"unknown"`);`skillName` / `skillVersion` 仅 `agent` 时可选发送 -- `bizSource`:全局 `--biz-source` 声明的业务来源(可选);经 `normalizeBizSource` 归一化(缺省省略,空白/非法 → `"unknown"`),与 `callerName` 独立;映射到 AEM `c6` 专用扁平列 +- `bizFrom`:全局 `--biz-from` 声明的业务来源(可选);经 `normalizeBizFrom` 归一化(缺省省略,空白/非法 → `"unknown"`),与 `callerName` 独立;映射到 AEM `c6` 专用扁平列 - 失败时的 `errorMessage`、`exitCode`、`httpStatus`、`requestId` - 安全 allowlist 过滤后的 `params` -`bizSource` 是调用方(skill/agent/产品)通过全局 `--biz-source` 主动声明的来源标签,用于按来源区分命令调用的 PV/UV。它走 `GLOBAL_FLAGS` → `buildSettings` → `settings.bizSource` → `trackCommandExecution` 读取,不经命令自有 flag,也不进 `PARAM_ALLOWLIST`(c1)。归一化复用 caller 的 `NAME_PATTERN`(小写、空格/下划线转连字符, bounded charset)防 PII。AEM 侧除随 `ext` 上报外,另映射到专用扁平列 `c6`(标量字符串),无需 JSON 解析维度配置即可直接按 `c6` 筛选/分组:PV=事件计数,UV=distinct `uid`;按命令路径(如 `flow-agent *`)过滤即得某命令组的来源 PV/UV。`bizSource` 与 `callerType`/`callerName`(宿主归因)是独立维度,不得混用。 +`bizFrom` 是调用方(skill/agent/产品)通过全局 `--biz-from` 主动声明的来源标签,用于按来源区分命令调用的 PV/UV。它走 `GLOBAL_FLAGS` → `buildSettings` → `settings.bizFrom` → `trackCommandExecution` 读取,不经命令自有 flag,也不进 `PARAM_ALLOWLIST`(c1)。归一化复用 caller 的 `NAME_PATTERN`(小写、空格/下划线转连字符, bounded charset)防 PII。AEM 侧除随 `ext` 上报外,另映射到专用扁平列 `c6`(标量字符串),无需 JSON 解析维度配置即可直接按 `c6` 筛选/分组:PV=事件计数,UV=distinct `uid`;按命令路径(如 `flow-agent *`)过滤即得某命令组的来源 PV/UV。`bizFrom` 与 `callerType`/`callerName`(宿主归因)是独立维度,不得混用。 调用方归因只认本次进程的 `BAILIAN_CALLER_*`(由 `readCaller` 归一化后写入事件): @@ -158,7 +158,7 @@ AEM 映射: | `c3` | HTTP status | | `c4` | 错误文案,最多 500 字符 | | `c5` | request ID | -| `c6` | `bizSource` 业务来源(全局 `--biz-source`,归一化标量;专用扁平列,直接筛选/分组) | +| `c6` | `bizFrom` 业务来源(全局 `--biz-from`,归一化标量;专用扁平列,直接筛选/分组) | 远端发送是 best-effort,不得阻塞命令或改变退出码。正常退出最多等待 1 秒,SIGINT 最多等待 500 ms。 diff --git a/packages/cli/tests/e2e/registry.smoke.e2e.test.ts b/packages/cli/tests/e2e/registry.smoke.e2e.test.ts index c73422e6..da8b1c16 100644 --- a/packages/cli/tests/e2e/registry.smoke.e2e.test.ts +++ b/packages/cli/tests/e2e/registry.smoke.e2e.test.ts @@ -70,7 +70,7 @@ describe("e2e: bl registry smoke", () => { expect(stderr).toMatch(/--console-region/); expect(stderr).toMatch(/--console-site/); expect(stderr).toMatch(/--console-switch-agent/); - expect(stderr).toMatch(/--biz-source/); + expect(stderr).toMatch(/--biz-from/); expect(stderr).not.toMatch(/^\s*--region\s/m); }); diff --git a/packages/core/src/config/loader.ts b/packages/core/src/config/loader.ts index 655b1451..85216d5a 100644 --- a/packages/core/src/config/loader.ts +++ b/packages/core/src/config/loader.ts @@ -338,6 +338,6 @@ export function buildSettings(s: ResolutionSources): Settings { consoleSwitchAgent: flags.consoleSwitchAgent || file.console_switch_agent || undefined, dryRun: flags.dryRun || false, telemetry: env.DO_NOT_TRACK === "1" ? false : (file.telemetry ?? true), - bizSource: flags.bizSource ?? undefined, + bizFrom: flags.bizFrom ?? undefined, }; } diff --git a/packages/core/src/config/schema.ts b/packages/core/src/config/schema.ts index 38b2f11c..5b053119 100644 --- a/packages/core/src/config/schema.ts +++ b/packages/core/src/config/schema.ts @@ -253,6 +253,6 @@ export interface Settings { quiet: boolean; dryRun: boolean; telemetry: boolean; - /** Per-invocation business source label (--biz-source) for usage analytics; not persisted. */ - bizSource?: string; + /** Per-invocation business source label (--biz-from) for usage analytics; not persisted. */ + bizFrom?: string; } diff --git a/packages/core/src/telemetry/caller.ts b/packages/core/src/telemetry/caller.ts index 4bd6c835..7ac4ff4f 100644 --- a/packages/core/src/telemetry/caller.ts +++ b/packages/core/src/telemetry/caller.ts @@ -34,12 +34,12 @@ function normalizeCallerName(raw: string | undefined): string { } /** - * Normalize a caller-declared business source label (--biz-source) to a stable id. + * Normalize a caller-declared business source label (--biz-from) to a stable id. * Absent (undefined) stays undefined so the event omits the field; a present but * blank/invalid label falls back to `unknown`, mirroring callerName. Reuses the * caller name pattern to keep the value space bounded and free of PII. */ -export function normalizeBizSource(raw: string | undefined): string | undefined { +export function normalizeBizFrom(raw: string | undefined): string | undefined { return raw === undefined ? undefined : normalizeCallerName(raw); } diff --git a/packages/core/src/telemetry/event.ts b/packages/core/src/telemetry/event.ts index e752feea..37c0260e 100644 --- a/packages/core/src/telemetry/event.ts +++ b/packages/core/src/telemetry/event.ts @@ -23,8 +23,8 @@ export interface TrackingEvent { callerName?: string; skillName?: string; skillVersion?: string; - /** Caller-declared business source (--biz-source), normalized; reported as AEM c6. */ - bizSource?: string; + /** Caller-declared call source (--biz-from), normalized; reported as AEM c6. */ + bizFrom?: string; } export function createTrackingEvent(opts: { @@ -36,7 +36,7 @@ export function createTrackingEvent(opts: { authMethod?: AuthRequirement; params?: Record; caller: CallerAttribution; - bizSource?: string; + bizFrom?: string; }): TrackingEvent { const event: TrackingEvent = { command: opts.command, @@ -58,8 +58,8 @@ export function createTrackingEvent(opts: { event.callerName = opts.caller.callerName; } - if (opts.bizSource !== undefined) { - event.bizSource = opts.bizSource; + if (opts.bizFrom !== undefined) { + event.bizFrom = opts.bizFrom; } if (opts.authMethod) { @@ -108,8 +108,8 @@ export function buildRemoteAemOptions(event: TrackingEvent): Record", description: { diff --git a/packages/core/tests/config-priority.test.ts b/packages/core/tests/config-priority.test.ts index b27a32bc..66edaee5 100644 --- a/packages/core/tests/config-priority.test.ts +++ b/packages/core/tests/config-priority.test.ts @@ -33,11 +33,11 @@ function src(s: { const resolve = (s: Parameters[0]): Settings => buildSettings(src(s)); -test("maps --biz-source flag into settings.bizSource (not persisted)", () => { - expect(resolve({ flags: { bizSource: "coze" } }).bizSource).toBe("coze"); - expect(resolve({ flags: {} }).bizSource).toBeUndefined(); +test("maps --biz-from flag into settings.bizFrom (not persisted)", () => { + expect(resolve({ flags: { bizFrom: "coze" } }).bizFrom).toBe("coze"); + expect(resolve({ flags: {} }).bizFrom).toBeUndefined(); // Explicit empty string is preserved (declared-but-empty), not folded to undefined. - expect(resolve({ flags: { bizSource: "" } }).bizSource).toBe(""); + expect(resolve({ flags: { bizFrom: "" } }).bizFrom).toBe(""); }); test("token-plan Profile 预设保持固定", () => { diff --git a/packages/core/tests/telemetry-caller.test.ts b/packages/core/tests/telemetry-caller.test.ts index dc5371b4..e3ce3c78 100644 --- a/packages/core/tests/telemetry-caller.test.ts +++ b/packages/core/tests/telemetry-caller.test.ts @@ -1,5 +1,5 @@ import { expect, test } from "vite-plus/test"; -import { normalizeBizSource, readCaller } from "../src/telemetry/caller.ts"; +import { normalizeBizFrom, readCaller } from "../src/telemetry/caller.ts"; test.each([ { label: "missing", env: {} }, @@ -62,14 +62,14 @@ test("normalizes callerName and falls back to unknown", () => { }); }); -test("normalizeBizSource keeps absent undefined and normalizes present labels", () => { - expect(normalizeBizSource(undefined)).toBeUndefined(); - expect(normalizeBizSource("Coze")).toBe("coze"); - expect(normalizeBizSource("My Skill")).toBe("my-skill"); - expect(normalizeBizSource("qwen_code")).toBe("qwen-code"); - expect(normalizeBizSource("")).toBe("unknown"); - expect(normalizeBizSource(" ")).toBe("unknown"); - expect(normalizeBizSource("bad/name!")).toBe("unknown"); +test("normalizeBizFrom keeps absent undefined and normalizes present labels", () => { + expect(normalizeBizFrom(undefined)).toBeUndefined(); + expect(normalizeBizFrom("Coze")).toBe("coze"); + expect(normalizeBizFrom("My Skill")).toBe("my-skill"); + expect(normalizeBizFrom("qwen_code")).toBe("qwen-code"); + expect(normalizeBizFrom("")).toBe("unknown"); + expect(normalizeBizFrom(" ")).toBe("unknown"); + expect(normalizeBizFrom("bad/name!")).toBe("unknown"); }); test("drops illegal skillName and only keeps version when skillName is valid", () => { diff --git a/packages/core/tests/telemetry-tracker.test.ts b/packages/core/tests/telemetry-tracker.test.ts index 05d11b4f..6a6c6d15 100644 --- a/packages/core/tests/telemetry-tracker.test.ts +++ b/packages/core/tests/telemetry-tracker.test.ts @@ -313,22 +313,22 @@ test("does not call sinks when telemetry is disabled", async () => { expect(sinkMocks.remoteSink).not.toHaveBeenCalled(); }); -test("reports bizSource as a structured field and dedicated AEM c6 column", () => { +test("reports bizFrom as a structured field and dedicated AEM c6 column", () => { const event = createTrackingEvent({ command: "flow-agent create", durationMs: 1, success: true, identity, caller: unknownCaller, - bizSource: "coze", + bizFrom: "coze", }); - expect(event.bizSource).toBe("coze"); + expect(event.bizFrom).toBe("coze"); const opts = buildRemoteAemOptions(event); expect(opts.c6).toBe("coze"); - expect(opts.ext).toMatchObject({ bizSource: "coze" }); + expect(opts.ext).toMatchObject({ bizFrom: "coze" }); }); -test("omits bizSource and c6 when no source is declared", () => { +test("omits bizFrom and c6 when no source is declared", () => { const event = createTrackingEvent({ command: "flow-agent create", durationMs: 1, @@ -336,41 +336,38 @@ test("omits bizSource and c6 when no source is declared", () => { identity, caller: unknownCaller, }); - expect(event.bizSource).toBeUndefined(); + expect(event.bizFrom).toBeUndefined(); const opts = buildRemoteAemOptions(event); expect(opts).not.toHaveProperty("c6"); - expect(opts.ext).not.toHaveProperty("bizSource"); + expect(opts.ext).not.toHaveProperty("bizFrom"); }); test.each([ - { label: "valid", bizSource: "My Skill", expected: "my-skill" }, - { label: "underscore", bizSource: "qwen_code", expected: "qwen-code" }, - { label: "invalid", bizSource: "bad/name!", expected: "unknown" }, - { label: "blank", bizSource: " ", expected: "unknown" }, - { label: "empty", bizSource: "", expected: "unknown" }, -])( - "normalizes settings.bizSource ($label) into the event and c6", - async ({ bizSource, expected }) => { - sinkMocks.localSink.mockClear(); - sinkMocks.remoteSink.mockClear(); - await trackCommandExecution( - { - identity, - settings: { telemetry: true, bizSource } as Settings, - authMethod: "console", - caller: unknownCaller, - }, - ["flow-agent", "create"], - {}, - async () => {}, - ); - const event = sinkMocks.remoteSink.mock.calls[0]![0]; - expect(event.bizSource).toBe(expected); - expect(buildRemoteAemOptions(event).c6).toBe(expected); - }, -); + { label: "valid", bizFrom: "My Skill", expected: "my-skill" }, + { label: "underscore", bizFrom: "qwen_code", expected: "qwen-code" }, + { label: "invalid", bizFrom: "bad/name!", expected: "unknown" }, + { label: "blank", bizFrom: " ", expected: "unknown" }, + { label: "empty", bizFrom: "", expected: "unknown" }, +])("normalizes settings.bizFrom ($label) into the event and c6", async ({ bizFrom, expected }) => { + sinkMocks.localSink.mockClear(); + sinkMocks.remoteSink.mockClear(); + await trackCommandExecution( + { + identity, + settings: { telemetry: true, bizFrom } as Settings, + authMethod: "console", + caller: unknownCaller, + }, + ["flow-agent", "create"], + {}, + async () => {}, + ); + const event = sinkMocks.remoteSink.mock.calls[0]![0]; + expect(event.bizFrom).toBe(expected); + expect(buildRemoteAemOptions(event).c6).toBe(expected); +}); -test("absent settings.bizSource omits the field and c6", async () => { +test("absent settings.bizFrom omits the field and c6", async () => { sinkMocks.localSink.mockClear(); sinkMocks.remoteSink.mockClear(); await trackCommandExecution( @@ -385,6 +382,6 @@ test("absent settings.bizSource omits the field and c6", async () => { async () => {}, ); const event = sinkMocks.remoteSink.mock.calls[0]![0]; - expect(event.bizSource).toBeUndefined(); + expect(event.bizFrom).toBeUndefined(); expect(buildRemoteAemOptions(event)).not.toHaveProperty("c6"); }); diff --git a/skills/bailian-cli/reference/index.md b/skills/bailian-cli/reference/index.md index 161ebd83..faa45c63 100644 --- a/skills/bailian-cli/reference/index.md +++ b/skills/bailian-cli/reference/index.md @@ -183,7 +183,7 @@ Available on every command (in addition to command-specific flags): | `--verbose` | switch | no | Print HTTP request/response details | | `--dry-run` | switch | no | Dry run mode | | `--config ` | string | no | Use a config profile for this command | -| `--biz-source ` | string | no | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| `--biz-from ` | string | no | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | `--help` | switch | no | Show help | | `--version` | switch | no | Print version | diff --git a/skills/bailian-finetune/reference/index.md b/skills/bailian-finetune/reference/index.md index cc0821c9..e5f2c124 100644 --- a/skills/bailian-finetune/reference/index.md +++ b/skills/bailian-finetune/reference/index.md @@ -113,7 +113,7 @@ Available on every command (in addition to command-specific flags): | `--verbose` | switch | no | Print HTTP request/response details | | `--dry-run` | switch | no | Dry run mode | | `--config ` | string | no | Use a config profile for this command | -| `--biz-source ` | string | no | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| `--biz-from ` | string | no | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | `--help` | switch | no | Show help | | `--version` | switch | no | Print version | diff --git a/skills/bailian-gen/reference/index.md b/skills/bailian-gen/reference/index.md index cee00683..85758739 100644 --- a/skills/bailian-gen/reference/index.md +++ b/skills/bailian-gen/reference/index.md @@ -61,7 +61,7 @@ Available on every command (in addition to command-specific flags): | `--verbose` | switch | no | Print HTTP request/response details | | `--dry-run` | switch | no | Dry run mode | | `--config ` | string | no | Use a config profile for this command | -| `--biz-source ` | string | no | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| `--biz-from ` | string | no | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | `--help` | switch | no | Show help | | `--version` | switch | no | Print version | diff --git a/skills/bailian-knowledge/reference/knowledge.md b/skills/bailian-knowledge/reference/knowledge.md index d9e7af1f..bf303459 100644 --- a/skills/bailian-knowledge/reference/knowledge.md +++ b/skills/bailian-knowledge/reference/knowledge.md @@ -23,7 +23,7 @@ bl knowledge category add --name [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --collection-id | string | — | Create under this collection (defaults to the platform collection) | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | @@ -75,7 +75,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --category-id | string | yes | Category ID to delete | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | @@ -120,7 +120,7 @@ bl knowledge category list [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --collection-id | string | — | Filter by exact collection ID | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | @@ -176,7 +176,7 @@ bl knowledge chat --message --agent-id [flags] | --agent-version | string | — | Service version to call: beta (draft for debugging) or a published number; default is the latest published version | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --enable-cache-control | boolean | — | Explicit context cache control | @@ -237,7 +237,7 @@ bl knowledge chunk add --index-id (--content | --field ) [flags | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --content | string | — | Chunk body text, up to 6000 chars (document-type); alternative to --content-file | | --content-file | string | — | Read chunk body from a UTF-8 plain text file (.md/.txt etc.) | @@ -305,7 +305,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --chunk-id | array | yes | Chunk ID to delete (repeatable; batches of 10 are sent automatically) | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | @@ -351,7 +351,7 @@ bl knowledge chunk list --index-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --doc-id | string | — | Only show chunks belonging to this document | | --dry-run | switch | — | Dry run mode | @@ -400,7 +400,7 @@ bl knowledge chunk update --index-id --chunk-id --doc-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --chunk-id | string | yes | Chunk ID (metadata._id from the chunk list output) | | --config | string | — | Use a config profile for this command | | --content | string | — | New chunk content, 10-6000 chars; alternative to --content-file | @@ -455,7 +455,7 @@ bl knowledge collection create --name --description [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --description | string | yes | What this collection holds and what it is for — tells collections apart in the list | | --dry-run | switch | — | Dry run mode | @@ -507,7 +507,7 @@ bl knowledge collection get (--collection-id | --name ) [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --collection-id | string | — | Collection ID; alternative to --name | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | @@ -548,7 +548,7 @@ bl knowledge create --name --description (--doc-id | --catego | --------------------------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --category-id | array | — | Import every file under this category (repeatable); mutually exclusive with --doc-id | | --chunk-size | number | — | Chunk size in characters (default: 600, recommended 300-800) | | --config | string | — | Use a config profile for this command | @@ -619,7 +619,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -672,7 +672,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --doc-id | array | yes | Document ID to delete (repeatable) | | --dry-run | switch | — | Dry run mode | @@ -724,7 +724,7 @@ bl knowledge doc import --index-id (--doc-id ... | --category-id < | ------------------------------------------------------ | ------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --category-id | array | — | Data-center category ID (repeatable; excludes --doc-id) | | --chunk-mode | string | — | Document chunk mode (not video time slicing) | | --chunk-size | number | — | Document chunk size, 1-6000 characters | @@ -777,7 +777,7 @@ bl knowledge doc import-oss --bucket --region --oss-key [flags | --------------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --bucket | string | yes | Authorized OSS bucket name | | --category-id | string | — | Target data-center category (default: the default category) | | --config | string | — | Use a config profile for this command | @@ -832,7 +832,7 @@ bl knowledge doc list --index-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --details | switch | — | Include file-level chunk configuration (page size up to 10) | | --dry-run | switch | — | Dry run mode | @@ -881,7 +881,7 @@ bl knowledge doc status --index-id --job-id [flags] | ------------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -942,7 +942,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | ------------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --category-id | string | — | Data-center category ID (default: workspace default on first run) | | --config | string | — | Use a config profile for this command | | --delete | switch | — | Delete managed index documents missing locally | @@ -999,7 +999,7 @@ bl knowledge doc tag --doc-id --tag [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --doc-id | array | yes | Data-center file ID to tag (repeatable, 1-20 per call) | | --dry-run | switch | — | Dry run mode | @@ -1047,7 +1047,7 @@ bl knowledge doc upload --file [flags] | -------------------------------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --category-id | string | — | Target data-center category; defaults to the workspace default category | | --category-type | string | — | File category type (SESSION_FILE for temporary chat attachments) | | --config | string | — | Use a config profile for this command | @@ -1121,7 +1121,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --file-id | string | yes | Data-center file ID to delete | @@ -1168,7 +1168,7 @@ bl knowledge file get --file-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --file-id | string | yes | Data-center file ID | @@ -1204,7 +1204,7 @@ bl knowledge file list --category-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --category-id | string | yes | Category to list (find ids via the category list command); exact match | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | @@ -1256,7 +1256,7 @@ bl knowledge info --index-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1305,7 +1305,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | ------------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1360,7 +1360,7 @@ bl knowledge list [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1412,7 +1412,7 @@ bl knowledge search --agent-id (--query | --image ) [flags] | --agent-version | string | — | Service version to call: beta (draft for debugging) or a published number; default is the latest published version | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1465,7 +1465,7 @@ bl knowledge service copy --agent-id [flags] | --agent-id | string | yes | Source service (agent) ID to copy | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1506,7 +1506,7 @@ bl knowledge service create --name --scene [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --config-file | string | — | Complete agent_config JSON file (excludes --index-id) | | --description | string | — | What this service answers and who it serves — recommended: agents read it to pick the right service (up to 1000 chars) | @@ -1567,7 +1567,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --agent-id | string | yes | Service (agent) ID | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1622,7 +1622,7 @@ Use `--yes` only after the user has confirmed this operation and its scope. Exit | --agent-id | string | yes | Service (agent) ID | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1673,7 +1673,7 @@ bl knowledge service get --agent-id [flags] | --agent-version | string | — | Specific version to inspect (beta or a published number); omit for all versions | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1719,7 +1719,7 @@ bl knowledge service list --scene [flags] | --agent-id | string | — | Filter by exact agent ID | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --help | switch | — | Show help | @@ -1772,7 +1772,7 @@ bl knowledge service update --agent-id [flags] | --agent-version | string | — | Target version (default: beta draft). Published versions only accept --version-desc | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --config-file | string | — | JSON file replacing the whole agent_config (for nested settings like kb_search_configs); mutually exclusive with scalar config flags | | --description | string | — | New service description (up to 1000 chars) | @@ -1842,7 +1842,7 @@ bl knowledge stats --index-id [flags] | --------------------- | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------- | | --api-key | string | — | API key | | --base-url | string | — | API base URL | -| --biz-source | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | +| --biz-from | string | — | Business source for usage analytics; callers/skills should pass their name so command calls are attributed to the calling skill/product | | --config | string | — | Use a config profile for this command | | --dry-run | switch | — | Dry run mode | | --end