lesson
20 min

Advanced Prompt Techniques

Level up with chain-of-thought reasoning, few-shot examples, and role prompting — three techniques the pros use.

You know the basics: be specific, give context, show examples. Now let's go deeper. These three techniques are what separate casual AI users from people who get genuinely impressive results.

Don't let the word "advanced" scare you. These are just smarter ways of asking.

Technique 1: Chain-of-Thought (Think Step by Step)

Here's a weird thing about AI: if you ask it to think step by step, it actually gives better answers. Not just more detailed — more accurate.

Why? Remember, AI predicts what comes next. When you force it to work through a problem step by step, each step becomes context for the next one. It's like showing your work in math class — the process leads to a better answer.

Without chain-of-thought:

I make $15/hour and work 32 hours a week. After taxes and rent, can I afford a $300/month car payment?

With chain-of-thought:

I make $15/hour and work 32 hours a week. Walk me through this step by step:

  1. Calculate my monthly gross income
  2. Estimate my take-home pay after Texas taxes
  3. Subtract my rent ($850/month)
  4. Subtract other essential expenses (food $300, phone $60, utilities $120)
  5. Tell me what's left and whether a $300 car payment is realistic

The second prompt forces the AI to show its reasoning at each step. You can follow along, check the math, and catch any mistakes.

Phrases that ask for step-by-step thinking:

  • "Think through this step by step"
  • "Walk me through your reasoning"
  • "Break this down for me"
  • "Explain how you got to that answer"
  • "Let's work through this one piece at a time"

Use this technique whenever you need the AI to solve a problem, make a calculation, or analyze something complex.

Technique 2: Few-Shot Prompting (Give Multiple Examples)

In the last lesson, we talked about giving one example. Few-shot prompting takes that further — you give the AI two or three examples so it really locks onto the pattern you want.

This is incredibly useful when you need AI to follow a specific format or style.

Let's say you're writing descriptions for job listings:

I need you to write job descriptions in this format. Here are two examples:

Warehouse Associate — $16/hr H-E-B Distribution Center, east side. Full-time, Mon-Fri. You'll pick and pack grocery orders for store delivery. Must be able to lift 50 lbs. No experience needed — they train you. Benefits start day one.

Front Desk Receptionist — $14/hr Westover Hills dental office. Part-time, mornings only. Answer phones, check in patients, handle paperwork. Bilingual English/Spanish preferred but not required. Scrubs provided.

Now write one for: Security guard position at a downtown office building, $17/hour, overnight shift, no experience required, must pass background check.

Because you gave two examples, the AI knows exactly the format, length, tone, and style you want. It'll match it closely.

When to use few-shot:

  • You want a specific format repeated
  • The AI keeps getting the style wrong and you want to show, not tell
  • You're doing a batch of similar tasks (writing multiple emails, creating multiple descriptions)

Pro tip: Two to three examples is usually enough. More than five and you're wasting space without much improvement.

Technique 3: Role Prompting (Give AI a Character)

This one is powerful and kind of fun. You tell the AI to take on a specific role before answering your question. This shapes how it responds — the vocabulary it uses, the perspective it takes, the advice it gives.

Without a role:

How should I negotiate my salary?

With a role:

You are an experienced HR manager at a mid-size company in San Antonio. You've conducted hundreds of salary negotiations. Based on your experience, coach me on how to negotiate a starting salary for a customer service position. Tell me what works, what backfires, and what most candidates don't realize.

By giving the AI a role, you get a more focused, more expert-sounding response. The AI draws on patterns associated with that role in its training data.

Some useful roles to try:

  • "You are a career counselor for young adults" — great for job search advice
  • "You are a patient and encouraging tutor" — great when learning something new
  • "You are a financial advisor for people living paycheck to paycheck" — realistic money advice
  • "You are a Texas-based attorney explaining legal rights in plain English" — legal info made accessible
  • "You are a hiring manager reviewing applications" — honest feedback on your resume

You can combine roles with other techniques:

You are a hiring manager at a San Antonio hospital reviewing applications for medical assistant positions. I'm going to show you my resume. Tell me step by step what stands out as strong, what's missing, and what would make you call me for an interview.

That's role prompting + chain-of-thought in one prompt. Powerful combination.

Quick Reference

TechniqueWhen to Use ItKey Phrase
Chain-of-thoughtProblem solving, analysis, math"Think step by step"
Few-shotMatching a format or style"Here are some examples..."
Role promptingGetting expert-level perspective"You are a..."

One More Thing: You Can Combine Everything

The best prompts often use multiple techniques together. Here's what a really well-crafted prompt looks like:

You are a workforce development specialist in San Antonio who helps young adults aged 18-24 find their first professional jobs. Think step by step about my situation and give me a realistic 90-day plan.

My situation: I'm 20, I have a GED, I've worked fast food for 2 years, and I want to break into office work. I have no certifications and no car (I take the bus). I can dedicate about 2 hours a day to career development outside of work.

Format the plan like this example: Week 1-2: Focus area. Specific actions to take. Resources to use.

That's role prompting + chain-of-thought + context + few-shot formatting, all in one. And it'll get you a genuinely useful response.


Exercises

Try This: Take a question you've already asked AI and rewrite it using chain-of-thought. Add "Think step by step" or "Walk me through your reasoning." Compare the original answer with the new one. Was the step-by-step version better?

Try This: Use role prompting to get advice from three different perspectives. Ask about the same topic — like "Should I go back to school?" — but use these three roles: a career counselor, a financial advisor, and a successful person who never went to college. Notice how the role changes the advice.

Talk About It: Is it ethical to have AI pretend to be a doctor, lawyer, or financial advisor? Where's the line between getting helpful perspective and getting advice you shouldn't trust? What safeguards would you want?

Judgment Check: Roles Have Limits

Role prompting is useful. You can ask AI to act like a coach or an editor. But an AI playing a doctor, lawyer, or immigration expert is still guessing.

Use those roles to prepare questions for a real professional. Do not use them to make the decision. In San Antonio, free legal help is available through groups like Texas RioGrande Legal Aid.

Quiz: Which technique fits?

  1. 01You want AI to check a budget's math one step at a time. Which technique fits best?

    Choose one.

  2. 02You want ten job ads written in the same style as two you like. Which technique fits best?

    Choose one.

  3. 03You ask AI to act as a lawyer about your lease. What is the right way to use the answer?

    Choose one.