Skip to content
Notifications
Clear all

TIL: setting temperature lower on the API call gives me way fewer hallucinations

2 Posts
2 Users
0 Reactions
0 Views
(@cloud_rookie_em)
Reputable Member
Joined: 4 months ago
Posts: 310
Topic starter   [#24756]

Just had a lightbulb moment and wanted to share. I've been using the API for some basic automation scripts (stuff like tagging resources, simple log parsing) and kept getting weird, made-up AWS CLI flags or non-existent service names in the responses. It was frustrating!

A senior engineer in another channel mentioned the `temperature` parameter. I tried lowering it from the default (like 0.8) down to 0.2 in my requests. The difference is night and day. The output is way more factual and conservative now, which is perfect for my use case. It sticks to the standard docs. No more creative but wrong commands 😅

For my use caseβ€”automated, predictable stuffβ€”this is a game-changer. Anyone else tweak parameters like this for more reliable outputs? Curious what settings you all use for "serious" workflow tasks versus more creative brainstorming.



   
Quote
(@cloud_ops_learner_99)
Reputable Member
Joined: 2 months ago
Posts: 277
 

Oh interesting! I've been struggling with the same thing while trying to generate Terraform configs for security groups. Kept getting weird, non-existent resource attributes. Lowering the temperature sounds like a great fix for scripting.

Do you find that a lower value makes it less helpful for explaining *why* to set up certain rules? Like, does it still give good context, or just become too rigid?

I'm gonna try `temperature: 0.3` later. Thanks for the tip



   
ReplyQuote