On the Locality and Magnitude of Complexity in Systems
Complexity is inherent in any problem. The problem being solved for by a system is likely in of itself complex in some way. This is the inherent complexity of the system. Any more complexity than this is either accidental complexity added by mistake, or some extension to the problem (e.g., do it faster - therefore we have to introduce complexity, or reduce the problem scope in some way). Less complexity than the inherent complexity means we have simplified the problem. Maybe we have ignored some edge cases. ...
Edge Cases at Scale
At times we can be quick to bat off edge cases, this will only affect 1% of requests, or this has a one in a million chance of occuring! It’ll be fine! Something often left under-considered is the relationship of this with scale. That is to say, as you scale, and process more requests or messages or serve more pages or whatever it is you are doing more of - you will run into edge cases more and more often. ...
The Speed of Responsibly
“Have you ever noticed that anybody driving slower than you is an idiot, and anyone going faster than you is a maniac?” ― George Carlin I remember hearing this quote when I was first learning to drive. It works well, because we can all relate to it. And it gives us an easy out to get unstuck and realise that there is no objective truth. Everyone has their own speed which they think is responsible and reasonable given the conditions. ...
AI != LLM
Perhaps I just feel this way because I worked for a number of years at an AI startup before LLMs existed. But I am quite sick of people meaning LLM when they say the word AI. I know I just need to adapt, and keep up with the times. But I still get confused when somebody uses the word AI to purely mean LLMs. Venn Diagrams AI is a field, the persuit of Artificial forms of Intelligence. ...
Properties of Good Engineering Documentation
In an age of Genies magically whipping up thousands of lines of code based off of some context, your Engineering documentation matters more than ever. It is more and more easy to do many things, to pump them out. But how do we know we are doing the right thing? The Document The Context Before any solution can be introduced, it’s problem must be introduced. But for a problem to make sense, we must have a shared understanding of the context surrounding the problem. ...
How Does Vector Search Work?
A part 2 to my post on How Does Search Work? Vector Search as a concept is nothing new. We have been projecting data onto planes and querying the distances and relationships in these vectors for decades. But cheap(er) accessability to LLMs has lead to the rapid rising popularity of Semantic Document Search with Vectors. Similar to how Lexucal BM25 search works, Vector Search is also surprisingly easy to grock. Embeddings The heart of leveraging Vector Search technologies for Semantic Search. The Embedding ...
How Does Search Work?
There’s no better way to understand what is going on under the hood than getting in there and trying to build it yourself. So that’s what I’ve done with a Search Engine. This is intentionally simplified and omits many production concerns such as advanced tokenisation, query parsing, compression, and indexing optimisations. Just the core Information Retrieval logic. To get in there and understand what is really happening. Let me walk you through what I have found. ...
Digging the Pit of Success
I first came across this metaphor on coding horror. The metaphor has stuck with me, and I find it applies widely. The core concept here is that if it’s easy to make mistakes, mistakes will happen. We are all human, and the “correct” thing to do is not always consistent or obvious. It might even seem to change depending on your context. This is connected to Hyrum’s law, if somebody can do something with your system with enough users they will. We cannot rely on people to magically read our minds about how we intended things to work. ...
There is No Such Thing as the Right Time
When I was a younger man, I lived my life planning. Waiting for the right time to make my moves. And I did, but I didn’t always get it right. Sometimes my timing was wrong. What makes it the right time to do something? What does this mean? Well, at a basic level it can be about your ability to deal with the risk related to the opportunity in front of you. ...
Trying to Not Get Left Behind
For the past couple of years, a lot of us Software Engineers have spent a lot of our time trying to not get left behind. But where are we going? And what are we being left behind from? The token prediction genie Ever since ChatGPT was released to the world 3 years go, the core functionality behind Agentic coding and LLMs has remained the same. It is a machine learning model which tokenises input, and then produces what the next most likely token is to be. It has a “context window”, so the next token it predicts is within the context of the whole window. ...