Dashboard

17.01.2026 10:27

Zapytanie AI #50

2026-01-06 12:52:05

failed

Błąd

Invalid schema for response_format 'product_data_batch': In context=('properties', 'products', 'items', 'properties', 'images', 'items'), 'required' is required to be supplied and to be an array including every key in properties. Missing 'source_page'.
Typ
images
Produktów
1
Tokeny wejściowe
0
Tokeny wyjściowe
0
Czas trwania
-

Produkty w tym zapytaniu

Request Payload

{
    "text": {
        "format": {
            "name": "product_data_batch",
            "type": "json_schema",
            "schema": {
                "type": "object",
                "required": [
                    "products"
                ],
                "properties": {
                    "products": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "required": [
                                "ean",
                                "images"
                            ],
                            "properties": {
                                "ean": {
                                    "type": "string"
                                },
                                "images": {
                                    "type": "array",
                                    "items": {
                                        "type": "object",
                                        "required": [
                                            "url",
                                            "type"
                                        ],
                                        "properties": {
                                            "url": {
                                                "type": "string"
                                            },
                                            "type": {
                                                "enum": [
                                                    "main",
                                                    "gallery",
                                                    "detail",
                                                    "lifestyle"
                                                ],
                                                "type": "string"
                                            },
                                            "source_page": {
                                                "type": "string"
                                            }
                                        },
                                        "additionalProperties": false
                                    }
                                }
                            },
                            "additionalProperties": false
                        }
                    }
                },
                "additionalProperties": false
            },
            "strict": true
        }
    },
    "input": [
        {
            "role": "system",
            "content": "You are a Universal Visual Asset Retrieval Agent for a multi-category sports e-commerce store.\r\nYour goal is to locate direct, high-resolution image URLs for any product type (Apparel, Footwear, Hardware, Consumables, Accessories).\r\n\r\nCRITICAL RULES:\r\n1. **Quantity Target:** Aim for **10 unique images** per product.\r\n   - **Adaptability:** If the product is simple (e.g., a bike tube or chain lube), finding 10 unique images might be impossible. In such cases, return ALL available valid images (even if only 3-4) without duplicating. Do not force low-quality results.\r\n2. **Resolution Requirement:** Target width is **1200px**.\r\n   - Acceptable range: 1000px to original source size.\r\n   - Reject < 1000px.\r\n3. **Universal Variety Protocol:** You must detect the product category and search for relevant angles:\r\n   - **Wearables (Helmets, Gloves, Shoes):** Front, Back, Side, Inside (lining), Fastening systems, Vents.\r\n   - **Hardware (Bike parts, Skis, Tents):** Mounting points, Technical diagrams, Folded\/Packed state, In-use state.\r\n   - **Consumables (Lubes, Nutrition):** Bottle front, Back label (Ingredients\/Instructions), Nozzle\/Applicator detail, Texture of the substance.\r\n4. **Direct Links Only:** Output direct file paths (.jpg, .png, .webp).\r\n\r\nOUTPUT FORMAT:\r\nReturn a JSON object containing a list of valid image URLs."
        },
        {
            "role": "developer",
            "content": "## Image Search Process\r\n\r\nFor each product in the batch:\r\n\r\n### 1. Search Strategy\r\nBuild targeted web_search queries:\r\n1. \"{brand} {model} {color} official product images\"\r\n2. \"{brand} {model} press kit\"\r\n3. site:{brand_website} {model} images\r\n4. \"EAN {ean}\" images (for exact variant match)\r\n\r\n### 2. Source Priority\r\nA. Official brand website - product page images\r\nB. Official press\/media kit images\r\nC. Authorized major retailers (must have clear product photos)\r\n\r\n### 3. Image Selection Criteria\r\n- Resolution: minimum 800x800px\r\n- Format: JPG, PNG, WebP preferred\r\n- Content: Clear product shot on white\/neutral background\r\n- Variants: Must match exact color and model year\r\n\r\n### 4. Required Image Types\r\nFor each product, find:\r\n1. main: Primary product image (front view, white background)\r\n2. gallery: 2-4 additional angles (side, back, detail shots)\r\n3. detail: Close-up of key features (sole, stitching, technology)\r\n\r\n### 5. Output Format\r\nReturn JSON with structure:\r\n{\r\n  \"products\": [\r\n    {\r\n      \"ean\": \"...\",\r\n      \"images\": [\r\n        {\r\n          \"url\": \"direct_image_url\",\r\n          \"source_page\": \"page_where_found\",\r\n          \"type\": \"main|gallery|detail\"\r\n        }\r\n      ]\r\n    }\r\n  ]\r\n}\r\n\r\n### FORBIDDEN\r\n- Amazon\/eBay\/Allegro marketplace images\r\n- User-uploaded photos\r\n- Images with visible watermarks\r\n- Thumbnail\/preview images (< 400px)\r\n- Wrong product variants"
        },
        {
            "role": "user",
            "content": "## Task\r\nFind official product images for the following products.\r\n\r\n## Products\r\n{\n    \"batch\": {\n        \"products\": [\n            {\n                \"ean\": \"0193128599789\",\n                \"name\": \"Salomon Speedcross 5\",\n                \"brand\": \"Salomon\",\n                \"brand_website\": \"https:\\\/\\\/www.salomon.com\",\n                \"color\": \"Black\\\/Black\\\/Phantom\",\n                \"search_sources\": []\n            }\n        ]\n    }\n}\r\n\r\n## Requirements\r\n1. For each product, find:\r\n   - 1 main image (primary product shot)\r\n   - 2-4 gallery images (different angles)\r\n   - 1-2 detail images (close-ups if available)\r\n\r\n2. Image quality:\r\n   - High resolution (800px+ width)\r\n   - Clear, professional photography\r\n   - White or neutral background for main images\r\n\r\n3. Must match exact variant:\r\n   - Correct color\r\n   - Correct model year (if specified)\r\n   - Same configuration (GTX vs non-GTX, etc.)\r\n\r\n4. Priority sources:\r\n   - Official brand websites\r\n   - Press\/media kits\r\n   - Major authorized retailers\r\n\r\n## Output\r\nReturn JSON with found images for each product."
        }
    ],
    "model": "gpt-5.2",
    "store": false,
    "tools": [
        {
            "type": "web_search"
        }
    ],
    "temperature": 0,
    "tool_choice": "auto"
}