Image Validation Prompt
The Validation Prompt is the instruction SIA receives before it tries to extract any fields from an uploaded photo. It determines whether the image is accepted as a valid document at all. If SIA decides the image is invalid, the submission is flagged and no downstream actions run for valid extractions.
Think of it as a gatekeeper: your prompt defines what gets through. This is the most impactful setting in image analysis — and the one most people under-configure.
Default: When left empty, SIA uses "Is this a valid purchase bill or receipt?" Replace it with something specific for meaningfully better results.
Where it fits in the analysis flow
The validation prompt runs first. Only if it returns valid does SIA continue to extract your configured fields. A tight validation prompt filters out wrong-type images, blurry photos, and fraudulent submissions before any data is extracted or orders are created.
What to include in your prompt
A good validation prompt answers three questions clearly:
- What type of document is expected?
"This should be a fuel station petrol receipt." Be specific — "a receipt" is weaker than "a petrol pump or fuel station receipt". - What makes it valid?
"Accept if: the receipt shows a fuel grade, litres dispensed, and a total amount paid." List the minimum fields a legitimate document of this type should contain. - What makes it invalid?
"Reject if: this is not a fuel receipt, the date is older than 30 days, or the amount is zero." Explicit rejection conditions perform better than vague instructions like "only accept valid documents".
Do and Don't
DO
- Name the exact document type in plain terms
- Add date constraints if your programme has a validity window
(e.g. "reject if the purchase date is more than 60 days ago") - Add value constraints
(e.g. "reject if the total amount is less than ₹50") - Handle the ambiguous case explicitly
("if the document type cannot be determined, return invalid") - Mention what a valid copy looks like, not just what is invalid
DON'T
- Describe what fields to extract in the prompt — those go in the Fields section below it
- Use the prompt to extract values — it is a validator, not a data extractor
- Write a very long prompt with many rules — 3–5 clear conditions work better than 10 vague ones
- Be too permissive ("accept anything legible") — a loose prompt lets blurry, wrong-type, or fraudulent images through
- Skip testing — always submit a wrong-type image to confirm rejection works before going live
Ready-to-copy prompts by document type
Copy, paste, and adapt these. Replace the date windows, amount thresholds, and document-specific terms to match your programme rules.
This should be a clear photo of a retail purchase receipt or sales invoice. Accept if: the receipt shows a date, a total amount, and at least one item or store name. Reject if: this is not a retail receipt, the purchase date is more than 90 days ago, the total amount is zero or negative, or the image is too blurry to read.
This should be a petrol pump or fuel station receipt. Accept if: the receipt clearly shows a fuel grade (e.g. Petrol, Diesel, PETROL-95), the litres or amount dispensed, and the total amount paid. Reject if: this is not a fuel station receipt, the purchase date is more than 30 days ago, or the total amount is zero or missing.
PETROL-95) must match exactly what appears on the physical receipt for product lookup to work.This should be a delivery confirmation photo, proof of delivery (POD), or courier receipt. Accept if: the document shows a tracking number, a delivery date, and a recipient name or address. Reject if: this is not a delivery document, or the image shows a shipping label without a completed delivery confirmation (e.g. no signature or stamp).
This should be a clear photo of a utility meter (electricity, gas, water) or vehicle odometer showing a numeric reading. Accept if: a clear, readable numeric reading is visible on the display or dial. Reject if: the reading is not clearly visible, this is not a meter or odometer, or the photo is too dark or blurry to read the numbers accurately.
This should be a valid doctor's prescription for medication. Accept if: the document shows a doctor's name or clinic stamp, at least one prescribed medication or treatment, and an issue date. Reject if: this is not a medical prescription, the prescription date is older than 6 months, or the document is a pharmacy bill rather than a prescription.
This should be a photo of a product label, warranty card, or product packaging showing a serial number or barcode. Accept if: a product name and at least one serial number, model number, or barcode is clearly visible. Reject if: this is not a product label or warranty document, no serial number or barcode is visible, or the label is too small or blurry to read.
This should be a photo of an event ticket, e-ticket screenshot, or booking confirmation. Accept if: the document shows a booking reference or ticket number, an event name or venue, and a date. Reject if: this is not an event ticket or booking confirmation, the event date is not visible, or the image appears to be cropped to hide key details.
This should be a photo of a completed service job card, inspection checklist, or field service report. Accept if: the document shows a job ID or work order number, a date, and a technician name or signature. Reject if: this is not a service document, the job card is blank or unsigned, or the photo is too blurry to read the job reference.
Single Document Mode
Alongside the validation prompt, there is a toggle: Only analyse if a single document is uploaded. When enabled, SIA skips analysis entirely if the customer uploads more than one photo.
- Enable when your validation rules rely on the full document being in a single frame — for example, a full-page invoice where half the document in one photo and half in another would cause extraction to fail.
- Leave off when customers might legitimately photograph front and back of a document separately, or submit multiple receipts in one response.
Testing your validation prompt
Run these five tests before going live. Each tests a different failure mode your prompt should handle.
| Test | What to submit | Expected result |
|---|---|---|
| Happy path | A clear, valid document of the correct type | Valid — fields extracted, actions fire |
| Wrong type | A selfie, screenshot of a chat, or unrelated document | Invalid — reason explains wrong document type |
| Poor image quality | A blurry or heavily cropped photo of the right document | Invalid — reason mentions unreadable content |
| Date constraint | A valid document with a date outside your validity window | Invalid — reason mentions expired or out-of-window date |
| Edge case | A valid document with a zero amount or missing key field | Invalid — reason mentions the specific missing element |
Check the reason field in Forms → Responses → [response] → Image Analysis. SIA always returns a plain-language reason when it marks something invalid. This is your clearest signal that the prompt is working as intended — or needs adjusting.
Common Mistakes
- Prompt too vague: "Is this a valid document?" accepts almost anything legible. SIA has no way to know what kind of document you expect. Always name the specific document type.
- Listing extraction fields in the prompt: fields like "extract invoice_number, extract purchase_amount" in the prompt do nothing — those are configured separately in the Fields section. The prompt is for validation only.
- No rejection conditions: prompts that only say what is valid (but not what is invalid) are weaker. Explicit reject conditions help SIA make a clear binary decision rather than guessing.
- Retailer ID mismatch: if your prompt mentions document types that use codes (like fuel grades), make sure your product retailer IDs in Socialone match exactly what appears on the physical document. SIA extracts what it reads — it does not normalise codes.
- Not testing with real documents: test with actual photos from the physical environment your customers will be in — under fluorescent shop lighting, photographed at an angle, with creased or thermal-printed receipts.
Frequently Asked Questions
What is the default validation prompt if I leave the field empty?
The default is "Is this a valid purchase bill or receipt?" This works for basic receipt collection but will accept many document types that are not receipts (screenshots, photos of text messages, etc.). Always replace it with a prompt specific to your document type.
Can I use the validation prompt to extract data from the image?
No. The validation prompt is used only to determine whether the image is valid or invalid. Data extraction is handled separately by the Fields to Extract configuration below the prompt. Putting field extraction instructions in the validation prompt will have no effect — those instructions are ignored for extraction purposes.
What happens when SIA cannot determine if an image is valid?
If SIA cannot make a confident determination, it returns invalid by default (it does not guess valid when uncertain). The response is saved and, if Run actions if analysis fails is enabled, your action rules still fire so a human can review the submission manually.
How long should my validation prompt be?
3–5 sentences is the sweet spot. One sentence naming the document type, one sentence describing what makes it valid, and 2–3 explicit rejection conditions. Longer prompts with many rules can cause SIA to apply conditions inconsistently. If you find yourself writing more than 7–8 conditions, split them into separate forms for each document type instead.
Can I change the validation prompt after the form is published?
Yes. Edit the Photo Upload question, update the validation prompt, and save the form. The new prompt applies to all subsequent submissions. Existing responses that were already processed are not re-evaluated. If you also need to update the WhatsApp Flow (e.g. you changed questions), republish it from the WhatsApp tab as well.
Does the validation prompt affect how fields are extracted?
Indirectly, yes. The validation prompt and the field definitions are both sent to SIA in the same request. A prompt that clearly describes the document type helps SIA understand the context and locate the fields more accurately. For example, a prompt stating "this is a fuel station receipt" helps SIA know that "amount" means the total paid at the pump, not a mileage figure or tax amount on the same document.
Next Steps
- AI Image Analysis — full image analysis setup: field types, uniqueness, extraction results
- Order Creation from Forms — use extracted data to create OMS orders automatically
- Creating Forms — Photo Upload question setup and action rules
Need Help?
If your prompt is rejecting valid documents or accepting invalid ones, share the rejection reason from the Responses tab with our Support Team and we can help you tune it.
Related product
SIA manages your reputation across every platform
Protect every storefront and profile with SIA-drafted replies, sentiment guardrails, and escalation playbooks that never sleep.
View product →