siluzan-tso-cli 1.1.21-beta.5 → 1.1.21-beta.6

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 CHANGED
@@ -51,7 +51,7 @@ siluzan-tso init -d /path/to/skills # 写入自定义目录
51
51
  siluzan-tso init --force # 强制覆盖已存在文件
52
52
  ```
53
53
 
54
- > **注意**:当前为测试版(1.1.21-beta.5),供内部测试使用。正式发布后安装命令将改为 `npm install -g siluzan-tso-cli`。
54
+ > **注意**:当前为测试版(1.1.21-beta.6),供内部测试使用。正式发布后安装命令将改为 `npm install -g siluzan-tso-cli`。
55
55
 
56
56
  | 助手 | 建议 `--ai` |
57
57
  | ----------------------- | ------------------------------------ |
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: siluzan-tso
3
3
  description: >-
4
- Siluzan TSO 广告 skill(siluzan-tso-cli):Google/Bing/Yandex/TikTok/Kwai 账户开户与管理、Google Ads CRUD、数据分析、优化报告、智能预警、TikTok/Meta 线索、发票财务,并提供 RAG 知识库查询,google广告关键词推荐;当你发现你的上下文被压缩过后,你需要根据用户的需求,重新阅读本skill相关的文件,保证skill功能正常。
4
+ Siluzan TSO 广告 skill(siluzan-tso-cli):Google/Bing/Yandex/TikTok/Kwai 账户开户与管理、Google Ads CRUD、数据分析、优化报告、智能预警、TikTok/Meta 线索、发票财务,并提供 RAG 知识库查询,google广告关键词推荐。**每个新的用户任务/话题切换时**,必须先 Read 本 Skill 路由表指向的 references(勿凭上一轮记忆直接跑 CLI);上下文被压缩后须重读 SKILL + 当次任务相关 references。
5
5
  license: MIT
6
6
  metadata:
7
7
  requires: nodejs,siluzan-tso-cli
@@ -76,13 +76,55 @@ Windows 注意:部分 Agent 客户端通过 PowerShell / cmd 代执行命令
76
76
 
77
77
  ---
78
78
 
79
+ ## 文档加载纪律(Agent 必读)
80
+
81
+ 本 Skill 采用 **SKILL 路由 + references 按需加载** 以控制体积;**「按需」= 每个用户任务都要按需,不是整段对话只读一次**。
82
+
83
+ ### 何时必须 Read references
84
+
85
+ | 触发 | 动作 |
86
+ | ---- | ---- |
87
+ | **新的用户任务**(新需求、新账户、新媒体、新报告类型) | 用下方「任务 → 文档」表确定路径,**Read 全部必读项**后再计划/执行 CLI |
88
+ | **同一对话内换话题**(例:刚查余额 → 用户改问建系列 / 预警 / 发票) | **重新 Read** 新话题对应 references,**禁止**沿用上一任务的参数记忆 |
89
+ | **Playbook 编号不同**(P1→P3、P4→P5) | 即使刚做过 P1,执行 P3 仍须 Read `accounts.md`(`accounts-digest`)等 P3 专属节 |
90
+ | **专用 report-templates**(OKKI / 询盘分析) | Read 对应 `report-templates/*.md` **全文**,勿只凭 SKILL 摘要 |
91
+ | **上下文被压缩 / 记不清字段或命令** | 重读 `SKILL.md` 路由表 + 当次任务 references |
92
+ | **CLI 返回 400 / 字段对不上** | 回到对应 reference 核对参数名与口径,勿猜 |
93
+
94
+ ### 禁止
95
+
96
+ - **禁止**「上次已经读过 `accounts.md` / `google-ads.md`,本任务直接 `siluzan-tso …`」
97
+ - **禁止**用对话记忆中的示例 ID、金额、命令 flags 代替当次 Read 文档
98
+ - **禁止**跳过 `references/tips.md` 里的 outline→JSON 顺序(与是否读过无关,**每次** `--json-out` 落盘都要遵守)
99
+
100
+ ### 任务 → 必读 references(执行 CLI 前)
101
+
102
+ | 用户意图(关键词) | 必读(Read 后再 `-h` / 执行) |
103
+ | ------------------ | ----------------------------- |
104
+ | 账户列表 / 余额 / 消耗 / 分享 / MCC / BC / 多账户汇总 | `references/accounts.md`;金额加 `currency.md`;`accounts-digest` 见 accounts § accounts-digest |
105
+ | 拉数 / 报告 / 周报 / 分析 / `google-analysis` | `references/account-analytics.md` + `references/tips.md`;多账户批处理加 `google-analysis-batch.md` |
106
+ | Google 新建搜索系列 | `references/google-ads-campaign-plan.md`(再按需 `google-ads.md`、模板 JSON) |
107
+ | Google 广告 CRUD / 拒审 / 系列组关键词 | `references/google-ads.md` |
108
+ | PMax | `assets/pmax-create-template.md` + `references/pmax-api.md` |
109
+ | 拓词 / keyword | `references/keyword-planner-workflows.md`;要客户背景先 `rag.md` |
110
+ | 优化报告(TSO 平台) | `references/reporting.md` |
111
+ | 预警 | `references/forewarning.md` |
112
+ | 发票 / 转账 / 充值 | `references/finance.md` |
113
+ | 开户 | `references/open-account-by-media.md`(Google 另见 `open-account-google-ui.md`) |
114
+ | OKKI 周报 | `report-templates/okki-weekly-google-client.md` |
115
+ | Google 询盘分析 | `report-templates/google-inquiry-analysis.md` |
116
+
117
+ > 表未覆盖时:先查上方「功能路由」表 → Read 对应 reference → 再执行 CLI。
118
+
119
+ ---
120
+
79
121
  ## AI 行为规范
80
122
 
81
123
  ### 执行流程
82
124
 
83
125
  **计划 → 确认 → 执行 → 验证 → 推测下一步**:
84
126
 
85
- 1. 读对应 references 用 `-h` 确认命令 → 向用户输出操作计划
127
+ 1. **按「文档加载纪律」Read 当次任务 references**(新任务/换话题必做,勿复用上一轮)→ 用 `-h` 确认命令 → 向用户输出操作计划
86
128
  2. 涉及写入/修改/删除的操作必须与用户确认
87
129
  3. 按计划执行,说明每步意图
88
130
  4. 用成对的读命令复核写入结果;异步任务每 5s 轮询直到完成
@@ -186,8 +228,12 @@ Windows 注意:部分 Agent 客户端通过 PowerShell / cmd 代执行命令
186
228
 
187
229
  ## Playbook:高频任务标准动作
188
230
 
231
+ > **每个 Playbook 开始前**:按「文档加载纪律」Read 该 Playbook 列出的 references(**不因同对话内刚做过其他 Playbook 而跳过**)。
232
+
189
233
  ### P1 · 单账户投放画像
190
234
 
235
+ **必读**:`references/account-analytics.md`、`references/currency.md`、`references/tips.md`。
236
+
191
237
  1. 反问时间范围(已授权默认时按白名单并写明区间)。
192
238
  2. `list-accounts -m Google -k <mediaCustomerId> --json-out ./snap-p1`
193
239
  3. `stats -m Google -a <mediaCustomerId> --start <S> --end <D> --json-out ./snap-p1`
@@ -196,6 +242,8 @@ Windows 注意:部分 Agent 客户端通过 PowerShell / cmd 代执行命令
196
242
 
197
243
  ### P2 · 多账户余额扫描
198
244
 
245
+ **必读**:`references/accounts.md`(`balance-scan`)、`references/currency.md`。
246
+
199
247
  **全量巡检**:
200
248
 
201
249
  ```bash
@@ -215,6 +263,8 @@ siluzan-tso balance-scan -m Google -a id1,id2,id3 --json-out ./snap-p2-subset
215
263
 
216
264
  ### P3 · 多账户投放画像汇总
217
265
 
266
+ **必读**:`references/accounts.md` § `accounts-digest`、`references/currency.md`、`references/tips.md`。
267
+
218
268
  ```bash
219
269
  siluzan-tso accounts-digest -m Google -a id1,id2,... --start <S> --end <D> --json-out ./snap-p3
220
270
  ```
@@ -226,6 +276,8 @@ siluzan-tso accounts-digest -m Google -a id1,id2,... --start <S> --end <D> --jso
226
276
 
227
277
  ### P4 · Google 账户周期报告
228
278
 
279
+ **必读**:`report-templates/google-period-report.md`、`references/account-analytics.md`、`references/tips.md`。
280
+
229
281
  1. 确认时间范围;区间 > 3 个月时分段(季度/月)。
230
282
  2. 按 P1 步骤拿数据,用 `report-templates/google-period-report.md` 模板输出,首行标注统计区间和货币。
231
283
  3. 报告须含:账户概览、投放趋势、Top 关键词/系列/地区分布、优化建议。
@@ -234,6 +286,8 @@ siluzan-tso accounts-digest -m Google -a id1,id2,... --start <S> --end <D> --jso
234
286
 
235
287
  > 适用:账户数 ≥ 2 且需拉取 ≥ 2 个 google-analysis 维度。**禁止**外层 for-loop。
236
288
 
289
+ **必读**:`references/google-analysis-batch.md`、`references/account-analytics.md`、`references/tips.md`。
290
+
237
291
  **入口选择**:全量 → 省略 `-a`;2~10 子集 → `google-analysis -a id1,id2,...`(自动转发 batch);≥10 子集或需 resume → `google-analysis-batch run -a id1,id2,...`
238
292
 
239
293
  1. 反问时间范围 + 维度(默认 `campaigns,geographic,keywords`,可按需追加)。
@@ -264,6 +318,8 @@ siluzan-tso accounts-digest -m Google -a id1,id2,... --start <S> --end <D> --jso
264
318
 
265
319
  > **触发**:用户话术含 `使用okki周报模板` / `OKKI 周报` / `okki 周报` 等,且指向 Google 账户 + 日期区间。
266
320
 
321
+ **必读**:`report-templates/okki-weekly-google-client.md`(全文)、`references/account-analytics.md`、`references/tips.md`。
322
+
267
323
  1. **不要**按 `google-period-report.md` 展开默认 8 维;改读 `report-templates/okki-weekly-google-client.md` 全文并按其结构交付。
268
324
  2. 确认 `mediaCustomerId` 与 `--start` / `--end`(未给齐按「时间范围强制反问」)。
269
325
  3. 同一 `--json-out` 目录执行模板中的命令组合:`list-accounts`(可选但推荐)、`stats`、`balance`、`google-analysis --sections overview,campaigns,keywords,search-terms,campaign-device,campaign-geo`。
@@ -276,6 +332,8 @@ siluzan-tso accounts-digest -m Google -a id1,id2,... --start <S> --end <D> --jso
276
332
  >
277
333
  > **不要**按 `google-period-report.md` 默认 8 维流程;改读 `report-templates/google-inquiry-analysis.md` 全文。
278
334
 
335
+ **必读**:`report-templates/google-inquiry-analysis.md`(全文)、`references/account-analytics.md`、`references/tips.md`、`references/geo-continents.json`(脚本映射用)。
336
+
279
337
  1. **时间窗口强约束**:**严格 3 个月** = 分析月份 + 向前 2 个完整自然月。**禁止**扩展到 7 个月(即使样表是 7 个月);样表 4~7 列旧数据在 Sheet 4/6 跨 7 月写时**留空或不写**,仅写当前 3 月。
280
338
  2. **询盘资料入场**:
281
339
  - **流程 A**(用户已附文件):宿主 Agent 解析任意载体(xlsx/csv/pdf/截图/文本表格)→ 抽取询盘行 → 落盘 `./snap-inquiry/inquiries.json`(字段见模板「询盘字段清单」)。
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "slug": "siluzan-tso",
3
- "version": "1.1.21-beta.5",
4
- "publishedAt": 1779700715977
3
+ "version": "1.1.21-beta.6",
4
+ "publishedAt": 1779702256218
5
5
  }
@@ -1,5 +1,7 @@
1
1
  # CLI 使用技巧:`--json-out` 落盘 + Node.js 精准查询
2
2
 
3
+ > **文档重读(与落盘无关,但同样硬)**:**每个新的用户任务**或**同对话内换话题**时,须按 `SKILL.md`「文档加载纪律」**重新 Read** 当次任务对应的 `references/*.md` / `report-templates/*.md`,再执行 CLI。**禁止**因上一轮已读过某 reference 而跳过(参数、批量命令、Playbook 编号会随任务变化)。
4
+
3
5
  > **AI 助手(本 Skill)**:凡需结构化数据,一律使用 **`--json-out <路径>`**(**目录** 或 **`*.json` 具体文件**)将 JSON 写入磁盘(并更新 **`cli-manifest[-<查询id>].json`**,与 `google-analysis` 的 **`manifest-<accountId>.json`**、`report …` 的 **`report-manifest[-<accountId>].json`** 并存于各自目录),再用 **脚本读文件**(`fs.readFileSync` / `require`)做筛选与聚合;**不要**依赖对话里粘贴的 stdout 整包 JSON。命令成功时 **stdout 仅一行摘要 JSON**(体积小),其中 **`outlineFile`** 指向与当次 `*.json` **同 stem** 的 **`*.outline.txt`**(纯文本单行,接近 **TypeScript 类型字面量**:`{ a: number; b: string }`、`(T | U)[]` 等;数组由**前 8 项**去重推断并集;环 / 同对象再出现为 `any`)。完整数据仍以落盘 `*.json` 为准,类型扫一眼读 outline 文件即可。
4
6
  >
5
7
  > **文件命名规则(重要)**:当一条命令具备明确的"查询 id"(mediaCustomerId / entityId / ruleId / auditId 等)时,目录模式落盘的 `*.json`、`*.outline.txt` 与对应 manifest **都会带上 `-<查询id>` 后缀**:
@@ -9,7 +9,7 @@ $ErrorActionPreference = 'Stop'
9
9
  # -- Package info (injected at build time) ------------------------------------
10
10
  $PKG_NAME = 'siluzan-tso-cli'
11
11
  # PKG_VERSION 锁定到与本脚本同批构建产物一致的版本,避免与 dist/skill 错位
12
- $PKG_VERSION = '1.1.21-beta.5'
12
+ $PKG_VERSION = '1.1.21-beta.6'
13
13
  $CLI_BIN = 'siluzan-tso'
14
14
  $SKILL_LABEL = 'Siluzan TSO'
15
15
  $INSTALL_CMD = 'npm install -g siluzan-tso-cli@beta'
@@ -9,7 +9,7 @@ set -euo pipefail
9
9
  # -- Package info (injected at build time) ------------------------------------
10
10
  readonly PKG_NAME="siluzan-tso-cli"
11
11
  # PKG_VERSION 锁定到与本脚本同批构建产物一致的版本,避免与 dist/skill 错位
12
- readonly PKG_VERSION="1.1.21-beta.5"
12
+ readonly PKG_VERSION="1.1.21-beta.6"
13
13
  readonly CLI_BIN="siluzan-tso"
14
14
  readonly SKILL_LABEL="Siluzan TSO"
15
15
  readonly INSTALL_CMD="npm install -g siluzan-tso-cli@beta"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "siluzan-tso-cli",
3
- "version": "1.1.21-beta.5",
3
+ "version": "1.1.21-beta.6",
4
4
  "description": "Siluzan 广告账户管理 CLI — 查询账户、余额、消耗数据,管理绑定关系与充值。",
5
5
  "keywords": [
6
6
  "ad-account",