What "Open Weights" Means
I was browsing the headlines of Hacker News and came across one called China's open-weights AI strategy is winning. I had been curious what the term "open weights" means, so I spent an hour or so learning a few things, and I will share what I learned with you right now.
Let's begin with the word weight. In neural networks, a weight is a single number that controls how strongly one part of the network influences another. It is also called a parameter. It has nothing to do with physical weight. It's about influence, significance, or importance.
Ok, so "weights" is the same thing as "parameters". When models get released, one of the key indicators of how good they are are the number of parameters. The higher the number, the more oooh and ahhhs there are.
So, what's a parameter? Well, like I said, it is a single number that controls how strongly one part of the network influences another.
But what does that mean? I don't know yet. There are too many gaps in my knowledge to truly grok it by reading that definition.
I fired up my current favorite learning too, lathe and gave it this prompt:
I would like to understand what "open-weights" means in the context of AI models. I saw this headline on Hacker News: https://werd.io/american-ai-is-locked-down-and-proprietary-its-losing/ -- i've heard the term, and i understand it as open meaning open-source (e.g., the "weights" are available to the public) but i don't know what weights are and why they are significant.
This sentence helped me see things a bit more clearly:
A large language model is built from layers of matrix multiplication: numbers flow in, get multiplied against grids of weights, get added together, and flow out transformed.
- "numbers flow in" -> a prompt (?)
- "get multiplied against grids of weights" -> still don't really understand this.
- "get added together" -> part of the formula (?)
- "flow out transformed" -> the response
Edit from the next day: this is essentially the formula that powers neural networks. There is an input expressed as a bunch of numbers, and it gets multiplied (layer by layer) by some more numbers (weights), then added to some more numbers (biases?), and then produce another set of numbers.
Grids of weights, I think, refers to the matrix of numbers (aka a 2-dimensional array aka an array of arrays). So the weights are what make up a matrix. A matrix is a bunch of weights.
What do the weights do? Well, they seem to have an influence on the end result.
I'm visualizing a drive-thru carwash. The car enters and is transformed by a bunch of... Dare I say, tensor tentacles, that seem to understand the input. Ah-ha... They are familiar with it from the data the model was trained on. "Hey, I've seen a 2016 Black Toyota Prius before." -> the models feature detection is giving priusy vibes, especially black-ish and early 2000sy.
Weights are fixed. People spend a lot of time and energy into training models. When they decide to publish it (whether publicly or privately -- more on that later...) it is like a snapshot of the parameters they deemed juuuuust right.
But if the weights are fixed, then why isn't LLM behavior deterministic? That'll have to be for another session, but some quick research shows that there are reasons at the hardware and software label.
Hmm, what is a tensor, though? For now, my working definition is an n-dimensional array of numbers. When we get past 3 dimensions, it gets a bit fuzzy, in my mind at least. But layers of input can exceed 3, so directions are used to describe how dense this container of numbers is.
- 0 directions - A scalar. A single number:
39.6 - 1 direction - A vector (I'm more familiar with the term array). A row of numbers:
[1, 2, 4] - 2 directions - A matrix. A grid of numbers (2-d array):
[ [55.2, 11], [67.0, 4], [2, 9] ] - n directions - A tensor. A container that has
nnumber of directions
The rank is the number of directions a tensor has.
Wait, so the weights are numbers contained by tensors? Or weights are tensors? Or tensors are weights?
Yes. Well, not exactly. I'd say, the input-tensors get multiplied by the weight-tensors and the transformed-tensor comes out. It's tensors all the way down.
Here's another term: In the carwash analogy, the 2016 Black Toyota Prius first gets turned into numbers. The word becomes a vector, often thousands of numbers long, often called an embedding.
Ok, so I have a better understanding of what weights are. There is so much to learn, but let's start to wrap this up by answering the original question: What does "open-weight" mean?.
I was incorrect in thinking it was the same as open source. It's not. It just means that some people released a snapshot of their model. They packed up a bunch of weight-tensors and said, "here ya go. have fun". People can download the model from sites like HuggingFace, pass input to them, and see the result.
Most of the open-weight models come from people not in the United States. Big companies like Anthropic and OpenAI do not publish their models. The weights are not open. You have to pay them to use the model.
But open weight does not mean the people share the training data or training code that they used to product the model. Some do, thankfully, but some of the large open-weight models like Qwen do not publish the datasets the model was trained on.
Open weight does not necessarily mean free, either. Although, for most of us it does. But if you have a company with millions of users, you might have to pay for a license to use the model.
The Open Source Initiative has a pretty short manuscript that describes what they consider open source, and it goes far beyond merely making the weight public.