Thuta Learning
ExercisesAIbeginner

Spec and Prompt Writing Drills

Relax. We'll talk through this in plain words — no textbook voice.

What you'll walk away with

  • Try out the Spec and Prompt Writing Drills yourself
  • Practice the skills you've already learned to make them solid
  • Get good at finding mistakes, fixing them, and checking your own work

Take a moment to think about this

In earlier lessons you learned how to write specs, how to write prompts, and how to give context. This lesson is about putting those skills into practice instead of just letting them sit in memory. There's no new teaching here — it's set up as a self-test so you can check your own work. Write out each task on paper or in a text editor, then actually run it through an AI tool.

Practice Drills

Task 1: Write a one-paragraph spec for a "to-do list app" — it needs to cover features, constraints, and edge cases, all three. Task 2: From that spec, write a coding prompt to give the AI, and check that it covers all four: role, context, constraints, and output format. Task 3: Run the prompt and see whether the output matches the spec — if it doesn't, write down exactly which point caused the mismatch, one line per issue.

Code Example

markdown
## Spec: To-do List App

### Goal
User တစ်ယောက်က task list ကို add/complete/delete လုပ်နိုင်ရမည်။

### Must have
- Add task (title text, empty မဖြစ်ရ)
- Mark complete/incomplete
- Delete task

### Edge cases
- Empty title နဲ့ submit လုပ်ရင် reject ရမည်
- Task list ဗလာဖြစ်ရင် "No tasks yet" ပြရမည်
- Title character 200 ကျော်ရင် truncate/reject ရမည်

---

## Prompt draft
Role: You are a senior frontend engineer.
Context: React + TypeScript project, function components only.
Task: Build a TodoList component per the spec above.
Constraint: no external state library, inline validation only.
Output: single .tsx file, no explanation text.
You should see
You'll compare the spec, the prompt, and the AI output side by side, and come away with a list of gaps between them.

Try It in 5 Minutes

Write out Task 1 and Task 2 within 5 minutes, then actually run them through an AI tool (Cursor, ChatGPT, Claude, etc.) — note down how much of the spec's coverage the output actually delivers.

A Quick Word of Caution

Don't pick a task that's too easy — throw in at least one tricky edge case, or the practice won't mean much.

Easy traps

  • Jumping straight into writing a prompt without a spec, which causes edge cases to slip through
  • Leaving constraints (library, format) out of the prompt, so the output doesn't match your project's style

Now Try It Yourself

Write out Task 1 and Task 2 within 5 minutes, then actually run them through an AI tool (Cursor, ChatGPT, Claude, etc.) — note down how much of the spec's coverage the output actually delivers.

You'll know it worked when: You'll compare the spec, the prompt, and the AI output side by side, and come away with a list of gaps between them.

Spec and Prompt Writing Drills | Thuta Learning