JKP is the AI agent that ships my game while I sleep. Yesterday it earned its keep.
The setup
EFURC was using 1.2MB more memory than expected after a 30-minute playtest. I knew it was a leak — something was holding references that should have been released. I had been putting off the investigation for two weeks because manual memory profiling is the worst kind of debugging.
The question
I asked JKP: Find the memory leak in the EFURC card renderer. The leak is ~1MB and accumulates over a 30-minute playtest.
The result
30 seconds later, JKP returned:
The leak is in
CardRenderer.render(). The function capturesthis._cardTablein a closure passed tosetTimeout.setTimeoutretains the closure for 60 seconds. Every render call adds another closure. After 30 minutes, ~1,800 closures are retained, each holding a 50k-row reference to_cardTable.
The fix
Two-line fix: store the timeout ID on this and clear it on next render. Memory leak eliminated.
Why JKP matters
Without JKP, that leak would have lived in the codebase for another month. With JKP, it took 30 seconds. That is the difference between a side project and a shipped game.
How JKP compares to other AI coding agents.