It's Time to Divest from Twitter

This post reproduces a bluesky thread where I talk about what it means for me to divest from twitter.

Okay, it's time to divest from Twitter. I haven't been on the platform for months. But my account is still there, and I want to wind it down responsibly. I'm going to spend today thinking through what that entails for me personally. I'm open to hearing other people's thoughts.

I use the word "divest" to convey something intentional. It's not just deleting my account. In fact, I'm not even sure that's the right thing. More on that later.

Instead, divesting is about trying to take back the power I've given to the platform. Reducing it's importance and impact on my life.

I'm not leaving Twitter because I want to. Despite its many ongoing problems, I had made my peace with the tradeoffs of being on Twitter. It was my preferred home online, and I appreciated it very much. But the changes are significant enough that it's not the same place anymore.

I wanted to write a well-researched and persuasive argument about why a principled person should consider leaving Twitter. I want to convince other people that it's time to let it go. But honestly my thoughts aren't organized enough to do a good job there. I'm sorry I can't provide that today.

I can give you the short, off the cuff thread version though. It's not time to leave Twitter simply because we don't like Elon Musk. And it's not because he has made significant changes to the platform that we don't like. It's because the balance of power has shifted, and Twitter is actively unsafe.

Musk is allying with white supremacy and many other forms of bigotry. He is actively giving power to fascist factions. He wields his control over the platform capriciously and punitively. He has no respect for privacy. Not even the veneer that we usually expect from corporate entities.

Remaining on Twitter is equivalent to giving a bigoted and immature man-child direct power over many aspects of your online life. By staying, you also help to legitimize a platform that should no longer hold the same legitimacy in our culture and our society.

From a more practical perspective, I don't think your Twitter content will remain available on Twitter. At some point, it will no longer be available to you. I also believe Musk will actively use your content and your identity to enrich himself and his partners. He's probably doing it already.

We can't take all of our power back from Twitter. Based on the terms of service, they basically own everything you've ever given them. We've known that for a while now. We just hoped that we wouldn't end up in the worst case scenario of that tradeoff. But here we are.

So what can we do that is meaningful? Obviously we can stop contributing to the platform. Don't post. Log out. Convince the people you know to divest. Our goal should be to actively shrink Twitter's engagement and relevance until it is not so big a threat.

Ideally we should use this opportunity to levy as many consequences against Musk as we can. We have to remind shitty billionaires that although they may have unlimited power and resources, that doesn't mean they are free from consequences when they fuck with us. Together, we wield power too.

But we also need to bring this back down to the individual level. What do you need for yourself in this moment? What do I need?

I need safety from being personally attacked. I need to ensure that the identity I had on Twitter won't be misused now or in the future. And I need to reclaim my history.

I've already succeeded in downloading my full Twitter archive. I've been encouraging other people to do so if they can. But I know it's not working for everybody. I would love to see third party solutions that enable people to retrieve their content from Twitter.

The big decision I need to make is what to do with my account. Deleting it feels like an obvious step. But I think there are more things to consider. Regardless of what happens going forward, our past on Twitter was and is highly relevant. Twitter is history. I want to preserve what I did there.

The problem is that I don't expect my account to stay in its current state going forward. Musk can do anything he wants with it. He can make drastic changes to how it is presented and what it represents, and it will still have my face on it. That's part of what I mean by misusing my identity.

I want to take my identity out of his control. But I'm not sure there is an effective way to do that while still leaving some lasting indicator that I was there. Again, I'm happy to hear ideas. I've heard lots of them already, but I'm still processing what matters to me.

Then finally there's personal safety. This is the part that is difficult to explain without sounding like a conspiracy theorist. I believe that leaving your account unattended on Twitter is potentially hazardous. Musk has emboldened and even empowered the most toxic elements of social media.

I was outspoken on Twitter. I was radicalized there. I found my voice there. But in order to speak my truth, I had to learn how to protect myself and my family. I think that equation has changed. I don't know how to protect myself with the platform directly under the control of someone like Musk.

Even deleting your account doesn't solve that problem. Once we accept that Musk is duplicitous and unethical, we have to accept that he doesn't have to do the right thing even if we delete our accounts. But that may still be the best step we can take.

This thread is long enough, so I'm gonna leave it here. I will read all replies, but I may not respond. It should go without saying, but I'm not interested in arguing about this. Feel free to have different opinions about any of it. But we don't need to debate. Thanks.

The real question driving AI hype

This post reproduces a twitter thread where I examine a fundamental question underlying a lot of the fervor around AI.

One fascinating part of this emerging era of human-like AI is learning what traits humans automatically assign to our new robot assistants.

In this case, the assumption is that an AI is a) competent at assessing creative work and b) completely "objective" in this assessment. 

This tweet is no longer available. It attached a Tik Tok video where a person advocates that writers should use ChatGPT to critique their writing. Ostensibly because it’s more “objective”. https://twitter.com/JackHarbon/status/1648051301706522625

I'm going to keep reminding people that the current incarnation of human-like AI chatbots don't "think" in any real sense. They make shit up in a very convincing way. It turns out, a lot of people want that and don't care about the distinction.

You’re gonna keep seeing examples of LLMs supposedly doing amazing things. But It’s important to understand that they are not “smart”. They do not actually engage with real data. They can confidently make things up because maybe someone has written something similar in the past.

I've been thinking a lot about the need that is being served here. When we look at the incredible reaction to these new chatbots, I think we have to recognize that we've activated a very deep need in people. But what is it?

In this example, it's a reaction to a dynamic that writers are very familiar with and frustrated by. It's very hard to get your work seen and published. Because other humans get to decide to pick it up or to discard it. And other people's judgment seems arbitrary and capricious.

That's bringing me back to what I think is the core need driving this fascination with human-like AI. It seeks to deliver on a fundamental question that is causing a lot of angst in our current moment.

What if you didn't need other humans in order to be successful?

What if there was a thing that knew how to communicate with humans. It's very accessible and you don't have to be "technical" to use it. But it's not a human. It will always be ready and willing to engage with you. It doesn't get tired or irritable. It can't reject you.

Moreover, this robot assistant always talks about what you want to talk about. It doesn't deflect or change the subject. It doesn't decide to talk about itself instead. It can't "grin fuck" you instead of giving you the answer. It can't hit on you instead of giving you the answer.

When we start to understand these non-obvious qualities of human-like AI, we start to see the need that is being met. We can see how a lot of people might decide that it matters less that the thing is actually competent or accurate. It's still giving what needs to be gave.

Chatbots like ChatGPT are being used in professional contexts. But we are going to see this new breed of AI expand into many other areas as well. I've seen discussions about using these for therapy, for learning how to talk to girls. Literally anything humans want to do.

So it brings me back to the core question that I think is defining this space right now. But amended a little bit to encompass the true scope of what we've unleashed.

What if you didn't need to interact with other humans in order to get what you want?

The "I don't want to interact with other people" thing has been building in our society for a while now. It's a deep topic, and I won't do it justice.

I do think this next iteration is gonna be a doozy. People are really ready to give power over to these machines.

I'm gonna end this thread by being clear about what I personally think of all this.

I think it's bad. Where I see us currently headed feels like a really bad idea to me. And I hope we find the strength to change the trajectory before too much damage is done.

How to actually integrate Angular and NestJS

I don’t know who needs to hear this. But your frontend and backend systems don’t need to be completely separate.

I started anew side project recently. You know, one of things that allows me to tinker with new technology but will probably never be finished.

I’m using Angular for the frontend and nestjs for the backend. All good. But then I go to do something that I thought was very normal and common and run into a wall.

I want to integrate the two frameworks. I want to serve my initial html with nestjs and add script tags so that Angular takes over the frontend. This will allow me to do dynamic things on the backend and frontend however I want. But also deploy the system all as one cohesive product. Apparently this is no longer How Things Are Done.

I literally could not find documentation on how to do this. When you read the docs and blog posts, everybody expects you to just have two systems that run entirely independently. Here’s the server for your backend and here’s the entirely different server for your frontend. Hashtag winning!

When I google for “integrate angular and nestjs”, nobody knows what I’m talking about. On the surface, this seems like is a great technical blog post from LogRocket. It says “I will teach you how. First, set up two separate servers…”

I think I know why the community has ended up in this place. But that’s a rant for another blog post. Let me try to explain what I’m talking about.

Angular is designed as an a frontend framework (let’s set aside SSR for now). The primary output of an Angular build is javascript and css files that are meant to run in the browser. When you run ng build, you’ll get a set of files put into your output folder. Usually the folder is dist/<your_project_name>. Let’s look at what’s in there.

polotek $> ls -la dist/my-angular-project
-rw-r--r--  1 polotek  staff    12K Sep 13 14:15 3rdpartylicenses.txt
-rw-r--r--  1 polotek  staff   948B Sep 13 14:15 favicon.ico
-rw-r--r--  1 polotek  staff   573B Sep 13 14:15 index.html
-rw-r--r--  1 polotek  staff   181K Sep 13 14:15 main.c01cba7b28b56cb8.js
-rw-r--r--  1 polotek  staff    33K Sep 13 14:15 polyfills.2f491a303e062d57.js
-rw-r--r--  1 polotek  staff   902B Sep 13 14:15 runtime.0b9744f158e85515.js
-rw-r--r--  1 polotek  staff     0B Sep 13 14:15 styles.ef46db3751d8e999.css

Some javascript and css files. Just as expected. A favicon. Sure, why not. Something about 3rd party licenses. I have no idea what that is, so let’s ignore it. But there’s also an index.html file. This is where the magic is. This file sets up your html so it can serve Angular files. It’s very simple and looks like this.

<!doctype html>
<html lang="en" data-critters-container>
<head>
    <meta charset="utf-8">
    <title>MyAngularProject</title>
    <base href="/">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="icon" type="image/x-icon" href="favicon.ico">
    <link rel="stylesheet" href="styles.ef46db3751d8e999.css">
</head>
<body>
    <app-root></app-root>
    <script src="runtime.b3cecf81bdcc5839.js" type="module"></script>
    <script src="polyfills.41808b7aa9da5ebc.js" type="module"></script>
    <script src="main.cf1267740c62d53b.js" type="module"></script>
</body>

</html>

It turns out the web browser still works the way it always did. You use <script> tags and <link> tags to load your javascript and css into the page. But we want to let the backend do this rather than using this static html file.

I’m using NestJS for the backend. It’s modeled after Angular, so a lot of the structures are very similar. Just without all of the browser-specific stuff. Nest is not so important here though. This problem is the same with whatever backend you’re using. The important thing is how static files are served. If you copy the above html into a backend template, it probably won’t work. This is what you get in the browser when you try this with NestJS.

Screenshot of web browser. The page is blank and the Chrome devtools are open to the Network tab. You can see that several javascript and css files failed to load with a 404 error code.

This is part of my gripe. By default, these are two separate systems right now. So NestJS doesn’t know that these files exist. And they’re in two separate folders. So it’s unclear what the best way is to integrate them. In the future, I might talk about more sustainable ways to do this for a real project. But for now, I’m going to do the simple thing just to illustrate how this is supposed to work.

In NestJS, or whatever backend you’re using, you should be able to configure where your static files go. In Nest, it looks something like this.

async function bootstrap() {
  const app = await NestFactory.create<NestExpressApplication>(AppModule);

  app.useStaticAssets(path.resolve("./public"));

  await app.listen(3000);
}
bootstrap();

So there should be a folder called public in your backend project, and that’s where it expect to find javascript and css files. So here’s the magic. Copy the Angular files into that folder. Let’s say you have the two projects side by side. It might look like this.

polotek $> cp my-angular-project/dist/my-angular-project-ui/* my-nest-project/public/

This will also copy the original index.html file and the other junk. We don’t care about that for now. This is just for illustration. So now we’ve made NestJS aware of our Angular files. Reload your NestJS page and you should see this.

Screenshot of web browser. The page shows the standard "Welcome" screen for new Angular projects.The Chrome devtools are open to the Network tab. You can see all files loading properly.

We did it! This is how to integrate a cohesive system with frontend and backend. The frontend ecosystem has wandered away from this path. But this is how the web is supposed to work in my opinion. And more importantly, it is actually how a lot of real products companies want to manage their system.

I want to acknowledge that there are still a lot of unanswered questions here. You can’t deploy this to production. The purpose of this blog post is to help the next person like me who was trying to google how to actually integrate Angular and a backend like NestJS because I assumed there was a common and documented path to doing so. If this was useful for you, and you’re interested in having me write about the rest of what we’re missing in modern frontend, let me know.

Advice on managing your time as an engineer

Recently, a friend of mine asked an open question about tips for managing your time. Today’s engineering roles often come with many demands on your time and attention, but very little guidance on how to navigate things. I gave some thoughts on Ann Daramola’s question, and they seemed to resonate with people. So as usual, I figured I should write it down somewhere people can see.

Question: Did you receive any training for working with JIRA tickets as a developer? Basically, how did you learn to manage your day-to-day work when you first started out in your corner of the tech industry?

My Answer:

Developers rarely get "training" on anything. What sometimes happens is that you just join a team that has a workflow already and you just do what other people are doing.

As a manager, I do end up helping individuals on my team develop a personal workflow that works for them.

I usually coach people to break up their day around major interruptions. Before lunch and after lunch. Tuesdays and Thursdays are light meeting days. Something like that. Know where your solid blocks of time are. Then only focus on one project or task per day. There is a lot of pressure to context switch and try to make progress on multiple fronts. But it just doesn't work. Pick a thing and show significant progress on that. Do that for 2-3 things per week and you are doing well.

I’ve definitely reached that stage in my career where I take a lot of things for granted. Learning to manage your time is super important as an engineer (or any kind of knowledge worker). But I’ve lost perspective on what it felt like before I learned it.

No one ever gave me as clear a message as the one above. So how did I learn it? Same way I learned most things over a 20 year career. Building experience through trial and error. Screwing it up for a long time and then paying attention to what works and what doesn’t. Tips for managing your time are useful. But it’s much more important to learn to take in feedback and make adjustments based on what’s expected. Every environment is slightly different. I think being flexible and learning what people actually want from you is one of the most valuable skills to invest in.

Thinking out loud about LLM tech

Thinking more seriously about use cases for LLMs. I can’t see any way to cajole them into being accurate. It seems really obvious to me what kind of AI people actually want. One that “understands” the data and gives them answers they can trust. But that’s not possible here in any meaningful way.

So instead I’m trying to learn the underlying tech a little better and asking myself “what else could this possibly do?”

Here are some qualities of the tech that I think are interesting. Folks should feel free to correct me where I’m wrong. I’m still trying to wrap my head around it.

  • It’s made up of a system of transformers that can be massively parallelized. The capabilities of the system scales up with the amount of compute

  • There are two phases with difference affordances and properties. The training phase, where you can try to teach the system how to interpret the underlying data. And the inference phase, where you can try to teach it what kind of output is acceptable.

  • The training phase is a one time, up front investment. Given some interesting and significantly large training set, you could make your own LLM. Rather than piggybacking off existing models.

  • The inference phase happens at runtime given some input. The size of the input it will take is also a function of how much compute you have available (??). But it has no memory, so you have to send in the whole input each time. That’s why the size of input the model can take is important. It’s an unchangeable constraint on a particular instance of a model.

  • There is also RLHF. Reinforcement Learning from Human Feedback. Essentially you can have humans in the loop giving the model feedback on the quality of its answers. And that can yield significant improvements in how the model performs at a given task.

  • I don’t understand RLHF all that well yet. For instance, what is it exactly that you can impact with RLHF? Does it happen at training time or inference time? I’m reading this today. https://huggingface.co/blog/rlhf