How Springcraft validated the springrep CAD kernel with 3,487 questions
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.
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.
For an AI-written CAD kernel, I would rather give it an exam. 3,487 questions, and it still works with another kernel.
The Springcraft team kept getting blocked by existing CAD kernels while modeling robot parts. Co-founder Tony used Claude Code to write one himself, called springrep. When you click on the screen to fillet a hole opening, this software layer calculates which faces change and how much material remains in the part.
But how do you know it calculated correctly? If you check it against another CAD system and the numbers differ, you still have to determine which one is wrong.
Tony’s approach was to choose questions whose answers can be derived directly from geometric relationships. The simplest example: drill a through-hole in a square plate; the remaining material can be calculated by subtracting a cylinder from the plate’s volume. If the hole is cut half a millimeter too shallow, it looks exactly the same from the front, but the volume calculation exposes it.
This test suite found hundreds of issues in springrep that the existing tests had missed, including errors in special cases and operations that ran particularly slowly. All 3,487 questions now pass. Tony also says this is the first version, and both the questions and the code connecting to different kernels may contain errors.
I think the most cost-effective step was open-sourcing the kernel and the exam separately. If a better kernel appears one day, the team can test it with the same questions without stepping into the same pitfalls again. They have already run it against several open-source kernels.
Next time I estimate how much work AI can save me, I want to ask myself one question first: if it gets something wrong, how long will it take me to notice?
If the answer is “until the customer calls,” then I have only assigned the customer extra work.
Source: Xiao Tan · x.com