AI for Government
Aware · M15 · lesson 15 of 31 · queued
Preview — browse every lesson free. Enroll to mark lessons complete, open partner links and save your progress. Login & enroll →
Prompt Engineering Basics
📖
now learning

Prompt Engineering Basics

10 min

Learning Objectives

After completing this lecture, you will be able to:

  • Understand the key concepts of prompt engineering basics in a government context
  • Apply knowledge of be specific, provide context, set format, iterate
  • Apply knowledge of the craft framework (context, role, action, format, tone)
  • Complete hands-on exercises that reinforce practical skills

Key Topics Covered

  • How to write effective prompts: be specific, provide context, set format, iterate
  • The CRAFT framework (Context, Role, Action, Format, Tone)
  • Government context for prompt engineering basics
  • Practical applications and next steps

Why This Matters for Government

Government agencies face unique challenges when it comes to AI adoption. This lecture addresses these challenges head-on by providing all government employees with the knowledge and frameworks needed to navigate AI in the public sector responsibly and effectively.

As part of the L1 (AI Aware) curriculum, this lecture builds on the foundational principle that every AI system in government ultimately serves citizens. Whether you are working with AI tools daily or setting strategy for your agency, understanding prompt engineering basics is essential for responsible, effective government AI adoption.

Lecture URL: https://skill.re/learn/govt/prompt-engineering-basics.php

======================================================================

TRANSCRIPT: Prompt Engineering Basics

======================================================================

What you will learn: How to write effective prompts. Be specific, provide context, set format, iterate. The CRAFT framework: Clear, Relevant, Accurate, Formatted, Tested.

Here's the truth: most people are not very good at writing prompts to AI systems. They treat AI like a search engine: ask a vague question, hope for magic.

But AI systems are more like smart colleagues. The more specific you are, the more context you provide, the clearer you are about what you want, the better the result you get.

In this lecture, we're going to learn how to write prompts that work. I'm going to teach you a framework—CRAFT—that will help you think through prompts systematically. By the end, you'll be writing prompts that actually produce useful output.

WHY THIS MATTERS FOR GOVERNMENT

In government, the quality of AI output matters. You're not using AI to entertain yourself. You're using it to support decisions that affect people.

If you ask an AI system a vague question and get a vague answer, and then you rely on that vague answer to make a government decision, you've just made that decision based on low-quality input.

Learning to write good prompts is not a luxury. It's foundational to using AI responsibly.

THE CRAFT FRAMEWORK

Here's a framework for writing effective prompts. CRAFT stands for:

C - Clear

Be specific about what you want. Not "write about benefits programs" but "explain the eligibility requirements for the SNAP program in plain language suitable for someone with a high school education."

Vague prompts produce vague outputs. Specific prompts produce specific, useful outputs.

Ask yourself: Could someone else read my prompt and understand exactly what I'm asking for?

R - Relevant

Provide context. If you're asking the AI to analyze something, give it the information it needs to do so responsibly.

Example (not relevant): "What's the best way to reach homeless people?"

Example (relevant): "We're a city social services agency trying to reach unhoused people in our area to inform them about available services. We have a budget of $50,000. We have staff who speak English and Spanish. What outreach approaches would be most effective?"

The second prompt provides context that enables the AI to give useful, specific advice.

A - Accurate

Make sure the information you provide in your prompt is correct. If you give the AI false information, it will use that false information and produce output based on lies.

If you're not sure about facts, say so: "I believe the program was established in 2015, but I'm not certain. Please note this assumption in your analysis."

F - Formatted

Tell the AI what format you want the output in. Do you want a bullet list? A narrative? A table? Technical language or plain language?

Example (no format): "Summarize the major challenges in disaster response."

Example (with format): "Create a bullet-point summary (5-7 points) of the major challenges in disaster response for a briefing with the city council. Use plain language. Avoid jargon."

The second prompt tells the AI exactly what format you want.

T - Tested

Don't assume the first output is perfect. Read it. Critically evaluate it. Does it answer your question? Is it accurate? If not, refine your prompt and try again.

This is iteration. Good prompts often require 2-3 rounds of refinement.

PRACTICAL TECHNIQUES

Technique 1: The Role-Play Prompt

Tell the AI what role it should play. "You are a senior budget analyst for a city government. You have 10 years of experience."

This helps the AI calibrate its response to the right level of sophistication and expertise.

Technique 2: The Example-Based Prompt

Give the AI an example of what you want. "Here's an example of a policy memo I like. Please write a memo in this style about..."

Examples guide the AI toward the right tone, length, and structure.

Technique 3: The Constraint-Based Prompt

Tell the AI what constraints to work within. "Write this for an audience with no background in policy. Avoid technical jargon. Keep to one page."

Constraints focus the output.

Technique 4: The Iteration Prompt

After the first output, give feedback: "Good start. I like the structure but it's too technical. Can you rewrite this for a general audience?"

Each iteration refines the output.

COMMON MISTAKES

Mistake 1: Asking Vague Questions

"What should we do about crime?" is too vague. The AI doesn't know what level of government you are, what your budget is, what type of crime, what you've already tried.

Specific is better: "We're a police department in a mid-sized city. We have 100 officers. We're seeing increased property crime in the downtown district over the past 6 months. What evidence-based strategies should we consider?"

Mistake 2: Providing False Information

You tell the AI, "Our city has a population of 2 million," but you're not sure that's right. The AI uses that number in its analysis. The analysis is wrong.

If you're not sure, say so: "Our city has approximately 2 million people (I'm not certain of the exact number)."

Mistake 3: Not Specifying Output Format

You ask the AI to "write a report" without saying how long, what structure, what audience.

Be specific: "Write a 2-3 page report suitable for city council members (non-technical audience), with an executive summary, key findings, and recommendations."

Mistake 4: Asking the AI to Make High-Stakes Decisions

"Should we approve this permit?" is not an appropriate AI question. AI can provide information and analysis. But high-stakes decisions require human judgment.

Better: "What factors should we consider when evaluating this permit application?"

Mistake 5: Not Checking the Output

The AI produces something. You use it without verification. If the AI made up facts (hallucination) or got something wrong, you won't know unless you check.

Always check: fact-check claims, verify citations, read carefully.

ANTI-PATTERNS / MISUSE RISKS

Anti-Pattern 1: Treating AI as Oracle

You ask the AI a question and accept the answer as truth without verification.

Risk: The AI might be wrong. It might have made up facts. You rely on incorrect information for a decision.

Anti-Pattern 2: Copying AI Output Directly

The AI produces something. You copy it verbatim into a document without reading it carefully or making edits.

Risk: The output might not fit your context. It might have errors. You're putting your name on something you haven't reviewed.

Anti-Pattern 3: Using AI for High-Stakes Decisions

You ask the AI "Should we deny this person's benefits?" and use the AI's recommendation as the basis for the decision.

Risk: The AI is a tool, not a decision-maker. For high-stakes decisions, AI should inform human judgment, not replace it.

Anti-Pattern 4: Not Providing Context

You ask a vague question and expect useful output.

Risk: The AI produces generic, low-quality output that's not useful for your specific situation.

PRACTICE / REFLECTION PROMPTS

  • Write a prompt asking an approved AI tool to do something useful in your work. Apply the CRAFT framework. Is your prompt clear, relevant, accurate, formatted, and testable?
  • Think about the last time you asked an AI system a question. Did you get a useful answer? If not, how could you have revised your prompt?
  • What's a high-stakes decision in your work that you might be tempted to ask an AI system to make? How would you reframe that question so AI informs human judgment instead?

KEY TAKEAWAYS

  • Specific prompts produce better outputs. Vague prompts produce vague answers.
  • Provide context. Help the AI understand your situation so it can tailor its response.
  • Tell the AI what format you want. Be specific about length, structure, audience, tone.
  • Iterate. The first output is rarely perfect. Refine your prompt based on the output you get.
  • Always verify. Check facts. Read carefully. Don't assume AI is right.
  • Use AI to inform, not decide. For high-stakes decisions, AI should support human judgment, not replace it.

TERMS / GLOSSARY ITEMS

Prompt: A question or instruction given to an AI system.

Prompt Engineering: The practice of crafting prompts to get better output from AI systems.

Hallucination: When an AI system generates false information with confidence.

Context: Background information that helps the AI understand your situation.

Iteration: Refining a prompt based on the output you receive and trying again.

You work in a city planning department. You want to use AI to help research best practices for improving pedestrian safety in downtown areas.

Weak prompt: "What's the best way to make pedestrians safe?"

This is too vague. The AI doesn't know what your city is like.

Better prompt: "I work for the city planning department in a medium-sized U.S. city (population 300,000). We're trying to improve pedestrian safety in our downtown business district. We have moderate funding and can implement changes over 12-18 months. What evidence-based approaches have worked in similar cities? Please format as a bullet list with brief explanations. Assume the reader has no background in urban planning."

This prompt:

  • Provides context (city size, budget, timeline)
  • Specifies format (bullet list, brief explanations)
  • Sets audience (non-technical reader)
  • Asks for evidence-based approaches (more credible)

You'd get a much better response to the second prompt.

15 minutes.

Write three prompts:

  • A weak, vague prompt asking an AI tool for something
  • A better version of the same prompt applying the CRAFT framework
  • Your reasoning for why the second is better

Good prompting is a skill. It takes practice. But it's a skill that will make your AI use dramatically more effective.

Take time to write good prompts. Read the output carefully. Iterate. You'll be amazed at the difference it makes.

Government AI CLUB Certification Program

Level 1: AI Aware | Your Agency's Approved AI Tools | Lecture 3.2

A GOVT.CLUB initiative.

<- 1.3.1 Your Agency's Approved AI Tools 1.3.3 Evaluating AI Outputs ->

Start Your CLUB Certification

This lecture is part of L1: AI Aware—8 hours of comprehensive government AI training.

Explore CLUB Certification

L1 1.3.1—Your Agency's Approved AI Tools 20 min - Hands-On Lab

L1 1.3.3—Evaluating AI Outputs 20 min - Hands-On Lab

L1 1.3.4—AI for Government Tasks: Summarization and Drafting 20 min - Hands-On Lab

Frequently Asked Questions

What will I learn in Prompt Engineering Basics?

In this 25 min hands-on lab lecture, you will How to write effective prompts: be specific, provide context, set format, iterate. The CRAFT framework (Context, Role, Action, Format, Tone)

What level is Prompt Engineering Basics?

This is a Level 1 (AI Aware) lecture, part of Chapter 1.3 \u2014 Practical AI Skills. It is designed for all government employees.

How long is lecture 1.3.2?

Lecture 1.3.2 (Prompt Engineering Basics) takes 25 min. It is delivered as a hands-on lab format.

Do I need prerequisites for Prompt Engineering Basics?

This lecture is part of L1 (AI Aware). Prerequisites: None.

What is the CLUB Certification?

CLUB (Community Leading Unified Benchmarks) is a maturity-based AI certification for government professionals with 5 levels (L1-L5), 215 lectures, and 25 chapters aligned with NIST AI RMF, OMB, and GAO frameworks.