Hot take: setting the temp to 0 for code gen beat my fancy prompt chain every time | AI Innovations - Freelance Forum - The Community for Independent Professionals
Hot take: setting the temp to 0 for code gen beat my fancy prompt chain every time
I spent about two weeks building a prompt chain for generating unit tests with an AI coding assistant. It had a role prompt, a few examples, a step to critique its own output, and a final cleanup pass. It worked okay, maybe 60 percent of the tests passed on the first run. Then last Wednesday I tried something dumb: just one plain prompt with a clear spec and the temperature set to 0. That simple version hit 85 percent on the first try across 20 test files. The big difference was less noise. The chain kept rewriting things and adding weird helper functions that didn't exist. The plain low temp prompt just followed the spec. I still keep a small review step after, but I deleted the rest of the chain. I'm curious if anyone here has had luck with a middle ground, maybe just one example and nothing else.