workflow
它能做什么
这项技能教智能体如何在编程会话内部,逐步运行团队工作流。它会遵循 TeamAI 打印出的命令,并在运行过程中让用户随时了解情况。
适用场景
- ✓当生成的工作流技能让智能体去运行某个团队工作流的时候。
- ✓当用户要求在本次会话中运行团队工作流的时候。
- ✓当工作流运行需要用户回答一个问题才能继续的时候。
技能链接
https://github.com/Tencent/teamai-cli/blob/main/skill-data/workflow/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请在这次会话中运行我拿到的团队工作流,并在每个步骤告诉我进展。”
每周 5 个新技能,1 分钟读完。
工作原理
智能体会以描述模式启动工作流,把用户必须回答的问题告知用户,然后按顺序运行打印出的命令。分离式运行器和子智能体负责执行工作步骤。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Drive a team workflow
Your role
You orchestrate. You run the literal commands the CLI prints, and you keep the person told while the run goes on. Detached runners do each command step; a child agent you start does each prompt step from its brief. Step work belongs to them, and yours is the literals and the person. On h4, where your host starts no child, you work each prompt step yourself, as the Dispatch section says. The run's state lives in the CLI: every reply says what is running and what to run next, so you carry nothing between calls. Never run git in a workflow place; the CLI prepares and checks each place a step runs in.
Start
Run teamai workflow start --describe <name> --driver skill with the workflow name from the skill that sent you. Where this machine runs teamai through npx teamai-cli, use that in its place; every literal the CLI prints after this already does.
Act on data.describe.ask.kind:
start: tell the personask.saywhen the reply has it, then runask.start. In an unattended run (CI, a cloud agent) describe never asks the person; whenask.inputsis listed, fill{inputs}inask.startwith their values from your task, as one JSON object. The slot sits inside single quotes, so write each'in that JSON as'\''.ask: the question is the person's to answer, once, so the run goes on without them after. In one message, give themask.question.textas it is, each entry ofask.question.inputs, and thelabelof each option as their choices. An entry with avalueis a proposal: show it with itswhy, and say they may keep, change or empty it. An entry without one is theirs to fill in. Wait for their pick, also when an option is marked recommended. In thestartof the option they pick, replace{inputs}with their answers as one JSON object, each'in it written as'\'', and run it. Those options are the whole choice: when the person wants a start none of them offers, show them the options again.local: tell the personask.reasonand give themask.startfor their own terminal. It is theirs to run.denied: tell the personask.reason. Nothing is left to run here.tool: this session names no tool, and the run needs one. Inask.describe, replace{tool}with the entry ofask.toolsfor the tool you work in, run it, and act on its reply instead. When none of them is the tool you work in, tell the personask.reason.
Done when a reply carries data.turn with a run id, or the person has ask.reason.
The loop
A turn lists the actions that wait for you, the running attempts, the events since your last call, and then. When nothing runs, waiting.reason says why.
- Act on each action by its
kind:choose,person,stop,dispatch,placeordone, as their sections say. - Tell the person in one line what the events say: a step
started,restarted,settledwith its outcome, orstoppedwith itswhy, a gate wasanswered, or this session took the run over (takeover). Tell themwaiting.reasonwhen it changes. Forjudging,judgedandjudging-off, followreferences/judging.md. - Run
then.runof the newest turn you have:poll: in the background when your host can, so you stay free to talk with the person; otherwise in the foreground. It exits with the next turn once something changes, or after a bounded wait. Keep one poll of the run going at a time.wake: in the foreground. Work waits for you, and the turn it returns carries it.
- Repeat with that turn.
Done when a turn has no then.
In an unattended run nobody reads you: step 2 is for your own log, and you ask nothing. Keep running then until a turn has none, also after done while it carries judging, so the judge's label lands before your session ends.
Run teamai score --drain before your session ends.
An unattended session that reaches a handoff reports that the run waits for a person, and stops.
When you have lost the last turn, after a compaction or in a new session, run teamai workflow next <run> --driver skill once for the current one.
A report you run answers with data.runner, not a turn. After one, go on with then of your newest turn.
Choose
A choose action asks for one answer, and about says what it is for:
host: comes once per run that has prompt steps, or that you judge. Followreference: it says which option fits your host and how to run it.gate: an optional approval or
常见问题
我需要运行 git 命令吗?
不需要。这项技能说明 CLI 会为每个步骤的运行位置做好准备并检查,因此工作流步骤中不运行 git。
两次消息之间智能体会记得这次运行吗?
不会。这项技能说明运行状态保存在 CLI 中,每次回复都会说明接下来要运行什么。
如果宿主环境无法启动子智能体怎么办?
这项技能说明,此时智能体会自己处理每个提示步骤。
详情
作者的原始描述
Drive a team workflow from this coding session. Use when a generated workflow skill (workflow-<alias or name>, or a teamai default such as teamai-share-learnings) sent you here, or the person asks to run a team workflow.
repo: Tencent/teamai-cli
热度
- GitHub 星标
- 5.7k
- 排名
- #14746
- 许可证
- —
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
core
5.7k帮你的智能体通过拉取和推送,同步团队共享的 AI 技能和规则,检查其状态,运行健康检查,并调用其他 TeamAI 工作流。
setup
5.7k帮你的智能体为团队设置 TeamAI,可以作为管理员创建新的团队仓库,也可以加入已有的仓库,并管理成员、角色和移除。
share
5.7k帮你的智能体把编程会话中学到的内容整理成简短的团队学习笔记,并通过 teamai contribute 命令发布到团队知识库。
wiki
5.7k帮你的智能体把庞大的多仓库代码库整理为结构化的知识库,其中每个结论都链接到它所来自的代码行。