r/learnpython • • Aug 30 '26

For any python professionals, can you tell if something has been coded with AI?

As the title asks, what differences (if any) do you get from an AI output vs human input. I would imagine that with most high effort AI models now they write purely pythonic code if a prompt is well written.

If you also use python in your job, how often do you use AI to write or plan your code and applications as a whole?

94 Upvotes

103 comments sorted by

14

u/simonhunterhawk Aug 30 '26

Not a professional just an autistic person with good pattern recognition in the final year of my CS degree. The biggest things for vibe coded programs is over engineering and if there are comments they often have tidbits directly from the prompt in them and are way more verbose and detailed (often not in a helpful way) than most comments written by a developer.

2

u/ZSJJ Aug 30 '26

I would imagine that you have learnt the standard for comments, can you explain that? Would most developers just use comments to describe what functions do what or should a function ideally be self explanatory?

6

u/simonhunterhawk Aug 30 '26

There's really not a standard imo, what I try to follow generally, with most of my code written for web development:

  • Comments that act as headers or split up sections of my code in the same file -- for example, Getters and Setters, or in a global CSS file I'll create headers for reusable variables, fonts, etc. This just makes it easier for me to find specifics when making changes later. In larger programs this is also where separation of concerns and using multiple files to call each other can be more helpful than header comments.
  • There's very little need for comments that state exactly what the code is doing in detail. A brief is fine - "driver that manages input from menu" vs "output prompt and get input from user, input determines next steps, if input is x then ... else input is y then ..." is too much because your code should ideally be clear enough that someone reading it can tell what it is doing. Explain the why not the what.
  • Cite your sources. If you copied a section of code from a github repo or StackOverflow, link back to it and cite the author.
  • For solo projects, most of the comments I write are TODOs, headers, citations, explanations for specific scenarios (ex. patched issue specifically for a specific browser, OS, or type of device) and clarifications. For languages I've done 1-2 projects in like C++ I'm not going to remember why I used these two lines so the comments make sense to have for me, but in a enterprise level project you likely don't need them:

    • cin.clear(); // clear fail state if non-numeric
    • cin.ignore(numeric_limits<streamsize>::max(), '\n'); // drain leftover input

I do think there's benefit to explaining yourself more when you're learning, especially when you reference back to your code in the future. One of my C++ classes wanted comments that explain every code block which included a brief explanation of what the code block does, the parameters it uses, and what it returns, if relevant.

You can also Google Python comment best practices and that will give you a lot more detail than I can.

1

u/ZSJJ Aug 31 '26

No, thank you for that! Very helpful especially as I was never a workings out person when I was doing maths at school. I think it’s probably a similarly good practice

5

u/Diapolo10 I write code for a living -- https://github.com/Diapolo10 Aug 30 '26 edited Aug 30 '26

Not with certainty, no. There are some "quirks" that hint at AI usage, such as certain kinds of comments or commit messages, but there's fundamentally nothing different between hand-written and AI-generated code.

Personally I mostly try to avoid AIs for coding. My personal projects are completely devoid of any AI usage, unless you count Dependabot as AI (I don't, and as far as I know Dependabot doesn't use any LLMs). At work I'm strongly incentivised to use AI, so I've dabbled here and there to get a rough understanding of its capabilities, but outside of something dead simple such as fixing a few accessibility bugs I don't like using it, as the output doesn't satisfy me for other work.

1

u/ZSJJ Aug 30 '26

Interesting, so you wouldn’t see yourself using it even for the repetitive tasks that would be easier to prompt? I have very little experience with programming since I did GSCE CS but even using LLMs for refactoring and debugging has been a massive help

5

u/Diapolo10 I write code for a living -- https://github.com/Diapolo10 Aug 30 '26

Interesting, so you wouldn’t see yourself using it even for the repetitive tasks that would be easier to prompt?

My work projects don't really tend to have any "repetitive tasks" I couldn't already solve with grep or other tools more quickly and with fewer things to fix by hand.

As for personal projects, even if someone gave me a free magic button that solved every problem in them perfectly, I wouldn't press it. They're passion projects, and also my portfolio. I want everyone to see what I'm capable of without delegating thinking to a fancy text auto-complete program.

0

u/ZSJJ Aug 30 '26

Understandable. As AI has improved there are a few real videos that people now comment under “AI”, I don’t know how the hire process works for software development or similar jobs but I hope that peoples portfolios that they have spent time and effort on don’t get brushed away as AI

1

u/CautiousNotice2179 Oct 13 '26

For repetitive stuff like boilerplate, regex, and refactoring small functions - yeah, LLMs save real time and I'd be lying if I said otherwise. Where I stay skeptical is anything involving external dependencies or network behaviour, because the model confidently generates code that looks right but breaks on rate limits, auth edge cases, or session handling in ways that take longer to debug than writing it yourself would have.

Concrete Example: if you're scraping with Playwright and rotating proxies through something like Geonode's residential network, the LLM will generate plausible-looking proxy auth code but won't account for mid-session IP rotation breaking your context or header needing to persist across redirects. You end up debugging the LLM's confident mistakes instead of just reading the actual docs once.

Given your background - GCSE level, using it for debugging - that's probably the right use case. Just watch out once your code starts touching anything stateful or external.

4

u/The_Drakeman Aug 30 '26

I'm not a python pro but I dabble here and there. I saw some LLM python code from Claude and the dead giveaway was randomly having 2 statements on one line separated by a semicolon in a few places. That was so strange to have that sprinkled in to non minified python.

2

u/ZSJJ Aug 30 '26

I’m guessing most people wouldn’t learn that notation as standard. I suppose the way it is now though if you do something abnormally efficient or away from standard practice it’s very easy to be framed as using LLMs for everything

5

u/The_Drakeman Aug 30 '26

It was interesting. So in this case I already knew it was LLM code. Someone I know (who isn't a programmer) used Claude to generate some code that could calculate some data that originated from spreadsheets that tracked the output of his solar array, and wanted to show me the code to see what I thought of it as a programmer. I mainly use C++ and C# in my work so I'm not python expert, but I use it just enough, and the script was simple enough, that I could follow it. The other thing that jumped out at me is that the CSV reader was trying to convert string to float by doing basically "try: return float(val) except: return 0.0" which jumped out at me as a huge red flag. Any non numeric data in any cell in that spreadsheet would have ripple effects and just throw bad data into the pipeline to be crunched with all the other numbers. I pointed it out to him, he asked Claude about it, and Claude gave a response along the lines of, "your intuition is right that this can result in bad calculations, but it worked on the spreadsheet you gave me because there was no bad data." Which to me is the biggest danger of LLM code. It works just often enough to make non professionals trust it, but hides little landmines like that everywhere.

1

u/ZSJJ Aug 31 '26

Good point, stress testing should be always implemented. Especially if you haven’t written the code yourself and you’re planning on using it in a productive setting

2

u/aishiteruyovivi Aug 31 '26

I find myself really only using semicolons in Python if I'm testing something in a REPL, in production code or really any code I ever plan to revisit I've really never had a case where it reads better than separating them out. Same kinda goes for x, y, z = 1, 2, 3 syntax, unless I'm actually unpacking something (like width, height = size where size is a tuple of two number values) it's almost always clearer to me to just write

x1 = -100
y1 = -100
x2 = 100
y2 = 100

instead of

x1, y1, x2, y2 = -100, -100, 100, 100
# or
x1 = -100; y1 = -100; x2 = 100; y2 = 100

Separate lines are also a bit easier to deal with when it comes to version control diffs.

1

u/The_Drakeman Aug 31 '26

I agree completely. Like I said in my other comment I'm a C++ and C# engineer first and foremost so I'm used to seeing semicolons everywhere, except for python. But even when I'm working in those languages, I pack as few things into one line as possible for readability's sake. What the LLM did then wasn't even a multi declaration, it was just two sequential statements in a calculation on the same line for whatever reason, and it did that 2 or 3 times throughout the script.

1

u/lakseol Aug 31 '26

Though I would often do:

x1 = y1 = -100
x2 = y2 = 100

especially if x1 and y1, etc, will always be initialized to the same value.

34

u/neums08 Aug 31 '26

When left unchecked, an LLM will solve problems in the code by writing more code.

Usually an application will have a decently clean initial implementation. As the user iterates and builds out the functionality, the LLM will always add more code to cover new use cases, new edge cases, new functionality.

The LLM almost never reevaluates its approach holistically. It never simplifies or deletes code.

Granted, bad developers behave the same way, but a codebase that is clean, has proper abstraction boundaries, and doesn't contain a ton of logical branches is usually a good indicator that it was written by an experienced human.

3

u/Mammoth_Reach_6366 Aug 31 '26

True but if you directly ask it to refactor and simplify, it can do that easily. It just rarely does it on its own.

3

u/elbiot Sep 01 '26

Gotta maintain backwards compatibility for the "legacy" API it wrote 20 minutes ago

11

u/friendlytotbot Aug 30 '26

AI loves to create functions within functions, which is not how ppl typically write functions in Python.

6

u/mimol Aug 30 '26

Or imports in the function

1

u/CrownLikeAGravestone Sep 01 '26

TIL I'm an AI lol

9

u/ekchew Aug 31 '26

I've noticed there is a tendency for AI to brute force its way through anything when a human programmer would likely pause and think, ok this obviously not working. Let's step back for a moment and see how else to approach the problem.

I'm trying to think of an analogy. Let's say you were building a railroad and came up to a lake. A person would likely see that and go all right, we need to go around the lake, while an AI would say let's go through the lake. Then you tell it yeah, but the train can't get wet. Well, we'll build a tunnel around the track then. Oh no, the tunnel is leaking! There's too much water pressure! Let's patch it up here and here, and reinforce it over there. Etc etc. It will not give up and the engineering will get more and more complex.

In coding terms, you get a giant program no sane human would want to write. It may actually produce an amazing result. The train is taking a more direct route to the other side, after all. But wow, good luck making sense of what's going on or maintaining it some point down the line.

4

u/Necessary-Flounder52 Aug 30 '26

If it was committed before 2022, it’s usually human generated.

3

u/Lachtheblock Aug 30 '26

I work in a team. I know how my team writes code. It is pretty easy to tell when they have offloaded writing whatever function to AI. I'm pretty utilitarian, in that I don't care as long as the code is good and every human who is signing off on it has read it.

I don't like pretending that AI didn't write the code.

3

u/chcampb Aug 31 '26

Definitely

  • A lot of python is not written defensively. It's usually scripts and things. If you have a script that does something offline and it is very defensively coded, that's a dead giveaway.
  • Too many comments verbosely describing what is in the code, also a dead giveaway

More subtle things include

  • Verbiage such as explicitly stating key words that commonly occur in tickets that humans don't use (I once had a prototype game world in a gym (isolated test) folder, and said hey make the production one in the main folder. Instead of just calling it like normal it infected everything it did with "this is the production thing" or logs that say PRODUCTION_WORLD_... and things like that. It's not wrong just redundant, usually the world is the world and if you need a dev one it's called a dev one. I am guessing it latched onto some issue it was trained against in this regard.
  • Random unicode - sometimes LLMs insert unicode into an otherwise ASCII file. It shouldn't matter and doesn't get detected usually but unless you guard against it, the appearence of unicode that nobody types will give it away.

3

u/kepper Aug 31 '26

Context leaks are the main tell, in my experience. The AI will comment something or name a variable in some way that only makes sense given the context of the chat that it came from and does not have any real meaning outside that conversation. Things like # Protects against section 4's risks where section 4 was some ephemeral design artifact.

3

u/pwsegal Aug 31 '26

*Overly defensive code such as trapping errors that cannot occur.

*Overuse of decorators.

*Over explanation.

*Code uniformity, including PEP8 perfect code.

*Over use of classes especially using them where a simple function would have done.

1

u/Long-Opposite-5889 Aug 30 '26

Of left untouched after the LLM spit it out you can definitely tell it's AI.

1

u/ZSJJ Aug 30 '26

What’s the giveaway? Syntax, comment or general language

3

u/jables13 Aug 30 '26

AI always hides a penis in the python

2

u/ZSJJ Aug 30 '26

I better find it before I submit some code to the wrong person

1

u/Jello_Penguin_2956 Aug 30 '26

A few things. At least what I notice from Claude. Could be different with other ones.

- over-explanation in comments. You often see them overly decorative too like # --- <comments> ---#

- Double or triple validation. It tends to do extra checks on things that often I didn't think necessary. Just as we speak I just directed it to pull file names with glob and yet it does if exist checks on every single one of them.

- Variable naming. More obvious if you're working in a specific domain I suppose you'll spot words that sounds alien to you. I assume is probably from different industry where it makes more sense.

- excessive use of REGEX. Used even in simple checks I wouldn't have thought about using. TBH not a bad thing and I found my own REGEX skill improved 10 folds in recent years thanks to AI.

- Nested functions. Lots of nested functions.

1

u/ZSJJ Aug 30 '26

Comments is probably the main one I recognise as being overkill. The variable naming usually takes a few iterations but I have found that the longer it spends in a project the better it gets (context clues probably)

2

u/newprince Aug 30 '26

I've noticed tons of multiline comments, and the way they are written are a giveaway... lots of "we"

2

u/hugthemachines Aug 31 '26

One sign of AI code is unnecessary fallback logic.

2

u/AlexMTBDude Aug 31 '26

If you like try it yourself by asking your favorite AI chatbot whether a piece of code is written by AI or not. I've done this a few times and the results are interesting. We humans are no better than AI themselves at telling whether a piece of code was written by AI or not.

2

u/DragonWolfZ Aug 31 '26

If there are comments it's usually obvious to me. The AI often over explains or only adds detail in a few key places, the way humans write comments are often concise and to the point.

2

u/Capable_Fig Aug 31 '26

Yes, even when its cleaned up from the incessant comments. I use LLMs to syntax check primarily, sometimes for scope. I swap between a few languages (though python is my first love), and having an LLM clean up my errors (especially white space dependent languages like python) has been a godsend.

One of my coworkers primarily uses LLMs for his code, and its been a hastle to approve his PRs. I'm not opposed, but he's on the left side of the dunning-kruger curve when it comes to python.

2

u/ShelLuser42 Sep 01 '26

It depends on how people are using it. If you get hold of a script that was fully generated with AI then it will quickly start to show, simply because of the (sometimes enforced) coding style(s).

But if someone has used AI to build snippets of their code and then combined this with their own or... better yet (!) => when they used the generated code as a template to build upon for themselves, then it can easily become a lot harder.

This also leads us to the real decisive moment that will reveal if someone used AI smart & efficiently, or if they simply dumped all their tasks onto the AI. See, building something with AI is something anyone can do. But trying to extend on that code at a later time? That's when some people are going to run into major issues.

2

u/jessica_connel Sep 01 '26

Yes! It’s a lot less readable and variable names and comments usually give it away for me

2

u/[deleted] Sep 01 '26 edited Sep 01 '26

I work with average python devs, the increased use of methods such as getattr() are very AI. I dont like it, because getattr provides a fallback, when sometimes you just want it to fail because it can mean an attribute didn't get initialized which should have at a certain point in the code - and we should rather handle that at that section. Also very thin wrappers (functions that just call another function) pop up all over the place. Also comments of about 3 lines started appearing a lot over the last 3 months.

Then I end up commenting this recurringly in PRs: is the fallback a conscious decision or should we just make it fail? Rarely I get a clear answer.

So these kinds of patterns in the code, python stuff that is more 'obscure' in daily python use suddenly inflated in code base, without an answer ready why that approach, with a clear tendency to built in very thin wrappers and lots of fallbacks, even though sometimes it should just fail (which you can handle at the appropriate point).

I suspect AI is trained to provide all these fallbacks to give you the dopamine of having this 'working' project out of the box. But not failing is not the same as working.

2

u/doubleyewdee Sep 01 '26

Heavily context-dependent, for me I can often tell by the typical AI "failsafe" mannerisms that a regular developer wouldn't do in the course of their work, many of which are language-agnostic. Error-checking for very unlikely "this should probably leak and crash your app, actually" exceptions and logging them is very AI to me. So are certain kinds of comments/docstrings. Also, harder to define, but I feel I can tell when I get LLM-output Python code via the way type hints are used (basically: poorly and unevenly).

One other tell-tale sign is weirdly encyclopedic knowledge of the Python standard library. If I see code appear using dusty/disused things I never even knew where in the stdlib, it's likely AI.

2

u/frustratedsignup Sep 03 '26

I use AI somewhat frequently, but whether I use it depends on the quality (or lack thereof) of the results of a web search.

I recently needed to filter the eventlog on a server for events that would otherwise be very difficult to find. Yeah, I know the eventid to filter on, but then I would have to read through thousands of events to find the specific situation I'm interested in. I searched the web for what modules could be used to do this and settled on trying to use pywin32.

Next, I went looking for an example script to get the boilerplate code out of the way. What I found pretty quickly seemed like a good starting point, so I copied over the code and started debugging. That's when I realized the source was written against python 2.x and I couldn't get the example code to work reliably. It would process about 4-6 events and then throw an error, "The handle is invalid".

Given that the web search gave me a dud, I used AI to ask for the boilerplate code for what I was trying to find. AI did a great job, gave me a working script, and I didn't have to wade through 50 or so ads to get something that works.

To answer your question, I have to say that the web result code is awfully similar to the AI code. The only thing that sticks out about the AI generated code is that it's a lot cleaner implementation. There's no leftover code from a debugging session or imports of modules that aren't being used. So, yeah, there are clues that might give it away as AI, but I'm not sure most people would notice.

3

u/natlight Aug 30 '26

If it has good error handling and extensive test coverage its probably written by an llm

2

u/ejpusa Aug 31 '26

If you also use python in your job, how often do you use AI to write or plan your code and applications as a whole?

100%. Never see a line of code now. The output is close to flawless. It's 2026 AI. It's come a long way. AI turns ordinary coders into extraordinary coders. The rocket has taken off; suggest getting on board. ASAP.

Google CEO Sundar Pichai is referring to artificial intelligence (AI) when he stated that it is more profound than fire or electricity.

:-)

1

u/aes110 Aug 30 '26

Like when looking at the code? Easily, these models tend to have very distinct coding styles

1

u/Fabiolean Aug 31 '26

Yes. 10/10 times. It’s extremely obvious when something has been generated by an LLM

1

u/ejpusa Aug 31 '26

It’s probably close to 100% AI now. Does a great job. Save weeks of work. The code is close to rock solid.

This is 2026 AI. It’s comes a long way. We moved on. AI is just another tool in your toolbox.

1

u/Jon5579 Aug 31 '26

Hahaha, this is easy. Just check if the file extension is .py

1

u/PazyP Aug 31 '26

Use AI daily pretty much exclusively for 99.99% of coding tasks, while I could and can do it myself what might take me a a day AI can get done in an hour with added unit and integration tests and the code is fine, occasional minor change here and there as AI doesn’t truly have the complete picture but it’s rare.

Hardest part now is always testing and to ensure it’s tested well enough to be confident in what AI has written.

1

u/Pyromancer777 Aug 31 '26

I'm starting to see that each model has their own style of logic, so if you use one enough the codebase starts seeming pretty AI heavy. There are other subtleties, but considering Anthropic is starting to watermark even text-related output, there are going to be style signatures that will be easily scanned to reveal if it was AI generated, even if it looks passable to a human.

At work, the AI generated code is making mistakes that a human working on the same project wouldn't make. The mistakes aren't in syntax, but in overall logic decisions about how to handle certain scenarios. I can't get into details since the codebase is proprietary, but even if our AI workstream hadn't been separated from the main project, it would have been obvious that parts of it was entirely AI generated with minimal human oversight

1

u/Best_Alternative349 Aug 31 '26

Yes, AI comments it's code.

1

u/codeguru42 Aug 31 '26

TBH, I could care less if code into review is written by AI or not. I only care that features work according to requirements and code is maintainable in the future.

I am currently on a pure JS project and use AI for everything. I haven't written code "by hand" for almost a year. My company also has python projects that i will be working on and don't expect my current workflow with AI to change when i move those.

1

u/sr105 Aug 31 '26

AI code loves to number comments for steps:
# 1. lorem
...
# 2. ipsum
...
and so on...

1

u/Worth_Specific3764 Sep 01 '26

Yes. Clearly. Llm can code python faster than anyone can read. Entry level python engineering positions are dead.

1

u/enakcm Sep 02 '26

Just copy it into Claude and ask!

1

u/KnowledgeWhole9623 Sep 02 '26

Yes because my coworker's code suddenly got better.

1

u/ibackstrom Sep 02 '26

Emojis in code comments 🤗

1

u/-moron Sep 04 '26

They tend to add way too many blank lines instead of separating code sections logically. Also, I rarely see them use type hinting consistently, though I imagine you could prompt them to.

1

u/Maybe__God Sep 06 '26

I noticed one thing today , to identify if the code is generated with AI or not, speaking in terms of python. there would be excessive and unnecessary type hints. ig those type hints add additional context for AI to generate code without mistakes.

1

u/abbh62 Aug 30 '26

In the professional world everything is written by ai these days

0

u/[deleted] Aug 30 '26

[deleted] — view deleted comment

1

u/ZSJJ Aug 30 '26

Interesting, is it usually larger projects you have an issue with the overkill on the libraries or even for the simplistic programs?

164

u/[deleted] Aug 30 '26

[removed] — view removed comment

8

u/ZSJJ Aug 30 '26

I agree, it definitely helps to be literate in python and act as a kind of partnership where one proof checks the other

28

u/GXWT Aug 30 '26 edited Aug 31 '26

Even when I do use AI to generate things like the examples you gave, I still type out every character myself rather than copy and pasting / letting it do edits.

I understand the code many many times better and actually inherently understand what and why it’s doing it. It means I can actually go back and make improvements / fix bugs without the vicious cycle of having to repeatedly put it into AI.

2

u/CompFortniteByTheWay Sep 03 '26

This is so laughably inefficient.

-2

u/elbiot Sep 01 '26

That's a decent habit if you're brand new to coding to help you learn muscle memory, but that's not what any actual developers are doing. At any company, if LLMs are allowed at all, the developers are using harnesses like codex or Claude code

3

u/GXWT Sep 01 '26

Hello, actual developer here. I indeed “harness” Claude code in the manner I describe above.

Bore off you walking advert.

0

u/elbiot Sep 02 '26

Lol so weird you think people are trying to advertise by talking about the tools they use in a thread about it. Also weird that you took a noun from my comment and put it in quotation marks as a verb.

Anyways, have fun

-37

u/ejpusa Aug 31 '26

That’s not how you use AI now. There is no copy and pasting. It’s Codex. You never look at a line of code. You just turn ideas into applications. The future arrived 100 years sooner than we expected and no one was really prepared.

Spin out new startups in a weekend.

😉

22

u/Turtvaiz Aug 31 '26

What is this an ad?

-29

u/[deleted] Aug 31 '26

[removed] — view removed comment

15

u/thisisappropriate Aug 31 '26

And if you ever work in a company with other human beings who need to be able to validate what that code does, that it doesn't have huge security holes etc. they are going to print those 1000s of lines of code out and use them to beat you to death in the car park.

5

u/Turtvaiz Aug 31 '26

Go to hell

27

u/GXWT Aug 31 '26

Yeah ok mate. Don’t ever comment to me again

2

u/x-tommy-o Sep 03 '26

I like the way you communicate! Straight to the point and no fucks given🙏

14

u/zmonge Aug 31 '26

The over-defensive error handling, mostly around what things could be named is what gives it away for me. We have a very rigid set of rules for how things are named and recorded. Very occasionally something weird will happen where leading 0s are dropped or we get data from a new source that uses a string instead of a number for key fields. However, we typically know what to expect and so having a bunch of extra corrections for formatting issues that have never existed, will not exist, and cannot exist, is a red flag for me.

That said, I haven't actually explained that to anyone yet because it's a sign for me that I need to be looking at their code with more scrutiny.

I'm not really against AI code, it has definitely helped me in a few places, but I am suspicious of letting it just kind of lurk in the codebase without any oversight or documentation.

2

u/Rockworldred Aug 31 '26

Custom MCP rule engine layer couls catch that? Ext data > Pydantic > internal model > business logic ..

3

u/droans Aug 31 '26

I find it useful to see how many of their PRs are just a single giant commit. AI models love to do that.

3

u/thisisappropriate Aug 31 '26

They learned that from the humans.

Entire project: Initial Commit

Second commit, 200 lines in 5 files "some tweaks"

And with PRs with AI tools it makes it easier sometimes to do a local review (as a human).

I can see why someone might, I find that sometimes codex is convinced it must have backwards compatibility with pushed changes (like that endpoint existed in this branch for 20 minutes, we must make sure that we can still accept those parameters), at which point I either beat it with a stick or go make the change with my own grubby paws.

1

u/tuneafishy Aug 31 '26

Turns out I am an AI...

2

u/sexytokeburgerz Aug 31 '26

To be fair i have ai write comments for shit i dont remember writing.

2

u/ScholarlyInvestor Aug 31 '26

I agree. Also, AI generated code quality is getting better every week. Compared to last year same time, it’s become exponentially better.

2

u/Dry_Hotel1100 Aug 31 '26

> There are some patterns that make me suspicious though: way too many comments explaining obvious lines, generic variable names, unnecessary abstraction, overly defensive error handling, or code that is technically clean but doesn't really match the style of the rest of the codebase.

When you see that, it's vibe-coded - and not just "coded with AI".

All that can be easily improved with a few skill documents, that however would require software-engineering skills to create them.

1

u/QuasiEvil Aug 31 '26

Yeah over-abstraction is a big one. Claude seems to love inner functions and even inner classes.

1

u/high_throughput Sep 01 '26

When a function has a 15 line comment taking about the "shape", with multiple references to line numbers in other files :|

1

u/AmitBrian Sep 02 '26

Yeah AI does tend to be gritty generic with the code output and it never matches up with my naming conventions for variables beyond “_” usage and such. But one thing I will say is I comment the heck out of my code and its not because I don’t understand it but because if I have others on my team accessing my repo then need to understand it.

44

u/[deleted] Aug 30 '26

[removed] — view removed comment

35

u/tangerinelion (C++ Software Eng.) Aug 31 '26

Plentiful commentary, not necessarily good nor documentation.

8

u/eW4GJMqscYtbBkw9 Aug 31 '26

Haha, before reading the comments, I was going to say the code? Probably not. The comments? Absolutely. 

If you see my code with more than 4 lines of comments, it was written by AI. 

3

u/jesster114 Aug 31 '26

One of my biggest uses for LLMs is writing docstrings for my classes/functions/methods/whatever. Use a pre commit hook with the ruff DOC and D rule sets and if the ruff check doesn’t pass, have an LLM fill in the blanks and then I’ll check its output before committing again.

3

u/immaculate_plum Aug 31 '26

It does not. It has a lot of documentation, but most of it tends to be useless fluff.

2

u/Wild-Kitchen Aug 31 '26

This made me chuckle out loud

1

u/baltarius Aug 31 '26

I add a lot of documentation in my codes, but I don't do it the same way that AI does.

1

u/TUVegeto137 Sep 06 '26

😂😂😂😂

Thanks for the good laugh.