This article was written to keep people as long on the page as possible. It didn’t get to the point before i left. Someone has a tl;dr?
Because AI detectors suck and are the modern day equivalent of dowsing rods?
They’re circular. If the text is too predictable it was written by an LLM* but LLMs are designed to regurgitate the next word most commonly used by humans in any given context.
*AI is a complete misnomer for the hi-tech magic 8ball
The next most commonly used word would result in a loop of common word. LLMs do not work like that
In context. And that is exactly how they work. It’s just a statistical prediction model with billions of parameters.
regurgitate the next word most commonly used by humans in any given context.
is not what it does. That would create non sensical text (you can try yourself).
This is a summary of the method, as summarized by gtp-4:
Sure, here is a detailed description of how text is generated with ChatGPT, which is based on the GPT architecture:
- Initial Prompt: The process begins with an input prompt. This could be something like “Tell me about the weather today” or any other string of text.
- Tokenization: The input text is broken down into smaller parts, called tokens, which can represent words, parts of words, or punctuation. GPT uses a byte pair encoding (BPE) tokenization, which essentially breaks down text into commonly occurring chunks.
- Embedding: Each token is then turned into a vector via an embedding. This vector captures semantic information about the token and serves as the input for the model.
- Processing the Input: The GPT model processes the input vectors sequentially with a stack of transformer layers. Each layer applies self-attention and feeds its output into the next layer.
- Self-Attention Mechanism: The self-attention mechanism in the Transformer model allows it to weigh the importance of different words when predicting the next word. For example, when trying to predict the last word in the sentence “The cat sat on the ____,” the words “cat” and “on” are likely to have more influence on the prediction than “The”. This weighing is learned during training and allows the model to generate more coherent and contextually appropriate responses.
- Output Layer: The output from the final transformer layer for the last input token goes through a linear layer followed by a softmax function, which turns it into a probability distribution over the possible next tokens in the vocabulary. Each possible next token is assigned a probability.
- Sampling with Temperature: The next token is chosen based on these probabilities. One common method is to sample from this distribution, which introduces some randomness into the process. The temperature parameter controls the amount of randomness: a higher temperature makes the distribution more uniform and the output more random, while a lower temperature makes the model more likely to choose the highest-probability token.
- Decoding: The chosen token is then decoded back into text and appended to the output.
- Next Iteration: The process then repeats for the next token: the model takes the output so far (including the newly-generated token), processes it, and generates probabilities for the next token. This continues until a maximum length is reached, or an end-of-sequence token is produced.
- Post-Processing: Any necessary post-processing is applied, such as cleaning up tokenization artifacts.
In this way, the model generates a sequence of tokens, one at a time, based on the input prompt and the tokens it has generated so far. Please note that while this process typically uses sampling with a temperature parameter, other methods like beam search or top-k sampling can also be used to choose the next token. These methods have different trade-offs in terms of computational efficiency, diversity, and quality of output.
You are missing the key part where the text is tranformed in a vector space of “concepts” where semanticic relationships are represented, that is where the inference happens. The inference is not on words to get the next commonly used word, otherwise it wouldn’t work. And you also missed the final sampling to introduce a randomness in the word selection.
I don’t understand why are you so upset for a chain of complex mathematical functions that complete and input sentence. Why are you angry?
You’re agreeing with me but using more words.
I’m more annoyed than upset. This technology is eating resources which are badly needed elsewhere and all we get in return is absolute junk which will infest the literature for decades to come.
I am not agreeing with you because “regurgitate the next most commonly world” is not what it does.
That said, the technology is not doing anything wrong. The people using it are doing it. The technology is a great achievement of human kind, possibly one of the greatest. If people decide to use it to print sh*t is people fault. Quantum mechanics is one of the greatest achievement of human kind, if people decided to use it to kill people, it is a fault of people. Many humans are simply shitty, don’t blame a clever mathematical function and its clever implementation
Removed by mod
I’ve recently checked my years-old essay using one of these AI plagiarism detectors and it said that the essay was 90% AI written. So either it’s all bs or I’m a time travelling AI.
As expected, they can’t be trusted. And the more AI evolves, the less likely AI content will be detectable IMO.
It will almost always be detectable if you just read what is written. Especially for academic work. It doesn’t know what a citation is, only what one looks like and where they appear. It can’t summarise a paper accurately. It’s easy to force laughably bad output by just asking the right sort of question.
The simplest approach for setting homework is to give them the LLM output and get them to check it for errors and omissions. LLMs can’t critique their own work and students probably learn more from chasing down errors than filling a blank sheet of paper for the sake of it.
given how much AI has advanced in the past year alone, saying it will “always” be easy to spot is extremely short sighted.
Some things are inherent in the way the current LLM’s work. It doesn’t reason, it doesn’t understand, it just predicts the next word out of likely candidates based on the previous words. It can’t look ahead to know if it’s got an answer, and it can’t backtrack to change previous words if it later finds out it’s written itself into a corner. It won’t even know it’s written itself into a corner, it will just continue predicting in the pattern it’s seen, even if it makes little or no sense for a human.
It just mimics the source data it’s been trained on, following the patterns it’s learned there. At no point does it have any sort of understanding of what it’s saying. In some ways it’s similar to this, where a man learned how enough french words were written to win the national scrabble competition, without any clue what the words actually mean.
And until we get a new approach to LLM’s, we can only improve it by adding more training data and more layers allowing it to pick out more subtle patterns in larger amounts of data. But with the current approach, you can’t guarantee that what it writes will be correct, or even make sense.
it just predicts the next word out of likely candidates based on the previous words
An entity that can consistently predict the next word of any conversation, book, news article with extremely high accuracy is quite literally a god because it can effectively predict the future. So it is not surprising to me that GPT’s performance is not consistent.
It won’t even know it’s written itself into a corner
It many cases it does. For example, if GPT gives you a wrong answer, you can often just send an empty message (single space) and GPT will say something like: “Looks like my previous answer was incorrect, let me try again: blah blah blah”.
And until we get a new approach to LLM’s, we can only improve it by adding more training data and more layers allowing it to pick out more subtle patterns in larger amounts of data.
This says nothing. You are effectively saying: “Until we can find a new approach, we can only expand on the existing approach” which is obvious.
But new approaches come all the time! Advances in tokenization come all the time. Every week there is a new paper with a new model architecture. We are not stuck in some sort of hole.
An entity that can consistently predict the next word of any conversation, book, news article with extremely high accuracy is quite literally a god because it can effectively predict the future
I think you’re reading something there other than what I said. Look, today’s LLM’s ingest a ton of text - more accurately tokens - and builds up statistics of which tokens it sees in that context. So statistically if you see the sentence "A nice cup of " statistically the next word is maybe 48% coffee, 28% tea, 17% water and so on. If earlier in the text it says something about heating a cup of oil, that will have a muuch higher chance. It then picks one of the top tokens at (weighted) random, and then the text (array of tokens) is fed in again into the LLM and a new prediction is made. And so on it continues until you stop the loop (usually from a end token or a keyword you’re looking for). Larger LLM’s are better at spotting more subtle patterns - or more accurate it got more layers of statistics that’s applied - but it still has the fundamental issue of going one token at a time and just going by what’s most likely to be the next token.
It many cases it does. For example, if GPT gives you a wrong answer, you can often just send an empty message (single space) and GPT will say something like: “Looks like my previous answer was incorrect, let me try again: blah blah blah”.
Have you tried that when it’s correct too? And in that case you mention it has a clean break and then start anew with token generation, allowing it to go a different path. You can see it more clearly experimenting with local LLM’s that have fewer layers to maintain the illusion.
This says nothing. You are effectively saying: “Until we can find a new approach, we can only expand on the existing approach” which is obvious.
But new approaches come all the time! Advances in tokenization come all the time. Every week there is a new paper with a new model architecture. We are not stuck in some sort of hole.
We’re trying to make a flying machine by improving pogo sticks. No matter how well you design the pogo stick and the spring, it will not be a flying machine.
The issue here is that you are describing the goal of LLMs, not how they actually work. The goal of an LLM is to pick the next most likely token. However, it cannot achieve this via rudimentary statistics alone because the model simply does not have enough parameters to memorize which token is more likely to go next in all cases. So yes, the model “builds up statistics of which tokens it sees in which contexts” but it does so by building it’s own internal data structures and organization systems which are complete black boxes.
Also, going “one token at a time” is only a “limitation” because LLMs are not accurate enough. If LLMs were more accurate, then generating “one token at a time” would not be an issue because the LLM would never need to backtrack.
And this limitation only exists because there isn’t much research into LLMs backtracking yet! For example, you could give LLMs a “backspace” token: https://news.ycombinator.com/item?id=36425375
Have you tried that when it’s correct too? And in that case you mention it has a clean break and then start anew with token generation, allowing it to go a different path. You can see it more clearly experimenting with local LLM’s that have fewer layers to maintain the illusion.
If it’s correct, then it gives a variety of responses. The space token effectively just makes it reflect on the conversation.
We’re trying to make a flying machine by improving pogo sticks. No matter how well you design the pogo stick and the spring, it will not be a flying machine.
To be clear, I do not believe LLMs are the future. But I do believe that they show us that AI research is on the right track.
Building a pogo stick is essential to building a flying machine. By building a pogo stick, you learn so much about physics. Over time, you replace the spring with some gunpowder to get a mortar. You shape the gunpowder into a tube to get a model rocket and discover the pendulum rocket fallacy. And finally, instead of gunpowder, you use liquid fuel and you get a rocket that can go into space.
The issue here is that you are describing the goal of LLMs, not how they actually work.
No, I am describing how they actually work.
it cannot achieve this via rudimentary statistics alone because the model simply does not have enough parameters to memorize which token is more likely to go next in all cases.
True, hence the limitations. That would require infinite storage and infinite compute capability.
Also, going “one token at a time” is only a “limitation” because LLMs are not accurate enough.
No, it’s done because one letter at a time is too slow. Tokens are a “happy” medium tradeoff.
The space token effectively just makes it reflect on the conversation.
It makes a “break” of the block, which lets it start a new answer instead of continuing on the previous. How it reacts to that depends on the fine tune and filters before the data hits the LLM.
To be clear, I do not believe LLMs are the future.
I have just said that LLM’s we have today can’t fix the problems with false data and hallucinations, because it’s a core principle of how it operates. It will require a new approach.
You could add a rocket engine and wings to a pogo stick, but then it’s no longer a pogo stick but an airplane with a weird landing gear. Today’s LLM’s could give us hints to how to make a better AI, but that would be a different thing than today’s LLM’s. From what has been leaked from OpenAI GPT4 has scaling issues so they use mixture of experts. Just throwing hardware at it is already showing diminishing returns. And we’re learning fascinating new ways of training them, but the inherent problem is the same.
For example, if you ask an LLM if it can give an answer to a question, it will have two paths to go down, positive and negative. Note, at the point where it chooses that it doesn’t know how to finish it, it doesn’t look ahead. But it sees for example that 80% of the answers in the texts it’s been trained on starts with a positive, then it will most likely start with “yes” - and when it does that it will continue to generate an answer - often very convincing and plausibly real looking answer, because it already committed to that path.
And as for the link about teaching it backspace token, the comments there are already pointing out the issue:
It’s interesting that in the examples (Table 3 on page 21), the model uses the backspace token to erase the randomly-added token from the prompt, but it does not seem to ever use the token to correct its own output. I’m curious how frequently the model actually uses this backspace token in practice - and if the answer is “vanishingly rarely”, what is the source of the improved Mauve score and sample diversity they show? Is it just that the different training procedure gives an improvement?
For it to use the backspace, wouldn’t it have to predict the wrong token with greater confidence than the corrected token? I would think this would require more examples of a wrong token + correction than the correct token, which seems a bit odd.
Almost none of the text it’s trained on has a backspace token, and to finetune it in is tricky since it’s a completely new concept - and remember it’s still doing token for token - so it would have to write a token and then right after find out that it’s more likely to send a backspace token than to continue it. It’s interesting, and LLM’s can pick up on some crazy patterns, but I’m skeptical.
Clearly the Founding Fathers were not advanced enough to have crafted the US Constitution unaided. It’s only reasonable to imagine that ancient aliens could have landed, given them an AI to assist them, and then departed with nobody the wiser.
I am certain we can find evidence of this if we dig hard enough.