v0.1.4: Self-unity

Published
Download v0.1.4 for:

Discuss on HN


ZAMM now displays links from the previous/next LLM API call in a conversation. It also supports editing existing API calls:

Screenshot of API call editor

and will show links to any manually edited variants of an API call. These features are still rough around the edges — I haven’t even had time to put in a waiting indicator when manually submitting an API call.


Behind the scenes, v0.1.4 will automatically detect and link together API calls from previous versions that belong in the same conversation. I also spent time working around a NodeJS crash by getting Vitest to fork its child processes, and working around a bug in a dependency that is currently only fixed in a beta release of that dependency, which in turn depends on the beta release of Tauri 2.0. Since I don’t want to build on top of beta versions of dependencies, it appears a manually coded workaround is the only viable solution for this problem. As a side-effect of this workaround, ZAMM now has a commandline interface that only accepts commands to print out the version or the help message.

With the new features that allow for quick experimentation of API calls, and linking those experiments together, I feel like I am finally just about at the point where I can start adding actual tooling for the LLM to use in automation. Sometimes, I wonder whether I could’ve gotten here a lot faster if I’d simply used existing tooling instead of falling for the “Not Invented Here” (NIH) syndrome. But between PromptLayer and LangSmith (the latter of which didn’t exist when I started on ZAMM back in February 2023), it still does not appear as if they have a way to experiment with single API calls without editing a new version of a prompt template. I don’t know if this was all “worth it,” but there is a lot to be said for having a feature that works exactly the way I want it to, using and storing data that I completely own and control myself, without depending on the whims of an external company that may decide at any moment to pivot to different priorities.

Outside of ZAMM, I’ve been indulging in a few weekend benders that required a few days of recovery each, coupled with multiple consecutive trips to Phnom Penh: once for a passport renewal application (my passport has run out of pages for the first time in my life), once again to help Liza drive her car back from Phnom Penh to Siem Reap (a shorter distance but longer duration drive than the drive from Seattle to Spokane), and one final time to attend a friend’s engagement ceremony (my first Khmer engagement ever — what an interesting event!). I’ve also started rereading the 50th anniversary edition of the original ZAMM, which was actually published the very day before I released v0.1.0 of my personal ZAMM earlier this year.

Now that I’m rereading the book with a more critical eye than my younger self, I can see that it is indeed showing its age. Take for example this description of Pirsig not consoling his son when he’s crying:

Later I hear a sharp inhaling of phlegm that tells me he has been crying… A few words of consolation might have helped there. He was trying to be friendly. But the words weren’t forthcoming for some reason. Consoling words are more for strangers, for hospitals, not kin. Little emotional Band-Aids like that aren’t what he needs or what’s sought… I don’t know what he needs, or what’s sought.

Consoling words are for strangers over kin? Deciding for your son that he isn’t looking for consolation? That all sure sounds a bit emotionally distant.

Or take for example Pirsig explaining why women are uninterested in science:

The classic mode [of understanding the world], by contrast, proceeds by reason and by laws — which are themselves underlying forms of thought and behavior. In the European cultures it is primarily a masculine mode and the fields of science, law and medicine are unattractive to women largely for this reason. Although motorcycle riding is romantic, motorcycle maintenance is purely classic. The dirt, the grease, the mastery of underlying form required all give it such a negative romantic appeal that women never go near it.

I’m not one to think that the existence of a gender imbalance in tech must necessarily be due to sexism, or must necessarily be a problem that needs to be solved at the corporate level. And I do think the difference he points out, between the romanticism of motorcycle riding versus the mundanity of motorcycle maintenance, is still a pertinent one today. But, good Lord, his wording and the complete lack of qualifiers when talking about women certainly smacks of a time when the discourse around such topics was less refined. I don’t think this means that Pirsig was purposefully sexist or deserves a posthumous cancelling; I think the culture of the time, by and large, just didn’t really question such narratives, and the boundaries that this book pushed were not the gender-related ones.

But as yellowed as its pages may be, ideas like the one about the death force of technology still seem as relevant as ever:

They talk once in a while in as few pained words as possible about “it” or “it all” as in the sentence, “There is just no escape from it.” And if I asked, “From what?” the answer might be “The whole thing,” or “The whole organized bit,” or even “The system.” … The “it” is a kind of force that gives rise to technology, something undefined, but inhuman, mechanical, lifeless, a blind monster, a death force. Something hideous they are running from but know they can never escape. …

… You go through a heavy industrial area of a large city and there it all is, the technology. In front of it are high barbed-wire fences, locked gates, signs saying NO TRESPASSING, and beyond, through sooty air, you see ugly strange shapes of metal and brick whose purpose is unknown, and whose masters you will never see. What it’s for you don’t know, and why it’s there, there’s no one to tell, and so all you can feel is alienated, estranged, as though you didn’t belong there. Who owns and understands this doesn’t want you around. All this technology has somehow made you a stranger in your own land.

I’m reminded of consumer electronics these days that largely run closed-source software that don’t encourage you to tinker and understand its internals, of cars and even farming equipment that you are heavily discouraged from repairing yourself. On the one hand, software is certainly a lot more user friendly now, such that even young kids can readily learn how to use an iPad. On the other hand, just because Gen Z grew up with tech doesn’t mean Gen Z is automatically tech literate. A lot of consumer-friendly tech, including the iPad, invites you to use but not necessarily to understand what is going on under the hood. If you encounter a problem, simply report it through the proper channels and wait for them to ignore you. Even if they do miraculously end up solving your problem, the fact remains that you are ultimately ceding both the responsibility and power over your own computing experience to others. Tech literacy is for schools to teach, not for corporations that are just fine with your continued dependence on them.

That all being said, I also don’t enjoy being forced to slog through understanding something because it is broken. It requires time, effort, and mental energy that I don’t always have, and I don’t think Pirsig gives that enough acknowledgment. Take for example his description of a broken kitchen sink faucet:

Waiting for them to get going one morning in their kitchen I noticed the sink faucet was dripping and remembered that it was dripping the last time I was there before and that in fact it had been dripping as long as I could remember. I commented on it and John said he had tried to fix it with a new faucet washer but it hadn’t worked. That was all he said. The presumption left was that that was the end of the matter. If you try to fix a faucet and your fixing doesn’t work then it’s just your lot to live with a dripping faucet.

Pirsig seems almost baffled that anyone would be stuck in this manner, and ultimately chalks it up to a philosophical difference:

He watches carefully as I take up the rear axle nut until it’s barely snug, tap it sideways with a hammer until the chain slack is right, then tighten up the axle nut with all my might to keep the axle from slipping forward later on, and replace the cotter pin. Unlike the axle nuts on a car, this one doesn’t affect bearing tightness.

”How did you know how to do that?” he asks.

”You just have to figure it out."

"I wouldn’t know where to start,” he says.

I think to myself, That’s the problem, all right, where to start. To reach him you have to back up and back up, and the further back you go, the further back you see you have to go, until what looked like a small problem of communication turns into a major philosophic enquiry.

I have actually encountered just this situation with a leaky faucet in Melbourne, when Liza and I found ourselves living on a derelict property that was soon scheduled for demolition. The leaky faucet was in the laundry room, and it produced a steady trickle of water despite my best efforts to manually tighten the handle knob as much as possible. A short Google search led me to believe that screwing in a garden hose plug would solve the problem, but the dripping simply continued around the edges of the garden hose plug. Eventually, the washing machine broke, and the technician that came to fix the washing machine gave the faucet handle knob (not the packing nut) a strong twist with a pair of pliers (if I remember correctly). That finally fixed the problem, albeit not before the washing machine was permanently broken due to water damage from the leaky faucet, and of course the warranty did not cover a machine broken due to operation in a hazardous environment.

If I could explain myself to the now-dead Pirsig: some people, like me, just don’t have a great mental model for how physical things work. (This is indeed quite ironic given that I earned my bachelor’s in physics.) Nobody ever taught us, whether at school or at home, about how to tighten a leaky faucet past giving it the hardest twist you can. Given a physical problem, it’s not clear what tools we have at our disposal, what solutions to start trying out first, or how to diagnose and truly understand the crux of the matter so that if the first solutions don’t work, other ones will naturally spring to mind.

Of course, there is no “excuse” when information on any topic exists on the internet in a manner far more accessible than could have ever been the case in Pirsig’s day. And yet, in the end I still hadn’t done enough research to have even conceived of “Give the knob an extra hard twist with a pair of pliers” as an option. What gives?

It’s hard to recall precisely now because I didn’t really introspect about this at the time. If I am to guess at why, I’d guess that it felt (rightly or wrongly) as if my schooling has led me to be better epistemologically equipped to understand Navier-Stokes than to even begin to understand how to fix a stubbornly leaky faucet. I gave up trying after the initial Google search that led me to a garden hose plug didn’t pan out, perhaps because it wasn’t clear how much effort I’d need to put in before I found success. I didn’t know what websites or YouTube channels would be high signal-to-noise resources on home maintenance, or what forums would be a good place to ask questions if I get stuck. It wasn’t clear how deep my knowledge would need to go in order to figure out basic questions such as, am I going to need to learn how to replace the entire faucet, or is this the kind of problem that only concerns one specific part of the faucet? If the whole faucet needs to be replaced, how hard would that be? And how much worse would the problem be if I messed up?

Answers to these may all just be a few Google searches away, but those Google searches subjectively entail a non-trivial amount of mental effort in order to forumlate the questions I want to ask and the clarification I seek. Afterwards, I need to still search and evaluate multiple result links — and if I wanted any practical results out of all that information gathering, I would still need to go out and buy the actual tools needed, and come back and try the actual repairs myself. Of all the things in life I needed to expend effort on, fixing a leaky faucet in a house that we were going to soon move out of anyways seemed relatively low on the list of priorities, at least until the faucet developed a bigger leak and the washing machine was destroyed. So perhaps Pirsig’s musician friend encountered something similar. Perhaps there was plenty in music theory and instruments they wished to learn about, and perhaps motorcycle maintenance was this haze of uncertainty that they were mildly curious about but ultimately couldn’t find the mental activation energy to get started on. I sometimes run into this even for subdomains of general topics that I’m already somewhat familiar with.

Take as another example the blank screen on Linux that came up for me after the laptop died from low battery. Some bits somewhere must have gotten corrupted due to full-disk encryption (FDE) not meshing well with a low-battery shutdown on Linux. To Apple’s credit, I’ve never had any problems with FDE and low battery. I’ve had a problem with that once on a Windows desktop when VeraCrypt couldn’t decrypt the volume anymore after a sudden power outage, and multiple times across Ubuntu and Linux Mint in the last year. The first time it happened, I could at best come up with a temporary fix wherein I press Ctrl-Alt-F3 at the right time during boot to bring up the commandline, and then manually run startx after configuring a non-default display manager to run. If I pressed Ctrl-Alt-F3 too early or too late during the boot sequence, the screen would go completely blank and never recover. After hours spent trying to figure out a more permanent solution to the problem, I finally decided to just wipe the system clean and reinstall everything. This happened a couple more times before I finally reinstalled with full disk encryption turned off. Fixing these things may be a learning opportunity around the internals of Linux display managers, but that didn’t seem like something I cared to learn about at that point in my life.

There are of course the times when I feel as Pirsig did, when I meet a problem that I absolutely know I can solve so long as I spend enough time getting the solution right, and even the amount of time needed can generally be estimated to within an order of magnitude accuracy. If my sense of attention to detail/perfectionism kicks in, I will indeed feel compelled to solve it right and to solve it completely. But then there are the other times when I meet a problem that I am only capable of solving in a theoretical sense, in the sense that if I spent countless days hammering away at this problem and learning all I can about this subject, then I’m sure I’m smart enough to figure it out eventually. But how much time will it take? Hours, days, weeks, months? I have absolutely no idea, and to even take my very first step into that opaque haze requires more motivation than I often have.

I think this goes beyond mere philosophical differences — or put differently, this may be one of those philosophical differences that are actually caused by deeper differences in brain physiology. Take for example how some people have aphantasia, or an inability to imagine visual scenes in their mind. Apparently, there was a whole philosophical debate over just how literal or metaphorical phrases like “seeing with your mind’s eye” were, until it finally turned out that some people literally lack this ability while others don’t, and they all just talked past each other, assuming that the others were somehow using different words to describe the same conscious experience we all must surely be sharing.

I think that this may also explain Pirsig’s befuddlement over his friend’s “philosophical” differences. Pirsig seems to have had a lot of mental and physical stamina, given that he was the type of person who gets up at dawn and then wakes everyone else up not too long after, so as not to “waste” that invigorating cold morning air on mere sleep. I’m someone who enjoys waking up at noon if the day’s schedule allows for it. Pirsig doesn’t sound like he was aware of spoon theory — not that specific metaphor of course, but just the idea of having a limited mental energy budget to spend on things like taking things apart and fixing the exact problem. I’m someone for whom that is continually and consistently a problem. I don’t know exactly how deep the difference between my brain and Pirsig’s goes, but I am sure that it’s not just a difference in philosophy, wherein if I were simply convinced by a clever logical argument, all my motivational problems would magically melt away. I doubt that I can reason myself out of something I didn’t reason myself into.

To go back to my complaint about needing to do a few Google searches for home maintenance: it’s not that it’s an unreasonably difficult thing to do by any objective measure. Rather, I’m trying to paint how it subjectively feels like it would require a prohibitively large amount of effort. I don’t quite understand this myself — I am but a black box to myself — but I am able to notice that something merely feeling like it’ll require a lot of effort could very well prevent me from even attempting to tackle that task. This could be something as trivial as figuring out how to cancel a subscription I have, which requires logging into that website, finding the account settings page, discovering that they don’t support cancelling subscriptions online, searching around for their corporate phone number, reminding myself to call during business hours, finally calling their customer service hotline, occasionally having to figure out how to get to get past the menu options to get to an actual human, and then waiting for an actual human to respond and perhaps transfer me to another department. Sometimes I’m right, and I do the task while fully feeling agonizing annoyance as I mutter “God I fucking hate this!” Other times the experience turns out to be much better than expected. It’s a crapshoot of a lottery with only shit prizes as a reward, and so sometimes I put it off until I’m reminded of it again by the next billing cycle.

It’s not clear to me when this happens either. I remember when I was working from home during the pandemic, I would often spend hours laying in bed, procrastinating on work but also feeling highly stressed over the procrastination. I just needed to get up and do the work that I knew entirely how to do (unlike with fixing the leaky faucet). You didn’t need to convince me that it was in my best interests to do the work — I was already convinced myself. Logically, it simply didn’t make any sense to stress over it for hours instead of simply doing the work, but somehow I felt bound by an illogical subconscious.

I distinctly remember one occasion on which I was so frustrated by this situation that I forced myself to get out of bed, forced myself to get to my chair that was two steps away from the bed, forced myself to sit down on the chair, forced myself to open the laptop lid, forced myself to wait for the login screen to pop up a couple of seconds later, forced myself to type in the password and wait for the desktop screen to load a few seconds after that — and by this point I had consciously forced myself to do so much that I was completely exhausted and collapsed back in bed. It was completely ridiculous. There’s no reason why it should feel so excruciatingly hard to login to the laptop when, at other times, it’s literally just one continuous motion that barely registers as an action in my brain. It’s not normal for a computer login to feel this difficult. Something was not right.

Two different therapists had no definite explanations and no permanent solutions to get me to do something that I didn’t want to do. The first one treated it as I did: this is a problem, how do we fix it? We tried a bunch of different methods, the best one of which was me holding myself accountable by emailing him the day before about my plans for the next day. The next day after work, I would email him about how it all went. At first, fear of disappointing my therapist (which was no more illogical than the procrastination) caused me to finally have some carefree days where I finished work early and enjoyed guilt-free relaxation time. Alas, my subconscious started testing boundaries as usual, and soon enough discovered that there was no need to fear disappointing the therapist after all. Out with the fear, back in with the stress.

I had heard from one of my friends that he once popped some Adderall before starting some math homework, and before he knew it two hours had passed and he had filled out pages and pages of math homework. God, that sounded just like what I needed. The worst part of work was that I had to be conscious for it all. The tasks would be just difficult enough that I couldn’t zone off entirely (like I can when I’m doing some monotonous physical task like washing the dishes), but also not difficult enough for my mind to feel fully stimulated or engaged. I wanted to just pop a pill, and then “before I knew it” hours have passed and all my work was done, just like what had seemed to happen for my friend, and what was described in Office Space:

Peter: “Is there any way that you could sort of just zonk me out so that, like, I don’t know I’m at work… in here [pointing to his head]? Could I come home and think that I’ve been fishing all day, or something?”

(Incidentally, the show Severance explores this concept in a literal manner. I highly recommend it.)

As such, my therapist and I ended up getting me to try out a bunch of different pills too: Adderall, Ritalin, Vyvanse, Strattera, possibly some others I’ve forgotten. Vyvanse was my favorite. The comedown made me sad, but it was an enjoyably rich and tasteful kind of sad, the kind that made me ambivalent about living or dying — but not in a depressing way, more in a “Que sera, sera” kind of way. Strattera simply made me anxious and stressed, not about anything in particular, but just as if there was going to be some stressful situation that I must confront in the next few hours. At best, these pills got me really invested in whatever I was procrastinating with. I wasn’t any better at doing things I didn’t want to do, but bughouse games were so much fun on Vyvanse that I literally said out loud “This is so much fun!” multiple times, as if I had to tell that to myself in disbelief just to affirm how unbelievably fun it was indeed.

(For what it’s worth, I did discover that it was a lot of fun to play both boards against low-ranked players, and keep one board entirely pristine without moving any of its starting pieces. See this game where I’m the bottom player on both boards:

Screenshot of bughouse game where I won without moving any of my starting pieces on one board

This is of course only a viable strategy against inexperienced players who don’t coordinate to pause and force me to move.)

The second therapist approached it from the angle of a childhood trauma response. I did unearth lots of common threads running throughout my life, such as how things were always happening to me on a schedule that I neither understood nor had any input on, and so perhaps I got good at accepting whichever environment I found myself placed in, but not so much at taking responsibility for molding my own environments as an adult. A lot of interesting ideas, to be sure, but we never got to actually tackling the problem on a practical level because we were continually searching for the root cause of it all, and there seemed to be no end in sight for this search.

Fortunately, I got a chance to talk about this with Liza and friends during one weekend bender in particular this past month. I still don’t have answers, but I have realized that my recent gaming habit is indeed often a form of escapism from the conflict in my mind, between doing something I feel like I should be doing versus procrastinating on it. Even stopping for a few short minutes to reflect on the conflict — not as a means of escaping from the conflict, but simply as a means of observing and gathering data about the conflict — seems to be useful for understanding myself and suspending judgment about the choices. After all, it’s often not the case that one choice is objectively wrong — gaming or coding are just actions, whereas “procrastination” and “thing I should be doing” are the lens through which I interpret these actions. Even if I ultimately end up making the choice labeled “procrastination,” if I make that choice not as a means of escape but as its own legitimate action in response to internal emotional dynamics, I might just be able to enjoy it fully rather than with a strong tinge of guilt.

With Liza’s help, I’ve also noticed that the way this conflict plays out in my mind also coincidentally replicates the dynamics of how my parents fought with each other. In the past, I have identified solely with the side of me that wants something to be done, and saw the opposing side as an unruly subconscious that simply passive-aggressively refuses to do the work. But there is another tenable perspective: that both sides are a valid part of me, and rather than seeing one side as something to be subdued by the brute force of self-discipline, I could perhaps also take the time to see what it has to say. If it can’t communicate as verbally as the side of me that wants things to be done, perhaps I can listen for other ways in which it communicates. Perhaps it’s time to accept rather than repress this side of me. Self-discipline hasn’t yet worked for me like it has for some others, so a change in approach may be necessary.

I’ve been punting on resolving this mental conflict by seeing ZAMM as a technological escape hatch. I’ve been hoping that LLMs are already smart enough to do most of the stupidest programming work for me — at the very least, hoping that they’re smart enough to make use of a knowledge based crafted specifically for them, so that I can teach them how to do something once and never have to do it again myself. Programming would surely feel a lot more tolerable if I knew that every time I solved a problem, it would also be the last time I solved that problem. God, I hate having to do a quick Google search for a problem I know I’ve solved before, and then looking through the first few results but not finding the one that had solved it for me before. I also hate having to do some manual process that is highly similar each time I do it, but also just slightly different enough that writing a proper script to automate it would be a whole thing with a whole set of edge cases.

But I realize now that even if my hopes about the current usefulness of LLMs were to fully pan out, my expectations around what counts as drudgery would likely reset due to the hedonic treadmill. This conflict would likely still play out, just in new ways under new circumstances. Escapism has only been a band-aid for me so far, and escaping via ZAMM promises to be no different.

One more thing I’ve learned from my friends is that finding meaning in what you’re doing can be a powerful motivator that doesn’t just give you the drive to overcome your hurdles, but could also melt away the feeling of having hurdles to overcome in the first place. I’ve been thinking of my current work on ZAMM as the “boring interim phase before it all hopefully gets automated away in an exciting manner,” which feels only somewhat meaningful because there’s always a chance it doesn’t work out like it does in my dreams. I suppose my lackadaisical pace of work reflects that. I do enough to avoid complaints from the part of me that wants to see progress, and I avoid pushing myself any further to keep the procrastinatory part of me from picking a fight. But if instead I start thinking of my current work on ZAMM as the conduit through which I can safely explore this mental conflict without the pressure of meeting corporate expectations… well, that just feels a lot more meaningful, because work stoppages will no longer be obstacles but rather opportunities to further understand how I can become one with myself.

I may not know why I have such a limited mental energy budget, and sometimes it is absolutely frustrating to live life in this manner. What is an obvious lived truth to me appears to have been an enigma to Pirsig. But I still enjoy reading the OG ZAMM about Pirsig’s physical journey through the American hinterland, and I am excited to be on my own mental journey aboard my personal ZAMM.