ae-team

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

ae-team

ae-team

CRITICAL — Before running any
+<command>
command, you MUST first read the corresponding
references/<command>.md
.
The reference filename equals the command name without the leading
+
, for example
+run-start
references/run-start.md
. CRITICAL — Never guess team IDs, run IDs, or config JSON structures. Always use
+list
or
+list-templates
to discover real resources first. CRITICAL — For the core Agent workflow (find → start → poll → artifacts), follow Workflow A in the Typical Workflows section below.
重要提示 — 运行任何
+<command>
命令前,必须先阅读对应的
references/<command>.md
文档。
参考文件名等于不带开头
+
的命令名,例如
+run-start
references/run-start.md
重要提示 — 切勿猜测团队ID、运行ID或配置JSON结构。 务必先使用
+list
+list-templates
命令发现真实资源。 重要提示 — 对于核心Agent工作流(查找→启动→轮询→获取工件),请遵循下方“典型工作流”部分中的工作流A。

Global AE CLI Rules

AE CLI全局规则

AE CLI (
ae-cli
) is the command-line tool for the AE / TE / ThinkingEngine analysis platform.
Global parameters:
ParameterDescription
--format <json|table>
Output format. Default is JSON.
--jq <expr>
jq filter expression for JSON output.
--host <url>
Override the active AE host. Available on every command and may be placed after the subcommand, e.g.
ae-cli team +<command> --host <url>
.
--yes
Skip confirmation for
high-risk-write
(delete) operations.
--dry-run
Show request details without executing.
Output and errors:
  • Successful commands return machine-readable JSON by default. Envelope may include optional
    _notice.host_compat
    .
  • Failed commands return
    { "ok": false, "error": { "type": "...", "message": "...", "hint": "..." } }
    and exit non-zero.
  • CRITICAL — Host compat (do this first): If stderr or
    _notice.host_compat
    has a version warning, open the user reply with ⚠️ and quote
    npm i -g
    /
    npx skills add
    (or update-cluster) lines verbatim
    , then list projects/results. Never omit when summarizing. Soft tip;
    ok: true
    may still include the notice.
Safety constraints:
  • Read commands (
    +list
    ,
    +list-templates
    ,
    +list-projects
    ,
    +run-result
    ,
    +run-artifacts
    ,
    +ai-generate
    ) can execute directly once required IDs are known.
  • Ordinary
    write
    commands require explicit user intent but no CLI confirmation. Only
    high-risk-write
    commands use the confirmation gate and may receive
    --yes
    after explicit user authorization.
  • Never invent team IDs, run IDs,
    agentId
    values,
    mcpServerIds
    ,
    skillIds
    ,
    knowledgeBaseIds
    , project IDs, or any resource identifiers. Discover them with list commands or accept them from the user.
AE CLI (
ae-cli
) 是AE / TE / ThinkingEngine分析平台的命令行工具。
全局参数:
参数描述
--format <json|table>
输出格式。默认是JSON。
--jq <expr>
用于JSON输出的jq过滤表达式。
--host <url>
覆盖当前活跃的AE主机地址。所有命令均支持该参数,可放在子命令之后,例如
ae-cli team +<command> --host <url>
--yes
跳过
high-risk-write
(删除)操作的确认步骤。
--dry-run
显示请求详情但不执行实际操作。
输出与错误:
  • 成功的命令默认返回机器可读的JSON,返回结果可能包含可选的
    _notice.host_compat
    字段。
  • 失败的命令返回
    { "ok": false, "error": { "type": "...", "message": "...", "hint": "..." } }
    并以非零状态码退出。
  • 重要提示 — 主机兼容性(优先处理): 如果stderr或
    _notice.host_compat
    中存在版本警告,回复用户时需以⚠️开头,并逐字引用
    npm i -g
    /
    npx skills add
    (或update-cluster)的命令行
    ,然后列出项目/结果。总结时切勿遗漏该提示。即使
    ok: true
    也可能包含此通知。
安全约束:
  • 读取类命令(
    +list
    +list-templates
    +list-projects
    +run-result
    +run-artifacts
    +ai-generate
    )在获取所需ID后可直接执行。
  • 普通写入类命令需要明确的用户意图,但无需CLI确认。只有
    high-risk-write
    命令需要确认步骤,且在获得用户明确授权后可使用
    --yes
    参数跳过确认。
  • 切勿编造团队ID、运行ID、
    agentId
    值、
    mcpServerIds
    skillIds
    knowledgeBaseIds
    、项目ID或任何资源标识符。需通过列表命令发现或直接使用用户提供的标识符。

When to Use

使用场景

Use
ae-team
for all AI Agent Team work:
  • Team management: list available teams, create/update/delete a team, generate a team config draft with AI, browse templates.
  • TeamRun execution: start a run, interact in chat mode, cancel a run, reply to a waiting run, poll result until completion, retrieve artifacts.
If the user's intent is data analysis, audience management, metadata governance, or DataOps, switch to
ae-analysis
/
ae-dataops
/
ae-engage
.
使用
ae-team
处理所有AI Agent团队相关工作:
  • 团队管理:列出可用团队、创建/更新/删除团队、通过AI生成团队配置草稿、浏览模板。
  • TeamRun执行:启动运行、对话模式交互、取消运行、回复处于等待状态的运行、轮询结果直至完成、获取工件。
如果用户的需求是数据分析、受众管理、元数据治理或DataOps,请切换至
ae-analysis
/
ae-dataops
/
ae-engage
工具。

Command Format

命令格式

bash
ae-cli team +<command> [options]
All commands live under the
team
service. Quick help:
bash
ae-cli team --help
ae-cli team +list --help
ae-cli team +run-start --help
bash
ae-cli team +<command> [options]
所有命令都隶属于
team
服务。快速获取帮助:
bash
ae-cli team --help
ae-cli team +list --help
ae-cli team +run-start --help

Tool Groups (13)

工具组(13个)

Team Management (7)

团队管理(7个)

  • +list
    (doc) — list all visible teams
  • +create
    (doc) — create a new team with a TeamConfig
  • +update
    (doc) — patch one or more fields of an existing team
  • +delete
    (doc) — delete a team (409 if runs are active)
  • +ai-generate
    (doc) — AI-generate a team config draft from a goal description
  • +list-templates
    (doc) — browse built-in team templates
  • +list-projects
    (doc) — list projects available to the current user
  • +list
    (文档) — 列出所有可见团队
  • +create
    (文档) — 使用TeamConfig创建新团队
  • +update
    (文档) — 修改现有团队的一个或多个字段
  • +delete
    (文档) — 删除团队(若存在活跃运行则返回409错误)
  • +ai-generate
    (文档) — 根据目标描述通过AI生成团队配置草稿
  • +list-templates
    (文档) — 浏览内置团队模板
  • +list-projects
    (文档) — 列出当前用户可用的项目

TeamRun Execution (7)

TeamRun执行(7个)

  • +run-start
    (doc) — start a new TeamRun
  • +run-watch
    (doc) — stream a TeamRun via SSE (preferred over polling)
  • +run-chat
    (doc) — chat with a team (multi-turn, auto-resume)
  • +run-cancel
    (doc) — cancel a running TeamRun
  • +run-reply
    (doc) — reply to a run in
    waiting_user
    state
  • +run-result
    (doc) — get the full result of a TeamRun (fallback polling)
  • +run-artifacts
    (doc) — list artifacts produced by a TeamRun
  • +run-start
    (文档) — 启动新的TeamRun
  • +run-watch
    (文档) — 通过SSE流式传输TeamRun(优先于轮询方式)
  • +run-chat
    (文档) — 与团队对话(多轮次、自动恢复)
  • +run-cancel
    (文档) — 取消正在运行的TeamRun
  • +run-reply
    (文档) — 回复处于
    waiting_user
    状态的运行
  • +run-result
    (文档) — 获取TeamRun的完整结果(备用轮询方式)
  • +run-artifacts
    (文档) — 列出TeamRun生成的工件

TeamRun Status Reference

TeamRun状态参考

StatusDescription
pending
Queued, waiting to start
running
Actively executing
waiting_user
Paused —
+run-watch
exits with code 2; read
pendingQuestion
from stdout, present to user, then call
+run-reply
waiting_approval
Paused — waiting for approval
paused
Manually paused
completed
Finished successfully
failed
Execution failed
cancelled
Cancelled by user
Terminal statuses:
completed
,
failed
,
cancelled
. Poll
+run-result
until one of these is reached.
状态描述
pending
已排队,等待启动
running
正在执行
waiting_user
已暂停 —
+run-watch
以状态码2退出;从stdout读取
pendingQuestion
并展示给用户,然后调用
+run-reply
waiting_approval
已暂停 — 等待审批
paused
手动暂停
completed
执行成功完成
failed
执行失败
cancelled
被用户取消
终端状态:
completed
failed
cancelled
。需轮询
+run-result
直至进入上述状态之一。

Typical Workflows

典型工作流

Workflow A — Start an existing team and wait for results

工作流A — 启动现有团队并等待结果

bash
undefined
bash
undefined

1. Discover available teams

1. 发现可用团队

ae-cli team +list
ae-cli team +list

2. (Optional) Discover project IDs if needed

2. (可选)若需要则发现项目ID

ae-cli team +list-projects
ae-cli team +list-projects

3. Start a run

3. 启动运行

ae-cli team +run-start --team-id <team_id> --input "分析上周用户留存数据"
ae-cli team +run-start --team-id <team_id> --input "分析上周用户留存数据"

4. Stream until done (blocks; no polling needed)

4. 流式传输直至完成(阻塞;无需轮询)

ae-cli team +run-watch --id <run_id>
ae-cli team +run-watch --id <run_id>

exit 0 → completed/partial_success → go to step 5

退出码0 → 完成/部分成功 → 进入步骤5

exit 1 → failed/cancelled → inspect errorMessage in output, report to user

退出码1 → 失败/取消 → 检查输出中的errorMessage并告知用户

exit 2 → waiting_user → go to step 4a

退出码2 → waiting_user → 进入步骤4a

4a. Handle waiting_user: read pendingQuestion from stdout, get user's answer, reply, re-watch

4a. 处理waiting_user状态:从stdout读取pendingQuestion,获取用户回答,回复后重新监听

ae-cli team +run-reply --id <run_id> --input "<user_answer>" ae-cli team +run-watch --id <run_id> # repeat until exit 0 or 1
ae-cli team +run-reply --id <run_id> --input "<user_answer>" ae-cli team +run-watch --id <run_id> # 重复直至退出码为0或1

5. Retrieve artifacts

5. 获取工件

ae-cli team +run-artifacts --id <run_id> --include-content true
undefined
ae-cli team +run-artifacts --id <run_id> --include-content true
undefined

Workflow B — AI-generate a config, then create and run

工作流B — AI生成配置,然后创建并运行

bash
undefined
bash
undefined

1. Generate a draft config

1. 生成配置草稿

ae-cli team +ai-generate --prompt "需要一个分析用户行为并自动生成留存报告的团队"
ae-cli team +ai-generate --prompt "需要一个分析用户行为并自动生成留存报告的团队"

2. Create the team (paste / adjust the returned config)

2. 创建团队(粘贴/调整返回的配置)

ae-cli team +create --name "留存分析团队" --config '<config_json>'
ae-cli team +create --name "留存分析团队" --config '<config_json>'

3. Start a run

3. 启动运行

ae-cli team +run-start --team-id <new_team_id> --input "分析本月留存"
undefined
ae-cli team +run-start --team-id <new_team_id> --input "分析本月留存"
undefined

Workflow C — Multi-turn chat

工作流C — 多轮对话

bash
undefined
bash
undefined

First turn

第一轮对话

ae-cli team +run-chat --team-id <team_id> --input "帮我分析DAU趋势"
ae-cli team +run-chat --team-id <team_id> --input "帮我分析DAU趋势"

If run status is waiting_user, reply:

如果运行状态为waiting_user,则回复:

ae-cli team +run-reply --id <run_id> --input "请重点分析周末下降原因"
ae-cli team +run-reply --id <run_id> --input "请重点分析周末下降原因"

Continue same session

继续同一会话

ae-cli team +run-chat --team-id <team_id> --session-id <session_id> --input "给出优化建议"
undefined
ae-cli team +run-chat --team-id <team_id> --session-id <session_id> --input "给出优化建议"
undefined

Workflow D — Use a template to create a team

工作流D — 使用模板创建团队

bash
undefined
bash
undefined

1. Browse templates

1. 浏览模板

ae-cli team +list-templates --locale zh
ae-cli team +list-templates --locale zh

2. Create from a template's config

2. 使用模板配置创建团队

ae-cli team +create --name "我的分析团队" --config '<template_config>'
undefined
ae-cli team +create --name "我的分析团队" --config '<template_config>'
undefined

Quick Verification

快速验证

bash
ae-cli team --help
bash
ae-cli team --help