I still think @mpweiher's original response to the release of GitHub Copilot is spot on: https://blog.metaobject.com/2021/06/don-generate-glueextermi...
That is, rather than use an LLM to generate boilerplate code from an ambiguous natural-language prompt, use a high-level programming language to precisely, concisely, and directly express what you want.