Grinding Wheel

ChatGPT - Generative AI, from a backend-dev's perspective, who wanted to make a frontend.

At work I wrote a lot of backend code. There is never a graphical interface associated, and if there is ever what could be considered a front-end, it would be shell script wrappers around HTTP method calls to API servers we have developed in-house. For this blog I have written enough HTML and CSS to get words in front of a person over SSL/TLS, and then more with help - foreshadowing. This is my take of the current skill-set of developers, front-end, back-end, kernel, systems, etc, from the perspective of how generative (specifically from my experiments ChatGPT) might impact this.

Frontend

If what you write for a front-end is HTML, CSS, and vanilla JavaScript and all that you write are simple form pages - I think you are actually in trouble. ChatGPT is quite easily able to make this web forms that perform different HTTP methods (like submission of data to external API) along with writing validation JavaScript for you. It's even quite helpful in other areas outside of forms, it seems there is a complexity threshold that the code produced just doesn't work anymore and you will have to perform a code review to find out, but that seems to be when there are several moving parts and quite a bit of looping occuring with some state saving.

Frameworks - when we get into frameworks I think the level of difficult for ChatGPT becomes a bit higher. There are directories that are standard and files that it needs to keep track of, along with the operating system that you might be developing on. For instance, when I asked it to provide a sample productivity app front-end in Node.js it defaulted to assuming I was on a Debian based system (able to run sudo apt). Now while I was I can see this as an immediate assumption that brand-new front-end individuals that don't know the rudiments of their tech may stumble on or be discouraged with. It sounds highly authoritative, but sounding like you have authority (just like with people) doesn't actually mean you do. That being said for frameworks, it may do well after you get past all of the assumptions it makes, bu the framework is also doing a lot of the heavy lifting too.

Backend

I have personally only asked ChatGPT questions on how it might write a library for interacting with an API that I had already written - to see what it would produce. It seems to have a religion for using empty interfaces to marshal JSON data into. I'm not sure why this is the case, even after you tell it to use only defined struct types for this marshalling it will still output empty interfaces, just maybe not as many. It has a habit of using odd public repositories that are not very popular or maintained as they can abstract the verbosity of the idiomatic code. In the end, if I want backend code that is idiomatic, I won't use ChatGPT.

In progress