# Show HN: Iac-bench – a benchmarking framework for LLMs on OpenTofu generation

> Source: <https://github.com/massdriver-cloud/iac-bench>
> Published: 2026-11-30 16:02:11+00:00

**Recommendation:** When benchmarking LLM code generation, weight most of the score on mechanical checks of the output and artifacts, keep prompts vague to test expertise, and average 3 attempts per model.
More in the playbook "Evals and testing for LLM apps": <https://wpnews.pro/playbooks/evals-testing>

I made a framework for evaluating LLM performance at writing IaC (specifically OpenTofu) modules. You provide a prompt(s) and a rubric.yaml(s) and it will use models you choose to generate a module and grade the results. I've already written 6 briefs across clouds and services (S3, Cloud SQL, App Service, Aurora global, GKE, Azure storage) and have published the results. Each model gets 3 attempts and scores are averaged. The latest run included 24 models x 6 briefs x 3 attempts = 432 modules. Results are here: [https://www.massdriver.cloud/llm-rankings](https://www.massdriver.cloud/llm-rankings)

In terms of how models are scored, 70% is mechanical score from evaluating HCL and plan outputs. The other 30% is an LLM "judge" that uses a published "good OpenTofu" doctrine to grade the modules. Prompts are intentionally left a bit vague to evaluate the expertise the LLMs use to produce a module instead of how good they are at following specific instructions, which is generally quite good.

The tool, all of the results and the methodology are all open source.

Disclosure: I work at Massdriver, which is an infrastructure automation and continuous delivery platform. I've done my best to keep this tool and it's scoring independent. We simply use LLMs to generate a lot of IaC and built this to figure out which ones were the best at it and thought it would be interesting to the community.

Write-up and methodology: [https://www.massdriver.cloud/blogs/iac-bench-2026-11-results](https://www.massdriver.cloud/blogs/iac-bench-2026-11-results)

Happy to answer questions. I'd also love to hear from others that have done similar evaluations like this to see if there are some suggestions or requests for the prompts we evaluate and publish.

Comments URL: [https://news.ycombinator.com/item?id=50701553](https://news.ycombinator.com/item?id=50701553)

Points: 2

# Comments: 0
