Skip to content

The Workflow at a Glance ​

Six steps ​

A Context task follows the same six steps whether it covers one document set or several repositories. You talk to the Agent; the Agent follows the workflow the CLI returns.

mermaid
flowchart LR
  s1["1 Install"] --> s2["2 Initialize"]
  s2 --> s3["3 Research and plan"]
  s3 -->|work-start report| s4["4 Produce"]
  s4 --> s5["5 Review and preview"]
  s5 -->|revise| s4
  s5 -->|approve| s6["6 Build and commit"]
StepWhat you doWhat happens
1 InstallInstall the CLI and plugin onceEntries appear in your Agent host; see Installation
2 InitializeAsk /c4a:context to create a Context knowledge workspace in a directoryThe CLI creates src/, sources/, knowledge/ and the guidance in AGENTS.md
3 Research and planDescribe the knowledge, its sources and its intended form, then answer the Agent's questionsThe Agent registers sources, investigates them and presents a work-start report: confirmed configuration and scope, the planned content, and the expected package or site layout
4 ProduceWait, or ask for a local preview at any timeThe Agent writes articles bound to source evidence and reports progress against the task count
5 Review and previewRead the review report and approve, reject or ask for revisionsApproved candidates become durable Markdown under knowledge/
6 Build and commitConfirm the package and other outputsContext verifies and builds; the Agent commits the knowledge workspace to Git

What to expect ​

Production is the longest step: on average each writing task takes about a minute. Ask for a preview whenever you want to see pages in a browser. The work-start report and the review report are the two moments where your judgment shapes the result most; the Guides section on review explains what to look for.

Production, updates and questions ​

The six steps describe a first production round. Two other paths reuse the same knowledge workspace:

  • Updates. Building completes the currently approved state; it does not freeze the knowledge workspace. When sources change, a new round reopens only the affected knowledge. See Keeping Knowledge Current.
  • Questions. /c4a:context-inspect-search answers questions from knowledge packages or approved knowledge in the knowledge workspace and traces each answer back to its sources.

Why you can stop and resume ​

Each step is chosen from the knowledge workspace's actual state, not from the conversation. After every action the CLI observes the knowledge workspace again and returns the current step, its required reading and the exact commands. If you close the conversation and invoke /c4a:context later, it resumes where the work actually is. See Workflow Execution.

工作流概览 ​

六个步骤 ​

无论只涉及一套文档还是多个仓库,Context 任务都遵循相同的六个步骤。你和 Agent 对话;Agent 按 CLI 返回的工作流执行。

mermaid
flowchart LR
  s1["1 安装"] --> s2["2 初始化"]
  s2 --> s3["3 调研与计划"]
  s3 -->|"开工报告"| s4["4 生产"]
  s4 --> s5["5 审核与预览"]
  s5 -->|"修订"| s4
  s5 -->|"批准"| s6["6 构建与提交"]
步骤你要做的发生了什么
1 安装一次性安装 CLI 和插件入口出现在 Agent 宿主中;参见安装
2 初始化让 /c4a:context 在某个目录创建 Context 知识工作区CLI 创建 src/、sources/、knowledge/,以及 AGENTS.md 中的指引
3 调研与计划描述所需知识、来源和预期形态,并回答 Agent 的问题Agent 登记来源、展开调研,并给出开工报告:已确认的配置与范围、计划内容,以及预期的知识包或站点结构
4 生产等待,或随时要求本地预览Agent 撰写绑定来源证据的文章,并按任务数汇报进度
5 审核与预览阅读审核报告,选择批准、拒绝或要求修订已批准的候选成为 knowledge/ 下持久保存的 Markdown
6 构建与提交确认知识包及其他产物Context 验证并构建;Agent 把知识工作区提交到 Git

预期耗时 ​

生产是耗时最长的一步:平均每个写作任务约一分钟。想在浏览器里查看页面时,随时可以要求预览。开工报告和审核报告是你的判断对结果影响最大的两个时刻;指南中关于审核的章节说明了需要关注什么。

生产、更新与提问 ​

上述六个步骤描述的是首轮生产。另有两条路径复用同一个知识工作区:

  • 更新。 构建只是完成当前已批准的状态,并不会冻结知识工作区。来源变化时,新一轮只重新打开受影响的知识。参见知识的持续更新。
  • 提问。 /c4a:context-inspect-search 基于知识包或知识工作区中已批准的知识回答问题,并把每个答案追溯到来源。

为什么可以随时中断和恢复 ​

每一步都根据知识工作区的实际状态选出,而不是根据对话内容。每次动作之后,CLI 都会重新观察知识工作区,返回当前步骤、必读内容和确切命令。即使关闭对话,之后再调用 /c4a:context,也会从工作实际所处的位置继续。参见工作流运行。