Prerequisites: LLMs, Prompts, and What You Really Need to Know
How LLMs Are Trained (And Why It Matters)
You’re not training your own language model, but it helps to know what’s happening under the hood.
There are three main stages to how LLMs are trained:
1. Pre-Training
This is the brute-force phase.
The model reads everything, books, articles, websites. Trillions of words.
It learns by guessing the next word over and over.
No human correction. Just pattern recognition at massive scale.
Result?
A model that understands grammar, tone, sentence structure, and general knowledge.
But it’s still raw. It doesn’t follow instructions or know what you want.
2. Fine-Tuning
Now the model gets focused training.
It’s fed curated examples: prompt → ideal response.
This stage teaches it how to follow instructions properly.
It’s where “write a poem” turns into something actually worth reading.
Result?
More helpful, less robotic. Starts to sound like it gets you.
3. Human Feedback (RLHF)
Real people score multiple responses from the model.
The model learns what humans prefer and starts optimizing for those answers.
This makes it more aligned.
More useful.
Less weird.
What’s Actually Happening When an LLM Writes Text
Here’s the process in plain English:
1. Your message is split into chunks (tokens)
2. Those chunks get turned into numbers (vectors)
3. The model looks at the whole input, figures out context
4. It predicts the next token (aka the next word or word-piece)
5. It adds that to the response
6. Repeats until it decides to stop
Underneath all this is a thing called a transformer — the model architecture that makes this possible. You don’t need to know the math. Just know this is what lets it "read" your input properly and respond with context.
Challenges of Training LLMs
This process is not cheap or clean:
* Requires thousands of GPUs running for weeks
* Clean, balanced data is hard to find
* Hard to make it behave safely or ethically
* Tough to evaluate what “good” even means
* Consumes a ton of energy
So no, you’re probably not going to train one yourself. But knowing what goes into it helps you use them smarter.
Open Source vs Closed Source Models
You’ve got two lanes to choose from when working with AI models:
Closed Source
Think: GPT-4, Claude, Gemini.
Private companies own these. You access them through paid APIs.
Pros:
* Best performance, out of the box
* No infra to manage
* Constant updates and support
Cons:
* Can’t tweak them deeply
* You’re locked into their pricing
* You send your data to a third party
* If they shut off access, you’re stuck
Open Source
Think: LLaMA, Mistral, DeepSeek.
These models are public. You can download, tweak, and run them yourself.
Pros:
* Full control over everything
* Costs less over time if you scale
* You keep your data private
* Thriving community support
Cons:
* You need the compute power
* You need the talent
* You maintain everything yourself
* They usually don’t match the top-tier performance
What Smart Teams Actually Do
They use both.
* Closed source for speed and general tasks
* Open source for anything private, secure, or custom
This lets you optimize for performance, cost, and compliance, without being boxed in.
Prompt Engineering: Getting the Model to Do What You Want
The model’s smart. But it’s not psychic.
If your prompt is vague, your output will suck.
What Is Prompt Engineering?
It’s the skill of writing clear instructions for AI, so it gives you what you actually need.
Why It Matters
* Better results, less editing
* More control over tone, format, length
* Works first time, which is huge for automations
* Unlocks advanced tasks, like multi-step logic or math
Best Practices
1. Be specific.
“Tell me about AI” is weak.
“Explain how neural networks learn, focusing on backpropagation” is better.
2. Structure your input.
Use headers, quotes, or separators to make the prompt readable, for you and the model.
3. Use examples.
Show it how you want it to respond. This is called few-shot prompting.
4. Iterate.
Test. Refine. Repeat. Prompting is rarely one-and-done.
5. Use techniques like:
* Chain-of-thought: “Solve this step-by-step…”
* Role-based: “You’re a marketing strategist. Write…”
* Format control: “Reply in JSON with fields: title, summary, CTA…”
Real-World Prompts
* “Generate a polite reply for a late delivery complaint. Offer 15% discount.”
* “Write a blog intro about vegan diets. Friendly tone. Emphasize protein.”
* “Analyze this CSV and give trends in a markdown table.”
Bottom Line
LLMs only seem “smart” when you talk to them clearly.
Your prompt is the brain.
It controls tone, depth, structure, and usefulness.
Get good at prompting and you’ll get better results with less effort, less editing, and more consistency. This is the hidden edge in using AI effectively.
Thanks for reading, leave a like, follow along and let me know in the comments if you like it💫