news 2026/8/30 7:28:18

【AI原生研发转型·第4篇】没有计划不写码,机构知识变成文件

作者头像

张小明

前端开发工程师

1.2k 24
文章封面图
【AI原生研发转型·第4篇】没有计划不写码,机构知识变成文件

系列导语:本系列基于 Anthropic《The AI-Native SDLC Playbook》改写,保留 Claude Code / Claude Tag / MCP 等原品牌名。前几篇讲了意图和设计,这篇进第三阶段Build——最"重"的一个,也是最值得啃的。
《The AI-Native SDLC Playbook》相关文章链接:https://blog.csdn.net/justlookxia/article/details/164093318


agent 唰一下吐出大半个 diff,你敢直接合吗?

AI-native 的 Build 阶段,核心就一句话:没有"被接受的计划"就不实现;机构知识变成文件;护栏跑在代码层。


a) plan mode 当默认起点

传统:工程师读设计直接写码,计划只在脑中或工单里,评审看到 diff 才改。
AI-native:开plan mode,让 Claude 产出plan.md——可以查代码、但不改代码。
你审的是"计划",不是"改完的 diff"。审完提交,再去实现。

一份plan.md长这样:

# Plan: claims status self-service (from intent.md 2026-06-02) ## Files that change portal/src/claims/StatusPanel.tsx (new), claims-api/routes/status.py, claims-api/tests/test_status.py ## Order of work 1. Add the status endpoint behind existing auth. 2. Panel against the endpoint. 3. Wire into the portal nav. ## Risks The claims-core API rate-limits at 50 rps; the panel must cache. ## Proof test_status.py covers the four claim states; screenshot matches the approved mock.

b) auto mode:护栏成熟后默认自动

计划被批准后,Claude 可以进入auto mode自动改代码。
前提是护栏已经调熟——CLAUDE.md、skills、hooks、测试都到位。
成熟之后,例常工作默认 auto-accept,再配合worktrees并行推进多个特性。


c) 旁注:定好"事实源"

每个 artifact 都要声明"哪个系统是唯一事实源":repo 为源 / 旧系统(如 Jira)为源(通过 MCP connector 写回)/ 或只放最低限度链接。不要让两份东西"都算数"。


d) CLAUDE.md:给 agent 的"新人手册"

把"新人不说就懂"的上下文写进去——命令、架构、易错点。
/init生成 → 剪到一页以内→ 提交仓库根 → 凡 Claude 错两次的,写进文件。

# Payments service ## Commands - Build: make build - Test: make test (unit), make itest (integration, needs docker) - Lint: make lint (runs in CI; fix before pushing) ## Conventions - Java 21, Spring Boot 3. No new Lombok. - Money is always BigDecimal, never double. - Every endpoint needs an integration test in src/itest. ## Architecture - api/ holds REST controllers, core/ holds domain logic, adapters/ talks to external systems. - Kafka events are defined in schemas/; never edit generated classes. ## Things Claude gets wrong - Do not bump dependency versions; the platform team owns them. - The legacy v1/ package is frozen; changes go in v2/.

e) Skills 即机构知识

把"我们怎么做 XX"封装进SKILL.md,放.claude/skills/<name>/或走插件分发。
例如一个 API 安全审查 skill:

--- name: secure-api-review description: Apply the API security standard. Use whenever creating or modifying an external-facing endpoint, reviewing API code, or generating an OpenAPI spec. --- # Secure API review When you create or change an API endpoint: 1. Authentication: every endpoint requires the gateway JWT; no anonymous routes outside /health. 2. Input validation: validate request bodies against the OpenAPI schema and reject unknown fields. 3. Audit: every state-changing endpoint emits an audit event with actor, action, entity and timestamp. 4. Data classification: fields tagged pii in the schema must never appear in logs or error messages. Run scripts/check-endpoints.sh and include its output in your summary.

f) Hooks:构建期的确定性护栏

挡住对保护路径的编辑、跑 formatter/linter、挡住密钥进 diff。被"背书"的 skill,必须有 hook 或 PR 复查兜底。


g) 并行会话与子智能体

并行会话 = 独立的 Claude Code 实例 + git worktree(claude --worktree feature-auth)。子智能体在.claude/agents/定义,比如一个只"验工不修"的 verifier:

--- name: verifier description: Runs the app and checks the change works before the session reports done tools: Bash, Read --- Start the app with make run. Exercise the changed behavior and the two nearest neighboring flows. Report what you ran, what you saw, and any behavior that does not match plan.md. Do not fix anything; report only.

下篇预告

第 5 篇Test:怎么让 agent 在把成果交给你之前,自己先验收一遍——反馈回路 + CI 里的持续 evals。

系列文快链:
  1. 【AI原生研发转型·第1篇】为什么你的AI写码很快,团队却还是慢?
  2. 【AI原生研发转型·第2篇】想法不该等人写文档:用intent.md把意图一次性钉死
  3. 【AI原生研发转型·第3篇】需求与设计合体:一次会话出spec.md
  4. 【AI原生研发转型·第4篇】没有计划不写码,机构知识变成文件
  5. 05-08待发布

原文出处:https://claude.com/blog/the-ai-native-sdlc-playbook (Louis Claxton, 2026-08-21, Anthropic)
系列索引:① 总论 · ② Plan · ③ Design · ④ Build(本篇)· ⑤ Test · ⑥ Deploy · ⑦ Maintain · ⑧ 番外
本系列为外部技术博客的改写,保留原品牌名,仅供团队学习交流。

版权声明: 本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若内容造成侵权/违法违规/事实不符,请联系邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
网站建设 2026/8/30 8:00:10

开发者博客停更后如何重启?从11000关注者账号出发的完整行动方案

很多开发者都会在某个阶段遇到这样的问题&#xff1a;自己的博客曾经认真写了很久&#xff0c;也积累了上万关注者&#xff0c;但在某一天之后突然就停更了。停更的理由可能有很多&#xff0c;比如工作太忙、觉得没有反馈、失去兴趣、不知道写什么&#xff0c;甚至是被生活推着…

作者头像 李华
网站建设 2026/8/29 5:00:50

用Gemini API构建法律合同自动审查与知识库增强系统

这次我们来关注一个产品方向&#xff0c;而不是单纯某个模型版本&#xff1a;Google 把 Gemini 的能力直接下沉到了法律垂直场景&#xff0c;推出了 Gemini Enterprise for Legal。从公开信息看&#xff0c;它并不是简单地把通用聊天机器人换个皮套在律所里&#xff0c;而是围绕…

作者头像 李华
网站建设 2026/8/30 7:53:38

时间黑客编程大赛复赛复盘:算法策略、时间管理与提分技巧

那场比赛我印象太深了。倒计时界面跳到00:00:00的时候&#xff0c;我提交的最后一版代码刚好过了大样例&#xff0c;排名停在晋级线附近。说实话&#xff0c;最后五分钟改的那个优化纯粹是直觉带着走&#xff0c;连我都没把握它一定能过&#xff0c;但线上判题就是这么残酷——…

作者头像 李华
网站建设 2026/8/30 7:31:15

从网易运维笔试卷看系统运维核心能力与实战排查思路

说实话&#xff0c;网易2018年这套校招系统运维工程师笔试卷&#xff0c;在圈子里算是比较有代表性的。当年很多人考完出来一边吐槽“题目偏”&#xff0c;一边又承认这份卷子确实把运维岗该有的底子都摸了一遍。这几年我偶尔还会把这份卷子翻出来&#xff0c;给团队里刚入行的…

作者头像 李华
网站建设 2026/8/30 7:31:43

从国赛真题到实战:基于质量守恒与数值求解的高压油管压力建模

1. 项目概述&#xff1a;从一道国赛真题看数学建模的实战思维最近在整理资料&#xff0c;翻到了2019年高教社杯全国大学生数学建模竞赛&#xff08;简称“国赛”&#xff09;的A题&#xff0c;思绪一下子被拉回了那个充满挑战与激情的备赛阶段。这道题当年给不少队伍留下了深刻…

作者头像 李华
网站建设 2026/8/30 7:59:45

EN认证铁路计算机系统解析:从标准到选型的工程指南

我最近一直在跟进IBASE推出的EN认证铁路计算机系统&#xff08;EN-Certified Railway Computer System&#xff09;&#xff0c;打算用它做智能轨道交通项目里的车载和轨旁设备。说实话&#xff0c;干这一行久了你就会明白&#xff0c;“能进机房的工控机”和“能上车的工控机”…

作者头像 李华