App developers: Your opinion on use of AI in app development for my use case?

I would like to gauge your opinion on using AI for app development specifically. I am not interested in opinions about AI in general in this thread. I have seen OpenRepos: AI Created Apps and AI development - possibilities. But I have a more specific question.
I am curious on how you think of my use of AI:

I have hobby programming experience. I have used high level scripting with websites, I made my own games on my graphical calculator, I did some C++, I made a few games in godot (nothing worthy of release), I did tinkering with a FPGA (you should dip into verilog, it is weird!), batch scripting and some basic back in the MSDOS days when I was 7 years old, and way more I can’t remember right now. Most of it is between 15 - 30 years ago. I haven’t done much in the last 2 decades.

Now, I want to make a SFOS app. Maybe just for me, maybe it might get good enough to release it, I don’t know. I had a few small ideas, but the apps for those use cases already exist. So I went for my bigger idea: an engine for visual novels. Surprisingly, it goes pretty well.

I make use of AI a lot for this. I told an AI what pages I want, what entries to put in the pull down menus, and more. Then I had the AI write me a document with specifications for the engine, which I then read, modified and approved. I have the AI make code suggestions, that I let it explain in a way so that I understand every line of code, and I review, make modifications, and add comments. Yes, I opened the API docs to understand some of the Silica API calls. So, I read, know and understand every line of code. Still, most code is good, and needs only commenting added. So most code is purely AI generated.
I like to be transparent. So I am transparent about my use of AI as well.

Assuming the hypothetical that you need for VN engine:
Knowing this use of AI within mine, would you use it?
Would you take the time to file a bug report, or even contribute?
What amount of use of AI, or what AI use cases would be acceptable for you?

I’m very curious what you think.

9 Likes

If your apps do what is intended then I personally don’t see a problem with how it’s been created.
If helps you learn and gain experience and understanding more about coding, then good, again I see no problem personally.
I’ve read comments in threads where some users seem extremely annoyed by the use of AI for app making and quite honestly, I view that as their problem not mine.
I’m fully aware that AI gets things very wrong and writes unnecessarily complicated code, but sometimes it also is bang on.
You do you, if others don’t like it, well, again, that is their problem. I will continue using AI where I fail to get results.

3 Likes

AI tools are obviously totally fine.
As long as you understand what is happening in your app, it is auditable and maintainable, what’s the difference between using AI for help or copy pasting other people’s code from SO?

5 Likes

First AI is a tool like a pencil or a simple editor. Tools are only tools, not much worth to discuss to long. For me, only people who are unsure how to make a good solution will disuss much about tools :grinning_face: .

More important for a good software engineer are:

  • define good and detailed requirements
  • define requirements cleared with all stakeholder
  • get a suitable solution for this requirements
  • only single use products needs no maintainance
  • so anticipate the maintainance cycles in your software architecture
  • your product is a simple text - the program code. This text must be easy to unterstand, easy to maintain and well documented.

If you have a program code of about 300k lines you must be able to open one page of this code and are be able to understand and maintain at this page.

If your tool of choise produced spaghetti code please separate the 0-bits and the 1-bits for a good recylcing and try it again with a better tool.

Your question is very general. What’s your definition of e.g quality, done, good? Who has you planned further developments from third persons? Is your data structure scalable? On this level only small talk is possible.

Anyway: Happy hacking. :alien_monster:

1 Like

I was in the same boat as you. But I had no real experience with C++ or Qt. Professionally, I’m in the C# corner, and I’ve created Android apps as a hobby, which helped and hindered me in this endeavour.

AI helped me create an alternative to an app I use daily on Android (Readrops), which had no SFOS‑native variant: an RSS reader that supports a Fever backend for my FreshRSS instance (the app might make it to the Jolla Store someday).

Within a week, I had a pretty solid base, but it was somewhat messy, and the paradigm AI put me on for Qt was a bit odd. That was mostly because I skewed the prompts toward Android architecture instead of whats normal for Qt. So I started a new project, which is still going strong two months later. I’ve continued prompting, but I’ve also read a lot of Qt/C++ documentation, since AI is often mistaken or uses APIs from newer Qt versions.

Where AI really shined for me was HTML parsing of RSS feed content so that Qt can handle it properly in text elements. Honestly, if I had to write that code manually, I’d probably still be working on it, libxml2 is an interesting beast.
I’d say use your head in the architecture and keep it maintainable. I don’t usually play VN game but if the app works and is performant I don’t care AI helped.

1 Like

Just do what you want man, a lot of people will be glad about you being upfront about AI usage (the most deranged will still probably be dissatisfied, but who cares), as long as source is available everyone can check for themselves if there are any backdoors (unless it becomes 1mil loc monstrosity I guess), VN viewer is not anything critical anyway, the worst that can happen is the anti-ai crowd won’t use the app, their loss

1 Like

Okay, it looks like no problem whatever way. I’m beginning to look like the most anti-AI here myself, it seems. :stuck_out_tongue:
To me, it is a valid ethical discussion, where opinions can sway both ways. And however I would like to let you know the arguments from the anti-AI camp here, you’ve probably heard them before, and this thread is not the place.
I wanted to know beforehand what the consensus in this community was. Thanks all.

1 Like

I approve of using AI as much as you want within your project.

Hope it’s a success! Let us know how you get on with it!

I very much dislike apps written this way. Don’t get me wrong, I like AI, I just dislike how people use AI.

You might think you understand the code but you don’t understand why the code is written that way.

The problem with AI is that it’s a great tool to speed up some parts of programming but you have to understand what it’s doing and how to steer it.

It creates horrible and unmaintainable code.

If I needed a VN engine I probably would use yours only if it’s properly Sailjailed and uses minimum permissions, otherwise I wouldn’t trust it with my data.

6 Likes

Thank you for this feedback. I could see why you’d want proper Sailjail implementation. AI written code with access to camera, file system and internet?
Luckily I don’t think I’ll need permissions. The only thing I could think of is internet access for an optional update checker for scripts, so minor updates can be done without updating the complete app, but that’s not in the plans.
About maintaining and understanding:
Understanding what the code does, and being able to independently write the code, are 2 very different things. Somewhere in between is the understanding why code is written in some way. I think I did focus quite heavily on the why part of understanding the code. I’ll make sure to keep this focus.
I haven’t got much maintaining experience. I wrote JS web applet a few years back, which I got reviewed by a friend who is a professional programmer. He gave me compliments on my comments, but did correct me on many unconventional decisions. And I found out, that improving the code was pretty much impossible without rewriting it. I could imagine AI could have done a much better job writing maintainable code. Admittedly, that says more about me than about AI, but still, badly written but safely working code, might be better than not writing stuff at all? Maybe? What would I do to write better maintainable code? I already have good variable names, and lots of comments. Should I ask feedback? Get experience? Or just stay vigilant in my use of AI?

Hi,
The way you are using AI is imo very wise.
The trap is there if one wants to speed up more, giving away verification and understanding.
But as long as you keep in control, why not.

I would be very interested on a concrete discussion with/between developers on parts of IA written code.
We always talk about principles on IA use in coding, but examples on real code would be very exiting.

Anyway, this technology is so powerful, so easy.
Good or bad, moral or not, eco-friendly or not, professional or not, I’m afraid it will be used more every day…

No, if you can’t write the code yourself then you don’t understand it. That’s like saying you understand cooking but can’t cook.

And that’s the whole problem - you’re shipping code you don’t understand. You might be shipping bugs and RCEs which could be easily prevented.

3 Likes

What you describe seems like the best way to use AI for coding. You’re on a learning path and you take responsibility for the code. No, you probably don’t understand all of it in every single way and, yes, there will likely be problems you haven’t detected. That will be the case, maybe to different degrees, whether you use AI or not.

Maybe you could write unit tests yourself? That will help you think about various aspects of the problem you try to solve. It may also help you judge/improve the structure of the generated code, which will be needed at any point when you have to ask others for assistance.

Be careful with the assumption that AI could do a better job on the maintainable side. An LLM has no real idea of what that even means. I recently accepted a ‘too large’ number of commits made with claude to one of the apps I maintain.The dev had done a good job of documenting requirements and had done ‘relatively’ discrete commits. Unfortunately, the last third of the batch I had to roll back. The last commits although ‘clean’ on the face of it, led to intermittent crashing.

In the end, the boilerplate UI code that was produced was fine, and certainly cleaner than some I produce.

My advice is to make small discrete steps and commits where the areas that are commited to a vcs repo are not overlapping. The overlapping commits are what makes it difficult to debug later.

3 Likes

I have come to accept AI written code more and more with time. There is slop and there is good code. Same as with human written code.
I work as a software engineer and often have to look at PRs. If I did not write the application, then I do not know it well enough to understand how the PR might have side effects. It does not matter if the code is written by my college or AI.
Same goes for AI coded apps, you are just the person that did the PR.

1 Like

No sane user gives a shit how the software is written.
It could be written by a one-eyed cat riding a tank.
Who gives a shit?!

Is the app useful and good?
Then people will use it.

Is the app a buggy generic piece of shit?
Then people won’t use it.

The problem with “AI” (as some people call autocomplete nowadays for some reason) is not who generates the code, but whether the person making the app is competent enough to extract good code from the slop that the machine generates and put together a good app that they can actually maintain when the bugs and feature requests start coming in.
It is that simple.

Who gives a shit if you wrote the code with or without autocomplete?!
Nobody that matters gives a shit about that.
Only political activists and religious zealots care about irrelevant things like that.

1 Like

I recently began accepting that as long as enough attention is given to plans, requirements, layers of tests and checks, and code reviews, then, imho, no human needs to see the code at all.

My opinion/experience on AI assisted development as a non coder/developer:

The last few weeks and as an experiment i am developing an app -music player unrelated to SFOS- using microsofts copilot. I basically just spend a few hours telling it what to do and i have an app that more or less works and plays my music from my music library.

In order to write something like that and reach at the level it would have taken me 4-5 months of work at least. Yet without knowing the toolkit or much about coding in general i have something that works in a matter of days.

Of course if you have no idea what you are doing you are going to produce crappy code that is inefficient, wastes a lot of resources and more or less an app thats it not well “engineered”.

On the other hand for someone who knows his shit is an enhancement tool that will get you to a usable app in a matter of hours. The same app from someone knowing what to do and the toolkit would have taken probably a day at maximum. And of course it would be better engineered, more efficient and with better quality of code.

TLDR: Its a productivity enhancement tool for those who know what they are doing and how to command it.

I also had to use verilog once - it really is weird :sweat_smile:
One of the most difficult things to understand I have done.

I guess using AI doesn’t really make a difference here? If I would take the time to file a bug report or a merge request, I (personally) rather think about how annoying the bug is and I guess this won’t be affected by the use of AI or not. I can’t really imagine someone saying “this bug annoys me every day, but the code was written by AI so I won’t do anything about it”.

1 Like

One could say, if the developer doesn’t value this enough to write the code themselves, why would I value it enough to file a proper bug report? Why should I do work on something the developer doesn’t even want to touch themselves?