Skip to content
Xiao Tan· @tvytlx · X·· 14 d agoFeaturedAI score80

How Springcraft validated the springrep CAD kernel with 3,487 questions

Editorial summary

The Springcraft team built 3,487 test questions for its in-house CAD kernel springrep, with answers derivable from geometric relationships, to verify modeling results and detect errors. The tests found hundreds of issues missed by the original tests. All 3,487 questions currently pass, but the team explains that this is the first version and that the questions and code connecting to different kernels may still contain errors.

Why it matters

Separating CAD-kernel validation from geometric test questions demonstrates a method for finding edge-case errors and performance issues, while also showing the engineering value of reusing tests across kernels.

Back to English edition
Original text

一个用 AI 写的 CAD 内核,我更想拿走它的考卷。3487 道题,换个内核照样能用。

Springcraft 团队给机器人零件建模,老被现有的 CAD 内核卡住。联合创始人 Tony 借助 Claude Code,自己写了一个,叫 springrep。你在屏幕上点一下,给孔口倒个圆角,哪几张面要变、零件还剩多少材料,都归这层软件算。

可怎么知道它算对了?拿另一套 CAD 来核对,两边给的数不一样,你还得查究竟谁错了。

Tony 的办法是挑那些能从几何关系直接推出答案的题。举个最简单的例子:一块方板打一个贯穿的圆孔,剩多少材料,用方板的体积减去一个圆柱就能算出来。孔少挖了半毫米,从正面看着一模一样,一算体积就露馅了。

这套题在 springrep 里找出了几百处原有测试没发现的问题,包括特殊情况下的错误和跑得特别慢的操作。现在 3487 道题全部通过。Tony 也说,这是第一版,题目和对接各家内核的代码都可能有错。

我觉得最划算的一步,是他们把内核和考卷分开开源了。哪天有个更好用的内核,团队可以拿同一套题去验,不用把当初踩过的坑再踩一遍。他们已经拿几款开源内核跑过了。

下次估算 AI 能帮我省多少工,我想先问自己一句:它交错了,我多久能发现?

如果答案是「等客户打电话」,那我只是给客户多派了份活。

news.ycombinator.com/item?id=…

Source: Xiao Tan · x.com