LLMs contexts are fast to overload, as the article states.
That's why he writes smaller, specific packages, one at a time, and uses a web UI instead of something like cursor.
I had the same issue as you a few days ago. By separating the problem in smaller parts and addressing each parts one by one it got easier.
In your specific case I would try to fully complete the business logic one side. Reset the context. Then provide the logic to a new context and ask for an interface. Difficulty will arise when discovering that the logic is wrong or not suited to the UI, but i would keep using the same process to edit the code. Maybe two different contexts, one for logic, one for UI?
I'm french. Live in Paris. I do not understand the excitement the world has for Notre Dame.
Question for you, reader: what does the fire and/or the rebuild means to you? Why do you care?
I'm guessing it's because of "The Hunchback of Notre Dame", which if I recall correctly, Victor Hugo wrote to (successfully) stimulate desire to repair/restore the cathedral around 1800.
For me, personally, I think that Gothic architecture is the height of beauty, especially the interior. Notre Dame is one of the first examples, and was built quickly enough to have a consistent architecture (also Chartres and Amiens). Many Gothic cathedrals took 100 years to build and you can see variations in the architectural style in the different pieces which lessons the beauty somewhat. I also like the French circular apse rather than the English square apse (although that does allow for a gorgeous, huge window).
I also think beauty is important, especially in buildings, and Notre Dame is just a great example. It's beautiful inside and out. I've even spent quite a long time just enjoying the beauty of the back side.
For a lot of cultural/literary reasons, I think it's just iconic in a way that many other (at least equally beautiful) cathedrals--that most people probably couldn't even name, even the ones in Paris--are not.
I consider it to be a more recent (but still very old) entry in a category of human constructions that also includes the Parthenon, the Colosseum, the Taj Mahal, Angkor Wat, Machu Picchu, and Stonehenge.
I visited Notre Dame the first time I was in Paris, stood in the queue, climbed the stairs and took the photos everyone takes and have positive associations of the trip. The age, location and the view all help make nice memories that I guess many visitors feel. Victor Hugo & Disney probably add to that for others.
The trouble is the justification of a subscription is evaluated differently by businesses and customers, and both perspectives are rational. If you’ve got servers to pay for, subscriptions are a very appealing model since it makes the “is this business sustainable” math very easy (and less charitably lots of businesses are after that sweet sweet subscription revenue because it tends to be sticky). As a customer, I think it’s also very reasonable to get annoyed that “everything is becoming a subscription” and say “why would I pay this much for something I might need once in a blue moon.”
GP did say they understand why. Doesn't mean it's compelling from the other side.
'Pay for what you use' (micropayments?) seems under-explored outside of cloudhosting to me. Some small cost per meal solves the same problem while seeming more reasonable (or more obviously reasonable) to the consumer, doesn't it?
Honestly, the servers an app like this would need would be a $3/mo VPS. I'm not arguing about the price, the author can charge whatever he wants, but I don't think he'll get many customers that way. It's a good thing that the server requirements are minimal.
OP mentioned this is a “simple app”. They should follow the example of the author of parcelapp.net, which charges less than 5 EUR a year. That’s 50 k€ per year (judging by the ten thousand of reviews (4.8/5 star average) on the Apple App Store. Without taxes, of course.
> There are servers needed for the app to work, right?
But why?
This is described as "a simple app, in which we listed all the recipes we ever prepared, and it would propose randomly three of them. We would then choose together one of them."
You could, if you chose to, built/architect that in a way that doesn't require a backend at all.
You can use deep link URIs to send a _lot_ of data in a link in an email (like literally gigabytes on iOS). Easily enough data to send each other newly added meals/recipes.
You could also encode recipes in QR Codes, so one person enters a new recipe and the other can scan a QR Code the app generates to grab it - you can get about 4kb into a high density QR Code that'll read reliably off a phone screen.
Use one of those to maintain the whole meal/recipe database on each device, no backend required.
Maybe use a date based PRNG so both ends will pick the same "three random recipes" every day.
Send messages between apps as emails with deep links in them, so one user can use the native iOS "share by email" widget to send a "hey, what do you want for dinner" email, with an app generated message with three deeplinks, one for each random choice. Recipient responds by tapping the deep link for their recipe choice, which opens their version of the app - and the app digs the data out off the deeplink URI to pres3ent a "share your choice" button that also uses the native iOS "share by email" widget to send the response back to the first user.
Tapping links in emails and sharing via email isn't as "nice" as an app with a centralised database and push notifications, but it also has zero ongoing cost to run and you know for sure the developer has no lever to enshittify the service, and has no user PII or usage data to sell to surveillance capitalists.
Hmmm, I wonder if you could do this entirely as a web app?
Question for people writing highly complex SQL queries.
Why not write simple SQL queries and use another language to do the transformations?
Are SQL engines really more efficient at filtering/matching/aggregating data when doing complex queries? Doesn't working without reusable blocks / tests / logs make development harder?
Syntax is one thing, but actual performance (and safety/maintenance) is another deal?
If I need to join a million rows to another table and then calculate an aggregate value, and do it all in a single query, it's fast. It might only take 0.01 seconds.
Whereas if I make separate queries to retrieve a million rows, and a million rows from another table, then it's incredibly slow just due to the data transfer. No matter how conceptually easier another language may be. So it might take 30 seconds for repeated sequential serialization and network and deserialization.
And even if you're looking up individual rows (not a million), with lots of joins that would be lots of round-trips to the database which multiplies latency and load -- so even if you can still get your final result quickly (e.g. 0.01 seconds rather than 0.001 seconds), the load you can handle drops by the same multiple (e.g. you can now only serve 10% as many users).
The general rule of thumb with databases is that they can be super-fast when everything is done on the database machine in a single query and your final result is a small amount of data (assuming everything is indexed properly and the query is written properly). But they become super-slow when you're doing a bunch of queries in a row, and where those intermediate queries can return massive amounts of data, or (even worse) need to send back massive amounts of data.
I've worked on a few SQL systems used for analytics and ETL.
My users fell into (for the purposes of this discussion) three categories:
1. Analysts who prefer sheets
2. Data scientists that prefer pandas
3. Engineers who prefer C++/Java/JavaScript/Python
I'm fairly sure SQL isn't the first choice for any of them, but in all three cases a modern vectorized SQL engine will be the fastest option for expressing and executing many analysis and ETL tasks, especially when the datasets don't fit on a single machine. It's also easier to provide a shared pool of compute to run SQL than arbitrary code, especially with low latency.
Even as a query engine developer, I would prefer using a SQL engine. Performing even the basic optimizations a modern engine would perform -- columnar execution, predicate pushdown, pre-aggregation for shuffles, etc -- would be at least a week of work for me. A bit less if I built up a large library to assist.
I've heard great things about Pola.rs performance. To get there, they have a lazy evaluation so they can see more of the computation at once, allowing them to implement optimizations similar to those in a SQL engine.
In the early days, even as I appreciated what Pandas could do, I never found its API sane. Pandas has too many special cases and foot-guns. It is a notorious case of poor design.
The problems of the Pandas API were not intrinsic nor unavoidable. They were poor design choices probably caused by short-term thinking or a lack of experience.
On eager vs lazy evaluation -- pytorch defaulting to eager seemed to be part of the reason it was popular. Adding optional lazy evaluation to improve performance later seems to have worked for them.
I'm not interested in loading all the data in memory, or swapping it out if it doesn't fit, but also it may be a lot of data, and just moving it over the network is hard.
I have tests. I have reusable blocks (SQL functions, WITH blocks and views). I don't have logging though.
I can put the result in a non-materialized view and have it update in real time as the data changes. Or I can toggle it to materialized view and now it's snapshotted data.
Finally, views that depend on views that depend on views get automatically optimized by the query planner. You need a lot of very tricky custom code to start approaching that.
> Are SQL engines really more efficient at filtering/matching/aggregating data when doing complex queries?
As others have said, yes. In most cases, the more complex the query the better the result.
> Doesn't working without reusable blocks / tests / logs make development harder?
SQL isn't a programming language, it's a query language. You're effectively writing a single expression that describes the shape of the data that you want and then then the RDBMS goes off and finds the most performant way to retrieve the data that matches that shape. It doesn't compare well with procedural programming.
The closest "languages" that comparable to SQL are HTML and CSS. However you manage HTML and CSS is also how you can manage SQL.
>> Doesn't working without reusable blocks / tests / logs make development harder?
> SQL isn't a programming language, it's a query language. You're effectively writing a single expression that describes the shape of the data that you want...
Exactly this. Generally speaking, your SQL queries won't have "bugs" the way that you can create bugs when writing a function.
The challenging parts of building a complex query are usually 1) getting it to function at all (just being a valid SQL statement for your tables that gives you your desired output fields), and 2) making sure it runs performantly on realistically large table sizes (usually in milliseconds as opposed to seconds), which may involve rewriting things like joins vs. subqueries and/or adding indexes.
A lot of bugs in functions come from edge cases or different combinations of paths through code or unexpected combinations of parameter values or math formula errors or whatever... but a SQL query won't usually really have any of those things. It's just a single transformation that basically either works or doesn't.
One reason SQL has become more popular lately is as an API for map/reduce.
Before you would write a Java/c++ class that would do the map/reduce job for you distributed over 100s of CPUS. And you would feel like you were on the bleeding edge doing innovative stuff.
Turns out that SQL is a perfect API for map/reduce.
Everything you write in SQL can be transformed into a massively parallel job. And you don't even know about it.
This is the secret behind BigQuery and Trino/Presto/Athena.
> Why not write simple SQL queries and use another language to do the transformations?
> Are SQL engines really more efficient at filtering/matching/aggregating data when doing complex queries?
Yes. With knowledge of the data (like indices) and statistics of the data it is usually very much more efficient than piping the data to another process to handle the same job.
Of course that requires you to write a good query and know how to tell what makes a good query, but if your data is in a relational database it is usually more efficient to do your filtering/matching/aggregating there.
I run statistically-sound AB tests on Meta* and can tell you that people click, click more than you think and buy more than you think from clicking on ads!
The same goes for email and Whatsapp marketing. People love these messages.
* We do not use their built-in ab test tools of course...
Incredible. I can't imagine what it must be like to live inside their skulls. In all my life I have clicked maybe one or two ads on purpose, misclicked (either by honest mistake or through malicious design) probably five times, and never bought anything because of an online ad. The one ad that made think that I might use the service in question was a sponsor read for a PCB fabrication company.
I clicked and bought something via an online ad once. I needed a new jacket and the one in the ad was exactly what I was looking for. I overpaid because the jacket fell apart after a couple wears. The experience has definitely soured me on ads, even more than I was before. If marketers weren’t selling me overpriced junk I might have a more favorable view.
I have to say Instagram ads are incredibly well targeted to me. It's been like that for maybe a year, I think (I remember noticing it). I've clicked on a bunch of them, much more then elsewhere.
Yea, not immediately, but yes. E.g. specialty coffee an chocolate. Other ones were interesting job offers, which usually check and make note if the place is interesting
There's two kinds of things here, which I will call "push ads" and "pull ads".
Push ads we hate. I don't want your random ads shoved in my face. The harder and more intrusively you shove, the more I hate it. No, I'm not going to look at it to see if I'm interested; I just want it gone.
Pull ads are different. Let's say I'm on a business trip, and I get out of some meeting at 5 PM. Well, what is there to eat around here? What do I get in response to that? Ads! But in how they interact with me, it's completely different, because I actually want to eat.
Or let's say I'm going on a trip, and I search for "lodging in location X". Well, some of what comes back is ads. Say it's from hotel.com. I probably wouldn't have gone to hotel.com as one of my choices for investigating lodging in X, but they're going to give me kind of a one-stop overview of what's there, so maybe I'll click on their ad link anyway, because it's actually interesting information for what I'm trying to do right then.
But some random Temu junk that they insist on shoving in my face every time they can? No way. Just get it out of my life.
I think pull ads are hated too. They try to short circuit your brain into making a quick decision/have a preference without doing any research. It's all manipulation.
Do you enjoy going through your mail account and unsubscribe all useless newsletters?
Use email aliases?
are wary of all ads and brand claims you see on social media and prefer doing our own research?
hate clicking on SEA results: usually the landing page is a weird, summed up version of the full website (we want the full thing)
But i guess that's a particularity of hackers and tinkerers :)
For many different reasons make people click and buy: discounted prices, FOMO, clever retargeting, funny ads, hidden ads (sponsored/influence/fake news),...
Yeah, I give a lot of newsletters a chance, but only with Firefox single relay emails addresses which I have over 300+ currently. I probably unsubscribes 95% of them, but I did give them at least a chance. I probably should have tracked the ones I did so I could delete them.
Facebook's ads in particular are very well targeted, IMO. They know I'm into gaming, so I get gaming related ads (board/card games, conventions, arcades). Other sites like NYTimes, Amazon Prime Video, etc, all do a terrible job -- they think I'm a parent with a watch fetish who can't get enough prescription drugs.
If I were an ad buyer I'm not sure I'd bother with anything but Meta at this point.
I can definitely see clicking on things in email - after all I have already prescreened your company/product and found it to be interesting/worthwhile.
As for ads, maybe it is just that marketers generally have to advertise crap (because good things tend to sell themselves?) and so I rarely if ever see ads for things worth purchasing?
If someone from Shopify's backend team is around, i would love to know how difficult it is to maintain/improve the GraphQL API
It looks like Shopify is deprecating REST in favor of GraphQl so is the developer UX that good for Shopify developers?
And btw some features are missing from the GraphQL related to REST. I wonder if that's related to hard-to-implement features or good-occasion-to-delete features
(Eg Checkout)
> Why do you think that doing something which is maybe not study related is a bad idea?
Because 99.999% of those kids won't go on to start the next Google and make more money for PG's investments.
When I was at school there were a few kids who were genuinely moderately good at football/soccer. With only minor encouragement from PE staff and family they essentially had the attitude of "I don't need to study, I am going to be a professional footballer." (who by the way make huge huge huge sums of money if you are at the very top)
And how many of those went on to to be top-flight professional footballers do you think? Yep - zero. What are they doing now considering they crashed out of out of school with no qualifications, no professional sports career, and barely able to even do basic literacy and arithmetic etc? Low skilled and relatively dead-end jobs like gardeners, working on building sites, security guards etc.
They threw away their chance to study and gain skills because irresponsible and self-interested adults told them they should abandon school and concentrate on this dream of fame and fortune with essentially zero chance of it coming true. You're fucking with people's lives by doing this - don't tell people you don't need to try hard and study and learn, you just need to become a billionaire business owner!
I had the same issue as you a few days ago. By separating the problem in smaller parts and addressing each parts one by one it got easier.
In your specific case I would try to fully complete the business logic one side. Reset the context. Then provide the logic to a new context and ask for an interface. Difficulty will arise when discovering that the logic is wrong or not suited to the UI, but i would keep using the same process to edit the code. Maybe two different contexts, one for logic, one for UI?
How did you do?
reply