Working with tables and CSVs (small-scale)
Day 26 of 30 · 30 Days of AI
Safely transform small datasets with clear instructions
Learning goal
- Give column-aware instructions to reshape data.
- Ask for validation steps and highlight missing values.
Why it matters
- Specific column/format instructions avoid broken tables.
- Highlighting missing values prevents silent errors.
Explanation
- Specify columns, expected output format (markdown table), and operations (filter/sort/add column).
- Forbid adding rows; ask to flag missing/invalid data.
- Request a short “checks” line: counts, missing fields.
Examples
- Prompt: “You have columns A,B,C. Filter where status=Active, sort by date, add total=price*qty. Return markdown table; flag missing values; do not invent rows.”
- Weak: “Fix this CSV.”
- Provide 5–10 rows of sample data.
- Ask for a filtered/sorted/derived-column table with checks.
- Output table matches requested columns/ops.
- No invented data.
- Validation line present.
- Data prompts: prompt guide
Guided exercise (10–15 min)
Independent exercise (5–10 min)
Add a “validation” line: row count before/after, missing field list.