Prompting Basics and Methods

I came across this online book about Large Language Models (LLMs): Xiao, Tong, and Jingbo Zhu. “Foundations of Large Language Models,” 2025. I found it more on the technical side, but the Prompting chapter was an interesting read. I found it helpful, and wanted to share it simply here, with simplified examples of it (of course with the help of ChatGPT). Hope this bite-sized summary will be helpful in understanding the prompting essentials and methods.

What is Prompting?

Prompting is simply the art of asking AI the right way to get the answers you need. Imagine you’re at a coffee shop. If you just say, “Coffee,” the barista might be confused. Do you want a latte, black coffee, or espresso? Hot or iced?

Now, if you say, “I’d like a medium iced latte with oat milk, please,” you’re much more likely to get exactly what you want.

That’s what prompting is—giving AI a clear request so it understands what you need.

How to Talk to AI: Prompting Basics

If AI were a person, it would be the world’s most well-read—but slightly awkward—friend. It knows a lot but needs precise instructions. Here’s how you can guide it effectively:

1. Be Clear & Specific

  • Bad prompt: “Tell me about history.”
  • Better prompt: “Give me a 3-paragraph summary of the American Revolution, focusing on why it started.”

2. Give AI a Role

  • Bad prompt: “Give me business advice.”
  • Better prompt: “Pretend you are a startup mentor. What are three common mistakes new founders make, and how can they avoid them?”

3. Use Examples

  • Bad prompt: “Write a social media post.”
  • Better prompt: “Write a fun, engaging tweet about the benefits of drinking more water, in the style of Wendy’s Twitter account.”

How AI Learns from Examples (In-Context Learning)

Let’s say you’re training a dog. If you just say, “Sit!” without showing what that means, the dog may not understand. But if you demonstrate it a few times, the dog learns.

AI works similarly—it learns from patterns in the examples you provide. This is called in-context learning, and it comes in different forms:

  • Zero-shot – No examples, just asking: “Explain photosynthesis in simple terms.”
  • One-shot – Giving one example: “Explain photosynthesis like you’re talking to a 5th grader. Example: ‘Imagine plants eating sunlight like a snack…’”
  • Few-shot – Multiple examples for better results: “Here are two examples of how I explain science to kids. Now, explain photosynthesis in the same way.”

Advanced Prompting Tricks

1. Chain of Thought: Get AI to Think Step by Step

  • Bad prompt: “Solve this riddle: A farmer has a fox, a chicken, and a bag of grain…”
  • Better prompt: “Solve this riddle step by step, explaining your reasoning at each stage.”

2. Break Down Complex Problems (Problem Decomposition)

  • Bad prompt: “Write a business plan for my new coffee shop.”
  • Better prompt: “First, outline the key sections of a business plan. Then, provide details on each section. Start with the executive summary.”

3. Self-Refinement: Ask AI to Improve Its Own Answer

  • First, generate a response.
  • Then, ask: “Now refine this to be more persuasive and engaging.”

4. Ensembling: Combine Multiple Prompts for Better Answers

If you want a richer, more nuanced response, try ensembling—using multiple prompts and combining the best answers. For example:

  • Prompt A: “Summarize the history of electric cars.”
  • Prompt B: “List key breakthroughs in battery technology for electric vehicles.”
  • Final Output: Combine both responses for a more detailed overview.

Boosting AI’s Capabilities: RAG & Tool Use

AI has limits—it only knows what it was trained on. But Retrieval-Augmented Generation (RAG) solves this by letting AI pull in fresh, real-time data. Instead of just guessing, it looks up reliable information.

Similarly, tool use lets AI interact with external APIs, like a calculator, a translation service, or even a weather forecast tool. This allows for more precise and fact-based responses.

Using AI to Supercharge Your Work

AI isn’t just a fancy chatbot—it can save time, spark creativity, and boost productivity if used correctly. Here are some practical ways to use it:

  • Writing Help: Draft emails, social media posts, or reports.
  • Brainstorming: Ask AI for 10 ideas on a topic.
  • Summarizing: Condense long articles into key takeaways.
  • Learning: Explain complex topics in simple terms.

Final Thought: The AI Is Only as Good as Your Questions

Mastering AI isn’t about knowing technology—it’s about knowing how to ask good questions. The more thoughtful your prompt, the better the response.

Try experimenting with different prompts today, and see just how powerful AI can be when guided the right way!

Ayse Ozturk

Sources:


Discover more from Dr. Ayse Ozturk

Subscribe to get the latest posts sent to your email.

One response to “Prompting Basics and Methods”

  1. […] Example 1: My earlier blog post “Prompting Basics and Methods“ […]

Leave a Reply

Discover more from Dr. Ayse Ozturk

Subscribe now to keep reading and get access to the full archive.

Continue reading

Discover more from Dr. Ayse Ozturk

Subscribe now to keep reading and get access to the full archive.

Continue reading