Ok, let's try - if need be, in several steps
AI Text Generators
At their core, systems like ChatGPT et al. are nothing but "text extenders": given a sequence of characters (actually tokens, but that's a technical detail), they compute the character which should most probably come next and spit that out:
"earth has a moo"
Which character should come next? Presumably an "n".
This character is now added to the given text and the whole process repeated - leading to the emission of a principally endless stream of characters. The initial text is often called "prompt", sometimes it is preceeded (or surrounded) by an additional "context", and the whole process is called "inference".
In order to be able to determine the most probable "next" character, models have to be "trained" with large amounts of character sequences (aka "texts"). "Training" means to measure (and remember) how often a given character follows another one - and not just one previous character, but two, three or more characters. That's why such a lot of memory is required (in the GBs)
What makes "inference" so interesting is:
- in "useful" texts, characters do not follow each other randomly but systematically, building "patterns"
- as a consequence, many principally possible character sequences (such as "yyy", f.e.) are never found and lead to 0s in the probability data sets ("tensors")
- if, during an "inference", a model finds such a pattern, it starts emitting character sequences according to that pattern
Provided that the underlying tensors are large enough (allowing for many such patterns) and the trained texts comprehensive enough, an AI model starts emitting "useful" texts ("useful" in the eyes of their users)
Important to understand is:
- AI text generators never recognize any "sense" in given or generated texts - in fact, there is no notion of "sense" in these systems, just character sequences
- useful output is only generated if the trained data was useful (and prompt and context are useful as well)
- in addition, AI text generators simply combine trained character sequences, they do not really produce new ones
However, experience has shown, that large enough models produce astonishingly "intelligent" looking output - for uses at home, such models are typically in the range of "7B" or "13B" (a "quantized" model of class "7B" usually needs around 4GB of memory)
Even more surprising, such models can be given context information or even "instructions" which they then use to "process" the actual prompt given by a user - this is how "text generators" can be instructed to become "chatterbots" or even more (see the "reason+act" REACT pattern)