Can AI code an Entire Optimization Model?
Blog: For Practitioners by Practitioners!
SolverMax attempted to use an LLM tool to create an entire, non-trivial optimization model, with the AI doing all the programming. They asked Copilot to “Design a crop rotation optimization model“. Copilot responds with a comprehensive specification for this situation, but the entire process was not straightforward. It is described at https://www.solvermax.com/blog/can-ai-code-an-entire-optimization-model. Here is the conclusion:
“Overall, we achieved our goal. Some parts of the process are smooth, with Copilot being a very helpful and useful programming assistant. However, other parts of the process are frustrating and occasionally nonsensical. In total, the process takes longer than it would have if we wrote the model without AI – primarily due to the time taken to dig Copilot out of the rabbit holes that it goes down.
The abilities of LLM AI have improved substantially and rapidly. As a programming assistant, AI can certainly be useful for both general programming and writing an optimization model. When it works, it works well. But there are cases where the AI doesn’t work well and attempts to coerce it into doing what we want sometimes go awry. In such cases, sidelining the AI and doing the coding ourselves would be more effective and efficient.
Despite frequent recent predictions that computer programming will soon be an obsolete skill, our experience with Copilot suggests that time is not close. While we’re undoubtedly closer than we were in 1985, AI is not there yet. Even if or when AI tools become advanced enough to handle most or all programming, optimization model development is much more than just programming. As modellers, we don’t expect to be replaced by an AI any time soon.“