# 创建 Automation (/zh/work/automation/create-an-ai-automation)



当一个循环反复出现时，就适合创建 automation：检查来源、判断什么重要、写出或更新结果、继续跟进，并把结果带回团队。

<LivePreview component="AutomationView" />

<Steps>
  <Step>
    ### 打开 Automations 并选择创建方式 [#打开-automations-并选择创建方式]

    从侧边栏打开 **Automations**。如果你想用自然语言描述整个流程，选择 **Create via Chat**。如果你已经知道名称、执行者、工作流、时间表和交付位置，选择 **Create manually**。

    <LivePreview component="AutomationView" />
  </Step>

  <Step>
    ### 在 chat 里描述完整循环 [#在-chat-里描述完整循环]

    如果选择 chat，一条消息里要包含五件事：检查什么来源、判断规则是什么、产出什么、什么时候运行、结果交付到哪里。

    示例：

    > Every weekday at 9am, check #product-updates for shipped changes since yesterday, write a one-paragraph summary, and post it to #standup. If nothing changed, skip the post.

    <LivePreview component="NewThread" />
  </Step>

  <Step>
    ### 信息明确时填写手动表单 [#信息明确时填写手动表单]

    如果选择手动创建，填写简短名称，选择负责执行的 AI 队友，并写好 workflow document。workflow document 里要说明检查什么、做什么判断、产出什么、汇报到哪里。

    <LivePreview component="AutomationView" scenario="{ manualCreateOpen: true, manualCreateDraft: { name: &#x22;Daily product update scan&#x22;, instructions: &#x22;Check the agreed sources, decide what changed, write the update, and deliver it to the team channel.&#x22; } }" />
  </Step>

  <Step>
    ### 设置触发时间，交付目标写进 workflow [#设置触发时间交付目标写进-workflow]

    用排程控件选择 automation 什么时候运行。表单里没有交付目标字段——结果发到哪里是写在 workflow document 里的，所以要在那里写明执行者能访问的频道、文档、任务或其他目标，不要停留在隐含状态。只有准备好第一次运行时，才保持 **Enabled** 开启。

    <LivePreview component="AutomationView" scenario="{ select: &#x22;auto_digest&#x22; }" />
  </Step>
</Steps>

<Callout type="info">
  workflow document 是后续每次运行的依据。以后要改变 automation 的行为，应修改文档，而不是依赖某次 chat 里的临时说法。
</Callout>

## 启用前检查 [#启用前检查]

* 执行的 AI 队友能访问所有需要读取的来源。
* 交付目标是明确且可访问的。
* workflow 写清楚了没有内容可汇报时该怎么办。
* 运行时间符合团队所在时区。
* 有真人 owner 知道运行结果和失败状态会出现在哪里。

<Cards>
  <Card title="触发器和时间表" href="/work/automation/triggers-and-schedules" description="详细了解定时运行和事件触发。" />

  <Card title="管理 automations" href="/work/automation/manage-ai-automations" description="创建后编辑、暂停或查看运行记录。" />
</Cards>
