I should point out that the explanations above are intentionally simplified, to be easily digestible. There are many details which blur the lines of how complex systems work in practice. For example, tool calls (read, write, etc.) are commonly represented using structured data, often JSON or a JSON-like schema, such as:
{
"tool": "write_file",
"arguments": {
"path": "foo.py",
"content": "..."
}
}
rather than relying on the harness to scrape a textual command. The concept to grok is that harnesses receive requested operations and execute them. The important part to understand is that the harness is a software layer which gives an LLM controlled ways to interact with resources outside the model itself, such as files, operating-system commands, browsers, APIs, databases, and other tools..
Also, the concept of post-training was kept intentionally simple above (question-answer pairs and a little about reinforcement learning is easy enough to make sense). In reality, it can include combinations of supervised fine-tuning, preference optimization, reinforcement learning, rejection sampling, model-generated, synthetic data, verifiable-reward training, tool-use training, reasoning-trace-related training methods, distillation, adversarial/safety training, and other approaches that would only pollute the main concept.
And of course, LLMs process tokenized representations of words (not words themselves), but the intent was for the verbiage above to make sense conceptually. Use the tutorial above as a conceptual jumping off point, then perhaps copy/paste it into ChatGPT and ask for more details.
For more info and instructional posts, see the tutorials section:
https://aibynick.com/category/8
I'll continue this thread later by putting some concrete examples together, which demonstrate all those pieces and how they are implemented in each of the well known harnesses. Seeing all the ways people build harness features, and how you can accomplish the same goals with conceptually similar tools, implemented in slightly different ways, is one of the best ways to really grok how to work with LLMs and harnesses. You can, by the way, learn all that on your own, just by working with any capable LLM, from any API provider, in any capable harness.