Library › Legal & Compliance AI › Legal teams

Pull a contract request out of an email as JSON

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

About this exercise

Convert the email into JSON in one code block, with nothing before or after it. Use exactly these keys in order: requester, team, other_party, contract_type, value_usd, needed_by, notes. requester is written "Last, First". contract_type is exactly one of: nda, services, purchase, other. value_usd is a number with no $ or commas, using the latest figure. needed_by is YYYY-MM-DD (the email is dated Nov 4, 2026). notes is one string of 8 words or fewer about anything unusual, or null. Use null for anything not stated.

Common mistakes when you ask AI for this

  • Old value. The AI uses $85,000. Try: Say: "Use the latest figure as a plain number."
  • Date format. The AI writes 'the 20th' or Nov 20. Try: Say: "needed_by as YYYY-MM-DD."
  • Advice in notes. The AI says starting early is risky or fine. Try: Say: "notes states the fact only, no advice."
  • Prose around the JSON. The AI explains the fields. Try: Say: "One code block and nothing else."
  • Prose around the code. The AI adds explanation or several blocks. Try: Say: "One code block and nothing else."
  • Long code block. The AI adds extra lines or comments. Try: Say: "No comments, under N lines."

What a strong prompt includes

  • Exact keys
  • Date format
  • Number value
  • Null for unknown
  • One code block

Practice this now ↑

Related exercises