A Learner's First Few Steps for Exploring LLMs
Co-authored with ChatGPT o1-preview, as published in Testing Experience magazine.
Alright, so you've decided to dive into the world of Large Language Models (LLMs), have you? Bold soul.? I've been navigating this maze myself, so I figured I'd share my journey. It's been going well for me - when the stars align. But don't let me cramp your style. Go ahead, blaze your own trail. After all, who am I to steer your ship? To each their own, as they say.? Which is polite for 'I wouldn't do that but go ahead, poke the bear. I'm sure that it’s in a good mood today.’
The First Few Steps
1. Start with a Frontier Model's Web Interface
First things first, dip your toes in. Head over to a frontier model's web interface like ChatGPT or Claude. Start small. Ask it to craft an ode to your morning alarm clock or explain the secrets of the universe as told by a toddler. You know, the usual existential quests. It's all fun and games until the machine starts pondering your existence. Just kidding. Unless it already has. Probably.
Your goal at this stage is to grow beyond gotcha prompts that one borrows from the university of LinkedIn like “Which is larger - 9.11 or 9.9?” or “How many r’s are there in Strawberry?”. Wrap that up. Fast. Have one more go if you must. Have one last laugh. Then start asking questions that actually matter to you. Like requesting a love letter to your cat or a heartfelt apology to your neglected gym membership. At least that's personal and beats indulging in pseudo-intellectual games. It's far more rewarding than trying to stump the machine with overused riddles that only serve to inflate egos on LinkedIn.
2. Pay for It and Go Deeper
Once you've had your fun and realize the abyss of curiosity is deeper than you thought, consider parting with some cash. Yes, open that wallet. An investment in knowledge pays the best interest - or at least gives you something to talk about at parties. Dive deeper. Learn about prompt engineering - a term that makes "asking nicely" sound like a science.?
Try different types of problems and play around with input-output formats. Maybe even learn about Transformers and the Attention mechanism. No, not the robots or your tendency to zone out when someone mentions 'synergy.'
3. Experiment with Root Prompting
Time to get a bit more sophisticated. Experiment with root prompting - the first prompt that sets the tone for the entire chat. Think of it as your opening line at a party. You wouldn't walk in and shout something inappropriate - well, maybe you would, but let's aim higher. It's like your first tweet of the day: make it count before you're cancelled for that typo that changed "public" to something else entirely.?
Maybe go with, "You're a motivational speaker who uses sarcasm to inspire," and see how the AI motivates you. Or perhaps, "You're a journalist who can't resist a good pun." The idea is to set the stage so the AI knows which costume to wear. Or don't bother. It's your rodeo; I'm just the guy selling popcorn.
4. Create a Custom GPT
Why keep hammering out the same old commands when you can get the AI to read your mind - or at least pretend to? Noticing that your prompts are starting to feel like a scene from Groundhog Day? Saying the same thing over and over, like a sitcom rerun no one asked for? Repeating yourself like a parrot with short-term memory issues? It's time to build a Custom-GPT.?
Turn those repetitive requests into custom instructions.? It's like teaching a parrot to talk, but without the danger of it quoting your questionable late-night texts. Let the AI handle the repetitive stuff so you can ponder life's mysteries, like why socks always go missing in the wash.
5. Extend Custom GPT with Code and Tools
Feeling experimental? Upgrade your Custom GPT with some code or outside services. Add a few gadgets into the equation. How about connecting it to your smart mirror? Who knows? It might start giving you motivational speeches - or brutally honest critiques - every morning. The possibilities are endless - until you develop a complex.
By integrating code and external services with your Custom GPT, you're essentially giving it the keys to your digital kingdom. It's like handing over your house keys to a stand-up comedian - you don't know whether you'll come home to a surprise party or find your furniture rearranged for a joke.
Remember - with great power comes great potential for hilarious mishaps.
6. Explore the API Layer
Now we're stepping into the big leagues. Time to dive headfirst into the API layer. Don't panic; it's not as scary as it sounds. Start tinkering with the Chat API - send messages, receive responses, maybe even upload some images. Yes, even that unflattering selfie you've been hiding since the last family reunion. Who knows? The AI might appreciate your unique sense of style. Play around with response formats—make it sing, dance, or at least reply in JSON. Enable tool or function calling; make the AI fetch data, perform calculations, or tell you the weather in Timbuktu. Manage context like you're conducting a conversational orchestra, keeping every instrument in sync.?
But let's not get ahead of ourselves. This is still basic territory. So, maybe keep that cape in the closet a bit longer. You're not quite ready to audition for "America's Next Top Coder." Master Yoda you are not - yet.
7. Create a Mini-Framework
Fed up with the same old, same old? Time to whip up your own mini-framework. Craft some reusable modules to tackle the tedious bits, so you can focus on more crucial matters - like figuring out why you've got 200 unread emails or debating whether pineapple belongs on pizza.?
And hey, when you've automated the dull stuff, you can finally catch up on that series everyone's been spoiling for you.? Plus, automating repetitive tasks makes you look like a genius, even if you're just avoiding actual work. It's a win-win.
8. Explore LangChain and LangSmith
By now, you might as well dive into LangChain and LangSmith. They're like the secret sauce for working with LLMs - or perhaps just more rabbit holes to tumble down. Either way, worth a peek.?
But fair warning: LangChain can take a simple task and wrap it in layers of complexity so thick you'll need a machete to cut through. It's like asking for a glass of water and being handed a blueprint for a desalination plant. Sure, it's impressive, but all you wanted was a drink. On the bright side, wrestling with it gives you something to complain about on social media - because who doesn't love a good rant?
9. Chunking Large Content and Semantic Search
Why try to leap over a mountain in one bound when you can stroll up it one step at a time - and save yourself from cardiac arrest? Dealing with massive amounts of text? Time to learn about chunking and embeddings. No, it's not a new fitness regime or something you'd find in a dodgy nightclub.?
Use Vector Databases for semantic search. Sounds fancy, doesn't it? But it's not as high-tech as it sounds. Break down that colossal content into bite-sized pieces. Summarize effectively. Then casually drop "vector embeddings" into conversation at parties. Your friends will be so impressed they'll probably change the subject.
10. Dive into Retrieval-Augmented Generation (RAG)
At the end of this enlightening journey, it's time to tackle RAG - Retrieval-Augmented Generation. Start small; there's no need to wrestle a bear on your first day at the zoo; after all, even Picasso started with finger painting.?
Try out different RAG styles, like a chef experimenting with recipes - some will be culinary masterpieces, others will set off the smoke alarm. Combine your accumulated knowledge to craft something truly magnificent - or at least something that doesn't make you want to throw your computer out the window.
Be Skeptical and Think Critically
But hold on a minute. Before you get too carried away, remember to be skeptical. Wear your critical thinking hat - if you can find it under all that enthusiasm. There's no true learning or exploration without questioning what's in front of you. Especially with LLMs. They might dazzle you with eloquence, but they're just algorithms predicting text - not philosophers decoding the universe.
The LLMs can generate impressive text, but they don't understand context like a human does. They don't feel, they don't think, they don't ponder the meaning of life while sipping a cup of tea. So, while you're experimenting and building with LLMs, keep your wits about you. Question the outputs. Cross-check information. Just because it sounds convincing doesn't mean it's correct.
Think of LLMs as your chatty friend who always has an answer, even when they have no idea what they're talking about. Entertaining? Yes. Reliable? Not always. So, take everything with a grain of salt—maybe the whole shaker.
Wisdom isn't just about having answers; it's about knowing which questions to ask and which answers to trust.
Conclusion
So there you have it - a path for exploring LLMs that's been working for me. This should keep you occupied for a couple of months, or at least until the next big distraction comes along. Maybe it'll suit you, or maybe you'll forge your own path and make me look like I'm stuck in the Stone Age. Either way, it's all part of the adventure. Go on, place your bets. After all, what's the worst that could happen? Actually, on second thought, let's not go there.