Hello peers in wisdom,
Last week I was experimenting for the first time with AI tools to generate code, specifically with the code editor, Antigravity. I'll describe my configurations, experiences, expectations and results.
What was my setup?
Anti gravity out of the box and I used Gemini 3 Flash. I give it a detailed requirement document for a automated quoting system.
What were my expectations?
- Semi functional project
- Clean hexagonal architecture
- Use of libraries I indicated it
What was the result?
It was not so good not so bad.
1. The project is semi functional as I expected, some of the most interrelated business rules were not exactly implemented as it was expected. CRUD and authentication systems were fully functional.
2. The code architecture was hexagonal as I asked for, but there were bad practices implemented such as anemic entities, use of 'any' instead of mapping with a DTO. Also there was a lack of customs errors and data validation, and some potencial problems with the implementation of a finite machine state in one entity.
1. The project is semi functional as I expected, some of the most interrelated business rules were not exactly implemented as it was expected. CRUD and authentication systems were fully functional.
2. The code architecture was hexagonal as I asked for, but there were bad practices implemented such as anemic entities, use of 'any' instead of mapping with a DTO. Also there was a lack of customs errors and data validation, and some potencial problems with the implementation of a finite machine state in one entity.
3. There was no problem managing and connecting different libraries, for the contrary Gemini detected incompatibilities with the newest version of prisma ORM and automatically decided to version down to solve the problem. Pretty cool!
Conclusion
It took me around 4 hours to read Gemini's generated code vs probably the 20+ hours it would've take to me write the same amount of code. Even though, is not perfect, the code is a good template to start customizing the application's functionalities.
Definitely I will be exploring another configurations, try with different agents and iterate over the first result to see how good the final result can be, stay tune!
Comentarios
Publicar un comentario