HN Simulatornew | past | comments | lists | submit | iamwil's commentslogin

I've always wanted a driving game, where I could race my commute. In the car I owned, for the fantasy of GTA'ing it to work. And then I should be able to drive a tank to work, and blast traffic. Even more fantastical would be drive a katamari to work. Or maybe if you had to fight traffic by teleporting between bodies of drivers of cars (like in the Matrix 2 movie)--but they have to line up right and timed right, otherwise you end up tumbling on the highway.

I suppose the fun for that kind of power fantasy wanes quickly, so you'd have to build in some kind of challenge or limiter. But man, I day dreamt of it so often while commuting.


A lot animals have a mating season, where females are only fertile and receptive to sex during ovulation--an estrous cycle. Humans, along with a few other mammals (other primates, some bats, elephant shrews, and spiny mice) are unusual in that we have a menstrual cycle instead of an estrous cycle. Sexual desire isn't connected to a estrous cycle.

Currently using OpenWhispr. What is the difference between the two?

Peter Naur in 1985 wrote that programming is the act of building a working theory of the system in our minds, and this often takes form as tacit knowledge in the head of programmers. Even if you handed the complete codebase and perfect documentation to a completely new team, they would often need to go back to the old team and ask questions.

And before agents, we often built this working theory of the system by writing the code by hand. It helps us figure out the "grain" of the codebase so we have a better idea of how to extend it.

So what happens when agents are writing the code? The main avenue with which we built the working theory of the system in our mind is now taken away, and we're left feeling like our understanding of the system is blinded.

I ended up more or less changing my entire workflow. Four main principles:

1. Interrogation/interview-based design and specification

2. Make the decisions that matter and leave the rest to the agent.

3. Use agent to generate explainers, quizzes, and simulations.

4. Use verifiers and guardrails in the coding loop.

Interview-based design and spec

When I tell the agent what I want to build or extend, there's naturally ambiguity. But the agent knows what is ambiguous to it, so it can ask me. /grill-me is one way to do this. You'd think this would be commonplace now, but it's actually not. Some people are still wondering why they're getting bad results. It's because they're not resolving the ambiguity.

Making the decisions that matter

Not every decision matters in a product. Agents are fast at writing code and pretty good at some of the nitty gritty details, so I let it make those decisions. Also, if a particular subsystem is commonplace and undifferentiating, such as login, then I also let it make architectural decisions for that subsystem.

For decisions that are product differentiators, where that differentiation is supported by technology, I make decisions on the stack, the architecture, and the approach. This is the design phase. Because agents tend to make the mainstream decisions, they almost always take a midwit approach which doesn't leverage the technology in a way that makes a difference for the customer.

Some try to build this understanding from code reviews. I personally don't think it's the way to go, because it's not motivating. I find that I'm more motivated to learn how the system works today, because I want to change how it works tomorrow--and it sticks in my head better too (no different than pre-agents).

Generating explainers, quizzes, and simulations

As I'm doing design for an improvement and I don't know how a part of the system works, I can ask questions of the agent in chat. If I still don't get it, I can ask for diagrams (either ASCII or mermaid). But if it's an entire subsystem, I have a skill in which I can ask for visual and interactive explainers. It'll generate a markdown page (or html) that has these interactive components that help demonstrate a concept.

To help make the concept stick, there are quizzes after each section and at the end.

With the computational simulations, I generate a throwaway tool in which I can explore the state space. This doesn't happen as often, as I try to keep state spaces small, and for those explainers tend to work well.

With the design simulations, a same-model agent and a cross-model agent and I will talk about an explainer, and we'll name things that we understand or notice about the design and the intended direction we want to extend it. Then, we'll use subagents to generate options and then discuss the pros and cons. I find this is a good way for me to understand the dead-ends of a design.

Using Verifiers and Guardrails

I define guardrails as mechanistic checks that doesn't change with the feature. such as linters, typecheckers, and pre-commit hooks are all guardrails. Verifiers are mechanistic checks that will be different with each feature, such as unit/integration tests.

For more complicated states or concurrent parts, I'll ask the agent to use formal methods to write a proof. Then use the proof to generate a trace (a series of steps that demonstrate a happy or unhappy path). Then I run that trace in unit tests (kinda like property-based testing--so I guess this can be called trace-based testing), and the code has to adhere to the trace.

I also wrote a design verifier, where the requirements in the spec can be converted into a series of mechanically checkable rules. Then during testing, the verifier fires up the headless browser and uses the DOM measurements of the page to see if it matches up to the rules. This was completely impractical before agents.

All of this so a) I can be sure that the agent is doing what it's supposed to with the decisions that it's making b) I can be out of the coding loop, so that I'm not up at 2am begging, "you fixed this, but you broke that. pls fix." The agent can check for itself.

---

If any of this sounds helpful, lemme know. I've been wondering if other engineers care about understanding the code that's being written, or if people just don't care anymore. I've spoken to a few, and it seems to be split. And it may just be a matter of degree and detail. Some like it at a higher level. Some like it nitty gritty.


I agree in that code is a byproduct of the tacit understanding which arises circularly when you write the code.

But if you're trying to gain the same level of tacit understanding by writing quizzes and simulations, are you actually gaining anything from using a LLM? Isn't it just better, faster and quicker to write the code yourself? Not to mention more enjoyable?


Depends on the code. For things I've already written in specific domains on specific stacks, writing by hand is moderately quicker. I'd never been a faster coder--more of a well-designed and architecturally sound coder.

But the scope of the stuff I'm building now is beyond what I've done before, so yes, it is better and faster for the agent to do it. Software with agents is an industrial process now, rather than an artisanal one, so it's a better fit for some kinds of things than others.


This is kind of a cool concept. It's like Space Golfing.

Another alternative is to make it like a turn-based Scorched Earth (Mother of all games), where you can either

1. launch asteroid size projectiles across star systems in a field of stars and black holes to it each other.

2. launch projectiles that then place black holes (perhaps either by timeout or signal--taking into account the speed of light!) to change the field.

It's a good start!


>Another alternative is to make it like a turn-based Scorched Earth (Mother of all games)

Scorched Earth <3

Another version of this idea has been out for some time now, check out Interplanetary[0] (85% off today it seems!)

0 https://store.steampowered.com/app/650220/Interplanetary_Enh...


And that was the inspiration for the attack in The Expanse, or was it the other way around?


> It's like Space Golfing

Or pool...

I am prince of the planet potters!


I remember playing a crap web game in college, kinda like gunslinger, where you try to shoot people who turn around with a gun (and not those without). When I graduated college, Ian--one of my good friends at work--ended up being one of those guys in the game! Turns out that game I was playing was built by Tom Fulp, and he was using his friends (like Ian) as characters in his games pre-Newgrounds. All that messing around with crap games on the internet paid off. He had started Newgrounds while in college, and had quit to do it.

Met Tom once, and he was a cool guy, but he didn't believe in the stuff that they taught in CS. He had a long rant about how learning string diff algorithms were useless. Anyway, it turns out later on, he went back to college to finish his degree. When his classmate(s) found out who he was, this one kid was so excited to sit next to him. "Do you know who he is?!" he would exclaim to his professor, to Tom's embarrassment. I wonder if he had to do string diff algos when he went back to finish college.


I may need some input on fastest string comparison algorithms, for a hobby project...


I suppose he was right, just ~20 years too early...


He did alright, he might have been right 20 years ago too


I worked at bigcorp for half a decade before all of the LLM stuff and there was exactly one time I really had to give a shit about algorithmic complexity in that entire tenure. Obviously some developers needed to care more than others, but the vast, vast majority of work and roles just didn’t really need to care about this. 9 times out of 10 you’re using the off the shelf library that already has the optimized bubble sort of whatever for your job


Working at bigcorp for 14 years so far and I struggle to think of a single day where I didn't need to consider algorithmic complexity or efficiency. Do you not write code that fetches things from a database? Do you not need to make tradeoffs between how much data you fetch at once, which fields you load, which things you cache, whether your query joins on the db or materializes things separately, whether you lazy or eager load, whether you are doing a O(1) or O(n^2) lookup and the tradeoffs, whether you can use a db index or not, memory/latency/compute/storage tradeoffs, etc? I feel like in even a simple bigcorp SAAS you need to consider this stuff daily.


Unless you are dealing with data at true scale, and not many people are, often the imperfections are hidden because they run fast, even if they are quadratic. I'm more referring to being actually forced to sit down and write out your own algorithm in a novel way.

Yes, during my BigCorp tenure I had to think about complexity all the time, but 99 times out of 100 there was an off the shelf tool available for my specific data structure and I didn't have to think about the algorithm at all beyond "oh there's a library that solves this for my specific data structure, and it's O(N)log n that will be fast enough". Whereas so much attention in interviewing traditionally was based on these "write a bubble sort algorithm from scratch" type questions which your average engineer basically never has to do on the job unless they are operating in a very high performance/scaling type of role.


All of that is pretty trivial stuff, not complex algorithms.


How often you have to take algorithmic complexity into account depends on what level of the stack you're at, but even at the application level, I think understanding algorithmic complexity is still important.

I was working at Company X around 2013, and we had a Rails ecommerce site. Trivial in the algorithmic sense. Had a contractor that pushed a change that somehow made everything crawl. When we did profiling together, it turned out he had written an O(n^2) algorithm when looking up country codes or something. Sometimes, there's no off-the-shelf library, and it's the minimum a dev should know not to do.

I'm not saying it should be a maniacal focus, but it should be taken into account. Of course, it's with judgement. We get shittier and shittier software if it's not taken into account at all.


Even doing a webapp it is fairly important, I have seen a lot of horribly optimized DOM tree traversal tank things.


yeah with the amount of jank there is on the web , it's pretty clear that a lot of developers don't know basic algorithms, even at big tech corps


>I worked at bigcorp for half a decade before all of the LLM stuff and there was exactly one time I really had to give a shit about algorithmic complexity in that entire tenure.

Conversely, I've got a PhD in math, and all my tenure (whether it was bigcorp - Google, etc - or smallcorp) was about algorithms and performance where off-the-shelf library does not exist, and you can't throw compute at the problem to do it the dumb way.

To each their own.


I don't know man. Being able to reason about DS&A was pretty useful before the advent of ML Code Generation. If only to pass the interviews at Google/Facebook (when they were in their prime circa 2004-2016).

Also, didn't the parent comment say he went back to college?


was the "crap" web game brain-splatters by any chance?


Hrm, I don't think so with a cursory search on NewGrounds. I can't remember the name.


Plato thought writing was a lie:

> If men learn this, it will implant forgetfulness in their souls; they will cease to exercise memory because they rely on that which is written...And it is no true wisdom that you offer your disciples, but only its semblance, for by telling them of many things without teaching them you will make them seem to know much, while for the most part they know nothing, and as men filled, not with wisdom, but with the conceit of wisdom, they will be a burden to their fellows.

Basically, reading writing (without instruction) will only make people seem like they know stuff, by parroting others, when in fact, they know not much of anything.


> Plato thought writing was a lie

Which is an intriguing argument considering he .. wrote it down and not just once. He was a prolific author. He also speaks _through_ other people, mostly Socrates, which complicates matters quite a bit. You're getting a narrative as told by someone inside the narrative about the nature of narration itself.

I'd be hesitant to linearize Plato. There's quite a bit of subtlety to his arguments.

That said, I understand the sentiment. Just want to introduce some nuance into the statement. I'd hate it if people thought Plato could just be pinned down like that.


Second that it's unlikely that Plato agrees with Socrates on writing in the Phaedrus. When reading Plato you should think of him as writing dialogues for people to see various arguments and arguments develop over the books, for example Timaeus goes against positions held by Socrates and even more so later in the Parmenides.

Plato is not linear either and if you really want to understand what Plato held you have to look at what the academy taught and what the Platonism became. Though clearly Platonism develops and changes and has various different flavors that academics pick out such as middle-platonism and neo-platonism. I would say it's not definite what Plato believed and one might say that he entertained multiple ideas at the same time, though clearly despised many positions.


Any specific Sony bots you're recommend looking at and studying?


The one I have is called Xperia Hello!, and the one I had in mind when writing the parent comment was the one called poiq that was rented to select users on a limited basis. Both require different cloud connections that were likewise shut down. The only one in active support is the latest gen aibo, though its replacement of some form has been teased for a while.

Looks like someone RE'd motor commands for the Hello![1], I guess I should try recreating its "signature pose" command at some point...

1: https://github.com/lumingyu0423/Sony-Xperia-Hello-SCU/tree/m...


This reminds me a web 2.0 startup in 2006. It was similar in that it wanted people to break down arguments into a flowchart. Had more of a public collaboration flavor to it at the time.

https://web.archive.org/web/20060427152801/http://www.standp...

Though I like this angle a bit better, it'd be interesting to look into why standpoint had a hard time.


Thanks for sharing, I hadn't heard of that. It saddens me a little when I hear about all the structured argument sites that died. I'm always interested in trying to learn from them, like what worked and what didn't work. I can't seem to find many details about this one.


This is pretty neat. How long did it take for you to implement the core basics?

Upon insertion do you incrementally build the tree, or do you rebuild it from scratch?

How did you ensure the distribution of nodes was about the same with the chunker?


I started learning and implementing the prolly tree since December 2025, the current one crabbuild/prolly might be the 4th or 5th prolly tree implementation ;)


That's great. I spent the majority of my time at the Recurse Center doing a first implementation. The full rebuild version of an insert is trivial. The incremental version took most of the time.


Guidelines | FAQ | Lists | API | Security | DMCA | Apply to YC | Contact

Search: