Spaces:
Sleeping
Sleeping
Upload 5 files
Browse files- Preprocessing_&_Model_Analysis.ipynb.txt +1755 -0
- ViSum_Training.py +149 -0
- error_analysis.txt +134 -0
- requirement.txt +5 -0
- rouge_results.json +0 -0
Preprocessing_&_Model_Analysis.ipynb.txt
ADDED
|
@@ -0,0 +1,1755 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cells": [
|
| 3 |
+
{
|
| 4 |
+
"cell_type": "markdown",
|
| 5 |
+
"metadata": {
|
| 6 |
+
"id": "UrYUSkACCo62"
|
| 7 |
+
},
|
| 8 |
+
"source": [
|
| 9 |
+
"#CÀI ĐẶT THƯ VIỆN"
|
| 10 |
+
]
|
| 11 |
+
},
|
| 12 |
+
{
|
| 13 |
+
"cell_type": "code",
|
| 14 |
+
"execution_count": 1,
|
| 15 |
+
"metadata": {
|
| 16 |
+
"colab": {
|
| 17 |
+
"base_uri": "https://localhost:8080/"
|
| 18 |
+
},
|
| 19 |
+
"collapsed": true,
|
| 20 |
+
"id": "gZVgq40W9F-N",
|
| 21 |
+
"outputId": "8a61c824-b37f-4d50-d06b-11da018a1191"
|
| 22 |
+
},
|
| 23 |
+
"outputs": [
|
| 24 |
+
{
|
| 25 |
+
"output_type": "stream",
|
| 26 |
+
"name": "stdout",
|
| 27 |
+
"text": [
|
| 28 |
+
"Requirement already satisfied: rouge-score in /usr/local/lib/python3.12/dist-packages (0.1.2)\n",
|
| 29 |
+
"Requirement already satisfied: sacremoses in /usr/local/lib/python3.12/dist-packages (0.1.1)\n",
|
| 30 |
+
"Requirement already satisfied: transformers[sentencepiece] in /usr/local/lib/python3.12/dist-packages (5.7.0)\n",
|
| 31 |
+
"Requirement already satisfied: huggingface-hub<2.0,>=1.5.0 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (1.11.0)\n",
|
| 32 |
+
"Requirement already satisfied: numpy>=1.17 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (2.0.2)\n",
|
| 33 |
+
"Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (26.1)\n",
|
| 34 |
+
"Requirement already satisfied: pyyaml>=5.1 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (6.0.3)\n",
|
| 35 |
+
"Requirement already satisfied: regex>=2025.10.22 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (2025.11.3)\n",
|
| 36 |
+
"Requirement already satisfied: tokenizers<=0.23.0,>=0.22.0 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.22.2)\n",
|
| 37 |
+
"Requirement already satisfied: typer in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.24.2)\n",
|
| 38 |
+
"Requirement already satisfied: safetensors>=0.4.3 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.7.0)\n",
|
| 39 |
+
"Requirement already satisfied: tqdm>=4.27 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (4.67.3)\n",
|
| 40 |
+
"Requirement already satisfied: sentencepiece!=0.1.92,>=0.1.91 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.2.1)\n",
|
| 41 |
+
"Requirement already satisfied: protobuf in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (5.29.6)\n",
|
| 42 |
+
"Requirement already satisfied: absl-py in /usr/local/lib/python3.12/dist-packages (from rouge-score) (1.4.0)\n",
|
| 43 |
+
"Requirement already satisfied: nltk in /usr/local/lib/python3.12/dist-packages (from rouge-score) (3.9.1)\n",
|
| 44 |
+
"Requirement already satisfied: six>=1.14.0 in /usr/local/lib/python3.12/dist-packages (from rouge-score) (1.17.0)\n",
|
| 45 |
+
"Requirement already satisfied: click in /usr/local/lib/python3.12/dist-packages (from sacremoses) (8.3.3)\n",
|
| 46 |
+
"Requirement already satisfied: joblib in /usr/local/lib/python3.12/dist-packages (from sacremoses) (1.5.3)\n",
|
| 47 |
+
"Requirement already satisfied: filelock>=3.10.0 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (3.29.0)\n",
|
| 48 |
+
"Requirement already satisfied: fsspec>=2023.5.0 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (2025.3.0)\n",
|
| 49 |
+
"Requirement already satisfied: hf-xet<2.0.0,>=1.4.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (1.4.3)\n",
|
| 50 |
+
"Requirement already satisfied: httpx<1,>=0.23.0 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (0.28.1)\n",
|
| 51 |
+
"Requirement already satisfied: typing-extensions>=4.1.0 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (4.15.0)\n",
|
| 52 |
+
"Requirement already satisfied: shellingham>=1.3.0 in /usr/local/lib/python3.12/dist-packages (from typer->transformers[sentencepiece]) (1.5.4)\n",
|
| 53 |
+
"Requirement already satisfied: rich>=12.3.0 in /usr/local/lib/python3.12/dist-packages (from typer->transformers[sentencepiece]) (13.9.4)\n",
|
| 54 |
+
"Requirement already satisfied: annotated-doc>=0.0.2 in /usr/local/lib/python3.12/dist-packages (from typer->transformers[sentencepiece]) (0.0.4)\n",
|
| 55 |
+
"Requirement already satisfied: anyio in /usr/local/lib/python3.12/dist-packages (from httpx<1,>=0.23.0->huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (4.13.0)\n",
|
| 56 |
+
"Requirement already satisfied: certifi in /usr/local/lib/python3.12/dist-packages (from httpx<1,>=0.23.0->huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (2026.4.22)\n",
|
| 57 |
+
"Requirement already satisfied: httpcore==1.* in /usr/local/lib/python3.12/dist-packages (from httpx<1,>=0.23.0->huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (1.0.9)\n",
|
| 58 |
+
"Requirement already satisfied: idna in /usr/local/lib/python3.12/dist-packages (from httpx<1,>=0.23.0->huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (3.13)\n",
|
| 59 |
+
"Requirement already satisfied: h11>=0.16 in /usr/local/lib/python3.12/dist-packages (from httpcore==1.*->httpx<1,>=0.23.0->huggingface-hub<2.0,>=1.5.0->transformers[sentencepiece]) (0.16.0)\n",
|
| 60 |
+
"Requirement already satisfied: markdown-it-py>=2.2.0 in /usr/local/lib/python3.12/dist-packages (from rich>=12.3.0->typer->transformers[sentencepiece]) (4.0.0)\n",
|
| 61 |
+
"Requirement already satisfied: pygments<3.0.0,>=2.13.0 in /usr/local/lib/python3.12/dist-packages (from rich>=12.3.0->typer->transformers[sentencepiece]) (2.20.0)\n",
|
| 62 |
+
"Requirement already satisfied: mdurl~=0.1 in /usr/local/lib/python3.12/dist-packages (from markdown-it-py>=2.2.0->rich>=12.3.0->typer->transformers[sentencepiece]) (0.1.2)\n"
|
| 63 |
+
]
|
| 64 |
+
}
|
| 65 |
+
],
|
| 66 |
+
"source": [
|
| 67 |
+
"!pip install transformers[sentencepiece] rouge-score sacremoses"
|
| 68 |
+
]
|
| 69 |
+
},
|
| 70 |
+
{
|
| 71 |
+
"cell_type": "code",
|
| 72 |
+
"execution_count": 2,
|
| 73 |
+
"metadata": {
|
| 74 |
+
"id": "fN9HeTk_9aR3"
|
| 75 |
+
},
|
| 76 |
+
"outputs": [],
|
| 77 |
+
"source": [
|
| 78 |
+
"import json\n",
|
| 79 |
+
"import torch\n",
|
| 80 |
+
"import os\n",
|
| 81 |
+
"import re\n",
|
| 82 |
+
"import unicodedata\n",
|
| 83 |
+
"from transformers import AutoTokenizer, AutoModelForSeq2SeqLM\n",
|
| 84 |
+
"from rouge_score import rouge_scorer\n",
|
| 85 |
+
"from tqdm import tqdm\n",
|
| 86 |
+
"from datasets import load_dataset"
|
| 87 |
+
]
|
| 88 |
+
},
|
| 89 |
+
{
|
| 90 |
+
"cell_type": "code",
|
| 91 |
+
"execution_count": 3,
|
| 92 |
+
"metadata": {
|
| 93 |
+
"colab": {
|
| 94 |
+
"base_uri": "https://localhost:8080/"
|
| 95 |
+
},
|
| 96 |
+
"id": "GD72LMn0FC74",
|
| 97 |
+
"outputId": "a586718a-c523-4859-8687-9afb1bf9314f"
|
| 98 |
+
},
|
| 99 |
+
"outputs": [
|
| 100 |
+
{
|
| 101 |
+
"output_type": "stream",
|
| 102 |
+
"name": "stdout",
|
| 103 |
+
"text": [
|
| 104 |
+
"using device: cuda\n"
|
| 105 |
+
]
|
| 106 |
+
}
|
| 107 |
+
],
|
| 108 |
+
"source": [
|
| 109 |
+
"device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')\n",
|
| 110 |
+
"print('using device:', device)"
|
| 111 |
+
]
|
| 112 |
+
},
|
| 113 |
+
{
|
| 114 |
+
"cell_type": "markdown",
|
| 115 |
+
"metadata": {
|
| 116 |
+
"id": "vFoKipPwCltg"
|
| 117 |
+
},
|
| 118 |
+
"source": [
|
| 119 |
+
"#CÁC HÀM TIỆN ÍCH (UTILS)"
|
| 120 |
+
]
|
| 121 |
+
},
|
| 122 |
+
{
|
| 123 |
+
"cell_type": "code",
|
| 124 |
+
"execution_count": 4,
|
| 125 |
+
"metadata": {
|
| 126 |
+
"id": "A-2w4fF9_6_P"
|
| 127 |
+
},
|
| 128 |
+
"outputs": [],
|
| 129 |
+
"source": [
|
| 130 |
+
"def clean_text(text: str) -> str:\n",
|
| 131 |
+
" \"\"\"\n",
|
| 132 |
+
" Làm sạch văn bản tiếng Việt:\n",
|
| 133 |
+
" - Bỏ HTML tags\n",
|
| 134 |
+
" - Chuẩn hóa Unicode (NFC)\n",
|
| 135 |
+
" - Thay '_' -> ' '\n",
|
| 136 |
+
" - Xóa newline\n",
|
| 137 |
+
" - Chuẩn hóa khoảng trắng\n",
|
| 138 |
+
" - Chuẩn hóa dấu câu (có khoảng trắng sau dấu)\n",
|
| 139 |
+
" \"\"\"\n",
|
| 140 |
+
"\n",
|
| 141 |
+
" if not isinstance(text, str):\n",
|
| 142 |
+
" return \"\"\n",
|
| 143 |
+
"\n",
|
| 144 |
+
" # Bỏ HTML tags\n",
|
| 145 |
+
" text = re.sub(r'<[^>]+>', '', text)\n",
|
| 146 |
+
"\n",
|
| 147 |
+
" # Chuẩn hóa Unicode (NFC)\n",
|
| 148 |
+
" text = unicodedata.normalize('NFC', text)\n",
|
| 149 |
+
"\n",
|
| 150 |
+
" # thay underscore thành space\n",
|
| 151 |
+
" text = text.replace('_', ' ')\n",
|
| 152 |
+
"\n",
|
| 153 |
+
" # Xóa newline\n",
|
| 154 |
+
" text = text.replace('\\n', ' ')\n",
|
| 155 |
+
"\n",
|
| 156 |
+
" #chuẩn hóa dấu câu\n",
|
| 157 |
+
" text = re.sub(r'([.,!?;:])', r' \\1 ', text)\n",
|
| 158 |
+
"\n",
|
| 159 |
+
" #chuẩn hóa khoảng trắng\n",
|
| 160 |
+
" text = re.sub(r'\\s+', ' ', text)\n",
|
| 161 |
+
"\n",
|
| 162 |
+
" return text.strip()\n",
|
| 163 |
+
"\n",
|
| 164 |
+
"def truncate_text(text: str, max_words: int = 512) -> str:\n",
|
| 165 |
+
" \"\"\"\n",
|
| 166 |
+
" Cắt văn bản thành một đoạn có tối đa `max_words` từ.\n",
|
| 167 |
+
" \"\"\"\n",
|
| 168 |
+
" if not isinstance(text, str):\n",
|
| 169 |
+
" return \"\"\n",
|
| 170 |
+
"\n",
|
| 171 |
+
" words = text.split()\n",
|
| 172 |
+
" if len(words) <= max_words:\n",
|
| 173 |
+
" return text\n",
|
| 174 |
+
" else:\n",
|
| 175 |
+
" return ' '.join(words[:max_words]) + \"...\"\n",
|
| 176 |
+
"\n",
|
| 177 |
+
"\n",
|
| 178 |
+
"def compute_length(text: str) -> int:\n",
|
| 179 |
+
" \"\"\"\n",
|
| 180 |
+
" Tính số lượng từ trong văn bản.\n",
|
| 181 |
+
" \"\"\"\n",
|
| 182 |
+
" if not isinstance(text, str):\n",
|
| 183 |
+
" return 0\n",
|
| 184 |
+
"\n",
|
| 185 |
+
" words = text.split()\n",
|
| 186 |
+
" return len(words)\n",
|
| 187 |
+
"\n",
|
| 188 |
+
"\n",
|
| 189 |
+
"def compute_compression_ratio(article: str, summary: str) -> float:\n",
|
| 190 |
+
" \"\"\"\n",
|
| 191 |
+
" Tính tỷ lệ nén giữa văn bản gốc và văn bản đã được làm sạch.\n",
|
| 192 |
+
" \"\"\"\n",
|
| 193 |
+
" article_len = compute_length(article)\n",
|
| 194 |
+
" summary_len = compute_length(summary)\n",
|
| 195 |
+
"\n",
|
| 196 |
+
" if article_len == 0:\n",
|
| 197 |
+
" return 0.0\n",
|
| 198 |
+
"\n",
|
| 199 |
+
" return summary_len / article_len\n",
|
| 200 |
+
"\n",
|
| 201 |
+
"\n",
|
| 202 |
+
"def is_abnormal_sample(article: str, summary: str) -> bool:\n",
|
| 203 |
+
" \"\"\"\n",
|
| 204 |
+
" Detect sample bất thường:\n",
|
| 205 |
+
" - article quá ngắn\n",
|
| 206 |
+
" - ratio quá cao\n",
|
| 207 |
+
" \"\"\"\n",
|
| 208 |
+
" article_len = compute_length(article)\n",
|
| 209 |
+
" ratio = compute_compression_ratio(article, summary)\n",
|
| 210 |
+
"\n",
|
| 211 |
+
" if article_len < 50 or ratio > 0.8:\n",
|
| 212 |
+
" return True\n",
|
| 213 |
+
" return False\n"
|
| 214 |
+
]
|
| 215 |
+
},
|
| 216 |
+
{
|
| 217 |
+
"cell_type": "markdown",
|
| 218 |
+
"metadata": {
|
| 219 |
+
"id": "7UUsD5GjCrIl"
|
| 220 |
+
},
|
| 221 |
+
"source": [
|
| 222 |
+
"# TẠO DỮ LIỆU KIỂM THỬ (TEST SET)"
|
| 223 |
+
]
|
| 224 |
+
},
|
| 225 |
+
{
|
| 226 |
+
"cell_type": "code",
|
| 227 |
+
"execution_count": 5,
|
| 228 |
+
"metadata": {
|
| 229 |
+
"id": "WyvzumGMCNb4"
|
| 230 |
+
},
|
| 231 |
+
"outputs": [],
|
| 232 |
+
"source": [
|
| 233 |
+
"def is_valid_sample(article: str, summary: str) -> bool:\n",
|
| 234 |
+
" \"\"\"\n",
|
| 235 |
+
" Filter sample:\n",
|
| 236 |
+
" - article đủ dài\n",
|
| 237 |
+
" - ratio không quá cao (loại sample lỗi)\n",
|
| 238 |
+
" \"\"\"\n",
|
| 239 |
+
" if not article or not summary:\n",
|
| 240 |
+
" return False\n",
|
| 241 |
+
"\n",
|
| 242 |
+
" article_len = len(article.split())\n",
|
| 243 |
+
" ratio = compute_compression_ratio(article, summary)\n",
|
| 244 |
+
"\n",
|
| 245 |
+
" # rule\n",
|
| 246 |
+
" if article_len < 20:\n",
|
| 247 |
+
" return False\n",
|
| 248 |
+
"\n",
|
| 249 |
+
" if ratio > 0.3:\n",
|
| 250 |
+
" return False\n",
|
| 251 |
+
"\n",
|
| 252 |
+
" return True\n",
|
| 253 |
+
"\n",
|
| 254 |
+
"def run_create_test_set(num_samples=300, seed=42):\n",
|
| 255 |
+
" print(\"--- Loading dataset Vietnews... ---\")\n",
|
| 256 |
+
" dataset = load_dataset(\"harouzie/vietnews\", split='test')\n",
|
| 257 |
+
" raw_test = dataset.shuffle(seed=seed)\n",
|
| 258 |
+
"\n",
|
| 259 |
+
" test_data = []\n",
|
| 260 |
+
" print(\"--- Creating test set... ---\")\n",
|
| 261 |
+
" for sample in raw_test:\n",
|
| 262 |
+
" article = clean_text(sample[\"article\"])\n",
|
| 263 |
+
" summary = clean_text(sample[\"abstract\"])\n",
|
| 264 |
+
"\n",
|
| 265 |
+
" if not is_valid_sample(article, summary):\n",
|
| 266 |
+
" continue\n",
|
| 267 |
+
"\n",
|
| 268 |
+
" test_data.append({\"article\": article, \"abstract\": summary})\n",
|
| 269 |
+
" if len(test_data) >= num_samples:\n",
|
| 270 |
+
" break\n",
|
| 271 |
+
"\n",
|
| 272 |
+
" print(f\"Collected {len(test_data)} samples\")\n",
|
| 273 |
+
" return test_data\n"
|
| 274 |
+
]
|
| 275 |
+
},
|
| 276 |
+
{
|
| 277 |
+
"cell_type": "markdown",
|
| 278 |
+
"metadata": {
|
| 279 |
+
"id": "1urfHff7CzvP"
|
| 280 |
+
},
|
| 281 |
+
"source": [
|
| 282 |
+
"#HÀM ĐÁNH GIÁ MODEL (EVALUATE)"
|
| 283 |
+
]
|
| 284 |
+
},
|
| 285 |
+
{
|
| 286 |
+
"cell_type": "code",
|
| 287 |
+
"execution_count": 6,
|
| 288 |
+
"metadata": {
|
| 289 |
+
"id": "esX-8ESRC0oM"
|
| 290 |
+
},
|
| 291 |
+
"outputs": [],
|
| 292 |
+
"source": [
|
| 293 |
+
"def resolve_model_path_colab(model_path: str) -> str:\n",
|
| 294 |
+
" # Nếu là Repo ID trên Hugging Face (có dấu /) thì trả về\n",
|
| 295 |
+
" if \"/\" in model_path and not os.path.exists(model_path):\n",
|
| 296 |
+
" return model_path\n",
|
| 297 |
+
"\n",
|
| 298 |
+
" if not os.path.exists(model_path):\n",
|
| 299 |
+
" raise ValueError(f\"Path không tồn tại: {model_path}\")\n",
|
| 300 |
+
"\n",
|
| 301 |
+
" files = os.listdir(model_path)\n",
|
| 302 |
+
" if \"config.json\" in files:\n",
|
| 303 |
+
" return model_path\n",
|
| 304 |
+
" checkpoints = [f for f in files if f.startswith(\"checkpoint\")]\n",
|
| 305 |
+
" if checkpoints:\n",
|
| 306 |
+
" checkpoints.sort(key=lambda x: int(x.split('-')[-1]) if '-' in x else x)\n",
|
| 307 |
+
" return os.path.join(model_path, checkpoints[-1])\n",
|
| 308 |
+
" return model_path\n",
|
| 309 |
+
"\n",
|
| 310 |
+
"def evaluate_model_colab(model_path: str, test_data: list, output_path: str = \"rouge_results.json\"):\n",
|
| 311 |
+
" # Giải quyết đường dẫn\n",
|
| 312 |
+
" model_path = resolve_model_path_colab(model_path)\n",
|
| 313 |
+
" print(f\"Loading model from: {model_path}\")\n",
|
| 314 |
+
"\n",
|
| 315 |
+
" # Load model & tokenizer\n",
|
| 316 |
+
" # Colab có thể tải từ Hugging Face\n",
|
| 317 |
+
" tokenizer = AutoTokenizer.from_pretrained(model_path)\n",
|
| 318 |
+
" model = AutoModelForSeq2SeqLM.from_pretrained(model_path)\n",
|
| 319 |
+
"\n",
|
| 320 |
+
" device = torch.device(\"cuda\" if torch.cuda.is_available() else \"cpu\")\n",
|
| 321 |
+
" model.to(device)\n",
|
| 322 |
+
" model.eval()\n",
|
| 323 |
+
" print(f\"Device: {device}\")\n",
|
| 324 |
+
"\n",
|
| 325 |
+
" # ROUGE setup\n",
|
| 326 |
+
" scorer = rouge_scorer.RougeScorer(['rouge1', 'rouge2', 'rougeL'], use_stemmer=True)\n",
|
| 327 |
+
" results = {'rouge1': [], 'rouge2': [], 'rougeL': [], 'details': []}\n",
|
| 328 |
+
"\n",
|
| 329 |
+
" print(\"Evaluating...\")\n",
|
| 330 |
+
" for item in tqdm(test_data):\n",
|
| 331 |
+
" article = clean_text(item['article'])\n",
|
| 332 |
+
" reference = clean_text(item['abstract'])\n",
|
| 333 |
+
"\n",
|
| 334 |
+
" inputs = tokenizer(article, max_length=512, truncation=True, return_tensors=\"pt\").to(device)\n",
|
| 335 |
+
"\n",
|
| 336 |
+
" with torch.no_grad():\n",
|
| 337 |
+
" summary_ids = model.generate(\n",
|
| 338 |
+
" inputs[\"input_ids\"],\n",
|
| 339 |
+
" max_length=150,\n",
|
| 340 |
+
" min_length=30,\n",
|
| 341 |
+
" num_beams=4,\n",
|
| 342 |
+
" no_repeat_ngram_size=3,\n",
|
| 343 |
+
" early_stopping=True,\n",
|
| 344 |
+
" )\n",
|
| 345 |
+
"\n",
|
| 346 |
+
" generated = tokenizer.decode(summary_ids[0], skip_special_tokens=True)\n",
|
| 347 |
+
" generated = clean_text(generated)\n",
|
| 348 |
+
"\n",
|
| 349 |
+
" # Tính ROUGE\n",
|
| 350 |
+
" scores = scorer.score(reference, generated)\n",
|
| 351 |
+
" r1, r2, rl = scores['rouge1'].fmeasure, scores['rouge2'].fmeasure, scores['rougeL'].fmeasure\n",
|
| 352 |
+
"\n",
|
| 353 |
+
" results['rouge1'].append(r1)\n",
|
| 354 |
+
" results['rouge2'].append(r2)\n",
|
| 355 |
+
" results['rougeL'].append(rl)\n",
|
| 356 |
+
" results['details'].append({\n",
|
| 357 |
+
" \"reference\": reference,\n",
|
| 358 |
+
" \"generated\": generated,\n",
|
| 359 |
+
" \"rouge1\": round(r1, 4), \"rouge2\": round(r2, 4), \"rougeL\": round(rl, 4)\n",
|
| 360 |
+
" })\n",
|
| 361 |
+
"\n",
|
| 362 |
+
" # Tính trung bình\n",
|
| 363 |
+
" avg_r1 = sum(results['rouge1']) / len(results['rouge1'])\n",
|
| 364 |
+
" avg_r2 = sum(results['rouge2']) / len(results['rouge2'])\n",
|
| 365 |
+
" avg_rl = sum(results['rougeL']) / len(results['rougeL'])\n",
|
| 366 |
+
"\n",
|
| 367 |
+
" print(\"\\n\" + \"=\"*30)\n",
|
| 368 |
+
" print(\"ROUGE RESULTS\")\n",
|
| 369 |
+
" print(f\"ROUGE-1: {avg_r1:.4f}\")\n",
|
| 370 |
+
" print(f\"ROUGE-2: {avg_r2:.4f}\")\n",
|
| 371 |
+
" print(f\"ROUGE-L: {avg_rl:.4f}\")\n",
|
| 372 |
+
" print(\"=\"*30)\n",
|
| 373 |
+
"\n",
|
| 374 |
+
" # Lưu kết quả\n",
|
| 375 |
+
" with open(output_path, 'w', encoding='utf-8') as f:\n",
|
| 376 |
+
" json.dump({\n",
|
| 377 |
+
" \"model\": model_path,\n",
|
| 378 |
+
" \"average\": {\"rouge1\": round(avg_r1, 4), \"rouge2\": round(avg_r2, 4), \"rougeL\": round(avg_rl, 4)},\n",
|
| 379 |
+
" \"details\": results['details']\n",
|
| 380 |
+
" }, f, ensure_ascii=False, indent=2)\n",
|
| 381 |
+
" print(f\"Saved results to {output_path}\")"
|
| 382 |
+
]
|
| 383 |
+
},
|
| 384 |
+
{
|
| 385 |
+
"cell_type": "markdown",
|
| 386 |
+
"metadata": {
|
| 387 |
+
"id": "m5hlgELELX8M"
|
| 388 |
+
},
|
| 389 |
+
"source": [
|
| 390 |
+
"#tóm tắt lỗi"
|
| 391 |
+
]
|
| 392 |
+
},
|
| 393 |
+
{
|
| 394 |
+
"cell_type": "code",
|
| 395 |
+
"execution_count": 7,
|
| 396 |
+
"metadata": {
|
| 397 |
+
"id": "OnjDfjCZLZqe"
|
| 398 |
+
},
|
| 399 |
+
"outputs": [],
|
| 400 |
+
"source": [
|
| 401 |
+
"import json\n",
|
| 402 |
+
"import os\n",
|
| 403 |
+
"\n",
|
| 404 |
+
"def create_error_summary(input_path=\"rouge_results.json\", output_path=\"error_analysis.txt\", top_n=10):\n",
|
| 405 |
+
" \"\"\"\n",
|
| 406 |
+
" Phân tích kết quả ROUGE để tìm ra các mẫu model làm tệ nhất và tốt nhất.\n",
|
| 407 |
+
" \"\"\"\n",
|
| 408 |
+
" if not os.path.exists(input_path):\n",
|
| 409 |
+
" print(f\"Không tìm thấy file {input_path}. Hãy chạy evaluate.py trước!\")\n",
|
| 410 |
+
" return\n",
|
| 411 |
+
"\n",
|
| 412 |
+
" with open(input_path, \"r\", encoding=\"utf-8\") as f:\n",
|
| 413 |
+
" data = json.load(f)\n",
|
| 414 |
+
"\n",
|
| 415 |
+
" details = data.get(\"details\", [])\n",
|
| 416 |
+
" if not details:\n",
|
| 417 |
+
" print(\"File kết quả không có dữ liệu chi tiết (details).\")\n",
|
| 418 |
+
" return\n",
|
| 419 |
+
"\n",
|
| 420 |
+
" # 1. Sắp xếp danh sách theo điểm ROUGE-L tăng dần (tệ nhất lên đầu)\n",
|
| 421 |
+
" worst_samples = sorted(details, key=lambda x: x[\"rougeL\"])\n",
|
| 422 |
+
"\n",
|
| 423 |
+
" # 2. Lấy danh sách tốt nhất (để đối chiếu)\n",
|
| 424 |
+
" best_samples = sorted(details, key=lambda x: x[\"rougeL\"], reverse=True)\n",
|
| 425 |
+
"\n",
|
| 426 |
+
" with open(output_path, \"w\", encoding=\"utf-8\") as f:\n",
|
| 427 |
+
" f.write(\"==================================================\\n\")\n",
|
| 428 |
+
" f.write(\" BÁO CÁO PHÂN TÍCH LỖI TÓM TẮT \\n\")\n",
|
| 429 |
+
" f.write(\"==================================================\\n\\n\")\n",
|
| 430 |
+
"\n",
|
| 431 |
+
" f.write(f\"Model: {data.get('model', 'Unknown')}\\n\")\n",
|
| 432 |
+
" f.write(f\"Điểm ROUGE trung bình:\\n\")\n",
|
| 433 |
+
" avg = data.get(\"average\", {})\n",
|
| 434 |
+
" f.write(f\" - ROUGE-1: {avg.get('rouge1'):.4f}\\n\")\n",
|
| 435 |
+
" f.write(f\" - ROUGE-2: {avg.get('rouge2'):.4f}\\n\")\n",
|
| 436 |
+
" f.write(f\" - ROUGE-L: {avg.get('rougeL'):.4f}\\n\\n\")\n",
|
| 437 |
+
"\n",
|
| 438 |
+
" # PHẦN 1: TOP CÁC CÂU TỆ NHẤT\n",
|
| 439 |
+
" f.write(f\"--- TOP {top_n} MẪU CÓ ĐIỂM THẤP NHẤT (CẦN PHÂN TÍCH LỖI) ---\\n\")\n",
|
| 440 |
+
" for i, sample in enumerate(worst_samples[:top_n]):\n",
|
| 441 |
+
" f.write(f\"\\n[Mẫu lỗi số {i+1}]\\n\")\n",
|
| 442 |
+
" f.write(f\" > ROUGE-L: {sample['rougeL']:.4f} | ROUGE-1: {sample['rouge1']:.4f}\\n\")\n",
|
| 443 |
+
" f.write(f\" > Tham chiếu (Gold): {sample['reference']}\\n\")\n",
|
| 444 |
+
" f.write(f\" > Model viết: {sample['generated']}\\n\")\n",
|
| 445 |
+
" f.write(\"-\" * 30 + \"\\n\")\n",
|
| 446 |
+
"\n",
|
| 447 |
+
" f.write(\"\\n\" + \"=\"*50 + \"\\n\\n\")\n",
|
| 448 |
+
"\n",
|
| 449 |
+
" # PHẦN 2: TOP CÁC CÂU TỐT NHẤT\n",
|
| 450 |
+
" f.write(f\"--- TOP {top_n} MẪU CÓ ĐIỂM CAO NHẤT (MODEL LÀM TỐT) ---\\n\")\n",
|
| 451 |
+
" for i, sample in enumerate(best_samples[:top_n]):\n",
|
| 452 |
+
" f.write(f\"\\n[Mẫu tốt số {i+1}]\\n\")\n",
|
| 453 |
+
" f.write(f\" > ROUGE-L: {sample['rougeL']:.4f} | ROUGE-1: {sample['rouge1']:.4f}\\n\")\n",
|
| 454 |
+
" f.write(f\" > Tham chiếu (Gold): {sample['reference']}\\n\")\n",
|
| 455 |
+
" f.write(f\" > Model viết: {sample['generated']}\\n\")\n",
|
| 456 |
+
" f.write(\"-\" * 30 + \"\\n\")\n",
|
| 457 |
+
"\n",
|
| 458 |
+
" print(f\"Đã tạo báo cáo phân tích lỗi tại: {output_path}\")\n"
|
| 459 |
+
]
|
| 460 |
+
},
|
| 461 |
+
{
|
| 462 |
+
"cell_type": "code",
|
| 463 |
+
"execution_count": 8,
|
| 464 |
+
"metadata": {
|
| 465 |
+
"colab": {
|
| 466 |
+
"base_uri": "https://localhost:8080/",
|
| 467 |
+
"height": 584,
|
| 468 |
+
"referenced_widgets": [
|
| 469 |
+
"73fd47b411a24145a609bab0cf37eaa9",
|
| 470 |
+
"2c46fcfc647546f2aa0a499518c7f894",
|
| 471 |
+
"51f3b92a16c14098899b88605e5ae506",
|
| 472 |
+
"d065f191724f4f07b24698eaa70328f6",
|
| 473 |
+
"68e125c3d4b74a6db0dc706041cea907",
|
| 474 |
+
"0705273e51cf4be982faab30bbec3820",
|
| 475 |
+
"fe96abf3ed3240f39d7a7ad69ebeb38e",
|
| 476 |
+
"ff2134fadfeb473d97309dfe7d9f2fff",
|
| 477 |
+
"25227fefc594436ca8d042dedfaeb4ba",
|
| 478 |
+
"cf9fee299b7c402dab73371707cbc96b",
|
| 479 |
+
"25e25a2b5db14e65b518c1d9a7934311",
|
| 480 |
+
"4932c1b71001436d989bff89034d1489",
|
| 481 |
+
"700e4bfdd19a4da49746b64349825465",
|
| 482 |
+
"ddeb494331f244f5b7ba3b216ccee9d5",
|
| 483 |
+
"de7b4e36949140a383cde04f803f66d1",
|
| 484 |
+
"704c1c9ebc68429e86718a12f6f31e47",
|
| 485 |
+
"1288103230e143b78db2b655bbaa32a3",
|
| 486 |
+
"e4d8f471e4f14750987fd1f01326980c",
|
| 487 |
+
"18a62b050d9541428faead83567beb30",
|
| 488 |
+
"10861235615d4d76b7baaa40cffbbdef",
|
| 489 |
+
"cda61cbf54884c3aa98127049dad33bf",
|
| 490 |
+
"1c8d0998a1cc4d70af29c394c2949506",
|
| 491 |
+
"15f431ee684f448f897b20b1f4f4a3b1",
|
| 492 |
+
"a50de1c0ccc443f5a2a9fe9a791b02f6",
|
| 493 |
+
"afb39d22095b428da144710b43785445",
|
| 494 |
+
"3ee0b4fe1e5f4226bf25f0d8f301198f",
|
| 495 |
+
"b1dd37ad15bb4de6982db3c967021ae6",
|
| 496 |
+
"1fad9d81479d4dc4ae7a0573bd965b93",
|
| 497 |
+
"bab7bc50bb5e45caad41bcb7f4da2b98",
|
| 498 |
+
"d967b31fab6b402db5fa1ee4cd382044",
|
| 499 |
+
"aaccf77482b24a1ba9883d9601ebda81",
|
| 500 |
+
"b9e7c10eb925420fae0440946a62dcb3",
|
| 501 |
+
"16b56cb978bf4951abd8c093c65f9c60"
|
| 502 |
+
]
|
| 503 |
+
},
|
| 504 |
+
"id": "b6v8VIZVEBsm",
|
| 505 |
+
"outputId": "9c3944ed-5bd8-4e80-fd26-509e56e3e29b"
|
| 506 |
+
},
|
| 507 |
+
"outputs": [
|
| 508 |
+
{
|
| 509 |
+
"output_type": "stream",
|
| 510 |
+
"name": "stdout",
|
| 511 |
+
"text": [
|
| 512 |
+
"--- Loading dataset Vietnews... ---\n"
|
| 513 |
+
]
|
| 514 |
+
},
|
| 515 |
+
{
|
| 516 |
+
"output_type": "stream",
|
| 517 |
+
"name": "stderr",
|
| 518 |
+
"text": [
|
| 519 |
+
"/usr/local/lib/python3.12/dist-packages/huggingface_hub/utils/_auth.py:93: UserWarning: \n",
|
| 520 |
+
"The secret `HF_TOKEN` does not exist in your Colab secrets.\n",
|
| 521 |
+
"To authenticate with the Hugging Face Hub, create a token in your settings tab (https://huggingface.co/settings/tokens), set it as secret in your Google Colab and restart your session.\n",
|
| 522 |
+
"You will be able to reuse this secret in all of your notebooks.\n",
|
| 523 |
+
"Please note that authentication is recommended but still optional to access public models or datasets.\n",
|
| 524 |
+
" warnings.warn(\n",
|
| 525 |
+
"Warning: You are sending unauthenticated requests to the HF Hub. Please set a HF_TOKEN to enable higher rate limits and faster downloads.\n",
|
| 526 |
+
"WARNING:huggingface_hub.utils._http:Warning: You are sending unauthenticated requests to the HF Hub. Please set a HF_TOKEN to enable higher rate limits and faster downloads.\n"
|
| 527 |
+
]
|
| 528 |
+
},
|
| 529 |
+
{
|
| 530 |
+
"output_type": "stream",
|
| 531 |
+
"name": "stdout",
|
| 532 |
+
"text": [
|
| 533 |
+
"--- Creating test set... ---\n",
|
| 534 |
+
"Collected 300 samples\n",
|
| 535 |
+
"Loading model from: OrdinaryAI/visum-qlora-5epochs\n"
|
| 536 |
+
]
|
| 537 |
+
},
|
| 538 |
+
{
|
| 539 |
+
"output_type": "stream",
|
| 540 |
+
"name": "stderr",
|
| 541 |
+
"text": [
|
| 542 |
+
"WARNING:torchao:Skipping import of cpp extensions due to incompatible torch version. Please upgrade to torch >= 2.11.0 (found 2.10.0+cu128).\n"
|
| 543 |
+
]
|
| 544 |
+
},
|
| 545 |
+
{
|
| 546 |
+
"output_type": "display_data",
|
| 547 |
+
"data": {
|
| 548 |
+
"text/plain": [
|
| 549 |
+
"Loading weights: 0%| | 0/517 [00:00<?, ?it/s]"
|
| 550 |
+
],
|
| 551 |
+
"application/vnd.jupyter.widget-view+json": {
|
| 552 |
+
"version_major": 2,
|
| 553 |
+
"version_minor": 0,
|
| 554 |
+
"model_id": "73fd47b411a24145a609bab0cf37eaa9"
|
| 555 |
+
}
|
| 556 |
+
},
|
| 557 |
+
"metadata": {}
|
| 558 |
+
},
|
| 559 |
+
{
|
| 560 |
+
"output_type": "display_data",
|
| 561 |
+
"data": {
|
| 562 |
+
"text/plain": [
|
| 563 |
+
"adapter_model.safetensors: 0%| | 0.00/34.7M [00:00<?, ?B/s]"
|
| 564 |
+
],
|
| 565 |
+
"application/vnd.jupyter.widget-view+json": {
|
| 566 |
+
"version_major": 2,
|
| 567 |
+
"version_minor": 0,
|
| 568 |
+
"model_id": "4932c1b71001436d989bff89034d1489"
|
| 569 |
+
}
|
| 570 |
+
},
|
| 571 |
+
"metadata": {}
|
| 572 |
+
},
|
| 573 |
+
{
|
| 574 |
+
"output_type": "display_data",
|
| 575 |
+
"data": {
|
| 576 |
+
"text/plain": [
|
| 577 |
+
"Loading weights: 0%| | 0/384 [00:00<?, ?it/s]"
|
| 578 |
+
],
|
| 579 |
+
"application/vnd.jupyter.widget-view+json": {
|
| 580 |
+
"version_major": 2,
|
| 581 |
+
"version_minor": 0,
|
| 582 |
+
"model_id": "15f431ee684f448f897b20b1f4f4a3b1"
|
| 583 |
+
}
|
| 584 |
+
},
|
| 585 |
+
"metadata": {}
|
| 586 |
+
},
|
| 587 |
+
{
|
| 588 |
+
"output_type": "stream",
|
| 589 |
+
"name": "stdout",
|
| 590 |
+
"text": [
|
| 591 |
+
"Device: cuda\n",
|
| 592 |
+
"Evaluating...\n"
|
| 593 |
+
]
|
| 594 |
+
},
|
| 595 |
+
{
|
| 596 |
+
"output_type": "stream",
|
| 597 |
+
"name": "stderr",
|
| 598 |
+
"text": [
|
| 599 |
+
" 0%| | 0/300 [00:00<?, ?it/s][transformers] `use_return_dict` is deprecated! Use `return_dict` instead!\n",
|
| 600 |
+
"100%|██████████| 300/300 [09:08<00:00, 1.83s/it]"
|
| 601 |
+
]
|
| 602 |
+
},
|
| 603 |
+
{
|
| 604 |
+
"output_type": "stream",
|
| 605 |
+
"name": "stdout",
|
| 606 |
+
"text": [
|
| 607 |
+
"\n",
|
| 608 |
+
"==============================\n",
|
| 609 |
+
"ROUGE RESULTS\n",
|
| 610 |
+
"ROUGE-1: 0.5791\n",
|
| 611 |
+
"ROUGE-2: 0.2684\n",
|
| 612 |
+
"ROUGE-L: 0.3826\n",
|
| 613 |
+
"==============================\n",
|
| 614 |
+
"Saved results to rouge_results.json\n",
|
| 615 |
+
"Đã tạo báo cáo phân tích lỗi tại: error_analysis.txt\n"
|
| 616 |
+
]
|
| 617 |
+
},
|
| 618 |
+
{
|
| 619 |
+
"output_type": "stream",
|
| 620 |
+
"name": "stderr",
|
| 621 |
+
"text": [
|
| 622 |
+
"\n"
|
| 623 |
+
]
|
| 624 |
+
}
|
| 625 |
+
],
|
| 626 |
+
"source": [
|
| 627 |
+
"if __name__ == \"__main__\":\n",
|
| 628 |
+
" # Bước 1: Tạo dữ liệu test (dùng hàm của ông)\n",
|
| 629 |
+
" test_samples = run_create_test_set(num_samples=300)\n",
|
| 630 |
+
"\n",
|
| 631 |
+
" # Bước 2: Chạy đánh giá với Model trên Hugging Face\n",
|
| 632 |
+
" MODEL_ID = \"OrdinaryAI/visum-qlora-5epochs\"\n",
|
| 633 |
+
" evaluate_model_colab(MODEL_ID, test_samples)\n",
|
| 634 |
+
"\n",
|
| 635 |
+
" create_error_summary()"
|
| 636 |
+
]
|
| 637 |
+
},
|
| 638 |
+
{
|
| 639 |
+
"cell_type": "markdown",
|
| 640 |
+
"source": [
|
| 641 |
+
"**Ý nghĩa**\n",
|
| 642 |
+
"\n",
|
| 643 |
+
"* ROUGE-1: Đo lường mức độ trùng lặp của các từ đơn (unigrams) giữa bản tóm tắt của AI và bản tham chiếu của người.\n",
|
| 644 |
+
"\n",
|
| 645 |
+
"* ROUGE-2: Đo lường mức độ trùng lặp của các cụm 2 từ liên tiếp (bigrams). Chỉ số này đại diện cho độ mượt mà và khả năng kết nối ý của câu.\n",
|
| 646 |
+
"\n",
|
| 647 |
+
"* ROUGE-3: Dựa trên chuỗi con chung dài nhất (Longest Common Subsequence). Chỉ số này phản ánh khả năng duy trì cấu trúc câu và trình tự logic của thông tin.\n"
|
| 648 |
+
],
|
| 649 |
+
"metadata": {
|
| 650 |
+
"id": "yPAwkJfuFPgg"
|
| 651 |
+
}
|
| 652 |
+
},
|
| 653 |
+
{
|
| 654 |
+
"cell_type": "markdown",
|
| 655 |
+
"source": [
|
| 656 |
+
"**Nhận xét**\n",
|
| 657 |
+
"\n",
|
| 658 |
+
"* **ROUGE-1: 0.5791 (57.91%)**\n",
|
| 659 |
+
" - Nhận xét: Con số gần 58% là rất cao đối với phương pháp tóm tắt thực thể (Abstractive Summarization). Điều này chứng tỏ model cực kỳ giỏi trong việc trích xuất và giữ lại các thông tin cốt lõi, từ khóa quan trọng, tên riêng và các con số từ bài báo gốc.\n",
|
| 660 |
+
"\n",
|
| 661 |
+
"* **ROUGE-2: 0.2684 (26.84%)**\n",
|
| 662 |
+
" - Nhận xét: Trong tiếng Việt, ROUGE-2 đạt trên 25% là rất ấn tượng. Nó cho thấy model không chỉ \"nhặt\" từ đơn lẻ mà còn hiểu và tái tạo được các cụm từ có nghĩa, bám sát văn phong báo chí.\n",
|
| 663 |
+
"\n",
|
| 664 |
+
"* **ROUGE-L: 0.3826 (38.26%)**\n",
|
| 665 |
+
" - Nhận xét: Mức 38.26% khẳng định model giữ được mạch văn logic. Các ý chính được sắp xếp theo đúng trình tự thời gian hoặc diễn biến của sự kiện gốc, giúp bản tóm tắt dễ hiểu và mạch lạc."
|
| 666 |
+
],
|
| 667 |
+
"metadata": {
|
| 668 |
+
"id": "aOmbCIgvE7JJ"
|
| 669 |
+
}
|
| 670 |
+
},
|
| 671 |
+
{
|
| 672 |
+
"cell_type": "markdown",
|
| 673 |
+
"source": [
|
| 674 |
+
"**Đánh giá tổng quát về chất lượng Model**\n",
|
| 675 |
+
"\n",
|
| 676 |
+
"* Độ bao phủ thông tin (Informativeness): Với ROUGE-1 cao vượt trội, có thể kết luận model gần như không bỏ lỡ các chi tiết quan trọng của bài báo. Đây là yếu tố then chốt giúp bản tóm tắt có giá trị tin cậy cao.\n",
|
| 677 |
+
"\n",
|
| 678 |
+
"* Độ tự nhiên (Fluency): Chỉ số ROUGE-2 và ROUGE-L cho thấy model đã thoát khỏi việc copy-paste máy móc. AI đã thực hiện việc \"diễn đạt lại\" (paraphrasing) một cách thông minh, tạo ra các câu văn ngắn gọn nhưng vẫn đảm bảo đúng ngữ pháp tiếng Việt.\n",
|
| 679 |
+
"\n",
|
| 680 |
+
"* Khả năng nén thông tin: Kết quả này cho thấy model hoạt động cực tốt với bộ lọc dữ liệu (tỷ lệ nén < 0.3) mà ông đã thiết lập. Model biết cách cô đọng nội dung một cách tối ưu mà không làm mất đi bản chất của tin tức."
|
| 681 |
+
],
|
| 682 |
+
"metadata": {
|
| 683 |
+
"id": "BKRYfvvOJhcY"
|
| 684 |
+
}
|
| 685 |
+
},
|
| 686 |
+
{
|
| 687 |
+
"cell_type": "markdown",
|
| 688 |
+
"source": [
|
| 689 |
+
"**Kết luận**\n",
|
| 690 |
+
"\n",
|
| 691 |
+
"Kết quả thực nghiệm trên tập dữ liệu VietNews cho thấy model đạt hiệu năng rất cao với các chỉ số ROUGE-1, ROUGE-2 và ROUGE-L lần lượt là 0.5791, 0.2684 và 0.3826.\n",
|
| 692 |
+
"\n",
|
| 693 |
+
"Đặc biệt, chỉ số ROUGE-L vượt ngưỡng 0.38 cho thấy khả năng duy trì cấu trúc logic và tính liên kết của văn bản rất tốt. Điều này chứng minh rằng quy trình tiền xử lý dữ liệu chặt chẽ kết hợp với kiến trúc model tối ưu đã giúp hệ thống không chỉ bắt được các từ khóa quan trọng mà còn kiến tạo được những bản tóm tắt mượt mà, súc tích và có độ trung thực cao so với văn bản gốc."
|
| 694 |
+
],
|
| 695 |
+
"metadata": {
|
| 696 |
+
"id": "bS954RHJJsHH"
|
| 697 |
+
}
|
| 698 |
+
},
|
| 699 |
+
{
|
| 700 |
+
"cell_type": "code",
|
| 701 |
+
"source": [],
|
| 702 |
+
"metadata": {
|
| 703 |
+
"id": "n2ZUiPfQ_gR8"
|
| 704 |
+
},
|
| 705 |
+
"execution_count": 9,
|
| 706 |
+
"outputs": []
|
| 707 |
+
}
|
| 708 |
+
],
|
| 709 |
+
"metadata": {
|
| 710 |
+
"accelerator": "GPU",
|
| 711 |
+
"colab": {
|
| 712 |
+
"gpuType": "T4",
|
| 713 |
+
"provenance": []
|
| 714 |
+
},
|
| 715 |
+
"kernelspec": {
|
| 716 |
+
"display_name": "Python 3",
|
| 717 |
+
"name": "python3"
|
| 718 |
+
},
|
| 719 |
+
"language_info": {
|
| 720 |
+
"name": "python"
|
| 721 |
+
},
|
| 722 |
+
"widgets": {
|
| 723 |
+
"application/vnd.jupyter.widget-state+json": {
|
| 724 |
+
"73fd47b411a24145a609bab0cf37eaa9": {
|
| 725 |
+
"model_module": "@jupyter-widgets/controls",
|
| 726 |
+
"model_name": "HBoxModel",
|
| 727 |
+
"model_module_version": "1.5.0",
|
| 728 |
+
"state": {
|
| 729 |
+
"_dom_classes": [],
|
| 730 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 731 |
+
"_model_module_version": "1.5.0",
|
| 732 |
+
"_model_name": "HBoxModel",
|
| 733 |
+
"_view_count": null,
|
| 734 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 735 |
+
"_view_module_version": "1.5.0",
|
| 736 |
+
"_view_name": "HBoxView",
|
| 737 |
+
"box_style": "",
|
| 738 |
+
"children": [
|
| 739 |
+
"IPY_MODEL_2c46fcfc647546f2aa0a499518c7f894",
|
| 740 |
+
"IPY_MODEL_51f3b92a16c14098899b88605e5ae506",
|
| 741 |
+
"IPY_MODEL_d065f191724f4f07b24698eaa70328f6"
|
| 742 |
+
],
|
| 743 |
+
"layout": "IPY_MODEL_68e125c3d4b74a6db0dc706041cea907"
|
| 744 |
+
}
|
| 745 |
+
},
|
| 746 |
+
"2c46fcfc647546f2aa0a499518c7f894": {
|
| 747 |
+
"model_module": "@jupyter-widgets/controls",
|
| 748 |
+
"model_name": "HTMLModel",
|
| 749 |
+
"model_module_version": "1.5.0",
|
| 750 |
+
"state": {
|
| 751 |
+
"_dom_classes": [],
|
| 752 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 753 |
+
"_model_module_version": "1.5.0",
|
| 754 |
+
"_model_name": "HTMLModel",
|
| 755 |
+
"_view_count": null,
|
| 756 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 757 |
+
"_view_module_version": "1.5.0",
|
| 758 |
+
"_view_name": "HTMLView",
|
| 759 |
+
"description": "",
|
| 760 |
+
"description_tooltip": null,
|
| 761 |
+
"layout": "IPY_MODEL_0705273e51cf4be982faab30bbec3820",
|
| 762 |
+
"placeholder": "",
|
| 763 |
+
"style": "IPY_MODEL_fe96abf3ed3240f39d7a7ad69ebeb38e",
|
| 764 |
+
"value": "Loading weights: 100%"
|
| 765 |
+
}
|
| 766 |
+
},
|
| 767 |
+
"51f3b92a16c14098899b88605e5ae506": {
|
| 768 |
+
"model_module": "@jupyter-widgets/controls",
|
| 769 |
+
"model_name": "FloatProgressModel",
|
| 770 |
+
"model_module_version": "1.5.0",
|
| 771 |
+
"state": {
|
| 772 |
+
"_dom_classes": [],
|
| 773 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 774 |
+
"_model_module_version": "1.5.0",
|
| 775 |
+
"_model_name": "FloatProgressModel",
|
| 776 |
+
"_view_count": null,
|
| 777 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 778 |
+
"_view_module_version": "1.5.0",
|
| 779 |
+
"_view_name": "ProgressView",
|
| 780 |
+
"bar_style": "success",
|
| 781 |
+
"description": "",
|
| 782 |
+
"description_tooltip": null,
|
| 783 |
+
"layout": "IPY_MODEL_ff2134fadfeb473d97309dfe7d9f2fff",
|
| 784 |
+
"max": 517,
|
| 785 |
+
"min": 0,
|
| 786 |
+
"orientation": "horizontal",
|
| 787 |
+
"style": "IPY_MODEL_25227fefc594436ca8d042dedfaeb4ba",
|
| 788 |
+
"value": 517
|
| 789 |
+
}
|
| 790 |
+
},
|
| 791 |
+
"d065f191724f4f07b24698eaa70328f6": {
|
| 792 |
+
"model_module": "@jupyter-widgets/controls",
|
| 793 |
+
"model_name": "HTMLModel",
|
| 794 |
+
"model_module_version": "1.5.0",
|
| 795 |
+
"state": {
|
| 796 |
+
"_dom_classes": [],
|
| 797 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 798 |
+
"_model_module_version": "1.5.0",
|
| 799 |
+
"_model_name": "HTMLModel",
|
| 800 |
+
"_view_count": null,
|
| 801 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 802 |
+
"_view_module_version": "1.5.0",
|
| 803 |
+
"_view_name": "HTMLView",
|
| 804 |
+
"description": "",
|
| 805 |
+
"description_tooltip": null,
|
| 806 |
+
"layout": "IPY_MODEL_cf9fee299b7c402dab73371707cbc96b",
|
| 807 |
+
"placeholder": "",
|
| 808 |
+
"style": "IPY_MODEL_25e25a2b5db14e65b518c1d9a7934311",
|
| 809 |
+
"value": " 517/517 [00:00<00:00, 13216.57it/s]"
|
| 810 |
+
}
|
| 811 |
+
},
|
| 812 |
+
"68e125c3d4b74a6db0dc706041cea907": {
|
| 813 |
+
"model_module": "@jupyter-widgets/base",
|
| 814 |
+
"model_name": "LayoutModel",
|
| 815 |
+
"model_module_version": "1.2.0",
|
| 816 |
+
"state": {
|
| 817 |
+
"_model_module": "@jupyter-widgets/base",
|
| 818 |
+
"_model_module_version": "1.2.0",
|
| 819 |
+
"_model_name": "LayoutModel",
|
| 820 |
+
"_view_count": null,
|
| 821 |
+
"_view_module": "@jupyter-widgets/base",
|
| 822 |
+
"_view_module_version": "1.2.0",
|
| 823 |
+
"_view_name": "LayoutView",
|
| 824 |
+
"align_content": null,
|
| 825 |
+
"align_items": null,
|
| 826 |
+
"align_self": null,
|
| 827 |
+
"border": null,
|
| 828 |
+
"bottom": null,
|
| 829 |
+
"display": null,
|
| 830 |
+
"flex": null,
|
| 831 |
+
"flex_flow": null,
|
| 832 |
+
"grid_area": null,
|
| 833 |
+
"grid_auto_columns": null,
|
| 834 |
+
"grid_auto_flow": null,
|
| 835 |
+
"grid_auto_rows": null,
|
| 836 |
+
"grid_column": null,
|
| 837 |
+
"grid_gap": null,
|
| 838 |
+
"grid_row": null,
|
| 839 |
+
"grid_template_areas": null,
|
| 840 |
+
"grid_template_columns": null,
|
| 841 |
+
"grid_template_rows": null,
|
| 842 |
+
"height": null,
|
| 843 |
+
"justify_content": null,
|
| 844 |
+
"justify_items": null,
|
| 845 |
+
"left": null,
|
| 846 |
+
"margin": null,
|
| 847 |
+
"max_height": null,
|
| 848 |
+
"max_width": null,
|
| 849 |
+
"min_height": null,
|
| 850 |
+
"min_width": null,
|
| 851 |
+
"object_fit": null,
|
| 852 |
+
"object_position": null,
|
| 853 |
+
"order": null,
|
| 854 |
+
"overflow": null,
|
| 855 |
+
"overflow_x": null,
|
| 856 |
+
"overflow_y": null,
|
| 857 |
+
"padding": null,
|
| 858 |
+
"right": null,
|
| 859 |
+
"top": null,
|
| 860 |
+
"visibility": null,
|
| 861 |
+
"width": null
|
| 862 |
+
}
|
| 863 |
+
},
|
| 864 |
+
"0705273e51cf4be982faab30bbec3820": {
|
| 865 |
+
"model_module": "@jupyter-widgets/base",
|
| 866 |
+
"model_name": "LayoutModel",
|
| 867 |
+
"model_module_version": "1.2.0",
|
| 868 |
+
"state": {
|
| 869 |
+
"_model_module": "@jupyter-widgets/base",
|
| 870 |
+
"_model_module_version": "1.2.0",
|
| 871 |
+
"_model_name": "LayoutModel",
|
| 872 |
+
"_view_count": null,
|
| 873 |
+
"_view_module": "@jupyter-widgets/base",
|
| 874 |
+
"_view_module_version": "1.2.0",
|
| 875 |
+
"_view_name": "LayoutView",
|
| 876 |
+
"align_content": null,
|
| 877 |
+
"align_items": null,
|
| 878 |
+
"align_self": null,
|
| 879 |
+
"border": null,
|
| 880 |
+
"bottom": null,
|
| 881 |
+
"display": null,
|
| 882 |
+
"flex": null,
|
| 883 |
+
"flex_flow": null,
|
| 884 |
+
"grid_area": null,
|
| 885 |
+
"grid_auto_columns": null,
|
| 886 |
+
"grid_auto_flow": null,
|
| 887 |
+
"grid_auto_rows": null,
|
| 888 |
+
"grid_column": null,
|
| 889 |
+
"grid_gap": null,
|
| 890 |
+
"grid_row": null,
|
| 891 |
+
"grid_template_areas": null,
|
| 892 |
+
"grid_template_columns": null,
|
| 893 |
+
"grid_template_rows": null,
|
| 894 |
+
"height": null,
|
| 895 |
+
"justify_content": null,
|
| 896 |
+
"justify_items": null,
|
| 897 |
+
"left": null,
|
| 898 |
+
"margin": null,
|
| 899 |
+
"max_height": null,
|
| 900 |
+
"max_width": null,
|
| 901 |
+
"min_height": null,
|
| 902 |
+
"min_width": null,
|
| 903 |
+
"object_fit": null,
|
| 904 |
+
"object_position": null,
|
| 905 |
+
"order": null,
|
| 906 |
+
"overflow": null,
|
| 907 |
+
"overflow_x": null,
|
| 908 |
+
"overflow_y": null,
|
| 909 |
+
"padding": null,
|
| 910 |
+
"right": null,
|
| 911 |
+
"top": null,
|
| 912 |
+
"visibility": null,
|
| 913 |
+
"width": null
|
| 914 |
+
}
|
| 915 |
+
},
|
| 916 |
+
"fe96abf3ed3240f39d7a7ad69ebeb38e": {
|
| 917 |
+
"model_module": "@jupyter-widgets/controls",
|
| 918 |
+
"model_name": "DescriptionStyleModel",
|
| 919 |
+
"model_module_version": "1.5.0",
|
| 920 |
+
"state": {
|
| 921 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 922 |
+
"_model_module_version": "1.5.0",
|
| 923 |
+
"_model_name": "DescriptionStyleModel",
|
| 924 |
+
"_view_count": null,
|
| 925 |
+
"_view_module": "@jupyter-widgets/base",
|
| 926 |
+
"_view_module_version": "1.2.0",
|
| 927 |
+
"_view_name": "StyleView",
|
| 928 |
+
"description_width": ""
|
| 929 |
+
}
|
| 930 |
+
},
|
| 931 |
+
"ff2134fadfeb473d97309dfe7d9f2fff": {
|
| 932 |
+
"model_module": "@jupyter-widgets/base",
|
| 933 |
+
"model_name": "LayoutModel",
|
| 934 |
+
"model_module_version": "1.2.0",
|
| 935 |
+
"state": {
|
| 936 |
+
"_model_module": "@jupyter-widgets/base",
|
| 937 |
+
"_model_module_version": "1.2.0",
|
| 938 |
+
"_model_name": "LayoutModel",
|
| 939 |
+
"_view_count": null,
|
| 940 |
+
"_view_module": "@jupyter-widgets/base",
|
| 941 |
+
"_view_module_version": "1.2.0",
|
| 942 |
+
"_view_name": "LayoutView",
|
| 943 |
+
"align_content": null,
|
| 944 |
+
"align_items": null,
|
| 945 |
+
"align_self": null,
|
| 946 |
+
"border": null,
|
| 947 |
+
"bottom": null,
|
| 948 |
+
"display": null,
|
| 949 |
+
"flex": null,
|
| 950 |
+
"flex_flow": null,
|
| 951 |
+
"grid_area": null,
|
| 952 |
+
"grid_auto_columns": null,
|
| 953 |
+
"grid_auto_flow": null,
|
| 954 |
+
"grid_auto_rows": null,
|
| 955 |
+
"grid_column": null,
|
| 956 |
+
"grid_gap": null,
|
| 957 |
+
"grid_row": null,
|
| 958 |
+
"grid_template_areas": null,
|
| 959 |
+
"grid_template_columns": null,
|
| 960 |
+
"grid_template_rows": null,
|
| 961 |
+
"height": null,
|
| 962 |
+
"justify_content": null,
|
| 963 |
+
"justify_items": null,
|
| 964 |
+
"left": null,
|
| 965 |
+
"margin": null,
|
| 966 |
+
"max_height": null,
|
| 967 |
+
"max_width": null,
|
| 968 |
+
"min_height": null,
|
| 969 |
+
"min_width": null,
|
| 970 |
+
"object_fit": null,
|
| 971 |
+
"object_position": null,
|
| 972 |
+
"order": null,
|
| 973 |
+
"overflow": null,
|
| 974 |
+
"overflow_x": null,
|
| 975 |
+
"overflow_y": null,
|
| 976 |
+
"padding": null,
|
| 977 |
+
"right": null,
|
| 978 |
+
"top": null,
|
| 979 |
+
"visibility": null,
|
| 980 |
+
"width": null
|
| 981 |
+
}
|
| 982 |
+
},
|
| 983 |
+
"25227fefc594436ca8d042dedfaeb4ba": {
|
| 984 |
+
"model_module": "@jupyter-widgets/controls",
|
| 985 |
+
"model_name": "ProgressStyleModel",
|
| 986 |
+
"model_module_version": "1.5.0",
|
| 987 |
+
"state": {
|
| 988 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 989 |
+
"_model_module_version": "1.5.0",
|
| 990 |
+
"_model_name": "ProgressStyleModel",
|
| 991 |
+
"_view_count": null,
|
| 992 |
+
"_view_module": "@jupyter-widgets/base",
|
| 993 |
+
"_view_module_version": "1.2.0",
|
| 994 |
+
"_view_name": "StyleView",
|
| 995 |
+
"bar_color": null,
|
| 996 |
+
"description_width": ""
|
| 997 |
+
}
|
| 998 |
+
},
|
| 999 |
+
"cf9fee299b7c402dab73371707cbc96b": {
|
| 1000 |
+
"model_module": "@jupyter-widgets/base",
|
| 1001 |
+
"model_name": "LayoutModel",
|
| 1002 |
+
"model_module_version": "1.2.0",
|
| 1003 |
+
"state": {
|
| 1004 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1005 |
+
"_model_module_version": "1.2.0",
|
| 1006 |
+
"_model_name": "LayoutModel",
|
| 1007 |
+
"_view_count": null,
|
| 1008 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1009 |
+
"_view_module_version": "1.2.0",
|
| 1010 |
+
"_view_name": "LayoutView",
|
| 1011 |
+
"align_content": null,
|
| 1012 |
+
"align_items": null,
|
| 1013 |
+
"align_self": null,
|
| 1014 |
+
"border": null,
|
| 1015 |
+
"bottom": null,
|
| 1016 |
+
"display": null,
|
| 1017 |
+
"flex": null,
|
| 1018 |
+
"flex_flow": null,
|
| 1019 |
+
"grid_area": null,
|
| 1020 |
+
"grid_auto_columns": null,
|
| 1021 |
+
"grid_auto_flow": null,
|
| 1022 |
+
"grid_auto_rows": null,
|
| 1023 |
+
"grid_column": null,
|
| 1024 |
+
"grid_gap": null,
|
| 1025 |
+
"grid_row": null,
|
| 1026 |
+
"grid_template_areas": null,
|
| 1027 |
+
"grid_template_columns": null,
|
| 1028 |
+
"grid_template_rows": null,
|
| 1029 |
+
"height": null,
|
| 1030 |
+
"justify_content": null,
|
| 1031 |
+
"justify_items": null,
|
| 1032 |
+
"left": null,
|
| 1033 |
+
"margin": null,
|
| 1034 |
+
"max_height": null,
|
| 1035 |
+
"max_width": null,
|
| 1036 |
+
"min_height": null,
|
| 1037 |
+
"min_width": null,
|
| 1038 |
+
"object_fit": null,
|
| 1039 |
+
"object_position": null,
|
| 1040 |
+
"order": null,
|
| 1041 |
+
"overflow": null,
|
| 1042 |
+
"overflow_x": null,
|
| 1043 |
+
"overflow_y": null,
|
| 1044 |
+
"padding": null,
|
| 1045 |
+
"right": null,
|
| 1046 |
+
"top": null,
|
| 1047 |
+
"visibility": null,
|
| 1048 |
+
"width": null
|
| 1049 |
+
}
|
| 1050 |
+
},
|
| 1051 |
+
"25e25a2b5db14e65b518c1d9a7934311": {
|
| 1052 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1053 |
+
"model_name": "DescriptionStyleModel",
|
| 1054 |
+
"model_module_version": "1.5.0",
|
| 1055 |
+
"state": {
|
| 1056 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1057 |
+
"_model_module_version": "1.5.0",
|
| 1058 |
+
"_model_name": "DescriptionStyleModel",
|
| 1059 |
+
"_view_count": null,
|
| 1060 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1061 |
+
"_view_module_version": "1.2.0",
|
| 1062 |
+
"_view_name": "StyleView",
|
| 1063 |
+
"description_width": ""
|
| 1064 |
+
}
|
| 1065 |
+
},
|
| 1066 |
+
"4932c1b71001436d989bff89034d1489": {
|
| 1067 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1068 |
+
"model_name": "HBoxModel",
|
| 1069 |
+
"model_module_version": "1.5.0",
|
| 1070 |
+
"state": {
|
| 1071 |
+
"_dom_classes": [],
|
| 1072 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1073 |
+
"_model_module_version": "1.5.0",
|
| 1074 |
+
"_model_name": "HBoxModel",
|
| 1075 |
+
"_view_count": null,
|
| 1076 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1077 |
+
"_view_module_version": "1.5.0",
|
| 1078 |
+
"_view_name": "HBoxView",
|
| 1079 |
+
"box_style": "",
|
| 1080 |
+
"children": [
|
| 1081 |
+
"IPY_MODEL_700e4bfdd19a4da49746b64349825465",
|
| 1082 |
+
"IPY_MODEL_ddeb494331f244f5b7ba3b216ccee9d5",
|
| 1083 |
+
"IPY_MODEL_de7b4e36949140a383cde04f803f66d1"
|
| 1084 |
+
],
|
| 1085 |
+
"layout": "IPY_MODEL_704c1c9ebc68429e86718a12f6f31e47"
|
| 1086 |
+
}
|
| 1087 |
+
},
|
| 1088 |
+
"700e4bfdd19a4da49746b64349825465": {
|
| 1089 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1090 |
+
"model_name": "HTMLModel",
|
| 1091 |
+
"model_module_version": "1.5.0",
|
| 1092 |
+
"state": {
|
| 1093 |
+
"_dom_classes": [],
|
| 1094 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1095 |
+
"_model_module_version": "1.5.0",
|
| 1096 |
+
"_model_name": "HTMLModel",
|
| 1097 |
+
"_view_count": null,
|
| 1098 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1099 |
+
"_view_module_version": "1.5.0",
|
| 1100 |
+
"_view_name": "HTMLView",
|
| 1101 |
+
"description": "",
|
| 1102 |
+
"description_tooltip": null,
|
| 1103 |
+
"layout": "IPY_MODEL_1288103230e143b78db2b655bbaa32a3",
|
| 1104 |
+
"placeholder": "",
|
| 1105 |
+
"style": "IPY_MODEL_e4d8f471e4f14750987fd1f01326980c",
|
| 1106 |
+
"value": "adapter_model.safetensors: 100%"
|
| 1107 |
+
}
|
| 1108 |
+
},
|
| 1109 |
+
"ddeb494331f244f5b7ba3b216ccee9d5": {
|
| 1110 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1111 |
+
"model_name": "FloatProgressModel",
|
| 1112 |
+
"model_module_version": "1.5.0",
|
| 1113 |
+
"state": {
|
| 1114 |
+
"_dom_classes": [],
|
| 1115 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1116 |
+
"_model_module_version": "1.5.0",
|
| 1117 |
+
"_model_name": "FloatProgressModel",
|
| 1118 |
+
"_view_count": null,
|
| 1119 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1120 |
+
"_view_module_version": "1.5.0",
|
| 1121 |
+
"_view_name": "ProgressView",
|
| 1122 |
+
"bar_style": "success",
|
| 1123 |
+
"description": "",
|
| 1124 |
+
"description_tooltip": null,
|
| 1125 |
+
"layout": "IPY_MODEL_18a62b050d9541428faead83567beb30",
|
| 1126 |
+
"max": 34656568,
|
| 1127 |
+
"min": 0,
|
| 1128 |
+
"orientation": "horizontal",
|
| 1129 |
+
"style": "IPY_MODEL_10861235615d4d76b7baaa40cffbbdef",
|
| 1130 |
+
"value": 34656568
|
| 1131 |
+
}
|
| 1132 |
+
},
|
| 1133 |
+
"de7b4e36949140a383cde04f803f66d1": {
|
| 1134 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1135 |
+
"model_name": "HTMLModel",
|
| 1136 |
+
"model_module_version": "1.5.0",
|
| 1137 |
+
"state": {
|
| 1138 |
+
"_dom_classes": [],
|
| 1139 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1140 |
+
"_model_module_version": "1.5.0",
|
| 1141 |
+
"_model_name": "HTMLModel",
|
| 1142 |
+
"_view_count": null,
|
| 1143 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1144 |
+
"_view_module_version": "1.5.0",
|
| 1145 |
+
"_view_name": "HTMLView",
|
| 1146 |
+
"description": "",
|
| 1147 |
+
"description_tooltip": null,
|
| 1148 |
+
"layout": "IPY_MODEL_cda61cbf54884c3aa98127049dad33bf",
|
| 1149 |
+
"placeholder": "",
|
| 1150 |
+
"style": "IPY_MODEL_1c8d0998a1cc4d70af29c394c2949506",
|
| 1151 |
+
"value": " 34.7M/34.7M [00:02<00:00, 174MB/s]"
|
| 1152 |
+
}
|
| 1153 |
+
},
|
| 1154 |
+
"704c1c9ebc68429e86718a12f6f31e47": {
|
| 1155 |
+
"model_module": "@jupyter-widgets/base",
|
| 1156 |
+
"model_name": "LayoutModel",
|
| 1157 |
+
"model_module_version": "1.2.0",
|
| 1158 |
+
"state": {
|
| 1159 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1160 |
+
"_model_module_version": "1.2.0",
|
| 1161 |
+
"_model_name": "LayoutModel",
|
| 1162 |
+
"_view_count": null,
|
| 1163 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1164 |
+
"_view_module_version": "1.2.0",
|
| 1165 |
+
"_view_name": "LayoutView",
|
| 1166 |
+
"align_content": null,
|
| 1167 |
+
"align_items": null,
|
| 1168 |
+
"align_self": null,
|
| 1169 |
+
"border": null,
|
| 1170 |
+
"bottom": null,
|
| 1171 |
+
"display": null,
|
| 1172 |
+
"flex": null,
|
| 1173 |
+
"flex_flow": null,
|
| 1174 |
+
"grid_area": null,
|
| 1175 |
+
"grid_auto_columns": null,
|
| 1176 |
+
"grid_auto_flow": null,
|
| 1177 |
+
"grid_auto_rows": null,
|
| 1178 |
+
"grid_column": null,
|
| 1179 |
+
"grid_gap": null,
|
| 1180 |
+
"grid_row": null,
|
| 1181 |
+
"grid_template_areas": null,
|
| 1182 |
+
"grid_template_columns": null,
|
| 1183 |
+
"grid_template_rows": null,
|
| 1184 |
+
"height": null,
|
| 1185 |
+
"justify_content": null,
|
| 1186 |
+
"justify_items": null,
|
| 1187 |
+
"left": null,
|
| 1188 |
+
"margin": null,
|
| 1189 |
+
"max_height": null,
|
| 1190 |
+
"max_width": null,
|
| 1191 |
+
"min_height": null,
|
| 1192 |
+
"min_width": null,
|
| 1193 |
+
"object_fit": null,
|
| 1194 |
+
"object_position": null,
|
| 1195 |
+
"order": null,
|
| 1196 |
+
"overflow": null,
|
| 1197 |
+
"overflow_x": null,
|
| 1198 |
+
"overflow_y": null,
|
| 1199 |
+
"padding": null,
|
| 1200 |
+
"right": null,
|
| 1201 |
+
"top": null,
|
| 1202 |
+
"visibility": null,
|
| 1203 |
+
"width": null
|
| 1204 |
+
}
|
| 1205 |
+
},
|
| 1206 |
+
"1288103230e143b78db2b655bbaa32a3": {
|
| 1207 |
+
"model_module": "@jupyter-widgets/base",
|
| 1208 |
+
"model_name": "LayoutModel",
|
| 1209 |
+
"model_module_version": "1.2.0",
|
| 1210 |
+
"state": {
|
| 1211 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1212 |
+
"_model_module_version": "1.2.0",
|
| 1213 |
+
"_model_name": "LayoutModel",
|
| 1214 |
+
"_view_count": null,
|
| 1215 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1216 |
+
"_view_module_version": "1.2.0",
|
| 1217 |
+
"_view_name": "LayoutView",
|
| 1218 |
+
"align_content": null,
|
| 1219 |
+
"align_items": null,
|
| 1220 |
+
"align_self": null,
|
| 1221 |
+
"border": null,
|
| 1222 |
+
"bottom": null,
|
| 1223 |
+
"display": null,
|
| 1224 |
+
"flex": null,
|
| 1225 |
+
"flex_flow": null,
|
| 1226 |
+
"grid_area": null,
|
| 1227 |
+
"grid_auto_columns": null,
|
| 1228 |
+
"grid_auto_flow": null,
|
| 1229 |
+
"grid_auto_rows": null,
|
| 1230 |
+
"grid_column": null,
|
| 1231 |
+
"grid_gap": null,
|
| 1232 |
+
"grid_row": null,
|
| 1233 |
+
"grid_template_areas": null,
|
| 1234 |
+
"grid_template_columns": null,
|
| 1235 |
+
"grid_template_rows": null,
|
| 1236 |
+
"height": null,
|
| 1237 |
+
"justify_content": null,
|
| 1238 |
+
"justify_items": null,
|
| 1239 |
+
"left": null,
|
| 1240 |
+
"margin": null,
|
| 1241 |
+
"max_height": null,
|
| 1242 |
+
"max_width": null,
|
| 1243 |
+
"min_height": null,
|
| 1244 |
+
"min_width": null,
|
| 1245 |
+
"object_fit": null,
|
| 1246 |
+
"object_position": null,
|
| 1247 |
+
"order": null,
|
| 1248 |
+
"overflow": null,
|
| 1249 |
+
"overflow_x": null,
|
| 1250 |
+
"overflow_y": null,
|
| 1251 |
+
"padding": null,
|
| 1252 |
+
"right": null,
|
| 1253 |
+
"top": null,
|
| 1254 |
+
"visibility": null,
|
| 1255 |
+
"width": null
|
| 1256 |
+
}
|
| 1257 |
+
},
|
| 1258 |
+
"e4d8f471e4f14750987fd1f01326980c": {
|
| 1259 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1260 |
+
"model_name": "DescriptionStyleModel",
|
| 1261 |
+
"model_module_version": "1.5.0",
|
| 1262 |
+
"state": {
|
| 1263 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1264 |
+
"_model_module_version": "1.5.0",
|
| 1265 |
+
"_model_name": "DescriptionStyleModel",
|
| 1266 |
+
"_view_count": null,
|
| 1267 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1268 |
+
"_view_module_version": "1.2.0",
|
| 1269 |
+
"_view_name": "StyleView",
|
| 1270 |
+
"description_width": ""
|
| 1271 |
+
}
|
| 1272 |
+
},
|
| 1273 |
+
"18a62b050d9541428faead83567beb30": {
|
| 1274 |
+
"model_module": "@jupyter-widgets/base",
|
| 1275 |
+
"model_name": "LayoutModel",
|
| 1276 |
+
"model_module_version": "1.2.0",
|
| 1277 |
+
"state": {
|
| 1278 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1279 |
+
"_model_module_version": "1.2.0",
|
| 1280 |
+
"_model_name": "LayoutModel",
|
| 1281 |
+
"_view_count": null,
|
| 1282 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1283 |
+
"_view_module_version": "1.2.0",
|
| 1284 |
+
"_view_name": "LayoutView",
|
| 1285 |
+
"align_content": null,
|
| 1286 |
+
"align_items": null,
|
| 1287 |
+
"align_self": null,
|
| 1288 |
+
"border": null,
|
| 1289 |
+
"bottom": null,
|
| 1290 |
+
"display": null,
|
| 1291 |
+
"flex": null,
|
| 1292 |
+
"flex_flow": null,
|
| 1293 |
+
"grid_area": null,
|
| 1294 |
+
"grid_auto_columns": null,
|
| 1295 |
+
"grid_auto_flow": null,
|
| 1296 |
+
"grid_auto_rows": null,
|
| 1297 |
+
"grid_column": null,
|
| 1298 |
+
"grid_gap": null,
|
| 1299 |
+
"grid_row": null,
|
| 1300 |
+
"grid_template_areas": null,
|
| 1301 |
+
"grid_template_columns": null,
|
| 1302 |
+
"grid_template_rows": null,
|
| 1303 |
+
"height": null,
|
| 1304 |
+
"justify_content": null,
|
| 1305 |
+
"justify_items": null,
|
| 1306 |
+
"left": null,
|
| 1307 |
+
"margin": null,
|
| 1308 |
+
"max_height": null,
|
| 1309 |
+
"max_width": null,
|
| 1310 |
+
"min_height": null,
|
| 1311 |
+
"min_width": null,
|
| 1312 |
+
"object_fit": null,
|
| 1313 |
+
"object_position": null,
|
| 1314 |
+
"order": null,
|
| 1315 |
+
"overflow": null,
|
| 1316 |
+
"overflow_x": null,
|
| 1317 |
+
"overflow_y": null,
|
| 1318 |
+
"padding": null,
|
| 1319 |
+
"right": null,
|
| 1320 |
+
"top": null,
|
| 1321 |
+
"visibility": null,
|
| 1322 |
+
"width": null
|
| 1323 |
+
}
|
| 1324 |
+
},
|
| 1325 |
+
"10861235615d4d76b7baaa40cffbbdef": {
|
| 1326 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1327 |
+
"model_name": "ProgressStyleModel",
|
| 1328 |
+
"model_module_version": "1.5.0",
|
| 1329 |
+
"state": {
|
| 1330 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1331 |
+
"_model_module_version": "1.5.0",
|
| 1332 |
+
"_model_name": "ProgressStyleModel",
|
| 1333 |
+
"_view_count": null,
|
| 1334 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1335 |
+
"_view_module_version": "1.2.0",
|
| 1336 |
+
"_view_name": "StyleView",
|
| 1337 |
+
"bar_color": null,
|
| 1338 |
+
"description_width": ""
|
| 1339 |
+
}
|
| 1340 |
+
},
|
| 1341 |
+
"cda61cbf54884c3aa98127049dad33bf": {
|
| 1342 |
+
"model_module": "@jupyter-widgets/base",
|
| 1343 |
+
"model_name": "LayoutModel",
|
| 1344 |
+
"model_module_version": "1.2.0",
|
| 1345 |
+
"state": {
|
| 1346 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1347 |
+
"_model_module_version": "1.2.0",
|
| 1348 |
+
"_model_name": "LayoutModel",
|
| 1349 |
+
"_view_count": null,
|
| 1350 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1351 |
+
"_view_module_version": "1.2.0",
|
| 1352 |
+
"_view_name": "LayoutView",
|
| 1353 |
+
"align_content": null,
|
| 1354 |
+
"align_items": null,
|
| 1355 |
+
"align_self": null,
|
| 1356 |
+
"border": null,
|
| 1357 |
+
"bottom": null,
|
| 1358 |
+
"display": null,
|
| 1359 |
+
"flex": null,
|
| 1360 |
+
"flex_flow": null,
|
| 1361 |
+
"grid_area": null,
|
| 1362 |
+
"grid_auto_columns": null,
|
| 1363 |
+
"grid_auto_flow": null,
|
| 1364 |
+
"grid_auto_rows": null,
|
| 1365 |
+
"grid_column": null,
|
| 1366 |
+
"grid_gap": null,
|
| 1367 |
+
"grid_row": null,
|
| 1368 |
+
"grid_template_areas": null,
|
| 1369 |
+
"grid_template_columns": null,
|
| 1370 |
+
"grid_template_rows": null,
|
| 1371 |
+
"height": null,
|
| 1372 |
+
"justify_content": null,
|
| 1373 |
+
"justify_items": null,
|
| 1374 |
+
"left": null,
|
| 1375 |
+
"margin": null,
|
| 1376 |
+
"max_height": null,
|
| 1377 |
+
"max_width": null,
|
| 1378 |
+
"min_height": null,
|
| 1379 |
+
"min_width": null,
|
| 1380 |
+
"object_fit": null,
|
| 1381 |
+
"object_position": null,
|
| 1382 |
+
"order": null,
|
| 1383 |
+
"overflow": null,
|
| 1384 |
+
"overflow_x": null,
|
| 1385 |
+
"overflow_y": null,
|
| 1386 |
+
"padding": null,
|
| 1387 |
+
"right": null,
|
| 1388 |
+
"top": null,
|
| 1389 |
+
"visibility": null,
|
| 1390 |
+
"width": null
|
| 1391 |
+
}
|
| 1392 |
+
},
|
| 1393 |
+
"1c8d0998a1cc4d70af29c394c2949506": {
|
| 1394 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1395 |
+
"model_name": "DescriptionStyleModel",
|
| 1396 |
+
"model_module_version": "1.5.0",
|
| 1397 |
+
"state": {
|
| 1398 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1399 |
+
"_model_module_version": "1.5.0",
|
| 1400 |
+
"_model_name": "DescriptionStyleModel",
|
| 1401 |
+
"_view_count": null,
|
| 1402 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1403 |
+
"_view_module_version": "1.2.0",
|
| 1404 |
+
"_view_name": "StyleView",
|
| 1405 |
+
"description_width": ""
|
| 1406 |
+
}
|
| 1407 |
+
},
|
| 1408 |
+
"15f431ee684f448f897b20b1f4f4a3b1": {
|
| 1409 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1410 |
+
"model_name": "HBoxModel",
|
| 1411 |
+
"model_module_version": "1.5.0",
|
| 1412 |
+
"state": {
|
| 1413 |
+
"_dom_classes": [],
|
| 1414 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1415 |
+
"_model_module_version": "1.5.0",
|
| 1416 |
+
"_model_name": "HBoxModel",
|
| 1417 |
+
"_view_count": null,
|
| 1418 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1419 |
+
"_view_module_version": "1.5.0",
|
| 1420 |
+
"_view_name": "HBoxView",
|
| 1421 |
+
"box_style": "",
|
| 1422 |
+
"children": [
|
| 1423 |
+
"IPY_MODEL_a50de1c0ccc443f5a2a9fe9a791b02f6",
|
| 1424 |
+
"IPY_MODEL_afb39d22095b428da144710b43785445",
|
| 1425 |
+
"IPY_MODEL_3ee0b4fe1e5f4226bf25f0d8f301198f"
|
| 1426 |
+
],
|
| 1427 |
+
"layout": "IPY_MODEL_b1dd37ad15bb4de6982db3c967021ae6"
|
| 1428 |
+
}
|
| 1429 |
+
},
|
| 1430 |
+
"a50de1c0ccc443f5a2a9fe9a791b02f6": {
|
| 1431 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1432 |
+
"model_name": "HTMLModel",
|
| 1433 |
+
"model_module_version": "1.5.0",
|
| 1434 |
+
"state": {
|
| 1435 |
+
"_dom_classes": [],
|
| 1436 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1437 |
+
"_model_module_version": "1.5.0",
|
| 1438 |
+
"_model_name": "HTMLModel",
|
| 1439 |
+
"_view_count": null,
|
| 1440 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1441 |
+
"_view_module_version": "1.5.0",
|
| 1442 |
+
"_view_name": "HTMLView",
|
| 1443 |
+
"description": "",
|
| 1444 |
+
"description_tooltip": null,
|
| 1445 |
+
"layout": "IPY_MODEL_1fad9d81479d4dc4ae7a0573bd965b93",
|
| 1446 |
+
"placeholder": "",
|
| 1447 |
+
"style": "IPY_MODEL_bab7bc50bb5e45caad41bcb7f4da2b98",
|
| 1448 |
+
"value": "Loading weights: 100%"
|
| 1449 |
+
}
|
| 1450 |
+
},
|
| 1451 |
+
"afb39d22095b428da144710b43785445": {
|
| 1452 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1453 |
+
"model_name": "FloatProgressModel",
|
| 1454 |
+
"model_module_version": "1.5.0",
|
| 1455 |
+
"state": {
|
| 1456 |
+
"_dom_classes": [],
|
| 1457 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1458 |
+
"_model_module_version": "1.5.0",
|
| 1459 |
+
"_model_name": "FloatProgressModel",
|
| 1460 |
+
"_view_count": null,
|
| 1461 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1462 |
+
"_view_module_version": "1.5.0",
|
| 1463 |
+
"_view_name": "ProgressView",
|
| 1464 |
+
"bar_style": "success",
|
| 1465 |
+
"description": "",
|
| 1466 |
+
"description_tooltip": null,
|
| 1467 |
+
"layout": "IPY_MODEL_d967b31fab6b402db5fa1ee4cd382044",
|
| 1468 |
+
"max": 384,
|
| 1469 |
+
"min": 0,
|
| 1470 |
+
"orientation": "horizontal",
|
| 1471 |
+
"style": "IPY_MODEL_aaccf77482b24a1ba9883d9601ebda81",
|
| 1472 |
+
"value": 384
|
| 1473 |
+
}
|
| 1474 |
+
},
|
| 1475 |
+
"3ee0b4fe1e5f4226bf25f0d8f301198f": {
|
| 1476 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1477 |
+
"model_name": "HTMLModel",
|
| 1478 |
+
"model_module_version": "1.5.0",
|
| 1479 |
+
"state": {
|
| 1480 |
+
"_dom_classes": [],
|
| 1481 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1482 |
+
"_model_module_version": "1.5.0",
|
| 1483 |
+
"_model_name": "HTMLModel",
|
| 1484 |
+
"_view_count": null,
|
| 1485 |
+
"_view_module": "@jupyter-widgets/controls",
|
| 1486 |
+
"_view_module_version": "1.5.0",
|
| 1487 |
+
"_view_name": "HTMLView",
|
| 1488 |
+
"description": "",
|
| 1489 |
+
"description_tooltip": null,
|
| 1490 |
+
"layout": "IPY_MODEL_b9e7c10eb925420fae0440946a62dcb3",
|
| 1491 |
+
"placeholder": "",
|
| 1492 |
+
"style": "IPY_MODEL_16b56cb978bf4951abd8c093c65f9c60",
|
| 1493 |
+
"value": " 384/384 [00:00<00:00, 4076.86it/s]"
|
| 1494 |
+
}
|
| 1495 |
+
},
|
| 1496 |
+
"b1dd37ad15bb4de6982db3c967021ae6": {
|
| 1497 |
+
"model_module": "@jupyter-widgets/base",
|
| 1498 |
+
"model_name": "LayoutModel",
|
| 1499 |
+
"model_module_version": "1.2.0",
|
| 1500 |
+
"state": {
|
| 1501 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1502 |
+
"_model_module_version": "1.2.0",
|
| 1503 |
+
"_model_name": "LayoutModel",
|
| 1504 |
+
"_view_count": null,
|
| 1505 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1506 |
+
"_view_module_version": "1.2.0",
|
| 1507 |
+
"_view_name": "LayoutView",
|
| 1508 |
+
"align_content": null,
|
| 1509 |
+
"align_items": null,
|
| 1510 |
+
"align_self": null,
|
| 1511 |
+
"border": null,
|
| 1512 |
+
"bottom": null,
|
| 1513 |
+
"display": null,
|
| 1514 |
+
"flex": null,
|
| 1515 |
+
"flex_flow": null,
|
| 1516 |
+
"grid_area": null,
|
| 1517 |
+
"grid_auto_columns": null,
|
| 1518 |
+
"grid_auto_flow": null,
|
| 1519 |
+
"grid_auto_rows": null,
|
| 1520 |
+
"grid_column": null,
|
| 1521 |
+
"grid_gap": null,
|
| 1522 |
+
"grid_row": null,
|
| 1523 |
+
"grid_template_areas": null,
|
| 1524 |
+
"grid_template_columns": null,
|
| 1525 |
+
"grid_template_rows": null,
|
| 1526 |
+
"height": null,
|
| 1527 |
+
"justify_content": null,
|
| 1528 |
+
"justify_items": null,
|
| 1529 |
+
"left": null,
|
| 1530 |
+
"margin": null,
|
| 1531 |
+
"max_height": null,
|
| 1532 |
+
"max_width": null,
|
| 1533 |
+
"min_height": null,
|
| 1534 |
+
"min_width": null,
|
| 1535 |
+
"object_fit": null,
|
| 1536 |
+
"object_position": null,
|
| 1537 |
+
"order": null,
|
| 1538 |
+
"overflow": null,
|
| 1539 |
+
"overflow_x": null,
|
| 1540 |
+
"overflow_y": null,
|
| 1541 |
+
"padding": null,
|
| 1542 |
+
"right": null,
|
| 1543 |
+
"top": null,
|
| 1544 |
+
"visibility": null,
|
| 1545 |
+
"width": null
|
| 1546 |
+
}
|
| 1547 |
+
},
|
| 1548 |
+
"1fad9d81479d4dc4ae7a0573bd965b93": {
|
| 1549 |
+
"model_module": "@jupyter-widgets/base",
|
| 1550 |
+
"model_name": "LayoutModel",
|
| 1551 |
+
"model_module_version": "1.2.0",
|
| 1552 |
+
"state": {
|
| 1553 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1554 |
+
"_model_module_version": "1.2.0",
|
| 1555 |
+
"_model_name": "LayoutModel",
|
| 1556 |
+
"_view_count": null,
|
| 1557 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1558 |
+
"_view_module_version": "1.2.0",
|
| 1559 |
+
"_view_name": "LayoutView",
|
| 1560 |
+
"align_content": null,
|
| 1561 |
+
"align_items": null,
|
| 1562 |
+
"align_self": null,
|
| 1563 |
+
"border": null,
|
| 1564 |
+
"bottom": null,
|
| 1565 |
+
"display": null,
|
| 1566 |
+
"flex": null,
|
| 1567 |
+
"flex_flow": null,
|
| 1568 |
+
"grid_area": null,
|
| 1569 |
+
"grid_auto_columns": null,
|
| 1570 |
+
"grid_auto_flow": null,
|
| 1571 |
+
"grid_auto_rows": null,
|
| 1572 |
+
"grid_column": null,
|
| 1573 |
+
"grid_gap": null,
|
| 1574 |
+
"grid_row": null,
|
| 1575 |
+
"grid_template_areas": null,
|
| 1576 |
+
"grid_template_columns": null,
|
| 1577 |
+
"grid_template_rows": null,
|
| 1578 |
+
"height": null,
|
| 1579 |
+
"justify_content": null,
|
| 1580 |
+
"justify_items": null,
|
| 1581 |
+
"left": null,
|
| 1582 |
+
"margin": null,
|
| 1583 |
+
"max_height": null,
|
| 1584 |
+
"max_width": null,
|
| 1585 |
+
"min_height": null,
|
| 1586 |
+
"min_width": null,
|
| 1587 |
+
"object_fit": null,
|
| 1588 |
+
"object_position": null,
|
| 1589 |
+
"order": null,
|
| 1590 |
+
"overflow": null,
|
| 1591 |
+
"overflow_x": null,
|
| 1592 |
+
"overflow_y": null,
|
| 1593 |
+
"padding": null,
|
| 1594 |
+
"right": null,
|
| 1595 |
+
"top": null,
|
| 1596 |
+
"visibility": null,
|
| 1597 |
+
"width": null
|
| 1598 |
+
}
|
| 1599 |
+
},
|
| 1600 |
+
"bab7bc50bb5e45caad41bcb7f4da2b98": {
|
| 1601 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1602 |
+
"model_name": "DescriptionStyleModel",
|
| 1603 |
+
"model_module_version": "1.5.0",
|
| 1604 |
+
"state": {
|
| 1605 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1606 |
+
"_model_module_version": "1.5.0",
|
| 1607 |
+
"_model_name": "DescriptionStyleModel",
|
| 1608 |
+
"_view_count": null,
|
| 1609 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1610 |
+
"_view_module_version": "1.2.0",
|
| 1611 |
+
"_view_name": "StyleView",
|
| 1612 |
+
"description_width": ""
|
| 1613 |
+
}
|
| 1614 |
+
},
|
| 1615 |
+
"d967b31fab6b402db5fa1ee4cd382044": {
|
| 1616 |
+
"model_module": "@jupyter-widgets/base",
|
| 1617 |
+
"model_name": "LayoutModel",
|
| 1618 |
+
"model_module_version": "1.2.0",
|
| 1619 |
+
"state": {
|
| 1620 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1621 |
+
"_model_module_version": "1.2.0",
|
| 1622 |
+
"_model_name": "LayoutModel",
|
| 1623 |
+
"_view_count": null,
|
| 1624 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1625 |
+
"_view_module_version": "1.2.0",
|
| 1626 |
+
"_view_name": "LayoutView",
|
| 1627 |
+
"align_content": null,
|
| 1628 |
+
"align_items": null,
|
| 1629 |
+
"align_self": null,
|
| 1630 |
+
"border": null,
|
| 1631 |
+
"bottom": null,
|
| 1632 |
+
"display": null,
|
| 1633 |
+
"flex": null,
|
| 1634 |
+
"flex_flow": null,
|
| 1635 |
+
"grid_area": null,
|
| 1636 |
+
"grid_auto_columns": null,
|
| 1637 |
+
"grid_auto_flow": null,
|
| 1638 |
+
"grid_auto_rows": null,
|
| 1639 |
+
"grid_column": null,
|
| 1640 |
+
"grid_gap": null,
|
| 1641 |
+
"grid_row": null,
|
| 1642 |
+
"grid_template_areas": null,
|
| 1643 |
+
"grid_template_columns": null,
|
| 1644 |
+
"grid_template_rows": null,
|
| 1645 |
+
"height": null,
|
| 1646 |
+
"justify_content": null,
|
| 1647 |
+
"justify_items": null,
|
| 1648 |
+
"left": null,
|
| 1649 |
+
"margin": null,
|
| 1650 |
+
"max_height": null,
|
| 1651 |
+
"max_width": null,
|
| 1652 |
+
"min_height": null,
|
| 1653 |
+
"min_width": null,
|
| 1654 |
+
"object_fit": null,
|
| 1655 |
+
"object_position": null,
|
| 1656 |
+
"order": null,
|
| 1657 |
+
"overflow": null,
|
| 1658 |
+
"overflow_x": null,
|
| 1659 |
+
"overflow_y": null,
|
| 1660 |
+
"padding": null,
|
| 1661 |
+
"right": null,
|
| 1662 |
+
"top": null,
|
| 1663 |
+
"visibility": null,
|
| 1664 |
+
"width": null
|
| 1665 |
+
}
|
| 1666 |
+
},
|
| 1667 |
+
"aaccf77482b24a1ba9883d9601ebda81": {
|
| 1668 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1669 |
+
"model_name": "ProgressStyleModel",
|
| 1670 |
+
"model_module_version": "1.5.0",
|
| 1671 |
+
"state": {
|
| 1672 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1673 |
+
"_model_module_version": "1.5.0",
|
| 1674 |
+
"_model_name": "ProgressStyleModel",
|
| 1675 |
+
"_view_count": null,
|
| 1676 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1677 |
+
"_view_module_version": "1.2.0",
|
| 1678 |
+
"_view_name": "StyleView",
|
| 1679 |
+
"bar_color": null,
|
| 1680 |
+
"description_width": ""
|
| 1681 |
+
}
|
| 1682 |
+
},
|
| 1683 |
+
"b9e7c10eb925420fae0440946a62dcb3": {
|
| 1684 |
+
"model_module": "@jupyter-widgets/base",
|
| 1685 |
+
"model_name": "LayoutModel",
|
| 1686 |
+
"model_module_version": "1.2.0",
|
| 1687 |
+
"state": {
|
| 1688 |
+
"_model_module": "@jupyter-widgets/base",
|
| 1689 |
+
"_model_module_version": "1.2.0",
|
| 1690 |
+
"_model_name": "LayoutModel",
|
| 1691 |
+
"_view_count": null,
|
| 1692 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1693 |
+
"_view_module_version": "1.2.0",
|
| 1694 |
+
"_view_name": "LayoutView",
|
| 1695 |
+
"align_content": null,
|
| 1696 |
+
"align_items": null,
|
| 1697 |
+
"align_self": null,
|
| 1698 |
+
"border": null,
|
| 1699 |
+
"bottom": null,
|
| 1700 |
+
"display": null,
|
| 1701 |
+
"flex": null,
|
| 1702 |
+
"flex_flow": null,
|
| 1703 |
+
"grid_area": null,
|
| 1704 |
+
"grid_auto_columns": null,
|
| 1705 |
+
"grid_auto_flow": null,
|
| 1706 |
+
"grid_auto_rows": null,
|
| 1707 |
+
"grid_column": null,
|
| 1708 |
+
"grid_gap": null,
|
| 1709 |
+
"grid_row": null,
|
| 1710 |
+
"grid_template_areas": null,
|
| 1711 |
+
"grid_template_columns": null,
|
| 1712 |
+
"grid_template_rows": null,
|
| 1713 |
+
"height": null,
|
| 1714 |
+
"justify_content": null,
|
| 1715 |
+
"justify_items": null,
|
| 1716 |
+
"left": null,
|
| 1717 |
+
"margin": null,
|
| 1718 |
+
"max_height": null,
|
| 1719 |
+
"max_width": null,
|
| 1720 |
+
"min_height": null,
|
| 1721 |
+
"min_width": null,
|
| 1722 |
+
"object_fit": null,
|
| 1723 |
+
"object_position": null,
|
| 1724 |
+
"order": null,
|
| 1725 |
+
"overflow": null,
|
| 1726 |
+
"overflow_x": null,
|
| 1727 |
+
"overflow_y": null,
|
| 1728 |
+
"padding": null,
|
| 1729 |
+
"right": null,
|
| 1730 |
+
"top": null,
|
| 1731 |
+
"visibility": null,
|
| 1732 |
+
"width": null
|
| 1733 |
+
}
|
| 1734 |
+
},
|
| 1735 |
+
"16b56cb978bf4951abd8c093c65f9c60": {
|
| 1736 |
+
"model_module": "@jupyter-widgets/controls",
|
| 1737 |
+
"model_name": "DescriptionStyleModel",
|
| 1738 |
+
"model_module_version": "1.5.0",
|
| 1739 |
+
"state": {
|
| 1740 |
+
"_model_module": "@jupyter-widgets/controls",
|
| 1741 |
+
"_model_module_version": "1.5.0",
|
| 1742 |
+
"_model_name": "DescriptionStyleModel",
|
| 1743 |
+
"_view_count": null,
|
| 1744 |
+
"_view_module": "@jupyter-widgets/base",
|
| 1745 |
+
"_view_module_version": "1.2.0",
|
| 1746 |
+
"_view_name": "StyleView",
|
| 1747 |
+
"description_width": ""
|
| 1748 |
+
}
|
| 1749 |
+
}
|
| 1750 |
+
}
|
| 1751 |
+
}
|
| 1752 |
+
},
|
| 1753 |
+
"nbformat": 4,
|
| 1754 |
+
"nbformat_minor": 0
|
| 1755 |
+
}
|
ViSum_Training.py
ADDED
|
@@ -0,0 +1,149 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""
|
| 2 |
+
ViSum - QLoRA Fine-tune BARTpho trên 144K mẫu VietNews (5 Epochs)
|
| 3 |
+
GPU: RTX 3090 24GB
|
| 4 |
+
Author: OrdinaryAI
|
| 5 |
+
"""
|
| 6 |
+
|
| 7 |
+
from datasets import load_dataset
|
| 8 |
+
from transformers import (
|
| 9 |
+
AutoTokenizer, AutoModelForSeq2SeqLM,
|
| 10 |
+
Seq2SeqTrainingArguments, Seq2SeqTrainer,
|
| 11 |
+
DataCollatorForSeq2Seq, BitsAndBytesConfig,
|
| 12 |
+
)
|
| 13 |
+
from peft import LoraConfig, get_peft_model, TaskType, prepare_model_for_kbit_training
|
| 14 |
+
import torch
|
| 15 |
+
import os
|
| 16 |
+
|
| 17 |
+
# ============================================
|
| 18 |
+
# 1. LOAD DATASET (144K MẪU)
|
| 19 |
+
# ============================================
|
| 20 |
+
print("=" * 60)
|
| 21 |
+
print("BƯỚC 1: Load dataset VietNews (144K mẫu)")
|
| 22 |
+
print("=" * 60)
|
| 23 |
+
dataset = load_dataset("harouzie/vietnews")
|
| 24 |
+
train_data = dataset['train'] # 99.134 mẫu
|
| 25 |
+
val_data = dataset['validation'] # 22.184 mẫu
|
| 26 |
+
print(f"Train: {len(train_data)} | Val: {len(val_data)}")
|
| 27 |
+
|
| 28 |
+
# ============================================
|
| 29 |
+
# 2. TOKENIZE
|
| 30 |
+
# ============================================
|
| 31 |
+
print("\n" + "=" * 60)
|
| 32 |
+
print("BƯỚC 2: Tokenize")
|
| 33 |
+
print("=" * 60)
|
| 34 |
+
MODEL_NAME = "vinai/bartpho-syllable"
|
| 35 |
+
tokenizer = AutoTokenizer.from_pretrained(MODEL_NAME)
|
| 36 |
+
|
| 37 |
+
def preprocess(examples):
|
| 38 |
+
inputs = tokenizer(examples['article'], max_length=512, truncation=True)
|
| 39 |
+
labels = tokenizer(examples['abstract'], max_length=128, truncation=True)
|
| 40 |
+
inputs['labels'] = labels['input_ids']
|
| 41 |
+
return inputs
|
| 42 |
+
|
| 43 |
+
tokenized_train = train_data.map(
|
| 44 |
+
preprocess, batched=True,
|
| 45 |
+
remove_columns=train_data.column_names
|
| 46 |
+
)
|
| 47 |
+
tokenized_val = val_data.map(
|
| 48 |
+
preprocess, batched=True,
|
| 49 |
+
remove_columns=val_data.column_names
|
| 50 |
+
)
|
| 51 |
+
print(f"Tokenized: {len(tokenized_train)} train | {len(tokenized_val)} val")
|
| 52 |
+
|
| 53 |
+
# ============================================
|
| 54 |
+
# 3. QLoRA CONFIG + LOAD MODEL
|
| 55 |
+
# ============================================
|
| 56 |
+
print("\n" + "=" * 60)
|
| 57 |
+
print("BƯỚC 3: Load Model với QLoRA (4-bit)")
|
| 58 |
+
print("=" * 60)
|
| 59 |
+
bnb_config = BitsAndBytesConfig(
|
| 60 |
+
load_in_4bit=True,
|
| 61 |
+
bnb_4bit_quant_type="nf4",
|
| 62 |
+
bnb_4bit_compute_dtype=torch.float16,
|
| 63 |
+
bnb_4bit_use_double_quant=True,
|
| 64 |
+
)
|
| 65 |
+
|
| 66 |
+
model = AutoModelForSeq2SeqLM.from_pretrained(
|
| 67 |
+
MODEL_NAME,
|
| 68 |
+
quantization_config=bnb_config,
|
| 69 |
+
device_map="auto",
|
| 70 |
+
)
|
| 71 |
+
model = prepare_model_for_kbit_training(model)
|
| 72 |
+
|
| 73 |
+
lora_config = LoraConfig(
|
| 74 |
+
r=16, lora_alpha=32,
|
| 75 |
+
target_modules=["q_proj", "v_proj", "k_proj", "out_proj", "fc1", "fc2"],
|
| 76 |
+
lora_dropout=0.1, bias="none",
|
| 77 |
+
task_type=TaskType.SEQ_2_SEQ_LM,
|
| 78 |
+
)
|
| 79 |
+
model = get_peft_model(model, lora_config)
|
| 80 |
+
print("Trainable parameters: ", end="")
|
| 81 |
+
model.print_trainable_parameters()
|
| 82 |
+
|
| 83 |
+
data_collator = DataCollatorForSeq2Seq(tokenizer=tokenizer, model=model)
|
| 84 |
+
|
| 85 |
+
# ============================================
|
| 86 |
+
# 4. TRAINING (5 EPOCHS)
|
| 87 |
+
# ============================================
|
| 88 |
+
print("\n" + "=" * 60)
|
| 89 |
+
print("BƯỚC 4: Train 5 Epochs")
|
| 90 |
+
print("=" * 60)
|
| 91 |
+
|
| 92 |
+
training_args = Seq2SeqTrainingArguments(
|
| 93 |
+
output_dir="./visum-qlora-5epochs",
|
| 94 |
+
eval_strategy="epoch",
|
| 95 |
+
save_strategy="epoch",
|
| 96 |
+
logging_steps=500,
|
| 97 |
+
per_device_train_batch_size=8,
|
| 98 |
+
gradient_accumulation_steps=2,
|
| 99 |
+
per_device_eval_batch_size=8,
|
| 100 |
+
learning_rate=2e-4,
|
| 101 |
+
num_train_epochs=5, # ← 5 EPOCHS
|
| 102 |
+
predict_with_generate=True,
|
| 103 |
+
generation_max_length=150,
|
| 104 |
+
fp16=True,
|
| 105 |
+
save_total_limit=5,
|
| 106 |
+
report_to="none",
|
| 107 |
+
load_best_model_at_end=True,
|
| 108 |
+
metric_for_best_model="eval_loss",
|
| 109 |
+
greater_is_better=False,
|
| 110 |
+
)
|
| 111 |
+
|
| 112 |
+
trainer = Seq2SeqTrainer(
|
| 113 |
+
model=model,
|
| 114 |
+
args=training_args,
|
| 115 |
+
train_dataset=tokenized_train,
|
| 116 |
+
eval_dataset=tokenized_val,
|
| 117 |
+
processing_class=tokenizer,
|
| 118 |
+
data_collator=data_collator,
|
| 119 |
+
)
|
| 120 |
+
|
| 121 |
+
print("🚀 Bắt đầu train 144K mẫu - 5 epochs...")
|
| 122 |
+
print(f"⏱️ Dự kiến: ~24 tiếng (mỗi epoch ~4.8 tiếng)")
|
| 123 |
+
|
| 124 |
+
trainer.train()
|
| 125 |
+
|
| 126 |
+
# ============================================
|
| 127 |
+
# 5. LƯU MODEL
|
| 128 |
+
# ============================================
|
| 129 |
+
print("\n" + "=" * 60)
|
| 130 |
+
print("BƯỚC 5: Lưu Model")
|
| 131 |
+
print("=" * 60)
|
| 132 |
+
model.save_pretrained("./visum-qlora-5epochs")
|
| 133 |
+
tokenizer.save_pretrained("./visum-qlora-5epochs")
|
| 134 |
+
print("✅ Done! Model saved to ./visum-qlora-5epochs")
|
| 135 |
+
|
| 136 |
+
# ============================================
|
| 137 |
+
# 6. THÔNG TIN HUẤN LUYỆN
|
| 138 |
+
# ============================================
|
| 139 |
+
print("\n" + "=" * 60)
|
| 140 |
+
print("THÔNG TIN HUẤN LUYỆN")
|
| 141 |
+
print("=" * 60)
|
| 142 |
+
print(f" Model gốc: {MODEL_NAME}")
|
| 143 |
+
print(f" Dataset: harouzie/vietnews (144K mẫu)")
|
| 144 |
+
print(f" Phương pháp: QLoRA (4-bit) + LoRA (r=16, alpha=32)")
|
| 145 |
+
print(f" Epochs: 5")
|
| 146 |
+
print(f" Batch size: 8 × gradient_accumulation 2 = 16")
|
| 147 |
+
print(f" Learning rate: 2e-4")
|
| 148 |
+
print(f" GPU: NVIDIA GeForce RTX 3090 24GB")
|
| 149 |
+
print(f" Thư mục output: ./visum-qlora-5epochs")
|
error_analysis.txt
ADDED
|
@@ -0,0 +1,134 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
============================================================
|
| 2 |
+
BÁO CÁO PHÂN TÍCH LỖI TÓM TẮT
|
| 3 |
+
============================================================
|
| 4 |
+
|
| 5 |
+
Model: OrdinaryAI/visum-qlora-5epochs
|
| 6 |
+
ROUGE-1: 0.5791
|
| 7 |
+
ROUGE-2: 0.2684
|
| 8 |
+
ROUGE-L: 0.3826
|
| 9 |
+
|
| 10 |
+
--- TOP 10 MẪU CÓ ĐIỂM THẤP NHẤT ---
|
| 11 |
+
|
| 12 |
+
[Mẫu lỗi #1]
|
| 13 |
+
ROUGE-L: 0.1707 | ROUGE-1: 0.3171
|
| 14 |
+
Tham chiếu (Gold): Bạn mong ước một tổ ấm hạnh phúc hay một chiếc xe tiện nghi cho cả gia đình ? Bạn mong ước một cửa hàng của riêng mình hoặc một tương lai vững chắc cho con ?
|
| 15 |
+
Model viết: Ngânhàng TMCP Ngoạithương ViệtNam ( VietinBank ) vừa côngbố chươngtrình khuyếnmạng " Live Bigger - Sống tận hưởng " .
|
| 16 |
+
----------------------------------------
|
| 17 |
+
|
| 18 |
+
[Mẫu lỗi #2]
|
| 19 |
+
ROUGE-L: 0.1803 | ROUGE-1: 0.2787
|
| 20 |
+
Tham chiếu (Gold): Trước khi Lý Thái Tổ định đô trên nền thành Đại La đổ nát thì mảnh đất này có rất nhiều sông ngòi , hồ ao , kênh rạch và nối dòng với sông Hồng . Phía bắc của hồ Lục Thuỷ ( Hồ Gươm ngày nay ) có hồ Diên Hưng ( khu vực phố Hàng Ngang hiện nay ) , hồ Thái Cực ( khu vực phố Hàng Bè hiện nay ) .
|
| 21 |
+
Model viết: Truyềnthuyết Lê Lợi trả lại gươm thần cho rùa vàng sau khi đánh tan giặc Minh .
|
| 22 |
+
----------------------------------------
|
| 23 |
+
|
| 24 |
+
[Mẫu lỗi #3]
|
| 25 |
+
ROUGE-L: 0.1897 | ROUGE-1: 0.4310
|
| 26 |
+
Tham chiếu (Gold): 2 người trúng đạn , phải nhập viện cấp cứu sau cuộc hỗn chiến giữa 2 nhóm người trên Đại lộ Lê Nin , TP . Vinh ( Nghệ An ) .
|
| 27 |
+
Model viết: Khi bắt taxi đến điểm hẹn , anh Lê Ngọc Anh thấy Định đang bị một nhóm người cầm ghế , cốc đuổi theo phía sau . Thấy một người cầm súng bắn , Ngọc Anh lao đến thì bị bắn vào vai . Anh Ngọc Anh sau đó áp sát và tước được khẩu súng .
|
| 28 |
+
----------------------------------------
|
| 29 |
+
|
| 30 |
+
[Mẫu lỗi #4]
|
| 31 |
+
ROUGE-L: 0.1975 | ROUGE-1: 0.3951
|
| 32 |
+
Tham chiếu (Gold): Đại diện Việt Nam - Bùi Phương Nga vươn lên vị trí số 2/76 trong bảng xếp hạng Miss Popular Vote .
|
| 33 |
+
Model viết: Nếu xuất sắc vượt qua Lika Dy đến từ Campuchia , Phương Nga sẽ chính thức được gọi tên vào Top 10 trong đêm chung kết diễn ra vào 17h30 tối nay 25/10 ( giờ Việt Nam ) .
|
| 34 |
+
----------------------------------------
|
| 35 |
+
|
| 36 |
+
[Mẫu lỗi #5]
|
| 37 |
+
ROUGE-L: 0.2097 | ROUGE-1: 0.4677
|
| 38 |
+
Tham chiếu (Gold): Một giờ học code , nhóm trẻ em từ 5 đến 8 tuổi tham gia lớp Kids can code được giới thiệu , truyền cảm hứng về ngôn ngữ máy tính . Đây là buổi học thử nghiệm diễn ra vào sáng 5-1 trong không gian cạnh Thảo cầm viên , TP . HCM .
|
| 39 |
+
Model viết: Tối 20-5 , tại TP . HCM , Côngty Appable phốihợp với Moonlab tổchức chươngtrình ' Học lập trình bằng lắp ráp thẻ hình ' cho trẻem tại mái ấm Hạnh Phúc .
|
| 40 |
+
----------------------------------------
|
| 41 |
+
|
| 42 |
+
[Mẫu lỗi #6]
|
| 43 |
+
ROUGE-L: 0.2124 | ROUGE-1: 0.5133
|
| 44 |
+
Tham chiếu (Gold): Ở tuổi 41 nam chính trong phim " Giày thuỷ tinh " đã gặt hái được nhiều thành công trong sự nghiệp khiến nhiều người phải khao khát , nhưng trong tình duyên anh lại lận đận và vẫn đang miệt mài đi tìm hạnh phúc cho riêng mình .
|
| 45 |
+
Model viết: Sau nhiều năm " chìm nghỉm " trong showbiz , So Ji Sub một bước vụt sáng thành sao nhờ vai diễn ấn tượng trong dự án ăn khách Giày thuỷ tinh .
|
| 46 |
+
----------------------------------------
|
| 47 |
+
|
| 48 |
+
[Mẫu lỗi #7]
|
| 49 |
+
ROUGE-L: 0.2222 | ROUGE-1: 0.3556
|
| 50 |
+
Tham chiếu (Gold): Tờ Wall Street Journal cuối tuần trước tiết lộ rằng chính quyền Mỹ đã tăng sức ép , thúc giục các đồng minh ' nói không ' với Huawei vì an ninh quốc gia .
|
| 51 |
+
Model viết: Sau khi Tổngthống Mỹ DonaldTrump tuyênbố chiếntranh thươngmại với TrungQuốc đang bước vào giaiđoạn mới , nhiều quốcgia đồngminh của Mỹ đã bàytỏ quanđiểm cứngrắn .
|
| 52 |
+
----------------------------------------
|
| 53 |
+
|
| 54 |
+
[Mẫu lỗi #8]
|
| 55 |
+
ROUGE-L: 0.2264 | ROUGE-1: 0.3396
|
| 56 |
+
Tham chiếu (Gold): Lãnh đạo Việt Nam có chuyến thăm hai ngày đến Đức theo lời mời của Ngoại trưởng Đức Heiko Maas .
|
| 57 |
+
Model viết: Phó thủtướng PhạmBìnhMin sẽ thăm chínhthức Đức trong hai ngày 20/2 và 21/2 .
|
| 58 |
+
----------------------------------------
|
| 59 |
+
|
| 60 |
+
[Mẫu lỗi #9]
|
| 61 |
+
ROUGE-L: 0.2264 | ROUGE-1: 0.4717
|
| 62 |
+
Tham chiếu (Gold): Sau khi đốt nhà bà ngoại , ôm bình gas cố thủ , xả gas khiến 4 cán bộ công an bị thương , Phong đã bỏ trốn khỏi địa phương . Hơn 2 năm bị truy nã , Phong đã bị công an bắt giữ .
|
| 63 |
+
Model viết: Côngan quận Đồ Sơn , TP . Hải Phòng đang tạm giữ đốitượng Nguyễn Thành Phong ( SN 1994 , trú tại tổ dân phố Độc Lập , phường Ngọc Hải ) để điều tra về hành vi huỷ hoại tài sản .
|
| 64 |
+
----------------------------------------
|
| 65 |
+
|
| 66 |
+
[Mẫu lỗi #10]
|
| 67 |
+
ROUGE-L: 0.2353 | ROUGE-1: 0.5294
|
| 68 |
+
Tham chiếu (Gold): Bào chữa cho bị cáo Đinh La Thăng , luật sư Phan Trung Hoài đề nghị VKS xem xét lại tội danh đã truy tố thân chủ vì chưa đủ căn cứ pháp lý . Luật sư Nguyễn Huy Thiệp thì nói rằng : Xin gửi đến HĐXX niềm tin vào công lý !
|
| 69 |
+
Model viết: Trong phần xétxử ông Đinh LaThăng và đồngphạm tại Ngânhàng TMCP ĐạiDương ( Oceanbank ) , luật sư bàochữa cho ông Thăng cho rằng không có mối liên hệ nhân quả giữa các hành vi bị coi là cố ý làm trái với hậu quả thiệt hại xảy ra và cần xác định chính xác nguyên nhân PVN bị mất 800 tỉ đồng góp vốn tại Oceanbank .
|
| 70 |
+
----------------------------------------
|
| 71 |
+
|
| 72 |
+
============================================================
|
| 73 |
+
|
| 74 |
+
--- TOP 10 MẪU CÓ ĐIỂM CAO NHẤT ---
|
| 75 |
+
|
| 76 |
+
[Mẫu tốt #1]
|
| 77 |
+
ROUGE-L: 0.9550 | ROUGE-1: 0.9550
|
| 78 |
+
Tham chiếu (Gold): Đại sứ Việt Nam tại Ai Cập Trần Thành Công đã đến hiện trường và tới bệnh viện Al Haram nơi điều trị của các nạn nhân để thăm hỏi , động viên và nắm tình hình .
|
| 79 |
+
Model viết: Đại sứ ViệtNam tại Ai Cập Trần Thành Công đã đến hiện trường và tới bệnh viện Al Haram nơi điều trị các nạn nhân để thăm hỏi , động viên và nắm tình hình .
|
| 80 |
+
----------------------------------------
|
| 81 |
+
|
| 82 |
+
[Mẫu tốt #2]
|
| 83 |
+
ROUGE-L: 0.9412 | ROUGE-1: 0.9412
|
| 84 |
+
Tham chiếu (Gold): Thanh tra Chính phủ vừa công bố quyết định việc điều chỉnh tổng mức kinh phí Dự án cung cấp nước cho Khu kinh tế Vũng Áng và việc được hỗ trợ từ ngân sách địa phương , tại tỉnh Hà Tĩnh .
|
| 85 |
+
Model viết: Thanhtra Chính phủ vừa côngbố quyếtđịnh thanhtra việc điều chỉnh tổng mức kinh phí Dự án cung cấp nước cho Khu kinh tế Vũng Áng và việc được hỗ trợ từ ngân sách địa phương , tại tỉnh Hà Tĩnh .
|
| 86 |
+
----------------------------------------
|
| 87 |
+
|
| 88 |
+
[Mẫu tốt #3]
|
| 89 |
+
ROUGE-L: 0.8986 | ROUGE-1: 0.9420
|
| 90 |
+
Tham chiếu (Gold): Khu sân bay Phú Quốc cũ có diện tích 78 , 88 ha với dân số tính toán trong phạm vi quy hoạch là 6 . 633 người sẽ được xây dựng thành khu đô thị có kiến trúc hiện đại , chất lượng môi trường sống tốt .
|
| 91 |
+
Model viết: Khu sân bay Phú Quốc cũ có diện tích 78 , 88 ha với dân số tính toán trong phạm vi quy hoạch là 6 . 633 người sẽ được xây dựng thành một khu đô thị hiện đại , chất lượng môi trường sống tốt , cấu trúc chặt chẽ .
|
| 92 |
+
----------------------------------------
|
| 93 |
+
|
| 94 |
+
[Mẫu tốt #4]
|
| 95 |
+
ROUGE-L: 0.8671 | ROUGE-1: 0.9371
|
| 96 |
+
Tham chiếu (Gold): Việc Anh lục soát một máy bay của hãng hàng không Nga tại sân bay Heathrow ở London là nhằm bảo vệ Anh khỏi các tội phạm có tổ chức cũng như việc buôn lậu chất gây hại , bộ An ninh Anh tuyên bố .
|
| 97 |
+
Model viết: Bộ trưởng Anninh Anh Ben Wallace tuyên bố việc Anh lục soát một máy bay của hãng hàng không Nga tại sân bay Heathrow ở London là nhằm bảo vệ Anh khỏi các tội phạm có tổ chức cũng như việc buôn lậu các chất gây hại .
|
| 98 |
+
----------------------------------------
|
| 99 |
+
|
| 100 |
+
[Mẫu tốt #5]
|
| 101 |
+
ROUGE-L: 0.8257 | ROUGE-1: 0.8440
|
| 102 |
+
Tham chiếu (Gold): Cuộc tấn công quy mô lớn diễn ra ở vùng nông thôn phía tây Aleppo , nhằm vào các vị trí của phiến quân gần khu liên hiệp Al - Zahra ' a .
|
| 103 |
+
Model viết: Quân đội Syria cùng với Liwaa Al - Quds đã phát động một cuộc tấn công quy mô lớn ở vùng nông thôn phía tây Aleppo , nhằm vào các vị trí của phiến quân gần khu liên hiệp Al - Zahra ' a .
|
| 104 |
+
----------------------------------------
|
| 105 |
+
|
| 106 |
+
[Mẫu tốt #6]
|
| 107 |
+
ROUGE-L: 0.7532 | ROUGE-1: 0.8312
|
| 108 |
+
Tham chiếu (Gold): Hiệp hội Bất động sản Việt Nam kiến nghị sửa đổi , bổ sung luật Nhà ở năm 2014 theo hướng quy định việc thế chấp nhà ở có sẵn không bắt buộc phải có giấy chứng nhận tương tự như nhà ở hình thành trong tương lai .
|
| 109 |
+
Model viết: Tại diễn đàn Bất động sản ViệtNam thường niên lần thứ nhất , đại diện Hiệp hội Bấtđộngsản kiếnnghị cần sửađổi , bổ sung luật Nhà ở theo hướng quy định việc thế chấp nhà ở có sẵn cũng không buộc phải có giấy chứng nhận , tương tự như nhà ở hình thành trong tương lai .
|
| 110 |
+
----------------------------------------
|
| 111 |
+
|
| 112 |
+
[Mẫu tốt #7]
|
| 113 |
+
ROUGE-L: 0.7253 | ROUGE-1: 0.7912
|
| 114 |
+
Tham chiếu (Gold): Các nghị sĩ Canada đồng thanh hô " thêm 4 năm " khi Tổng thống Mỹ Barack Obama kết thúc bài phát biểu tại quốc hội nước này .
|
| 115 |
+
Model viết: Các nghị sĩ Canada đứng dậy vỗ tay và hô vang " thêm 4 năm " khi Tổng thống Obama kết thúc bài phát biểu tại hội nghị thượng đỉnh Các lãnh đạo Bắc Mỹ .
|
| 116 |
+
----------------------------------------
|
| 117 |
+
|
| 118 |
+
[Mẫu tốt #8]
|
| 119 |
+
ROUGE-L: 0.7132 | ROUGE-1: 0.7907
|
| 120 |
+
Tham chiếu (Gold): Đánh giá về hoạt động chất vấn và trả lời chất vấn tại kỳ họp thứ 6 Quốc hội khoá XIV , nhiều Đại biểu cho rằng , đây chính là cuộc sát hạch lại đối với các tư lệnh ngành .
|
| 121 |
+
Model viết: Đánh giá về hoạt động chất vấn và trả lời chất vấn tại kỳ họp thứ 6 Quốc hội khoá XIV , nhiều Đại biểu Quốc hội cho rằng rất hiệu quả và chất lượng , giải quyết được nhiều vấn đề mà cử tri quan tâm .
|
| 122 |
+
----------------------------------------
|
| 123 |
+
|
| 124 |
+
[Mẫu tốt #9]
|
| 125 |
+
ROUGE-L: 0.7045 | ROUGE-1: 0.7727
|
| 126 |
+
Tham chiếu (Gold): Bộ trưởng bộ Công Thương Trần Tuấn Anh phê bình nghiêm khắc lãnh đạo cục Quản lý thị trường ( QLTT ) vì thiếu trách nhiệm , buông lỏng quản lý .
|
| 127 |
+
Model viết: Bộ trưởng bộ Công Thương Trần Tuấn Anh đã phê bình nghiêm khắc cục Quảnlý thịtrường ( QLTT ) và cánhân Cục trưởng Trịnh Văn Ngọc .
|
| 128 |
+
----------------------------------------
|
| 129 |
+
|
| 130 |
+
[Mẫu tốt #10]
|
| 131 |
+
ROUGE-L: 0.6933 | ROUGE-1: 0.7733
|
| 132 |
+
Tham chiếu (Gold): Đang lấy củi trước vườn nhà , cụ Lộc bị đàn ong vò vẽ xúm lại đốt tới 200 mũi , gây suy hô hấp , suy nội tạng .
|
| 133 |
+
Model viết: Đi lấy củi trước vườn nhà , cụ Lộc bị ong vò vẽ xúm lại đốt , suy hô hấp , mạch khó bắt , huyết áp đo được .
|
| 134 |
+
----------------------------------------
|
requirement.txt
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
streamlit>=1.28.0
|
| 2 |
+
transformers>=4.35.0
|
| 3 |
+
torch>=2.0.0
|
| 4 |
+
sentencepiece>=0.1.99
|
| 5 |
+
protobuf>=3.20.0
|
rouge_results.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|