From a12bb3064a3deee90311e0fb427afc2430da092b Mon Sep 17 00:00:00 2001 From: qvdz Date: Sat, 17 Jan 2026 08:20:10 +0000 Subject: [PATCH] Update game.json --- game.json | 119 ++++++++++++++++++++++++++++++++---------------------- 1 file changed, 71 insertions(+), 48 deletions(-) diff --git a/game.json b/game.json index 1193b76..e23d1e9 100644 --- a/game.json +++ b/game.json @@ -496,6 +496,22 @@ "nullable": false, "mô_tả": "Danh mục của các từ CÒN LẠI (không phải đáp án)" }, + "image_url": { + "type": "string", + "nullable": true, + "mô_tả": "URL hình ảnh gợi ý" + }, + "image_description": { + "type": "string", + "nullable": true, + "mô_tả": "Mô tả hình ảnh" + }, + "is_required_image": { + "type": "boolean", + "nullable": false, + "default": false, + "mô_tả": "true = bắt buộc xem ảnh" + }, "is_example": { "type": "boolean", "nullable": false, @@ -687,22 +703,10 @@ "nullable": false, "mô_tả": "Câu với ____ đánh dấu chỗ trống" }, - "instruction": { - "type": "string", - "nullable": false, - "default": "Drag the correct answer", - "mô_tả": "Hướng dẫn cho người chơi" - }, - "options": { - "type": "array", - "nullable": false, - "min": 2, - "mô_tả": "Danh sách từ để kéo thả" - }, "answer": { "type": "string", "nullable": false, - "mô_tả": "Đáp án đúng - phải nằm trong options" + "mô_tả": "Đáp án đúng - phải nằm trong word_bank" }, "image_url": { "type": "string", @@ -727,49 +731,55 @@ "mô_tả": "true = đây là câu mẫu" } }, + "metadata_schema": { + "word_bank": { + "type": "array", + "nullable": false, + "min": 2, + "mô_tả": "Danh sách các từ để kéo thả (dùng chung cho toàn bộ bài)" + }, + "title": { + "type": "string" + }, + "description": { + "type": "string" + }, + "grade": { + "type": "number" + }, + "difficulty": { + "type": "number" + } + }, "variants": [ { - "name": "Kéo thả - Text Only", - "mô_tả": "Kéo từ vào câu, không có hình ảnh", + "name": "Kéo thả - Word Bank", + "mô_tả": "Điền từ vào chỗ trống từ ngân hàng từ vựng chung", "required_fields": [ "question", - "instruction", - "options", "answer" ], "example": { - "question": "He can ____.", - "instruction": "Hoàn thành câu", - "options": [ - "run", - "swim", - "read" + "items": [ + { + "question": "He can ____.", + "answer": "run", + "image_url": "...", + "is_required_image": true + }, + { + "question": "She can ____.", + "answer": "swim" + } ], - "answer": "run" - } - }, - { - "name": "Kéo thả - Với Hình ảnh", - "mô_tả": "Nhìn hình và kéo từ đúng vào chỗ trống", - "required_fields": [ - "question", - "instruction", - "options", - "answer", - "image_url", - "is_required_image" - ], - "example": { - "question": "She can ____.", - "instruction": "Nhìn tranh và hoàn thành câu", - "options": [ - "run", - "swim", - "read" - ], - "answer": "read", - "image_url": "https://example.com/girl_reading.jpg", - "is_required_image": true + "metadata": { + "word_bank": [ + "run", + "swim", + "read" + ], + "title": "Action Verbs" + } } } ] @@ -879,7 +889,20 @@ } ], "notes": { + "image_url": "Thay thế image_path từ backend, sử dụng URL hình ảnh trực tiếp có thể load được", + "removed_ai_fields": [ + "image_keywords", + "image_is_complex", + "original_quote", + "image_roi_box" + ], + "removed_audio_fields": [ + "audio_path", + "audio_script", + "is_required_audio" + ], "is_required_image": "true = bắt buộc phải có và xem hình ảnh để chơi game, false = hình ảnh chỉ là minh họa hoặc không có", "blank_format": "Sử dụng ____ (4 gạch dưới) cho chỗ trống trong câu hỏi", + "nullable_meaning": "nullable: true = có thể null/không điền, nullable: false = bắt buộc phải có giá trị" } } \ No newline at end of file