6 ms·
OP, don't read this as a direct criticism of you. I think the age of AI has really cheapened work like this. It's clear this library was vibe-coded; it's clear
by redfloatplane 1y ago
OP, don't read this as a direct criticism of you.
I think the age of AI has really cheapened work like this. It's clear this library was vibe-coded; it's clear enough that the python version of the library originally posted yesterday was vibe-coded; I didn't look at the original library but it would shock me not at all that it was vibe-coded. Often just one or two commits and a functional library, emoji all over the readme, "Clean and easy-to-use API", etc.
In many ways this is pretty amazing. Only a few years ago it would have been a huge pain in the ass to come across some valuable library only for it to be locked in some language I didn't understand or wasn't working in at that moment. But in other ways, maybe it feels a bit "cheap" now to do `claude -p "port this library to $LANG, make sure it works, do a good job" and I'm not sure there's a ton of... accomplishment? craft? care? in it.
- deleted 1y ago[deleted]
- tobyhinloopen 1y agoAI also loves to explain what code does with stuff like this: // Check if sensor is available if (sensor.isAvailable()) { // Read current angle double angle = sensor.readAngle(); Which, to me, is a clear indicator of the author (being AI, I hope) not caring about code readability.
- ofrzeta 1y agoYeah, it's typical for LLMs. A comment anti-pattern. I wonder if LLM explainability can deliver and answer on "why" they are doing it.
- numpad0 1y agoThis one is hallmark of Arduino sample code, which consists a majority of materials found on the internet regarding sensors and code. I think the original human intent is to inflate mental share on hardware and/or time domain issues as those are just routine occurences in Arduino projects.
- mort96 1y agoI wouldn't be surprised if it improves the language model's ability to write code. By inserting useless comments like that, its context will contain a very recent "prompt" of what it's trying to do when it actually writes the code.
- bapak 1y agoI need to create an AI agent that comments on any PR when it finds useless comments
- Aurelius108 1y agoOddly enough I find senior engineers at my company demand ridiculous comments like this oddly enough. I've found that a 1:3 comment:code ratio (basically a comment every 2-3 lines with a new line separating each block) is the only thing that will prevent some annoying code review comments asking for clarifications.
- tobyhinloopen 1y agoGive them a copy of Robert C Martin’s Clean Code hah
- walthamstow 1y agoI'm fighting this shit so hard at work every day, every PR review. The LLM writes comments like someone who can't read code is going to read it.
- balamatom 1y agoBold of you to assume the majority of developers can read code.
- jay-barronville 1y ago> Bold of you to assume the majority of developers can read code. Haha. Bold indeed.
- Aurelius108 1y agoUnfortunately staff engineers at my company will demand annoying comments like this so I don't think it's necessarily a sign of vibe coding
- socalgal2 1y agoI get worse. I write a test TEST(SubSystemABCTest,CheckIfAIsNegativeItThrows) { .... } And I get told all tests need a comment so I copy that line and add spaces between the words. WTF! >:(
- Aurelius108 1y agoI’ve run into this as well, it’s so obnoxious. Now I just go into multiple cursors mode and type the same exact stuff multiple times haha.
- saagarjha 1y agoOne would hope that the principal engineers above them have more sense…
- hackingonempty 1y agoWhat if a human wrote all of the comments in the function first then wrote the code? Should they then delete the comments?
- tobyhinloopen 1y agoYes 100%
- moshib 1y agoAt my $CORP job, I often see engineers enamored with creating new things. I completely understand the appeal -- it's fun to create something new, without preexisting constraints, with full ownership of the codebase. However, the real challenge is what happens _later_, when the thing is done. Most people don't really think about maintenance, and move on to other things, making the thing they worked on stale and stagnant. I think this applies here too: Vibe coding lets us create new _things_ quite easily, but we see value in places other than the sheer the existence of the project. We care about how the project is maintained, if it has a userbase, contributors, longevity. I think this is also part of why it feels so "cheap" and not genuine.
- teiferer 1y agoAs an "AI" skeptic, let me ask an out-of-character question: Could such maintenance be automated or at least heavily simplified with coding agents? Looking over whether something breaks when gcc is upgraded, automatically updating if needed, updating best practices, automatically reproducing reported issues and proposing fixes ... too much of a dream?
- redfloatplane 1y agoYes, definitely some of it can be simplified or automated. I've been migrating various apps from a docker-compose to a kubernetes environment. Spending a day writing a solid prompt document and running some agent on the repos involved has drastically sped up my workflow. The integration hell isn't much easier, but I spend _far_ less time actually writing configurations, yaml files, looking up docs, etc, which frees up my time so that I can deal with the workplace politics involved... actually, maybe I want to go back.
- redfloatplane 1y agoYes, indeed. I think that's why I haven't published much code in the last years since I vibe-code everything I build now and I have essentially no intention to maintain it once it's 'working'
- qq66 1y agoOn the other hand, this library probably wouldn’t exist without vibe coding, and you might never have known that the lid angle is readable.
- redfloatplane 1y agoI think that's the thing I'm trying to say. _This_ library might not exist but anyone with an Anthropic account and the knowledge that there is a readable sensor can make it exist just as easily.
- joenot443 1y agoI completely agree. I’d be so much more impressed if OP had come up with an interesting use case for this “library” rather than just writing a single prompt and firing up a Show HN macOS has hundreds of APIs. I’m not really convinced every single one needs a Claude wrapper library, nor am I convinced OP did any amount of interesting engineering work here. It’s a bit like releasing a music album comprised entirely of Suno tracks - sure, it’s there, you can press play, but is it something to be proud of?
- numpad0 1y agoThis couldn't have existed until someone else done it manually in Python and posted here on HN. The author likely fed that code to Claude or free tier Gemini.
- saagarjha 1y agoDid you see the link to the repo that inspired this?
- aa-jv 1y agoI think its easy to criticise vibe-coded work, if you're into programming for the sake of programming. But if you're into programming for the sake of the user, none of this matters. For me, I appreciate the clean, complete documentation and code generated for use in this project - I see nothing wrong with it, its useful and functional, and I can easily integrate this library into an app I'm building to get the screen angle. From this perspective, for the sake of the user/developer, I'd say things were definitely improved over Plain Ol' Human Code™ ...
- redfloatplane 1y agoHa, I'm not into programming for the sake of it. I vibe-code all the time now and don't think I've written a line of code by hand in over a year. I'm really not trying to criticise this library itself and I agree that in many ways it's quite good. What I think I'm trying to say is that this specific kind of thing now takes everyone the same amount of time to create. It's "cheapened" this specific type of code. I'm not trying to say this particular library is bad or anything, just that converting some small library from one language to another no longer really holds much value, since essentially everyone can do exactly the same thing exactly the same way now, for the same time cost.
- aa-jv 1y agoI think the point where we diverge is that this is a good thing: >everyone can do exactly the same thing exactly the same way now, for the same time cost. It doesn't have to be cool. It just has to work.
- redfloatplane 1y agoI'm not sure we diverge in this sense, I also think that's a good thing, if not the most amazing thing about modern programming! The democratisation of hyper-personal computing is incredible. Now anyone(-ish) can build exactly(-ish) what they need to create whatever they want to create. What I suppose I'm unsure about is the value of publishing utility code when the cost of bespoke creation is so low. But there are a couple of interesting perspectives in the responses so now I have to go away and think about it some more :)
- bapak 1y ago> I'm not sure there's a ton of... accomplishment? craft? care? in it. Who cares? What's important is that now I have a useful library. The only complaint I'd give is that it might not be super optimized, but it's open source so you can instruct your agent to take it and optimize it for you :)
- redfloatplane 1y agoThis is pretty much what I'm trying to get at. Why would you even begin with _this_ library when you also have an agent that can build precisely the thing you want with the abstractions, constraints, etc that you want? What value does _this_ library have, considering that it takes you _exactly_ as much time and effort to build your own?
- Fnoord 1y agoIn my world, using Claude is not free as in beer. It might be in yours, but in mine it isn't. I can use LLMs locally and remotely but there's always a cost attached to it (privacy is also a cost). I feel like it is a painter who devalues the works which can be made with tools like Photoshop and Illustrator. It feels like elitism, while you could also value the lower barrier point of entry.
- redfloatplane 1y agoThat's a very fair point in regards of the cost. I should have thought about that more. The analogy is very interesting, but I think perhaps I didn't do a good job of articulating my point - I feel I was trying to say that everyone*, myself included, is a Photoshop user now, and we know how much work it is or isn't to achieve some goal with it (which was previously impossible or difficult when we all just had paintbrushes and easels). I'm not doing a good job of articulating my point now either unfortunately. Perhaps I'm trying to say that we all* own photocopiers now? I'm not sure. I appreciate you taking an opposing view. I will think about my opinion some more.
- 1y ago
- madduci 1y agoAnd the Hungary Notation, typical of Win32 APIs?
- boxed 1y agoA class for no reason is a bit weird too. This is just not idiomatic C++.
- numpad0 1y agoThere do seem to be some of young brilliant minds today taking "with AI you can be xxx" too literally, thinking the sole remaining distinction between them and all the rich geniuses in the world is willingness to prompt something. They're not incentivized to fix that skewed perceptions because they have nothing else to reinforce their self esteem and "LLM is AGI" is giving them the crutch they desperately need. They'll be hard to de-program when the time comes...