需求卡片 #428 · 相关性 高 · 新发现

API 原型设计的高昂成本与回归测试缺失

更新于 2026/10/12 22:11:44

问题概述

Software engineers face difficulty in confidently designing APIs because building multiple prototypes is time‑consuming. Ephemeral testing approaches often end up as integration tests, offering little regression protection, and designers may miss hidden usage patterns which LLM‑generated code can reveal.

痛点标签

待验证问题

证据

原话
The big challenge with designing an API is that the only way to be confident in the design is to build a bunch of different things on top of it. But why invest all that effort in an API that you don't think is ready yet? With coding agents the cost of building those prototypes drops to almost nothing. I can exercise a proposed API design five different ways before I commit to the shape.
原话
Unless I'm missing something, this doesn't help with preventing regressions. In the end, as the author already puts it, it's an integration test in the end, why not just write the integration tests directly?
原话
This is an application of the rule of three: you need at least three clients to write a good library, protocol, or other underlying abstraction. Except it proposes using a large language model to write the three clients and then throwing them away.
原话
I had good results with a similar technique this summer. I was designing a DSL to help make a colleague’s work easier, and I tested it by having a coding agent re-implement some of their notebooks using a draft of the DSL. The LLM output was a decent enough approximation of “typical” use, and it uncovered some warts I didn’t catch by testing it myself. As its designer, I simply wouldn’t have thought to try using it in some of the ways the LLM-generated code did.

免责声明:本卡片由 AI 从社区讨论中提炼,属于「痛点证据」,是需求分析与验证的起点,不等同于「已验证的市场需求」。AI 存在分析局限,关键决策前请打开上方原始讨论人工复核。