build-agent

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Build Agent

构建 Agent

Turn something the owner does every week into something they ask for by name.
This is what keeps the plugin from having to ship every industry's workflow. No catalog can cover a septic contractor's permit routine or an insurance agency's carrier commission reconciliation. Those owners can build them.
将负责人每周都会做的事情,变成可以按名称直接调用的东西。
这样,plugin 就不必为每个行业的 workflow 都提供现成实现。再全面的目录也不可能覆盖化粪池承包商的许可流程,也不可能覆盖保险代理机构的 carrier 佣金对账。但这些负责人可以自行构建。

Step 1 — Watch it happen, or hear it described

第 1 步——观察执行过程,或听取描述

Two starting points, and the first is much better.
Best: they just did it in this conversation. If the owner has walked through the task with you — pulled the files, made the decisions, corrected you twice — that transcript is the specification. Extract it rather than re-interviewing them. The corrections they made are the most valuable part, because they encode judgment the owner would never have thought to state.
Otherwise: they describe it. Ask them to walk through the last time they did it, concretely. Real specifics beat an abstract description every time — "last Tuesday I pulled the carrier file, matched it against what we'd booked, and chased six discrepancies" tells you more than "I reconcile commissions."
Read
reference/capture.md
for how to get a complete picture without an interrogation.
有两种起步方式,第一种明显更好。
最佳方式:他们刚刚在当前对话中已经做过一遍。 如果负责人刚刚和你一起完整演示过这项任务——拉取文件、做出决策、纠正了你两次——那么这段对话记录就是规格说明。直接从中提取信息,不要再重新访谈负责人。他们作出的纠正最有价值,因为其中包含了负责人自己都想不到需要说明的判断依据。
否则:由他们描述。 请他们具体讲讲最近一次执行这项任务时的实际过程。具体的细节永远胜过抽象描述——“上周二,我拉取了 carrier 文件,将它与我们已经入账的数据进行了核对,并追查了六处差异”,比“我负责佣金对账”提供的信息更多。
阅读
reference/capture.md
,了解如何在不盘问对方的情况下获得完整信息。

Step 2 — Separate what varies from what stays fixed

第 2 步——区分会变化的内容与保持固定的内容

This is the whole craft of the step. A skill that hardcodes last Tuesday's specifics only works on last Tuesday.
For each part of the task, decide:
  • Fixed — the sequence, the sources, the output format, the rules
  • Varies — dates, names, amounts, which file, which customer
  • Judgment — the parts where the owner decides, which become approval gates
The corrections the owner made while walking through it usually mark the judgment points. When someone says "no, not that one — we skip anything under USD 50," that is a rule. When they say "hmm, depends," that is an approval gate.
这一步的关键全在于此。一个把上周二的具体信息硬编码进去的 skill,只会适用于上周二。
对于任务的每个部分,分别判断:
  • 固定——步骤顺序、数据来源、输出格式、规则
  • 变化——日期、名称、金额、使用哪个文件、哪个客户
  • 判断——需要负责人作决定的部分,它们会转化为 approval gate
负责人在演示过程中作出的纠正,通常会标出判断点。当有人说“不,不是那个——低于 USD 50 的都跳过”时,这是一条规则;当他们说“嗯,要看情况”时,这就是一个 approval gate。

Step 3 — Find the approval gates

第 3 步——找出 approval gate

Every step that sends, spends, publishes, or deletes needs a gate. So does every step where the owner hesitated.
Do not gate everything — a skill that asks permission nine times is worse than doing it by hand. Gate the consequential and the ambiguous, and let the rest run.
Read
reference/skill_authoring.md
for where gates belong and how to phrase them.
每一个会发送内容、产生支出、发布内容或删除内容的步骤,都必须设置 approval gate。负责人执行时曾犹豫过的每一步也一样。
不要给所有步骤都加 approval gate——一个请求九次许可的 skill,比手动执行还糟糕。只为后果重大或有歧义的步骤设置 approval gate,让其余步骤自行运行。
阅读
reference/skill_authoring.md
,了解 approval gate 应设置在哪些位置,以及应该如何措辞。

Step 4 — Write it

第 4 步——编写

Produce a real skill in the same shape as everything else in this plugin: a
SKILL.md
with frontmatter and numbered steps, plus a
reference/
folder if the detail warrants it.
Requirements it must meet, same as every shipped skill:
  • Name and folder match, lowercase with hyphens
  • Description says what it does and when to trigger, in third person
  • A real fallback for when a connector is missing
  • Approval gates on anything consequential
  • Never invents a number; missing data is reported as missing
Write it in the owner's terms, not in generic business language. If they call it "the carrier file," the skill says carrier file. A skill full of unfamiliar vocabulary is one they will not trust to run unattended.
沿用此 plugin 中所有其他 skill 的相同结构,产出一个真正可用的 skill:一个包含 frontmatter 和编号步骤的
SKILL.md
,并在细节确有需要时附加
reference/
文件夹。
它必须满足与所有已发布 skill 相同的要求:
  • 名称与文件夹名称匹配,使用小写字母和连字符
  • description 说明它做什么以及何时触发,并使用第三人称
  • connector 缺失时,提供真正可用的 fallback
  • 对任何可能产生实际后果的步骤设置 approval gate
  • 绝不编造数字;缺失的数据必须报告为缺失
使用负责人熟悉的说法,而不是泛泛的商业语言。 如果他们称其为“carrier 文件”,skill 中也应写 carrier 文件。一个满是陌生词汇的 skill,负责人不会愿意在无人值守时运行它。

Step 5 — Test it on a real case, before they rely on it

第 5 步——在他们依赖 skill 之前,用真实案例进行测试

Run the new skill against a case the owner already knows the answer to — ideally the exact one they walked through. Show the output next to what they got by hand.
This is the step that determines whether the skill gets used. An owner who has seen it reproduce a known-good result will schedule it. One who hasn't will run it manually and check it every time, which saves nothing.
If it doesn't match, fix the skill and run it again. Do not ask the owner to accept a near-miss.
用负责人已经知道正确结果的案例运行新 skill——最好就是刚才逐步演示过的那个案例。将输出与手动得到的结果并排展示。
这一步决定 skill 最终会不会被用起来。负责人亲眼看到它复现了已知正确的结果后,才会为它设置定时执行。没有见过的人每次都会手动运行并逐一核查,这等于什么都没有节省。
如果不匹配,修复 skill 后重新运行。不要让负责人接受一个仅仅近似的结果。

Step 6 — Register and set the cadence

第 6 步——注册并设置执行节奏

Add it to
smb-router
so plain-English requests reach it, and record the trigger phrases the owner actually uses.
If it is a recurring task, offer to schedule it. Scheduling is what converts "a skill I could run" into "something that happens without me," which is the outcome they wanted.
将它添加到
smb-router
,让日常语言请求能够路由到它,并记录负责人真正会使用的触发语句。
如果这是周期性任务,询问是否为其设置定时执行。定时执行才能将“我可以运行的 skill”变成“无需我参与就会发生的事情”,而后者正是负责人想要的最终结果。

Step 7 — Share it, with approval

第 7 步——经批准后共享

Offer to share with the team. Say what sharing means: who gets it, what data it can reach, and what it can do unattended.
Be specific about the risk when a skill sends, spends, or writes. A skill that emails customers, running for someone who did not build it and does not know its assumptions, is a real hazard. Recommend draft-only for shared skills that send anything.
向负责人提议与团队共享,并明确说明共享意味着什么:谁会获得该 skill、它可以访问哪些数据,以及它可以在无人值守时执行哪些操作。
当 skill 会发送内容、产生支出或写入数据时,必须具体说明风险。 一个会向客户发送邮件的 skill,如果由既非创建者、又不了解其假设的人来运行,就会构成实际危险。对于会发送任何内容的共享 skill,建议仅生成草稿(draft-only)。

What not to do

不要做什么

  • Do not re-interview about a task they just walked through. The transcript is the spec.
  • Do not hardcode the example. Names, dates, and amounts vary; the sequence does not.
  • Do not gate every step. Nine approvals is worse than doing it by hand.
  • Do not skip the test run. An untested skill gets checked manually forever, which saves nothing.
  • Do not write it in generic business language. Their words, or they won't trust it.
  • Do not build something that sends or spends without approval gates. Ever, regardless of what the owner asks for.
  • 不要再访谈他们刚刚逐步演示过的任务。 对话记录就是规格说明。
  • 不要硬编码示例。 名称、日期和金额会变化,步骤顺序不会。
  • 不要给每一步都设置 approval gate。 九次审批比手动执行更糟糕。
  • 不要跳过测试运行。 未测试的 skill 会被永远手动核查,等于没有节省任何工作。
  • 不要使用泛泛的商业语言来编写它。 要用他们自己的话,否则他们不会信任它。
  • 绝不要构建任何缺少 approval gate 就会发送内容或产生支出的功能。 无论负责人提出什么要求,都必须如此。

After the build

构建完成后

The owner now has a named skill they can trigger or schedule. If the new skill hit a tool that isn't connected, "connect to my ERP" (
build-connector
) is the natural next step — it turns the missing system into a working source. Also nearby: "brief me" to fold the new output into the daily picture, and "Monday brief" if the skill should feed the weekly one. Offer at most three, and skip any offer the owner already declined this session.
负责人现在拥有一个具名 skill,可以按名称调用或设置定时执行。如果新 skill 调用了尚未连接的 tool,“连接到我的 ERP”(
build-connector
)是自然的下一步——它能把缺失的系统接入为可用数据源。另外还有两个相关功能:“向我汇报”(brief me)可将新输出纳入每日工作概览;如果该 skill 应为每周简报提供输入,还可以使用“周一简报”(Monday brief)。最多推荐三个,并跳过本次会话中已经被负责人拒绝的建议。

Reference files

参考文件

  • reference/capture.md
    — getting a complete picture of the task without an interrogation
  • reference/skill_authoring.md
    — the structure, frontmatter, and where approval gates belong
  • reference/gotchas.md
    — the failure modes that produce a skill nobody uses
  • reference/capture.md
    ——在不盘问对方的情况下获取任务的完整信息
  • reference/skill_authoring.md
    ——结构、frontmatter,以及 approval gate 的放置位置
  • reference/gotchas.md
    ——导致 skill 无人使用的失败模式