Claude Code、Cursor、Windsurf 等 Coding Agent 工具让写代码的速度提升了 10 倍。但更快的编码 ≠ 更好的产品。
当一个 tide tracking app(潮汐追踪应用)能在 2 小时内从 idea 变成可运行的原型时,真正的挑战变成了:如何让这个产品从"能用"变成"好用"?
@swyx (Latent Space 播客主持人) 在 Twitter 上写道:
"AI coding assistants give you 10x speed on the first 80% of a project, but the last 20% of polish still takes just as long."
这"最后 20%"是什么?
这些工作不会出现在 AI 生成的 commit message 里,但却是区分 demo 和产品的关键。
Washington Clam(WACLAM)是一个帮助捕捞者追踪潮汐和海滩开放状态的应用。Coding Agent 在 3 小时内完成了 MVP,但随后的 2 周内进行了 47 次打磨提交。
初始方案(AI 生成):
// 每次用户打开页面都调用 NOAA API
const tides = await fetch(`https://api.tidesandcurrents.noaa.gov/...`);
问题:
打磨后:
// commit: Replace runtime NOAA API calls with pre-downloaded static tide data
// 使用 GitHub Actions 每小时同步一次数据
// tides.json 直接打包进应用
import tides from '../data/tides.json';
const getTides = (date) => tides[date];
结果:首屏加载时间从 2.5s 降至 0.3s,99.9% 可用性。
静态数据解决了速度问题,但海滩状态(是否开放、污染警告)需要实时更新。如何平衡新鲜度和性能?
// commit: Use 30-day cache for tides.json, 1-hour for beaches.json
// next.config.js
async headers() {
return [
{
source: '/data/tides.json',
headers: [
{ key: 'Cache-Control', value: 'public, max-age=2592000' } // 30天
]
},
{
source: '/data/beaches.json',
headers: [
{ key: 'Cache-Control', value: 'public, max-age=3600' } // 1小时
]
}
];
}
策略依据:潮汐数据可预测,30天不会变;海滩状态可能几小时内变化(天气、污染)。
Coding Agent 生成的移动端日历是"能用"的桌面端缩小版。但真实的 iOS 用户期待什么?
@daveverwer (iOS Dev Weekly 编辑) 在 iOS Dev Weekly 中强调:
"Users don't notice when you get platform conventions right, but they absolutely notice when you get them wrong."
重构前后的对比:
feat: Add iOS-native species selection bottom sheet on mobile — 底部弹出选择器,与系统设置一致feat: Unify desktop and mobile calendar with bar indicators — 统一组件,响应式适配Coding Agent 生成代码时会保留大量"以防万一"的逻辑。生产代码需要做什么?
# 真实的 commit 序列
630a4be Replace runtime species API with static import from beaches.json
bef4c5d Replace runtime DOH API calls with pre-downloaded static beach data
62bc075 Replace runtime NOAA API calls with pre-downloaded static tide data
19fdbfb Remove unused useTides hook and related dead code
4beaeed Remove unused code and consolidate tide utilities
c6656be Remove WDFW name scraper and featured field
规律:每增加一个新功能,就会暴露 2-3 个可以删除的旧功能。产品打磨是减法,不是加法。
数据同步频率不是技术问题,是产品决策:
feat: Update DOH data sync to 4x daily — 仍不够实时feat: Increase DOH data sync to hourly — 与官方 API 更新频率匹配关键认知:同步频率取决于数据源更新频率 + 用户容忍延迟。不是越频繁越好。
基于上述案例,产品从 MVP 到 production-ready 的打磨清单:
Coding Agent 擅长:
但 AI 不擅长:
@johnowhitaker (Stability AI) 写道:
"AI can write the code, but it can't decide what code to write. Product sense comes from understanding user pain points at a human level."
Coding Agent 不是替代开发者,而是改变了工作分配:
WACLAM 的 47 次打磨 commit 中,Coding Agent 协助完成了约 60% 的代码编写,但 100% 的决策点来自人的判断。
在 Coding Agent 时代,写代码的速度不再稀缺,产品判断力才是。
git log --oneline --all (47 commits post-MVP)