This take is unfathomable to me. How are LLMs not massively revolutionary, despite them not being infallible? This comment reminds me of there being competitions for finding useful purposes for electricity when it was first discovered. Imagine talking about the usefulness of LLMs while thinking that LLMs in 2026 just compress a few TB of data into a set of weights and that's all they work with lol.
Whichever side of the divide you're on, I think it's really weird that on a site like HN (where people have at least a passing familiarity with technology) there are such polarised takes on whether it's the next industrial revolution, or a technological parlour trick.
I'm giving away which side I'm on now, but most of the TAM have experienced the product at this point, and trillions of dollars have been invested. I would wager most other revolutionary technologies found their game changing, broad reaching applications by this point.
Did you experience the popularization of the WWW? There were massive disagreements even among smart tech-savvy people. We even had a stock market boom and just cycle associated with it.
Funnily, none of that mattered. What mattered is that enough ordinary people on the street found it useful, both for personal and business reasons. Ask yourself: are regular people using this tech, either as producers or consumers? And remember that this is the least powerful that it will ever be.
It's very hard to disagree with the point that it will get more powerful, perhaps in uenxpected ways.
I don't know that the average regular person is using this tech as a producer, and while it's hard not to consume it - I don't know if anybody consuming it really wants to. I'm in a bubble of people where we give it a lot more mindshare, but e.g my electrician is aware of the tech, knows what it does, and doesn't really care. I think you're right that if it could manage his books, help him rewire a switchboard, order inventory for him etc that would be very different.
> I don't know if anybody consuming it really wants to.
You don't know of people who ask LLMs questions? Or just chat with it for fun and to learn?
Maybe your electrician isn't interested. A pharmacist and a nurse I talk to are. Virtually everybody I've talked to uses it to some degree or another. I think it'll soon replace Alexa/Siri for most people, as well as google search.
I think the first parent post all this conversation originated from, pointed that LLMs are not groundbreaking inventions.
If people use it to replace voice assistants or search engines, you can see how this new invention is not really adding anything you already hadn't.
AIs in general are very useful, but apart from the campaign they did to change everything's name into AI (also well known algorithms and "old" machine learning), if you look at all the possible applications, LLMs are possibly the least useful of them.
Especially if you take into account how much money they spent, and how much effort they put to shove it in your throat.
If a technology is convenient for people, you shouldn't need to insist to make people use it. If it is convenient, people will use it in a natural way.
> If a technology is convenient for people, you shouldn't need to insist to make people use it.
This is like the railroads, and the tracks have been laid. Because of the enormous cost, it can't be left to "hope they'll find it useful," and has to be pushed like crazy, or we're going to be left with a train system with no goods or passengers, and no path into the future.
Personally, having AI as an intelligence I can call like it's a library from apps I build... and to help build those apps... I feel that the future is as bright as the sun. I've always believed in software, but I feel like a chef that's just discovered salt and butter.
I don't know what it means for the world stage, but I believe that software is the highest art, and it's just had an incalculably massive buff. As an artist, I am stoked. The possibilities for creation of good things are limitless, and if you can't see that, I can't help you.
However, I wouldn't necessarily invest in AI companies. I don't know how this all fits into the rest of the world, except that I believe in my own ability to make products, same as I ever did, but now with AI.
> This is like the railroads, and the tracks have been laid.
Except that for railroads I don't need people to convince me about how/when/why it can be useful.
Railroads came out to solve an issue we had (and then it evolved).
LLMs are not giving us any new solution, just different speed (better) and quality (worse) to solve things we co&ld already solve.
It's basically the same concept as fast fashion.
Worse quality, more speed, possibly more economic.
You can change your wardrobe possibly every year, but you will never wear good quality clothes.
Now you can write code at impressive speed, but it is worse in quality, and you need to review it more often than "normal" code.
AI code should always be fully reviewed and put into the correct context to make it useful, otherwise long term problems will void short term benefits
Nobody convinced me AI was useful. At this point, nobody could convince me it wasn't - it's like going from whittling stuff out of wood to having a kitted-out fully-manned machine shop.
It's clear from your words you lack experience and skill in this area - you've only got opinions.
I guess we might actually have similar feelings, except, you say "only speed", and "only economics". Only time and only money. As if those aren't two of the most valuable currencies on earth.
Yeah, because I can see some of my own thoughts and experience from a long time ago in your words, and my experience tells me loud and clear that they're outdated and wrong.
If people use [the Internet] to replace [Sears catalogs] or [paper mail], you can see how this new invention is not really adding anything you already hadn't.
It would have been a good counter-example, if only internet wasn't:
- adding encryption
- removing processing time
- removing geography
- removing logistic issues
... and much more at a convenient price.
They basically invented teleportation for sear catalogs and paper mail, can you see how this is different?
Also, Internet was built to solve a problem we had, and it solved it beautifully and at reasonable prices.
I for sure can understand it introduced different issues, buy this is another topic.
You can ask LLMs questions about an immense variety of subjects, and they can give you customized explanations to those questions. It is as if an acquaintance of yours had digested Wikipedia and tens of thousands of books and had infinite patience to help you understand whatever you are curious about. And while the answers are not going to be picture perfect every time, just like Wikipedia or a well-educated acquaintance, they will be generally very useful.
I understand exactly what the Internet of the 90s did and did not do, because I was there to witness it myself. I had these same types of conversations with naysayers back then. Guess who was right?
Maybe you have all the means to avoid sycophancy bias and other flaws LLMs have by design, this doesn't mean that everyone can use it the same way.
The fact the you were right in a previous topic, doesn't grant you objective truth.
You have your strong opinions on AI, and that's ok.
Fortunately not everyone has to share the same idea.
If you think LLMs can do better than you, feel free to use them in production and bring them to work with you, it's your choice.
Do not force others do the same, tho.
From what i hear in a small subset of local small businesses is that they are using it for backoffice stuff, like taxes, finding legal codes, organization, planning etc.
I’m remodeling a room in my house and I’ve used Gemini help me troubleshoot problems and it works pretty well. It’s come up with a lot of ideas that I wouldn’t have thought of. Of course it’s contradicted itself a few times too so you have to think about what you’re doing as well.
>Did you experience the popularization of the WWW? There were massive disagreements even among smart tech-savvy people. We even had a stock market boom and just cycle associated with it.
In the early phase of the Internet envelope, we all wanted to build the real Internet and destroy the AOL's and Compuserves' .. but now the Internet has turned into a mass of AOL's and Compuserves.
I think the same thing is happening with the silo'ization of LLM's. People don't want to have to use the "AOL of LLM's" for things - they want to build out their own infrastructure and have a pool of local LLM's (where once it was the company's own modem pool, etc.)
It is, oddly enough, parallel with the original arguments in the 70's and 80's regarding supercomputers versus personal computers, or the cloud versus locally managed resources, etc. We are still fighting this battle, just with higher bandwidth.
Do we operate a terminal with a fixed window into a bigger computer, or do we operate a heavier local computer with a proper interface?
Most people I know, blue and white collar up to and including surgeons and IT folks, use it as better search.
My wife is a GP, and all she would ever need is a reliable speech to voice recognition of medical jargon, in french. Not 98%, not almost there, just there.
Most people don't live in IT echo chambers like HN. For them, chatgpts are just another online gimmick that saves a bit of time vs googling things, or puts together some paperwork quicker, and thats it.
For me, I can see potential beyond but are largely unmoved by it. The price to pay, in fucking up our environment, losing skills and/or losing skills to build skills, making large swaths of population unemployed with no replacement in sight, seems much more like devolution and net loss. Extremely few winners and big bunch of losers. Very happy to be wrong here of course, but only time will tell and neither you nor me know for sure.
Because it’s so powerful and versatile. The other day my wife took a picture of our living room and chathgpt picked out the perfect rug. That’s both a better search and avoided, say, an interior decorator. In that scenario it’s kinda both.
But only a small part of AI applications are that search-like. I mean we could even argue if this is still only search, but that's semantics and boring. But even if we would, there are a lot more applications than pure search. So the GP's original claim that it's just an improved form of something that doesn't put people out of a job, and also puts large amounts of people out of a job, doesn't make sense. Framing tax advise as "yeah it's just a better way to search tax codes" is in the same boat. It's such a massive improvement of both searching and synthesizing that it's a bit weird to call it that. Like saying a 2026 car is just an improvement of a Model T.
I think we agree. I think we’ve barely touched the surface on its applications. It’s digitized reasoning. That’s hard to wrap one’s head around. My hope is that the vertical applications that gain traction aren’t from a handful of companies.
> Funnily, none of that mattered. What mattered is that enough ordinary people on the street found it useful, both for personal and business reasons.
Broad economic impact due to Internet boom in the the US came from 2 main categories:
1) New huge internet enabled tech companies appeared(Amazon, Google, Meta etc.), all created their own products, all were build on reliable foundational technology. LLMs is not a reliable foundational technology.
2) Existing legacy companies could utilize internet to connect their teams/departments/offices though a bunch of new software which were build on reliable foundational technology. LLMs is not a reliable foundational technology.
> And remember that this is the least powerful that it will ever be.
This mantra is being repeated but "serious LLMs's issues" I described are still there and will be there because they are part of how LLMs are built and work. Without addressing those you can't build products but LLMs's capability as a personal productivity tool will keep rising, yes.
The "best" possible outcome of LLMs to a broader economy might be that a smaller group of experts will be able to do the job in companies due to boost of their personal productivity and a bunch of people will be freed up(laid off) and they will have to go and work on something else and thus a boost of productivity in the economy. But it seems it won't be any low hanging fruits(problems to solve) this time as it was during the internet era. It is not like we out of problems: new cancer treatments, self driving cars, nuclear fusion, modular nuclear reactors etc. There is a huge value to capture there, here is the thing though, those are hard problems, it is not a new TikTok, gmail, netflix etc. Yes, people will have LLMs now but can we actually start solving hard problems with them? Because it might be the case that a gravy train of the last few decades for Silicon Valley is over, no more useless internet enabled services, no more billion dollar companies built on just applying internet to yet another thing and producing another digital product. People's free time is limited, its redistribution across digital services will not grow the economy, global internet penetration is already pretty high and won't grow that much, so there might not be much value to capture there.
The TAM of electricity is 99.999% of humanity, yet there was 82 years between Alessandro Volta's Voltaic Pile experiments and the first electrical grid in the world, Pearl Street Station, New York City.
A farmer may have seen an LLM answering their questions about how to make a less dry chicken sandwich, but he hasn't seen a specifically designed and tested harness that autonomously manages a crop harvester. There is not a lot of work in this space right now, because programming and math are infinitely more verifiable, and the capabilities of never models would probably invalidate any usecases, but if the model progress slows down, all attention will go towards making them work for any aspect of production.
Fair points (and I appreciate very much that they read like a human wrote them). As a counter point - and I know it's a weak one - a few years ago people were telling me that crypto was going to replace currency, and soon every person on the planet would be using it for every transaction. Many people believe that will still happen, but I don't think many serious people do.
I want to believe there is big bucks in this technology - my employer is tied up in it and so is my compensation. I just find it personally very unremarkable in a way that I never did with phones or the internet. When I got my first phone, or first started using Dogpile for research - I saw immediate value, and would have paid big bucks to keep it in my life. AI has had a few years and a huge amount of investment (time and money) and if it disappeared overnight I wouldn't pay $10 to get it back. I keep trying it, there's just something missing in my brain where it should be clicking for me :(
> a few years ago people were telling me that crypto was going to replace currency, and soon every person on the planet would be using it for every transaction. Many people believe that will still happen, but I don't think many serious people do.
As you say, that is a weak counter point. I do get what you're saying, but crypto flaws were built in from the start:
- Deflationary currency isn't going to be spent, it is going to be hoarded, if it would have any value at all. The design was self defeating from the very start.
- Technical limits of PoW. Obvious right from the start, which led to the block wars. PoS "solves" that but with other costs. And it still doesn't solve the first point.
Despite these, crypto did get adopted, just not in any way that crypto maximalists said it would. It got hoarded, as expected.
But the real test is: If crypto disappeared tomorrow, would the world notice or really care? I would argue, apart from people losing money, most of the world wouldn't even notice it was gone.
Nitpick or two. Holborn in London was a little earlier. Also neither was really a grid. That took another ~45 years. Maybe that's better for your argument - but I'm not quite sure that the analogy fully holds - as it's a different class of infrastructure problem.
>but he hasn't seen a specifically designed and tested harness that autonomously manages a crop harvester.
Eh, I'd say there is a lot more stuff like this being developed these days. Autonomous seeders are becoming more common and (semi-)autonomous tractors are in use.
I'd say a very large part of the in field work can be done now, and is using enhancements like vision models to identify potential problems that crop up to notify humans. It's when the machines have to interact in tight busy spaces or with non-farm traffic that control is handed over to a human.
That polarizing take is magnified by our failure to teach how to manage discussions that contain controversy and disagreement. Then there is the fact that most people's idea of debate is some game of dominance and not to find solutions.
We're still in early stages, but in just 2 years AI has presented higher education with the single most disruptive change in decades. Now a computer can do your entire coursework for you, is available to converse on a broad range of topics, and can accomplish unaided huge open-ended problems.
> most other revolutionary technologies found their game changing, broad reaching applications by this point.
I think your timeline expectations are miscalibrated. The steam engine goes back centuries. Even in the mid 1700s to 1800s, advances in engine design were decades apart, and the logistics of building and deploying steam engines mandated an uptake in years, even in perfectly-fitted applications.
Like these applications where there were existing manual-labor solutions that not only fought the technology but were still competitive, AI and LLMs weren't born in a vacuum. In order to revolutionize, it must displace, and people are rightly finding ways to do their jobs in more productive ways that moderate adoption speed.
Can you name some other technologies that have exploded from 0 to billions of users in just 3 years?
We absolutely are - but we’re still at the “weirdo factory owner installs experimental electric motor” stage. You look at what’s going on in robotics, look at GROOT/Isaac, and the circle closes quite neatly. World’s going to change in ways we can barely even imagine, no more than someone in 1720 could imagine the buffet car on an intercity express train.
I'm with you on this. I remember when the Internet became a thing, how revolutionary it was to all areas of my life.
This is comparable.
While I dislike the bonkers valuations, and "were building Agi so it tells us how to be profitable" is onion worthy statement LLMs are an absolutely revolutionary technology.
Even with all the hallucinations.
Imagine telling someone 15 years ago Internet/Google is useless because people sometimes do not tell the truth online... It's like that.
I also hate the fact AI is being used as justification to grab all compute in the world and lock it up in one country's datacenters.
I hope this endeavour fails, but sadly being realistic I have to admit I think the so called "AI bubble" will not pop. Instead the companies will be bailed out with printed money.
I recently looked up there are approximately $20Trillion in circulation. Even if they print extra $2T it will dilute existing money supply by 10%. So everyone that uses USD as a currency will pay for the datacenter build out wether we want it or not.
All the compute will be slurped from the market for this and companies like nvidia that get used to 50bln deals will never go back to making consumer stuff.
I never thought I'll live to see the PC revolution reverse, but that is what seems to be happening.
I strongly agree. I cannot understand how anyone could seriously use this technology and come away thinking it's mostly useless. I suspect there is a LOT of bias baked into their opinion.
I only used Claude a bit, but one of the things I dislike about it, is that it starts to 'push back' when you swear at it, saying things like 'if you continue like this, I won't be able to work with you' and such. I'm like MF'er you're a token prediction algorithm, what are you talking about, and it just makes me irrationally dislike it more. Codex otoh just lets you vent and straight up ignores such outbursts.
"Perhaps that can be done DIY from an PVC pipe with an hot air gun or a gas burner to soften and shape the end."
When I used to make my own PVC didgeridoos, I would melt candle wax and then dip one end repeatedly into the wax to build up wax layers until it had the desired thickness and shape.
Twenty years ago my neighbor, a retired surgeon, made me a PVC didgeridoo and did the wax buildup thing - I still mostly play that didgeridoo. Years later my wife bought me a traditional heavy didgeridoo from Australia, but it doesn’t play as well; still, when I played at a friend’s wedding I used the Australian one because it looks better :-)
I had excellent results using a large section of black bamboo, though I forget the exact taxonomy (lako?). I meticulously beat out the segment walls, then with a rasp fastened to a long stick, filed down the ridges. After sanding, I finished it with oil based stain, which necessitated it living outdoors for a while. In the end it proved a fine primitive instrument. I gifted it to someone and miss it. I can attest to the therapeutic effects of mastering the didge.
PVC works, but the acoustics do seem superior with actual plant material. Certainly the feel.
The one without the relieve valve is nicer to use because it's (much) easier to clean. Source: I've cleaned these things pretty much every weekday for the last 2 or 3 years.
That sucks. I have both and the ones with the pressure relieve valve are a pain in the ass to clean. You have to pull out the rubber inner thingy, you can't get a towel inside the hole that thingy goes into, and in general the rubber thing gets lost easily. I wish Thermos would send me a few of those 8 million stoppers, I'll promise I won't be a dumbass with them :(
That's not very empathic of fellow people who might just have mistakenly forgotten food in the container.
It's not like they were intentionally using this for brewing some illegal substance or misusing it in a way specifically forbidden in the manual or obviously unsafe (e.g. removing a magnetron and all of its protections from a microwave to make pretty wood carvings).
Can you also guarantee with absolute certainty that you'll never forget them anywhere another person who's unaware of the contents or the danger could find them?
If I buy a lawn mower, I don't expect anyone to guarantee with absolute certainty that there will never be a person who thinks 'hey maybe I can just stick my hand in there to unclog it' and gets their fingers chopped off. Probably a wrong analogy but I can't even be bothered to think it through, of course fermenting food causes things to explode, how is that even remotely the fault of the manufacturer? I loathe the times we live in where everything needs to be padded and cushioned because heavens forbid we start expecting people to think for a second. I mean, the valve requires a crevice where all sorts of things can grow (I've seen them, I've cleaned these things after they were left in a school bag throughout two weeks of school holidays with food in them), I'm not going to complain that it would somehow be Thermos' fault if one of my kids got sick off something getting stuck in there. At some point, there is such a thing as 'personal responsibility'.
I get your take that people should take the responsibility for things they are doing.
Without arguing your point there are a couple more things to consider from the perspective of the company and the society at large.
From the company perspective, if their product gets a bad reputation the sales will be worse. This could even extend beyond the one product. It doesn't matter if it is fair or nuanced at all. Even if everyone is a moron, investing in protecting the morons from themselves could be a good business decision.
From the society perspective, there is a positive-for-business intent in forcing a baseline for consumer safety and satisfaction. Threading that needle is of course hard but it makes it easier for a free market of consumer products to exist as a whole if the consumers can offload some of the investigation required before committing to something. The idea is that in a 100% buyer beware situation there is less buying overall and the market can't be big and as full of options because the cost/risk of buying isn't worth the end goal. You can make the counter argument that the trust should be part of the brand value but it might enable new companies and new products more effectively (making more good options in a free market) to reduce the consumer risk of purchasing their products.
Additionally, if everyone is doing the same prerequisite research (is this safe before I buy), it makes sense to consolidate this step either through curation/certification groups (the people who care fund it themselves - makes sense for specific preference choices [eg "plant based", "cruelty free"] or niches [eg "gluten free", "non gmo"]) or regulation (everyone funds it collectively - makes sense for broad application like "will I get food poisoning" and "am I risking being maimed").
Beyond personal purchases there's also society wide implications worth preventing for things like if a million cars exploded or if 10% of profession X and profession Y ended up losing fingers.
Like I said, not arguing with you about if people are dumb and if companies should be required to pay to deal with that, just pointing out there are other reasons a system might be in place beyond just a patronizing nanny state situation.
>Can you also guarantee with absolute certainty that you'll never forget them anywhere another person who's unaware of the contents or the danger could find them?
Why does he need to do that?
We're talking about a product that lightly injured ~20 people for ~8mil units sold and seriously injured ~3.
Should be be keeping his champagne in a protective enclosure?
I've seen Champagne disappear faster off the shelf more so around MBA's who are celebrating accomplishments having dubious value, compared to engineers who have actually achieved remarkable milestones ;)
I wonder if they track how many people are sickened by the difficult-to-clean valve, because I bet it's a lot more than 3.
Luckily I got one of the valveless models, and you bet your ass I'm keeping it. Maybe I'll stick an "open away from face" label on top or something, but I'm not about to go increasing my risk of food contamination.
There's not really any way to make anything containing hot pressurized foods safe from people pointing it at their face. Either you get the lid in your face or you get steam in your face. The poor hygiene the vent creates is just an added bonus.
I'd rather they slap a warning on it, like everything else that you can't safely point at your face.
"LLMS are good at "find me a two week vacation two months from now"?"
Of course they are. I gave one a similar prompt a few weeks ago, albeit quite a bit more verbose (actually I just dictated it, train of thought, with couple of 'eh actually, forget what I just said about x, do y instead") and although I wasn't brave enough to give it my credit card and finalize the bookings, it would have paid for the bookings I had it set up for me, had I done that. I gave it some RL constraints, like "we're meeting friends in place xyz at such and such date, make sure we're there then" and it did everything from watching we wouldn't be spending too many hours driving per day to check that hotels are kid friendly to things to do and see and what public holidays there are so that we know when supermarkets close early and a bunch of details I wouldn't have thought of. It checked my (and my wife's) calendar, checked what I had going on work wise, etc.
That is a fully solved 'problem' man. LLMs will run the whole thing for you. Just provide it with the login details to booking websites and you're off to the races.
I did have it upgrade the car, even if that pushed the cost outside the budget I gave it. Next time it'll know LOL.
It's a matter of getting used to things. We're only a few weeks further, I maybe would have given it now. It'd need some way to keep it private I guess, maybe I could have used a one off CC number. Those are just technicalities at this point. It got me to the point where I just had to enter my details and click a few confirm buttons. Those are solved problems. I'm not sure why the denialists here are saying those things are 'impossible'. I mean I've seen them happen, what do you want me to say? Claiming this is 'just hype' is ostrich behavior. I've been playing with an abliterated Gemma 4 yesterday on my local machine. Yes it would take longer and require a bunch of harness fiddling, but even if OpenAI and Anthropic would collapse tomorrow, I'm confident I could still do the exact same thing the day after with with what I have right now on my hard disk. I'm not sure what you want me to tell you mate. Yes there's rough edges to work out or just in general workflows to improve but the ideas are way beyond 'proof of concept'. There's people like myself using these things for purposes that 6 months ago were science fiction. I don't care if you believe me or not, I'm just some dude on the internet, but level of delusion on how 'inferior' these models (with proper harnessing) are is mind boggling for someone like me who sees it happen literally 20 centimeters to the side on my screen from where I see people claim that those things are impossible.
I have it, it's great. There's a free one, I paid a few bucks for the full set. Guy has a Youtube channel too where he shows how he does a few of the designs. Good guy, I had some troubles with the payment getting through to him and then the download didn't work for some reason (some weird combination of issues, don't remember details), and he just send me the whole pack without even knowing if I was going to actually put in the effort to make the payment work.
Why would one want to couple these two? Doesn't that couple, say, your API interface with your database schema? Whereas in reality these are separate concepts, even if, yes, sometimes you return a 'user' from an API that looks the same as the 'user' in the database? Honest question, I only just recently got into FastAPI and I was a bit confused at first that yes, it seemed like a lot of duplication, but after a little bit of experience, they are different things that aren't always the same. So what am I missing?
The ORM doesn't force you to use the DB model as your API schema. It's a regular Pydantic BaseModel, so you can make separate request/response schemas whenever you need to. For simple CRUD, using the model directly saves boilerplate. For complex cases, you decouple them as usual. The goal is not one model for everything, it's one contract. Everything speaks Pydantic, whether it's your API layer or your database layer.
You might be interested in a library that flips around the concept of an ORM, like sqlc [1] or aiosql [2]. You specify just what you want from the database, without needing to couple so much API with database tables.
A lot of people have this misconception that Pydantic models are only useful for returning API responses. This is proliferated by all-in-one frameworks like FastAPI.
They are useful in and of themselves as internal business/domain objects, though. For a lot of cases I prefer lighter weight dataclasses that have less ceremony and runtime slowdown with the validation layer, but we use Pydantic models all over the place to guarantee and establish contracts for objects flowing thru our system, irrespective of external facing API layer.
One advantage of something like attrs/cattrs is you can use the regular attrs objects inside the module without all the serialisation/validation baggage, then use cattrs to do the serialisation at the edge where you need it.
With proper DRY, you shouldn't need to repeat the types, docstrings and validation rules. You should be able to say "these fields from user go on its default presenter, there are two other presenters with extra fields" without having to repeat all that info. I have a vague memory that Django Rest Framework does something of the sort.
This feels hard to express in modern type systems though. Perhaps the craziness that is Zod and Typescript could do it, but probably not Python.
With this you don't need to have two sources of truth on the backend. Previously you will end up with one set of DB ORM level validation and a second set of validation on the data transfer object and you have to make sure the types line up. Now the data transfer object will automatically inherit the correct types.
The two sources of truth are for two disparate adapters. Neither the API nor the DB define the domain, but both must adapt the domain to their respective implementation concerns.
The ontology of your persistence layer should be entirely uncoupled from that of your API, which must accommodate an external client.
I'd rather define my db domain in-code so I do not have to worry about writing the queries without type hinting.
Raw sql -> eh, I don't have the patience
Raw sql w type hints -> better, I at least get a compilation error when I do something wrong, and preferably a suggestion
ORM -> this usually introduces it's own abstraction that needs it's own maintenance, but at least it's more code-oriented.
Yes, SQL is an awesome solution to querying DB's, hence I prefer option 2
Well yeah, of course. Sorry, when I said "DB" what I should have said was "data-layer," and this can include: repositories, ORM models, query-builders, etc. All of these are type-hinted "db domain in-code" and, still, not one coupled to your API.
I also find it really strange this weird ORM fascination. Besides the generic "ORM are the Vietnam War of CS" feeling, I feel that with average database to ORM/REST things, end up with at least one of:
a) you somehow actually have a "system of record", so modelling something in a very CRUD way makes sense, but, on the other hand, who the hell ends up building so many system of record systems in the first place to need those kinds of tools and frameworks?
b) you pretend your system is somehow a system of record when it isn't and modelling everything as CRUD makes it a uniform ball of mud. I don't understand what is so important that you can uniformly "CRUD" a bunch of objects? The three most important parts of an API, making it easy to use it right, hard to use it wrong, and easy to figure out the intent behind how your system is meant to be used, are lost that way.
c) you leak your API to your database, or your database to your API, compromising both, so both sucks.
The vietnam of computer science was written 20 years ago (2006 even), and didn't kill off ORMs then. We've only had 20 years of improvement of ORMs since then. We've long ago accepted Vietnam (the country) as what it is and what it will be in the forseeable future. We should do the same with ORM.
I for one don't want to write in a low level assembly language, and shouldn't have to in 2026. Yet, SQL still feels like one.
I've written a lot of one off products using an ORM, and I don't regret any of the time savings from doing so. When and if I make $5-50M a year on a shipped product, okay, maybe I'll think about optimizing. And then I'll hire an expert while I galavant around europe.
SQL is a pretty high-level, declarative language. It's unnecessarily wordy though, and not very composable.
The problem with ORMs is that they usually give you a wrong abstraction. They map poorly on how a relational database works, and what it is capable of. But the cost of it is usually poor performance, rarely it's obvious bugs. So it's really easy to get started to use; when it starts costing you, you can optimize the few most critical paths, and just pay more and more for the DB. This looks like an okay deal for the industry, it seems.
Suppose an API GET /users/:username call returns a "User" type. If returns the the same type as in your database, wouldn't you also get their password hash as well with that request? How do coupled frameworks deal with this?
reply