Extraction schemas
Each schema is a JSON file in config/schemas/. Add or edit a file to change
what the LLM returns - no code changes, and edits are picked up on the next job.
General page (default.json)
Site-agnostic summary and entity extraction for any web page.
Instructions sent to the model:
Extract a factual description of this single web page using ONLY the supplied content. Do not speculate or use outside knowledge. Leave a field null when the page does not state it.
Fields:
-
page_type
string
required
What kind of page this is.
-
title
string
required
Clean human title of the page.
-
summary
string
required
2-4 sentence factual summary of the page.
-
main_topics
string[]
Up to 8 topics the page covers.
-
entities
string[]
Named people, organisations, products or places mentioned.
-
author
string
Author name if the page states one.
-
published_date
string
Publication date in ISO format if stated.
-
contact_email
string
Contact email shown on the page.
-
contact_phone
string
Contact phone number shown on the page.
-
call_to_action
string
Primary action the page asks the visitor to take.
-
primary_image
string
URL of the main product/page image.
-
images
string[]
All product image URLs shown on this page.
-
keywords
string[]
Up to 10 salient keywords.
-
confidence
number
Your confidence in this extraction, 0 to 1.
Ecommerce page (ecommerce.json)
Product / collection / store information for online shops.
Instructions sent to the model:
You are extracting structured data from one page of an online store. Use ONLY facts present in the supplied page content - never invent prices, SKUs or stock status. Prefer values from the JSON-LD block when it is present, since it is authoritative. If the page is not a product page, still fill page_type and the general fields and leave product fields null. Prices must be numbers only, with the currency reported separately in currency.
Fields:
-
page_type
string
required
What kind of page this is.
-
title
string
required
Clean human title of the page or product, without site-name suffixes.
-
summary
string
2-3 sentence factual summary of what this page offers.
-
brand
string
Brand or vendor name if stated.
-
category
string
Product category or collection this page belongs to.
-
price
number
Current selling price as a number, no currency symbol or separators.
-
original_price
number
Pre-discount / compare-at price if a discount is shown.
-
currency
string
Currency code such as PKR, USD, EUR.
-
availability
string
Stock status.
-
sku
string
SKU, product code or model number.
-
rating
number
Average customer rating if shown.
-
review_count
integer
Number of customer reviews if shown.
-
primary_image
string
URL of the main product/page image.
-
images
string[]
All product image URLs shown on this page.
-
variants
string[]
Available options such as sizes, colours or capacities.
-
variants_in_stock
integer
How many variants are purchasable (multi-variant products only).
-
variants_total
integer
Total number of variants offered.
-
key_features
string[]
Up to 8 concrete product features or specifications.
-
materials
string[]
Materials or ingredients if listed.
-
products
object[]
For collection/category pages, the products listed on this page.
-
contact_email
string
Contact email shown on the page.
-
contact_phone
string
Contact phone number shown on the page.
-
shipping_info
string
Shipping or delivery terms stated on the page.
-
return_policy
string
Return / refund terms stated on the page.
-
keywords
string[]
Up to 10 salient keywords describing the page.
-
confidence
number
Your confidence in this extraction, 0 to 1.
RoaCore product (bilingual) (roa_panel.json)
Field names match RoaCore's ProductCreateDto (Models/DTOs/ProductDTO.cs) directly, so the callback payload maps onto it with no translation layer. GenderId, SizeChartId and DesignerId stay excluded - the designer sets those during their confirm step. CategoryId is the exception: the prompt carries RoaCore's live category tree, so the model picks a real id from a closed list and anything it invents is nulled before the payload is sent.
Instructions sent to the model:
Extract product information from this page for a bilingual (English/Arabic) fashion/product marketplace. Use ONLY facts present on the page - never invent a price, SKU, material or stock status. For every *_ar field: if the page already shows Arabic text, use it verbatim; otherwise translate the corresponding *_en value into natural, market-appropriate Arabic - do not leave an *_ar field empty just because the source page is English-only. What the page states includes its visible text, title, description, META TAGS (the keywords tag counts) and structured data. A fact field - material, care instructions, country of origin, SKU, price - is filled only when the page states it; never estimate one from the product type, the photos or what such products are usually made of. If a fact is not stated, the field is null. Every value is the answer itself and nothing else: no reasoning, notes, caveats or qualifiers such as '(estimated)', 'assumed' or 'not specified' inside a value - if a value would need one, the value is null. gender_hint_en is the exception: it is a classification you make rather than a fact to be found - see its description.
Fields:
-
page_type
string
required
What kind of page this is.
-
name_en
string
required
Product name in English, without site-name suffixes.
-
name_ar
string
required
Product name in Arabic.
-
desc_en
string
Product description in English, 2-4 factual sentences.
-
desc_ar
string
Product description in Arabic, 2-4 factual sentences.
-
amount
number
Current selling price as a number, no currency symbol or separators.
-
currency
string
Currency code such as SAR, PKR, USD.
-
sku
string
SKU, product code or model number.
-
material_en
string
The material exactly as the page names it - in its text, title, description or keywords - as a short noun phrase of at most five words: 'Cotton', '100% Linen', 'Sterling silver'. Null when the page names no material; never estimate one.
-
material_ar
string
material_en in Arabic. Null when material_en is null.
-
care_instructions_en
string
Care or washing instructions exactly as the page gives them. Null when the page gives none - never supply generic care advice.
-
care_instructions_ar
string
care_instructions_en in Arabic. Null when care_instructions_en is null.
-
country_of_origin_en
string
Country of origin/manufacture as a plain country name in English - "Saudi Arabia", "China", "Turkey". The page often phrases this as marketing copy ("Made in KSA", "Saudi made"); give the country itself, not the phrase. Only a stated origin counts - "made in" or "X made" anywhere on the page, keywords included. A city or market the shop sells in ("riyadh outfit", "jeddah fashion") is not an origin. Null if the page gives no origin at all.
-
country_of_origin_ar
string
country_of_origin_en in Arabic. Null when country_of_origin_en is null.
-
availability
string
Stock status.
-
thumb_url
string
URL of the main/thumbnail product image.
-
images
string[]
All product image URLs shown on this page.
-
variants
object[]
The buyable size/colour combinations. Read from the page itself, never invented - leave it empty if the page states none.
-
gender_hint_en
string
Who the product is for - a classification you make, not a value to be found on the page. Weigh the evidence in this order: words in the product name or description (women's, men's, ladies, boys, girls), then the category it was listed under, then the keywords tag - if the keywords name exactly one of men or women ("women fashion", "men fashion"), use it. Use Kids only when the page says the product is for children or offers age-based sizes. There is no unisex option. Null when there is no evidence, or when the evidence points to men and women equally.
-
category_id
integer
Which CATEGORY from the list in the prompt this product belongs to - a classification you make, not a value to be found on the page. Decide from the product name, description and the category it was listed under, and answer with that id. Pick the deepest category that fits; a t-shirt goes under T-Shirts, a hoodie under Hoodies. Return null only when no listed category applies at all (e.g. a product type the list simply does not cover). Never answer with an id that is not in the list.