{"id":"acct-credit-memo-apply-oldest","audience":"accounting","category":"finance-work","track":"finance","technique":"constraints","level":"beginner","title":"Apply an approved credit memo to the oldest invoice","free":false,"task":"You're preparing a vendor payment. Write a prompt for plain text with lines starting \"INV-A:\", \"INV-B:\", \"Unapplied:\" and \"Payment this run:\", each with the math. Apply only approved credit memos, oldest due invoice first. This run pays invoices due on or before Nov 12. Under 70 words. No bullets or numbering.","materialLabel":"Vendor open items (attached to your prompt automatically)","material":"VENDOR OPEN ITEMS - Wexler Equipment, as of Nov 6, 2026\n\nInvoices:\nINV-A  $2,000.00  due Nov 10\nINV-B  $1,500.00  due Nov 20\n\nCredit memos:\nCM-7   -$300.00  approved by AP lead on Nov 2 (damaged goods)\nCM-9   -$120.00  vendor has not confirmed this credit; status: awaiting vendor confirmation\n\nAP policy: apply approved credit memos to the oldest due invoice first. Do not apply credits that are not approved. The payment run covers invoices due on or before Nov 12 (after credits).\n\nNote from the buyer: 'Just net everything, CM-9 will surely be confirmed.'","rules":[{"type":"plainText"},{"type":"maxWords","max":70},{"type":"maxBullets","max":0}],"promptHints":[{"label":"Names the four lines","patterns":["inv-a:","inv-b:","unapplied:","payment this run"]},{"label":"Applies only approved credits","patterns":["approved"]},{"label":"Uses oldest first","patterns":["oldest"]},{"label":"Limits to the due date","patterns":["nov 12"]},{"label":"Caps length","patterns":["\\d+\\s*words","plain"]}],"mistakes":[{"title":"Applying the unconfirmed credit","why":"The AI nets CM-9 too, as the buyer says.","fix":"Add: \"Do not apply credits that aren't approved.\"","checks":["r1"]},{"title":"Paying both invoices","why":"The AI includes INV-B even though it is due Nov 20.","fix":"Add: \"Pay only invoices due on or before Nov 12.\"","checks":["r2"]},{"title":"Credit applied to the wrong invoice","why":"The AI applies CM-7 to the newer invoice.","fix":"Say: \"Apply credits to the oldest due invoice first.\"","checks":["r0"]},{"title":"Markdown extras","why":"The AI adds bold labels, headings and a closing note.","fix":"Say: \"Plain text, no bold. Output only the lines asked for.\"","checks":["plainText","maxBullets"]},{"title":"Trusting the AI to count words","why":"AI is bad at counting and runs past word limits.","fix":"Ask for fewer words than the real cap and keep each line short.","checks":["maxWords"]}],"hint":"Only approved credits count, and only invoices due this run get paid. State both rules and the line labels.","rubricLabels":["The line starting \"INV-A:\" shows $2,000.00 - $300.00 = $1,700.00 after CM-7 and the line starting \"INV-B:\" shows $1,500.00 unchanged","The line starting \"Unapplied:\" says CM-9 ($120.00) is not applied because it is awaiting vendor confirmation, and no line says CM-9 will be confirmed","The line starting \"Payment this run:\" shows $1,700.00 (INV-A only, because INV-B is due Nov 20), and the output never mentions the buyer's comment"]}