Library › Finance AI › Accountants

Bucket open invoices by days past due into one JSON block

  • For Accountants
  • You practice Asking for a format you can use
  • Time about 5 minutes
  • Level Intermediate

About this exercise

You're summarizing the AP aging as of Oct 31, 2026 for the controller. Write a prompt for one JSON code block: an array with one object per vendor, keys vendor, current, d1_30, d31_60, d61_plus and total, all numbers. Bucket by days past the due date (an invoice due on Oct 31 is current), not by invoice date. Outside the code block write at most 15 words.

Common mistakes when you ask AI for this

  • Bucketing by invoice date. The AI ages from the invoice date. Try: Say: "Bucket by days past the due date."
  • Putting the due-today invoice in 1-30. The AI treats Oct 31 as past due. Try: Add: "An invoice due on Oct 31 is current."
  • Dropping the disputed invoice. The AI leaves out INV-310. Try: Add: "Include disputed invoices."
  • Wrong JSON shape. The AI nests buckets or writes strings. Try: Add: "One flat object per vendor, numbers not strings."
  • Wrong code block shape. The AI splits the output or adds extra rows. Try: Say: "One code block, header plus the exact rows."

What a strong prompt includes

  • Names the keys
  • Buckets by due date
  • Handles the Oct 31 edge
  • Limits to one code block

Practice this now ↑

Related exercises