"<!DOCTYPE html>\n<html lang=\"zh\" data-theme=\"light\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>fulltext.txt — Vercel Design System</title>\n<link rel=\"preconnect\" href=\"https://fonts.googleapis.com\">\n<link rel=\"preconnect\" href=\"https://fonts.gstatic.com\" crossorigin>\n<link href=\"https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700&family=Geist+Mono:wght@400;500;600&display=swap\" rel=\"stylesheet\">\n<link rel=\"stylesheet\" href=\"https://cdn.jsdelivr.net/npm/katex@0.16.8/dist/katex.min.css\">\n<style>\n\n:root {\n  /* Vercel Palette */\n  --geist-foreground: #171717;\n  --geist-background: #ffffff;\n  --geist-secondary: #4d4d4d;\n  --geist-tertiary: #666666;\n  --geist-quaternary: #808080;\n  --geist-border: #ebebeb;\n  --geist-surface-tint: #fafafa;\n  \n  /* Workflow Accents */\n  --develop-blue: #0a72ef;\n  --preview-pink: #de1d8d;\n  --ship-red: #ff5b4f;\n  \n  /* Interactive & Status */\n  --link-blue: #0072f5;\n  --ds-focus-color: hsla(212, 100%, 48%, 1);\n  --badge-blue-bg: #ebf5ff;\n  --badge-blue-text: #0068d6;\n  \n  /* Shadow-as-Border Philosophy */\n  --shadow-border: rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;\n  --shadow-border-hover: rgba(0, 0, 0, 0.16) 0px 0px 0px 1px;\n  --shadow-card: rgba(0, 0, 0, 0.08) 0px 0px 0px 1px, rgba(0, 0, 0, 0.04) 0px 2px 2px, #fafafa 0px 0px 0px 1px;\n  --shadow-card-hover: rgba(0, 0, 0, 0.12) 0px 0px 0px 1px, rgba(0, 0, 0, 0.06) 0px 4px 6px, #fafafa 0px 0px 0px 1px;\n  --shadow-card-full: rgba(0, 0, 0, 0.08) 0px 0px 0px 1px, rgba(0, 0, 0, 0.04) 0px 2px 2px, rgba(0, 0, 0, 0.04) 0px 8px 8px -8px, #fafafa 0px 0px 0px 1px;\n  --shadow-ring: rgb(235, 235, 235) 0px 0px 0px 1px;\n  \n  /* Radius Scale */\n  --radius-xs: 2px;\n  --radius-sm: 4px;\n  --radius-md: 6px;\n  --radius-lg: 8px;\n  --radius-xl: 12px;\n  --radius-pill: 9999px;\n}\n\n[data-theme=\"dark\"] {\n  --geist-foreground: #ededed;\n  --geist-background: #000000;\n  --geist-secondary: #a1a1a1;\n  --geist-tertiary: #888888;\n  --geist-quaternary: #666666;\n  --geist-border: #222222;\n  --geist-surface-tint: #0a0a0a;\n  \n  --shadow-border: rgba(255, 255, 255, 0.14) 0px 0px 0px 1px;\n  --shadow-border-hover: rgba(255, 255, 255, 0.28) 0px 0px 0px 1px;\n  --shadow-card: rgba(255, 255, 255, 0.12) 0px 0px 0px 1px, rgba(0, 0, 0, 0.4) 0px 2px 4px, #111111 0px 0px 0px 1px;\n  --shadow-card-hover: rgba(255, 255, 255, 0.2) 0px 0px 0px 1px, rgba(0, 0, 0, 0.5) 0px 6px 12px, #111111 0px 0px 0px 1px;\n  --shadow-card-full: rgba(255, 255, 255, 0.12) 0px 0px 0px 1px, rgba(0, 0, 0, 0.5) 0px 8px 16px -4px, #111111 0px 0px 0px 1px;\n  --shadow-ring: rgb(40, 40, 40) 0px 0px 0px 1px;\n  \n  --badge-blue-bg: rgba(10, 114, 239, 0.15);\n  --badge-blue-text: #70b5ff;\n}\n\n* { box-sizing: border-box; }\nhtml { scroll-behavior: smooth; }\nbody {\n  margin: 0;\n  font-family: \"Geist\", Arial, -apple-system, BlinkMacSystemFont, \"Segoe UI\", sans-serif;\n  background-color: var(--geist-background);\n  color: var(--geist-foreground);\n  font-feature-settings: \"liga\" 1;\n  -webkit-font-smoothing: antialiased;\n  min-height: 100vh;\n}\n\na {\n  color: inherit;\n  text-decoration: none;\n  transition: color 0.15s ease;\n}\n\n/* 导航栏 (Vercel Clean Sticky Nav) */\n.vercel-nav {\n  position: sticky;\n  top: 0;\n  background-color: var(--geist-background);\n  box-shadow: var(--shadow-border);\n  z-index: 100;\n  padding: 0 24px;\n  height: 64px;\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n}\n.nav-brand {\n  display: flex;\n  align-items: center;\n  gap: 12px;\n}\n.vercel-triangle {\n  width: 22px;\n  height: 19px;\n  fill: var(--geist-foreground);\n}\n.nav-title {\n  font-size: 16px;\n  font-weight: 600;\n  letter-spacing: -0.32px;\n  color: var(--geist-foreground);\n}\n.nav-badge-pill {\n  font-family: \"Geist Mono\", ui-monospace, monospace;\n  font-size: 11px;\n  font-weight: 500;\n  text-transform: uppercase;\n  background: var(--badge-blue-bg);\n  color: var(--badge-blue-text);\n  padding: 2px 8px;\n  border-radius: var(--radius-pill);\n}\n\n.nav-links {\n  display: flex;\n  align-items: center;\n  gap: 24px;\n}\n.nav-link {\n  font-size: 14px;\n  font-weight: 500;\n  color: var(--geist-secondary);\n  text-decoration: none;\n  transition: color 0.15s;\n}\n.nav-link:hover, .nav-link.active {\n  color: var(--geist-foreground);\n}\n.nav-link.active {\n  font-weight: 600;\n}\n\n.nav-actions {\n  display: flex;\n  align-items: center;\n  gap: 12px;\n}\n\n/* 按钮规范 */\n.btn-primary-dark {\n  background: var(--geist-foreground);\n  color: var(--geist-background);\n  border: none;\n  padding: 8px 16px;\n  border-radius: var(--radius-md);\n  font-size: 14px;\n  font-weight: 500;\n  cursor: pointer;\n  text-decoration: none;\n  display: inline-flex;\n  align-items: center;\n  gap: 6px;\n  transition: opacity 0.15s;\n}\n.btn-primary-dark:hover {\n  opacity: 0.9;\n}\n.btn-secondary-white {\n  background: var(--geist-background);\n  color: var(--geist-foreground);\n  box-shadow: var(--shadow-border);\n  border: none;\n  padding: 8px 16px;\n  border-radius: var(--radius-md);\n  font-size: 14px;\n  font-weight: 500;\n  cursor: pointer;\n  text-decoration: none;\n  display: inline-flex;\n  align-items: center;\n  gap: 6px;\n  transition: background 0.15s, box-shadow 0.15s;\n}\n.btn-secondary-white:hover {\n  background: var(--geist-surface-tint);\n  box-shadow: var(--shadow-border-hover);\n}\n.theme-toggle-btn {\n  background: transparent;\n  border: none;\n  box-shadow: var(--shadow-border);\n  border-radius: var(--radius-md);\n  width: 36px;\n  height: 36px;\n  cursor: pointer;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  color: var(--geist-foreground);\n}\n\n/* 核心容器 */\n.vercel-container {\n  max-width: 1200px;\n  margin: 0 auto;\n  padding: 56px 24px 100px;\n}\n\n/* Hero Section (Gallery Emptiness + Negative Letter-spacing) */\n.vercel-hero {\n  text-align: center;\n  max-width: 860px;\n  margin: 0 auto 56px;\n}\n.hero-stage-badge {\n  display: inline-flex;\n  align-items: center;\n  gap: 8px;\n  background: var(--geist-surface-tint);\n  box-shadow: var(--shadow-border);\n  padding: 4px 14px;\n  border-radius: var(--radius-pill);\n  font-size: 13px;\n  font-weight: 500;\n  color: var(--geist-secondary);\n  margin-bottom: 24px;\n}\n.stage-dot {\n  width: 7px;\n  height: 7px;\n  border-radius: 50%;\n}\n.vercel-hero h1 {\n  font-size: 48px;\n  font-weight: 600;\n  line-height: 1.05;\n  letter-spacing: -2.4px;\n  color: var(--geist-foreground);\n  margin: 0 0 16px;\n}\n.vercel-hero p {\n  font-size: 20px;\n  font-weight: 400;\n  line-height: 1.80;\n  color: var(--geist-secondary);\n  margin: 0 auto 28px;\n}\n\n/* Workflow Pipeline (Develop -> Preview -> Ship) */\n.workflow-pipeline {\n  display: grid;\n  grid-template-columns: repeat(3, 1fr);\n  gap: 16px;\n  margin-bottom: 48px;\n}\n@media (max-width: 768px) {\n  .workflow-pipeline { grid-template-columns: 1fr; }\n}\n.workflow-step {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card);\n  border-radius: var(--radius-lg);\n  padding: 20px 22px;\n  transition: box-shadow 0.2s;\n}\n.workflow-step:hover {\n  box-shadow: var(--shadow-card-hover);\n}\n.step-mono-label {\n  font-family: \"Geist Mono\", monospace;\n  font-size: 12px;\n  font-weight: 500;\n  text-transform: uppercase;\n  letter-spacing: 0.5px;\n  margin-bottom: 8px;\n  display: flex;\n  align-items: center;\n  gap: 6px;\n}\n.step-title {\n  font-size: 20px;\n  font-weight: 600;\n  letter-spacing: -0.96px;\n  color: var(--geist-foreground);\n  margin-bottom: 6px;\n}\n.step-desc {\n  font-size: 14px;\n  color: var(--geist-secondary);\n  line-height: 1.5;\n}\n\n/* Metric Cards (Section 4 Spec) */\n.metric-grid {\n  display: grid;\n  grid-template-columns: repeat(4, 1fr);\n  gap: 16px;\n  margin-bottom: 48px;\n}\n@media (max-width: 900px) {\n  .metric-grid { grid-template-columns: repeat(2, 1fr); }\n}\n.metric-card {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card);\n  border-radius: var(--radius-lg);\n  padding: 20px;\n}\n.metric-number {\n  font-size: 40px;\n  font-weight: 600;\n  line-height: 1.0;\n  letter-spacing: -2.4px;\n  color: var(--geist-foreground);\n  margin-bottom: 8px;\n  font-feature-settings: \"tnum\" 1;\n}\n.metric-label {\n  font-size: 14px;\n  color: var(--geist-secondary);\n  line-height: 1.4;\n}\n\n/* VAD 专栏 Banner (Ship Red & Vercel Clean) */\n.vad-showcase {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card-full);\n  border-radius: var(--radius-xl);\n  padding: 32px;\n  margin-bottom: 48px;\n  position: relative;\n}\n.vad-header-row {\n  display: flex;\n  align-items: baseline;\n  justify-content: space-between;\n  flex-wrap: wrap;\n  gap: 12px;\n  margin-bottom: 12px;\n}\n.vad-header-row h2 {\n  font-size: 32px;\n  font-weight: 600;\n  letter-spacing: -1.28px;\n  color: var(--geist-foreground);\n  margin: 0;\n}\n.vad-pillars-grid {\n  display: grid;\n  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));\n  gap: 14px;\n  margin-top: 24px;\n}\n.vad-pillar-item {\n  background: var(--geist-surface-tint);\n  box-shadow: var(--shadow-border);\n  border-radius: var(--radius-md);\n  padding: 14px 16px;\n}\n.vad-pillar-title {\n  font-size: 14px;\n  font-weight: 600;\n  color: var(--ship-red);\n  margin-bottom: 4px;\n}\n.vad-pillar-text {\n  font-size: 13px;\n  color: var(--geist-secondary);\n  line-height: 1.5;\n}\n.vad-filter-bar {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  justify-content: space-between;\n  gap: 12px;\n  margin: 24px 0 16px;\n  padding: 12px 16px;\n  background: var(--geist-surface-tint);\n  border-radius: var(--radius-md);\n  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.06);\n}\n.vad-filter-btn {\n  font-family: 'Geist', sans-serif;\n  font-size: 13px;\n  font-weight: 500;\n  padding: 6px 14px;\n  border-radius: 9999px;\n  border: none;\n  background: transparent;\n  color: var(--geist-secondary);\n  cursor: pointer;\n  transition: all 0.15s ease;\n}\n.vad-filter-btn:hover {\n  color: var(--geist-foreground);\n  background: rgba(0,0,0,0.05);\n}\n.vad-filter-btn.active {\n  background: #171717;\n  color: #ffffff;\n}\n.vad-search-input {\n  font-family: 'Geist', sans-serif;\n  font-size: 13px;\n  padding: 7px 12px;\n  border-radius: 6px;\n  border: 1px solid var(--geist-border);\n  background: #ffffff;\n  color: var(--geist-foreground);\n  width: 280px;\n  outline: none;\n  transition: border-color 0.15s, box-shadow 0.15s;\n}\n.vad-search-input:focus {\n  border-color: #0a72ef;\n  box-shadow: 0 0 0 2px rgba(10, 114, 239, 0.2);\n}\n\n/* 控制栏：搜索、视图、筛选 */\n.control-bar {\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  gap: 16px;\n  margin-bottom: 24px;\n  flex-wrap: wrap;\n}\n.search-input-wrap {\n  position: relative;\n  flex: 1;\n  max-width: 480px;\n}\n.search-input {\n  width: 100%;\n  height: 40px;\n  padding: 0 38px 0 14px;\n  font-family: \"Geist\", sans-serif;\n  font-size: 14px;\n  color: var(--geist-foreground);\n  background: var(--geist-background);\n  box-shadow: var(--shadow-border);\n  border: none;\n  border-radius: var(--radius-md);\n  outline: none;\n  transition: box-shadow 0.15s;\n}\n.search-input:focus {\n  outline: 2px solid var(--ds-focus-color);\n  box-shadow: none;\n}\n.search-kbd {\n  position: absolute;\n  right: 12px;\n  top: 50%;\n  transform: translateY(-50%);\n  font-family: \"Geist Mono\", monospace;\n  font-size: 11px;\n  color: var(--geist-quaternary);\n  background: var(--geist-surface-tint);\n  box-shadow: var(--shadow-border);\n  padding: 2px 6px;\n  border-radius: var(--radius-sm);\n}\n\n.view-switcher {\n  display: flex;\n  box-shadow: var(--shadow-border);\n  border-radius: var(--radius-md);\n  background: var(--geist-background);\n  padding: 2px;\n}\n.view-btn {\n  background: transparent;\n  border: none;\n  font-size: 13px;\n  font-weight: 500;\n  color: var(--geist-tertiary);\n  padding: 6px 12px;\n  border-radius: var(--radius-sm);\n  cursor: pointer;\n  transition: color 0.15s, background 0.15s;\n}\n.view-btn.active {\n  background: var(--geist-surface-tint);\n  color: var(--geist-foreground);\n  font-weight: 600;\n}\n\n/* 筛选芯片行 (Filter Pill Strip) */\n.filter-group-strip {\n  display: flex;\n  flex-direction: column;\n  gap: 12px;\n  margin-bottom: 28px;\n  padding: 16px 20px;\n  background: var(--geist-surface-tint);\n  box-shadow: var(--shadow-border);\n  border-radius: var(--radius-lg);\n}\n.filter-row {\n  display: flex;\n  align-items: center;\n  gap: 8px;\n  flex-wrap: wrap;\n}\n.filter-label-mono {\n  font-family: \"Geist Mono\", monospace;\n  font-size: 11px;\n  font-weight: 500;\n  text-transform: uppercase;\n  color: var(--geist-quaternary);\n  min-width: 68px;\n}\n.pill-badge {\n  background: var(--geist-background);\n  color: var(--geist-secondary);\n  box-shadow: var(--shadow-border);\n  border: none;\n  padding: 3px 12px;\n  border-radius: var(--radius-pill);\n  font-size: 12px;\n  font-weight: 500;\n  cursor: pointer;\n  transition: all 0.15s;\n  display: inline-flex;\n  align-items: center;\n  gap: 6px;\n}\n.pill-badge:hover {\n  color: var(--geist-foreground);\n  box-shadow: var(--shadow-border-hover);\n}\n.pill-badge.active {\n  background: var(--geist-foreground);\n  color: var(--geist-background);\n  font-weight: 600;\n  box-shadow: none;\n}\n.pill-badge.active-blue {\n  background: var(--develop-blue);\n  color: #ffffff;\n  box-shadow: none;\n}\n.pill-badge.active-red {\n  background: var(--ship-red);\n  color: #ffffff;\n  box-shadow: none;\n}\n\n/* Bento Grid Cards (Section 4 & 6 Spec) */\n.card-grid-bento {\n  display: grid;\n  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));\n  gap: 16px;\n}\n.vercel-card {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card);\n  border-radius: var(--radius-lg);\n  padding: 20px;\n  display: flex;\n  flex-direction: column;\n  justify-content: space-between;\n  transition: box-shadow 0.2s, transform 0.2s;\n  text-decoration: none;\n  color: inherit;\n  overflow: hidden;\n  min-width: 0;\n  word-break: break-word;\n}\n.vercel-card:hover {\n  box-shadow: var(--shadow-card-hover);\n  transform: translateY(-2px);\n}\n.card-top {\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  margin-bottom: 12px;\n  gap: 8px;\n}\n.card-tag-mono {\n  font-family: \"Geist Mono\", monospace;\n  font-size: 11px;\n  font-weight: 500;\n  text-transform: uppercase;\n  color: var(--geist-quaternary);\n  letter-spacing: 0.5px;\n}\n.status-pill-badge {\n  padding: 2px 8px;\n  border-radius: var(--radius-pill);\n  font-size: 11px;\n  font-weight: 500;\n  flex-shrink: 0;\n}\n.pub-accepted { background: #ebfdf2; color: #027a48; }\n.pub-workshop { background: #eff8ff; color: #175cd3; }\n.pub-submitted { background: #fff8e6; color: #b54708; }\n.pub-preprint { background: #f2f4f7; color: #475467; }\n.pub-other { background: #f9f5ff; color: #6941c6; }\n\n[data-theme=\"dark\"] .pub-accepted { background: rgba(2, 122, 72, 0.2); color: #32d583; }\n[data-theme=\"dark\"] .pub-workshop { background: rgba(23, 92, 211, 0.2); color: #84caff; }\n[data-theme=\"dark\"] .pub-submitted { background: rgba(181, 71, 8, 0.2); color: #fec84b; }\n[data-theme=\"dark\"] .pub-preprint { background: rgba(71, 84, 103, 0.2); color: #98a2b3; }\n[data-theme=\"dark\"] .pub-other { background: rgba(105, 65, 198, 0.2); color: #d6bbfb; }\n\n/* 必读标杆徽章 (Vercel Amber Accent) */\n.milestone-badge {\n  display: inline-flex;\n  align-items: center;\n  gap: 3px;\n  padding: 2px 7px;\n  border-radius: var(--radius-pill);\n  font-size: 11px;\n  font-weight: 600;\n  white-space: nowrap;\n  flex-shrink: 0;\n  transition: all 0.15s ease;\n}\n.milestone-badge.ms-idea, .milestone-badge:not([class*=\"ms-\"]) {\n  color: #b54708;\n  background: #fff8e6;\n  border: 1px solid rgba(247, 144, 9, 0.35);\n  box-shadow: 0 1px 2px rgba(181, 71, 8, 0.05);\n}\n[data-theme=\"dark\"] .milestone-badge.ms-idea, [data-theme=\"dark\"] .milestone-badge:not([class*=\"ms-\"]) {\n  color: #fec84b;\n  background: rgba(181, 71, 8, 0.22);\n  border-color: rgba(254, 200, 75, 0.35);\n}\n.milestone-badge.ms-writing {\n  color: #6941c6;\n  background: #f9f5ff;\n  border: 1px solid rgba(105, 65, 198, 0.3);\n  box-shadow: 0 1px 2px rgba(105, 65, 198, 0.05);\n}\n[data-theme=\"dark\"] .milestone-badge.ms-writing {\n  color: #d6bbfb;\n  background: rgba(105, 65, 198, 0.22);\n  border-color: rgba(214, 187, 251, 0.35);\n}\n.milestone-badge.ms-value {\n  color: #027a48;\n  background: #ebfdf2;\n  border: 1px solid rgba(2, 122, 72, 0.3);\n  box-shadow: 0 1px 2px rgba(2, 122, 72, 0.05);\n}\n[data-theme=\"dark\"] .milestone-badge.ms-value {\n  color: #32d583;\n  background: rgba(2, 122, 72, 0.22);\n  border-color: rgba(50, 213, 131, 0.35);\n}\n\n/* 论文正文图表与插图卡片样式 (Geist Design) */\n.paper-figure, .article-body figure {\n  margin: 32px auto;\n  text-align: center;\n  max-width: 100%;\n}\n.paper-figure img, .article-body img {\n  max-width: 96%;\n  height: auto;\n  border-radius: var(--radius-md);\n  border: 1px solid var(--geist-border);\n  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);\n  background: #ffffff;\n  transition: transform 0.2s ease, box-shadow 0.2s ease;\n  display: block;\n  margin: 0 auto;\n}\n.paper-figure img:hover, .article-body img:hover {\n  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);\n}\n.paper-figure figcaption, .article-body figcaption {\n  font-size: 13px;\n  color: var(--geist-secondary);\n  margin-top: 10px;\n  line-height: 1.6;\n  font-style: italic;\n  max-width: 850px;\n  margin-left: auto;\n  margin-right: auto;\n}\n\n/* VAD 视图切换器 View Switcher */\n.vad-view-switcher {\n  display: inline-flex;\n  padding: 3px;\n  background: var(--geist-secondary-bg);\n  border: 1px solid var(--geist-border);\n  border-radius: 8px;\n  margin-bottom: 20px;\n  gap: 2px;\n}\n.view-switch-btn {\n  display: inline-flex;\n  align-items: center;\n  gap: 6px;\n  padding: 6px 14px;\n  font-size: 13px;\n  font-weight: 500;\n  color: var(--geist-secondary);\n  border-radius: 6px;\n  text-decoration: none;\n  transition: all 0.15s ease;\n}\n.view-switch-btn:hover {\n  color: var(--geist-foreground);\n  background: rgba(0, 0, 0, 0.04);\n}\n[data-theme=\"dark\"] .view-switch-btn:hover {\n  background: rgba(255, 255, 255, 0.06);\n}\n.view-switch-btn.active {\n  background: var(--geist-background);\n  color: var(--geist-foreground);\n  font-weight: 600;\n  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);\n}\n\n/* 关系图谱 Graph View Styles */\n.graph-container {\n  position: relative;\n  width: 100%;\n  height: 720px;\n  background: var(--geist-background);\n  border: 1px solid var(--geist-border);\n  border-radius: var(--radius-lg);\n  overflow: hidden;\n  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04);\n  margin-bottom: 40px;\n}\n.graph-toolbar {\n  position: absolute;\n  top: 14px;\n  left: 14px;\n  right: 14px;\n  z-index: 10;\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  background: var(--geist-background);\n  border: 1px solid var(--geist-border);\n  padding: 8px 14px;\n  border-radius: 8px;\n  box-shadow: 0 4px 16px rgba(0,0,0,0.06);\n  flex-wrap: wrap;\n  gap: 8px;\n}\n.graph-tool-title {\n  font-size: 13px;\n  font-weight: 700;\n  display: flex;\n  align-items: center;\n  gap: 6px;\n  color: var(--geist-foreground);\n}\n.graph-filter-group {\n  display: flex;\n  gap: 6px;\n  align-items: center;\n  flex-wrap: wrap;\n}\n.graph-chip {\n  font-size: 11px;\n  padding: 3px 8px;\n  border-radius: 4px;\n  border: 1px solid var(--geist-border);\n  background: var(--geist-background);\n  color: var(--geist-foreground);\n  cursor: pointer;\n  transition: all 0.15s ease;\n}\n.graph-chip:hover { background: var(--geist-secondary-bg); }\n.graph-chip.active {\n  background: var(--geist-foreground);\n  color: var(--geist-background);\n  border-color: var(--geist-foreground);\n}\n.graph-search-input {\n  padding: 3px 8px;\n  font-size: 11px;\n  border-radius: 4px;\n  border: 1px solid var(--geist-border);\n  background: var(--geist-background);\n  color: var(--geist-foreground);\n  outline: none;\n  width: 150px;\n}\n#vad-graph-svg {\n  width: 100%;\n  height: 100%;\n  cursor: grab;\n}\n#vad-graph-svg:active { cursor: grabbing; }\n.graph-legend {\n  position: absolute;\n  bottom: 14px;\n  left: 14px;\n  background: var(--geist-background);\n  border: 1px solid var(--geist-border);\n  border-radius: 8px;\n  padding: 10px 14px;\n  font-size: 11px;\n  box-shadow: 0 4px 16px rgba(0,0,0,0.06);\n  z-index: 10;\n  line-height: 1.6;\n  pointer-events: none;\n}\n.graph-legend-row { display: flex; align-items: center; gap: 8px; }\n.graph-legend-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }\n.graph-info-drawer {\n  position: absolute;\n  top: 66px;\n  right: 14px;\n  width: 310px;\n  max-height: 620px;\n  background: var(--geist-background);\n  border: 1px solid var(--geist-border);\n  border-radius: 8px;\n  box-shadow: 0 8px 30px rgba(0,0,0,0.12);\n  z-index: 10;\n  padding: 16px;\n  overflow-y: auto;\n  display: none;\n  backdrop-filter: blur(10px);\n  transition: transform 0.2s ease, opacity 0.2s ease;\n}\n.graph-drawer-close {\n  position: absolute;\n  top: 10px;\n  right: 12px;\n  cursor: pointer;\n  font-size: 16px;\n  color: var(--geist-tertiary);\n}\n.graph-drawer-badge {\n  display: inline-block;\n  padding: 2px 6px;\n  border-radius: 4px;\n  font-size: 10px;\n  font-weight: 600;\n  margin-bottom: 6px;\n}\n.graph-drawer-title {\n  font-size: 13px;\n  font-weight: 700;\n  line-height: 1.4;\n  margin-bottom: 8px;\n  color: var(--geist-foreground);\n}\n.graph-drawer-meta {\n  font-size: 11px;\n  color: var(--geist-secondary);\n  margin-bottom: 12px;\n}\n.graph-drawer-core {\n  font-size: 12px;\n  line-height: 1.6;\n  color: var(--geist-foreground);\n  background: var(--geist-secondary-bg);\n  padding: 8px 10px;\n  border-radius: 6px;\n  margin-bottom: 12px;\n  border: 1px solid var(--geist-border);\n}\n.graph-drawer-link {\n  display: block;\n  text-align: center;\n  padding: 7px 12px;\n  background: var(--geist-foreground);\n  color: var(--geist-background);\n  border-radius: 6px;\n  font-size: 12px;\n  font-weight: 600;\n  text-decoration: none;\n  transition: opacity 0.15s ease;\n  margin-bottom: 6px;\n}\n.graph-drawer-link:hover { opacity: 0.85; }\n.graph-drawer-pdf-link {\n  display: block;\n  text-align: center;\n  padding: 6px 12px;\n  background: var(--geist-secondary-bg);\n  color: var(--geist-foreground);\n  border: 1px solid var(--geist-border);\n  border-radius: 6px;\n  font-size: 11px;\n  font-weight: 500;\n  text-decoration: none;\n  transition: all 0.15s ease;\n}\n.graph-drawer-pdf-link:hover { background: var(--geist-border); }\n.node-circle {\n  cursor: pointer;\n  transition: r 0.2s, stroke-width 0.2s;\n}\n.node-label {\n  font-size: 10px;\n  font-weight: 600;\n  fill: var(--geist-foreground);\n  pointer-events: none;\n  text-shadow: 0 1px 2px var(--geist-background);\n}\n.link-line {\n  stroke: var(--geist-border);\n  stroke-opacity: 0.6;\n  stroke-width: 1.2;\n  transition: stroke 0.2s, stroke-width 0.2s, stroke-opacity 0.2s;\n}\n.link-label {\n  font-size: 9px;\n  fill: var(--geist-tertiary);\n  pointer-events: none;\n  text-anchor: middle;\n}\n\n/* 引用框与警示框 Alerts */\n.callout-alert {\n  margin: 20px 0;\n  padding: 14px 18px;\n  border-radius: var(--radius-md);\n  transition: all 0.15s ease;\n}\n.callout-important, .callout-idea {\n  border-left: 4px solid #b54708;\n  background: rgba(181, 71, 8, 0.06);\n  box-shadow: inset 0 0 0 1px rgba(247, 144, 9, 0.3);\n}\n[data-theme=\"dark\"] .callout-important, [data-theme=\"dark\"] .callout-idea {\n  border-left-color: #fec84b;\n  background: rgba(181, 71, 8, 0.18);\n  box-shadow: inset 0 0 0 1px rgba(254, 200, 75, 0.25);\n}\n.callout-writing {\n  border-left: 4px solid #6941c6;\n  background: rgba(105, 65, 198, 0.06);\n  box-shadow: inset 0 0 0 1px rgba(105, 65, 198, 0.3);\n}\n[data-theme=\"dark\"] .callout-writing {\n  border-left-color: #d6bbfb;\n  background: rgba(105, 65, 198, 0.18);\n  box-shadow: inset 0 0 0 1px rgba(214, 187, 251, 0.25);\n}\n.callout-value {\n  border-left: 4px solid #027a48;\n  background: rgba(2, 122, 72, 0.06);\n  box-shadow: inset 0 0 0 1px rgba(2, 122, 72, 0.3);\n}\n[data-theme=\"dark\"] .callout-value {\n  border-left-color: #32d583;\n  background: rgba(2, 122, 72, 0.18);\n  box-shadow: inset 0 0 0 1px rgba(50, 213, 131, 0.25);\n}\n\n.card-title {\n  font-size: 16.5px;\n  font-weight: 600;\n  line-height: 1.42;\n  letter-spacing: -0.4px;\n  color: var(--geist-foreground);\n  margin: 0 0 10px;\n  word-break: break-word;\n  overflow-wrap: anywhere;\n  hyphens: auto;\n}\n.card-title a {\n  color: var(--geist-foreground);\n  text-decoration: none;\n  display: inline;\n  transition: color 0.15s ease;\n}\n.card-title a:hover {\n  color: var(--develop-blue);\n  text-decoration: none;\n}\n.card-id-mono {\n  font-family: \"Geist Mono\", monospace;\n  font-size: 13px;\n  font-weight: 500;\n  color: var(--geist-quaternary);\n  margin-right: 5px;\n}\n.card-meta-row {\n  display: flex;\n  gap: 6px;\n  flex-wrap: wrap;\n  margin-bottom: 12px;\n}\n.meta-token {\n  font-size: 12px;\n  color: var(--geist-tertiary);\n  background: var(--geist-surface-tint);\n  box-shadow: var(--shadow-ring);\n  padding: 2px 7px;\n  border-radius: var(--radius-sm);\n  white-space: nowrap;\n}\n.card-body-text {\n  font-size: 13.5px;\n  color: var(--geist-secondary);\n  line-height: 1.6;\n  margin-bottom: 16px;\n  flex-grow: 1;\n  word-break: break-word;\n  overflow-wrap: anywhere;\n}\n.card-body-text strong {\n  color: var(--geist-foreground);\n  font-weight: 600;\n}\n\n.card-footer {\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  border-top: 1px solid var(--geist-border);\n  padding-top: 14px;\n}\n.card-link-action {\n  font-size: 13.5px;\n  font-weight: 500;\n  color: var(--link-blue);\n  display: inline-flex;\n  align-items: center;\n  gap: 4px;\n  text-decoration: none;\n  transition: all 0.15s ease;\n}\n.card-link-action:hover {\n  opacity: 0.85;\n  transform: translateX(2px);\n}\na.meta-token {\n  transition: all 0.15s ease;\n  cursor: pointer;\n  text-decoration: none;\n}\na.meta-token:hover {\n  background: var(--geist-selection);\n  color: var(--geist-foreground);\n  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);\n}\n\n/* 紧凑列表视图 (List View) */\n.card-list-view {\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n}\n.list-row-item {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card);\n  border-radius: var(--radius-md);\n  padding: 12px 18px;\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  gap: 16px;\n  transition: box-shadow 0.15s;\n}\n.list-row-item:hover {\n  box-shadow: var(--shadow-card-hover);\n}\n\n/* 阅读详情页 (Report Detail) */\n.reading-container {\n  display: grid;\n  grid-template-columns: minmax(0, 1fr) 260px;\n  gap: 40px;\n  align-items: start;\n}\n@media (max-width: 960px) {\n  .reading-container { grid-template-columns: 1fr; }\n  .reading-sidebar { display: none; }\n}\n\n.report-header-card {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card);\n  border-radius: var(--radius-lg);\n  padding: 28px 32px;\n  margin-bottom: 28px;\n}\n.crumb-bar {\n  font-size: 13px;\n  color: var(--geist-tertiary);\n  margin-bottom: 10px;\n}\n.report-title {\n  font-size: 32px;\n  font-weight: 600;\n  letter-spacing: -1.28px;\n  margin: 0 0 16px;\n  color: var(--geist-foreground);\n}\n.report-action-buttons {\n  display: flex;\n  align-items: center;\n  gap: 10px;\n  flex-wrap: wrap;\n  border-top: 1px solid var(--geist-border);\n  padding-top: 16px;\n  margin-top: 16px;\n}\n\n.article-body {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card-full);\n  border-radius: var(--radius-lg);\n  padding: 36px 42px 80px;\n  font-size: 16px;\n  line-height: 1.75;\n  color: var(--geist-foreground);\n}\n.article-body h1, .article-body h2, .article-body h3 {\n  color: var(--geist-foreground);\n  scroll-margin-top: 80px;\n}\n.article-body h1 { font-size: 28px; font-weight: 600; letter-spacing: -1.28px; border-bottom: 1px solid var(--geist-border); padding-bottom: 8px; margin-top: 32px; }\n.article-body h2 { font-size: 24px; font-weight: 600; letter-spacing: -0.96px; border-bottom: 1px solid var(--geist-border); padding-bottom: 6px; margin-top: 36px; }\n.article-body h3 { font-size: 18px; font-weight: 600; letter-spacing: -0.32px; margin-top: 26px; }\n.article-body table {\n  width: 100%;\n  border-collapse: collapse;\n  margin: 24px 0;\n  font-size: 14px;\n  box-shadow: var(--shadow-border);\n  border-radius: var(--radius-md);\n  overflow: hidden;\n}\n.article-body th, .article-body td {\n  padding: 10px 14px;\n  text-align: left;\n  border-bottom: 1px solid var(--geist-border);\n}\n.article-body th {\n  background: var(--geist-surface-tint);\n  font-weight: 600;\n  color: var(--geist-foreground);\n}\n.article-body blockquote {\n  border-left: 2px solid var(--geist-foreground);\n  margin: 20px 0;\n  padding: 8px 18px;\n  color: var(--geist-secondary);\n  font-style: normal;\n}\n.article-body code {\n  font-family: \"Geist Mono\", monospace;\n  font-size: 13.5px;\n  box-shadow: var(--shadow-ring);\n  background: var(--geist-surface-tint);\n  padding: 2px 6px;\n  border-radius: var(--radius-sm);\n}\n.article-body pre {\n  position: relative;\n  background: #000000;\n  color: #ededed;\n  box-shadow: var(--shadow-border);\n  border-radius: var(--radius-md);\n  padding: 18px;\n  margin: 24px 0;\n  overflow-x: auto;\n}\n.article-body pre code {\n  background: transparent;\n  box-shadow: none;\n  padding: 0;\n  color: inherit;\n  font-size: 13px;\n}\n.copy-code-btn {\n  position: absolute;\n  top: 8px;\n  right: 10px;\n  font-family: \"Geist Mono\", monospace;\n  font-size: 11px;\n  background: #171717;\n  color: #ffffff;\n  border: 1px solid #333333;\n  padding: 3px 8px;\n  border-radius: var(--radius-sm);\n  cursor: pointer;\n}\n\n/* 侧边大纲 (TOC) */\n.reading-sidebar {\n  position: sticky;\n  top: 80px;\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card);\n  border-radius: var(--radius-lg);\n  padding: 20px;\n  max-height: calc(100vh - 100px);\n  overflow-y: auto;\n}\n.sidebar-toc-title {\n  font-family: \"Geist Mono\", monospace;\n  font-size: 12px;\n  font-weight: 500;\n  text-transform: uppercase;\n  letter-spacing: 0.5px;\n  color: var(--geist-quaternary);\n  margin-bottom: 12px;\n}\n.reading-sidebar ul {\n  list-style: none;\n  padding-left: 0;\n  margin: 0;\n  font-size: 13px;\n}\n.reading-sidebar li {\n  margin: 6px 0;\n}\n.reading-sidebar ul ul {\n  padding-left: 14px;\n}\n.reading-sidebar a {\n  color: var(--geist-secondary);\n  text-decoration: none;\n  transition: color 0.15s;\n}\n.reading-sidebar a:hover, .reading-sidebar a.active {\n  color: var(--geist-foreground);\n  font-weight: 600;\n}\n\n/* 后台管理 (/admin) */\n.admin-card-container {\n  background: var(--geist-background);\n  box-shadow: var(--shadow-card-full);\n  border-radius: var(--radius-lg);\n  padding: 32px;\n  margin-bottom: 32px;\n}\n.form-row-2 {\n  display: grid;\n  grid-template-columns: 1fr 1fr;\n  gap: 16px;\n  margin-bottom: 16px;\n}\n@media (max-width: 600px) {\n  .form-row-2 { grid-template-columns: 1fr; }\n}\n.form-field {\n  display: flex;\n  flex-direction: column;\n  gap: 6px;\n  margin-bottom: 16px;\n}\n.form-field label {\n  font-size: 13px;\n  font-weight: 500;\n  color: var(--geist-foreground);\n}\n.form-field input, .form-field select, .form-field textarea {\n  font-family: \"Geist\", sans-serif;\n  font-size: 14px;\n  padding: 9px 12px;\n  background: var(--geist-background);\n  box-shadow: var(--shadow-border);\n  border: none;\n  border-radius: var(--radius-md);\n  color: var(--geist-foreground);\n  outline: none;\n}\n.form-field input:focus, .form-field select:focus, .form-field textarea:focus {\n  outline: 2px solid var(--ds-focus-color);\n  box-shadow: none;\n}\n\n/* 语法高亮 (Console Blue / Purple / Pink) */\n.codehilite .k, .codehilite .kd, .codehilite .kn { color: #eb367f; font-weight: 500; }\n.codehilite .s, .codehilite .s1, .codehilite .s2 { color: #0070f3; }\n.codehilite .nf, .codehilite .na { color: #7928ca; font-weight: 500; }\n.codehilite .c, .codehilite .c1 { color: #666666; font-style: italic; }\n.codehilite .mi, .codehilite .mf { color: #ff5b4f; }\n\n</style>\n\n</head>\n<body>\n\n    <nav class=\"vercel-nav\">\n      <div class=\"nav-brand\">\n        <a href=\"/\" style=\"display:flex;align-items:center;gap:10px;text-decoration:none\">\n          <svg class=\"vercel-triangle\" viewBox=\"0 0 76 65\" fill=\"none\">\n            <path d=\"M37.5274 0L75.0548 65H0L37.5274 0Z\" fill=\"currentColor\"/>\n          </svg>\n          <span class=\"nav-title\">Agent Harness KB</span>\n        </a>\n        <span class=\"nav-badge-pill\">Geist 2.0</span>\n      </div>\n\n      <div class=\"nav-links\">\n        <a class=\"nav-link \" href=\"/\">全景总览</a>\n        <a class=\"nav-link \" href=\"/vad\" style=\"color:var(--ship-red)\">🎯 VAD 专栏 (144)</a>\n        <a class=\"nav-link\" href=\"https://m0rtzz.github.io/paper-notes/\" target=\"_blank\" rel=\"noopener\">顶会 669 篇 ↗</a>\n        <a class=\"nav-link\" href=\"/download/all\">整库打包</a>\n        \n      </div>\n\n      <div class=\"nav-actions\">\n        \n        <button class=\"theme-toggle-btn\" id=\"theme-toggle-btn\" onclick=\"toggleTheme()\" title=\"切换亮暗主题\">🌙</button>\n      </div>\n    </nav>\n    \n<main class=\"vercel-container\">\n\n        <div class=\"report-header-card\">\n          <div class=\"crumb-bar\"><a href=\"/\">Home</a> / <b>fulltext.txt</b></div>\n          <h1 class=\"report-title\">fulltext.txt</h1>\n          <div class=\"report-action-buttons\">\n            <a class=\"btn-primary-dark\" href=\"?dl=1\">Download Text</a>\n          </div>\n        </div>\n        <article class=\"article-body\"><pre><code>MMR-AD: A Large-Scale Multimodal Dataset for Benchmarking General\nAnomaly Detection with Multimodal Large Language Models\nXincheng Yao1 , Zefeng Qian1 , Chao Shi1 , Jiayang Song1 , Chongyang Zhang1,2 *\nSchool of Information Science and Electronic Engineering, Shanghai Jiao Tong University\n2\nMoE Key Lab of Artificial Intelligence, AI Institute, Shanghai Jiao Tong University\n{i-Dover, zefeng qian, shichaostone, jiayang.song, sunny zhang}@sjtu.edu.cn1\nhttps://xcyao00.github.io/MMR-AD\n\narXiv:2604.10971v1 [cs.CV] 13 Apr 2026\n\n1\n\nAbstract\nIn the progress of industrial anomaly detection, general\nanomaly detection (GAD) is an emerging trend and also the\nultimate goal. Unlike the conventional single- and multiclass AD, general AD aims to train a general AD model\nthat can directly detect anomalies in diverse novel classes\nwithout any retraining or fine-tuning on the target data. Recently, Multimodal Large Language Models (MLLMs) have\nshown great promise in achieving general anomaly detection due to their revolutionary visual understanding and\nlanguage reasoning capabilities. However, MLLM’s general AD ability remains underexplored due to: (1) MLLMs\nare pretrained on amounts of data sourced from the Web,\nthese data still have significant gaps with the data in AD\nscenarios. Moreover, the image-text pairs during pretraining are also not specifically for AD tasks. (2) The current\nmainstream AD datasets are image-based and not yet suitable for post-training MLLMs. To facilitate MLLM-based\ngeneral AD research, we present MMR-AD, which is a\ncomprehensive benchmark for both training and evaluating\nMLLM-based AD models. With MMR-AD, we reveal that\nthe AD performance of current SOTA generalist MLLMs\nstill falls far behind the industrial requirements. Based on\nMMR-AD, we also propose a baseline model, Anomaly-R1,\nwhich is a reasoning-based AD model that learns from the\nCoT data in MMR-AD and is further enhanced by reinforcement learning. Extensive experiments show that our\nAnomaly-R1 achieves remarkable improvements over generalist MLLMs in both anomaly detection and localization.\n\n1. Introduction\nIn the past few years, industrial anomaly detection (IAD)\nhas undergone rapid progress, from single-class [12, 13, 41,\n52, 53] to multi-class [19, 21, 31, 56, 58] and the recent\n* Corresponding Author.\n\nObject\nCategories\n[188]\n\nAbnormal Images\n[98915]\nNormal\nImages\n[28222]\n\n(a)\n\n(b)\n\nFigure 1. (a) Overview of our MMR-AD dataset. (b) Visualization of the anomaly detection (AD) and anomaly localization (AL)\naccuracy comparison. Through post-training on our MMR-AD\ndataset, our finetuned Anomaly-R1-7B shows remarkable performance improvement, especially in anomaly localization.\n\ncross-class [54, 55, 63, 65] AD methods. An obvious trend\nis that AD models are changing from specialist to generalist. General AD aims to learn a general AD model that can\ndirectly detect anomalies in diverse novel classes without\nany retraining or fine-tuning on the target data. Like artificial general intelligence (AGI), general anomaly detection\n(GAD) is also the ultimate goal of anomaly detection.\nRecent advances in Multimodal Large Language Models (MLLMs) have shown revolutionary visual understanding and language reasoning capabilities. MLLMs have\ngreat potential to achieve general anomaly detection. Some\nrecent studies have attempted to explore MLLM-based\nanomaly detection. Based on proper prompts, some reports\n[8, 50, 61] evaluate IAD examples with MLLMs, demonstrating the advantages of MLLMs in generalization. However, they only test a few qualitative examples. Other studies, such as AnomalyGPT [18] and Myriad [28], follow\ninstruction fine-tuning to train MLLMs to directly predict\nwhether the input image contains anomalies, without providing detailed thinking steps. In contrast, for better inter-\n\n\fpretability, robustness, and generalizability, we expect models to first explain why an image is considered anomalous\nand provide the corresponding visual evidence, and then\nprovide the final answer. Based on reasoning, it is more advantageous for the model to detect novel anomalies through\nstep-by-step analysis and comparison, rather than relying\non whether the anomalies are trained. However, the current\nlarge-scale AD datasets are still image-based (e.g., RealIAD [45]) and not yet suitable for post-training MLLMs.\nThe AD community lacks multimodal AD datasets, especially large-scale reasoning-based multimodal AD datasets.\nIn this paper, to facilitate MLLM-based general AD\nresearch, we present MMR-AD, the current largestscale Multi-Modal Reasoning-based industrial Anomaly\nDetection dataset. MMR-AD can be used for both training and evaluating MLLM-based AD models. To ensure\nthat all samples are from real-world products with diverse\nproduct categories and anomaly types, we acquired a large\nnumber of high-quality samples from publicly available AD\ndatasets. We selected a total of 14 public datasets and found\nthat many samples in these datasets are of low-quality (e.g.,\nincorrect or ambiguous labeling of anomalies). Then, we\nmanually reviewed all the data and removed the low-quality\nsamples. Moreover, we also manually annotated the bounding boxes and text labels for the anomalous regions. In this\nway, the advantage of our MMR-AD is that it can be used\nto evaluate the model’s ability to accurately locate anomalies (i.e., original AD datasets only provide masks, but it’s\nhard to predict masks through text-based responses from\nMLLMs). For texts, manual annotations are quite inefficient, and the quality of reasoning texts is also low. We\nthen designed an automatic pipeline to leverage a strong\nMLLM to generate rich text contents (containing detailed\nreasoning steps) for each sample with visual hints and language hints. Ultimately, we collected 127137 samples from\n188 product categories across 14 public AD datasets. The\nestablished dataset contains a total of 395 anomaly types\nand 112875 annotated anomalous regions (see Fig.1(a)).\nAll samples are grouped into many subdatasets based on\ntheir original dataset names (e.g., MVTecAD, VisA, etc).\nThus, our MMR-AD is very suitable for training and evaluating MLLM-based GAD models (i.e., training on some\nsubdatasets and evaluating on the remaining subdatasets).\nWith MMR-AD, we conduct extensive experiments to\nevaluate current SOTA generalist MLLMs, including GPT\nseries [34, 37] and Gemini-2.5 series [16], as well as opensource models like Qwen2.5-VL [3] and InternVL3.5 [48].\nAs shown in Fig.1(b), when used for industrial AD, the accuracy levels of current generalist MLLMs are still far from\nmeeting practical standards, especially the precise anomaly\nlocalization performance. This reveals that due to data gaps\nand the lack of AD-related pretraining, current generalist\nMLLMs are still not competent for AD tasks and require\n\nfurther post-training on large-scale multimodal AD datasets\nto enhance their general AD capabilities.\nFurthermore, based on MMR-AD, we propose a baseline model, Anomaly-R1, which is a reasoning-based AD\nmodel that learns from the Chain-of-Thought (CoT) data in\nMMR-AD and is further enhanced via reinforcement learning. Extensive experiments demonstrate that Anomaly-R1\nachieves remarkable improvements over advanced generalist MLLMs in both anomaly detection and localization. Our\nexperiments also verify that, compared to texts only containing answers, comprehensive reasoning texts can enable\nthe model to learn how to analyze and compare images stepby-step to identify anomalies, which are more conducive to\nimproving the model’s general AD capabilities. Our contributions are as follows:\n1. Towards MLLM-based general AD research, based on\npublic unimodal AD datasets, we reconstruct a large-scale\nreasoning-based multimodal AD dataset, MMR-AD.\n2. We comprehensively evaluate the performance of representative MLLMs on MMR-AD. Due to data gaps and\nthe lack of AD-related pretraining, generalist MLLMs are\nstill weak in fine-grained anomaly detection and localization, highlighting the necessity of multimodal AD datasets.\n3. We further propose a baseline model, Anomaly-R1,\nby post-training Qwen2.5-VL on MMR-AD. Extensive experiments demonstrate that Anomaly-R1 achieves significant improvements over advanced generalist models.\n\n2. Related Work\nMultimodal Large Language Models. In the past few\nyears, MLLMs [3, 10, 34, 44, 57] have significantly revolutionized the computer vision field in a broad spectrum\nof tasks, underscoring their potential as a key stride toward\nAGI. The majority of open-source MLLMs, such as LLaVA\nseries [29, 30], Qwen-VL series [2, 3, 46], InternVL series\n[10, 11], CogVLM [47], and others [14, 38, 57, 64], follow the “ViT-Projector-LLM” architecture. Through partial\nparameter-freezing or multi-stage fine-tuning, MLLMs continuously bridge modality gaps and still ensure that core linguistic capacities remain uncompromised. The recent trend\nof MLLMs has gradually focused on more general and complex tasks, such as visual reasoning tasks and agentic tasks.\nMultimodal reasoning models [3, 16, 37, 48] can further\nanalyze the object relationships and answer complex questions through long-term thinking, remarkably expanding the\nperformance boundaries of MLLMs.\nMLLM-based Anomaly Detection Models. Recently,\nsome AD studies have demonstrated that MLLMs can be\napplied to anomaly detection through proper prompts or\nfine-tuning. In [8, 50, 61], the authors indicate that proper\nvisual and language prompts can effectively enhance the\nperformance of MLLMs in IAD tasks. Some valuable findings are that class information, normal text knowledge, and\n\n\fespecially normal reference samples can effectively improve the AD capabilities of MLLMs. Some other works\nhave attempted to fine-tune open-source MLLMs on IAD\ndatasets, such as AnomalyGPT [18], Myriad [28], FabGPT\n[25], VMAD [26], and Anomaly-OV [49]. However, the\ntext replies in these models during training are simple and\nlack detailed reasoning, this prevents these models from\ntruly taking advantage of MLLM’s strong reasoning and\ngeneralization abilities. Furthermore, these models only undergo SFT training without further reinforcement learning.\nWhile a recent work, SAGE [60], utilizes DPO for training,\nwhich requires preference data pairs. The preference pairs\nare constructed by an LLM-based entropy method, which is\nmore complex and costly compared to the rule-based GRPO\nin our work.\nMultimodal Anomaly Detection Datasets. Recently,\nthere are three multimodal AD datasets, MMAD [24] and\nAnomaly-Instruct-125K [49] and AD-PL [60]. In MMAD,\nthe text of each sample is presented in a multiple-choice\nformat and includes distractor options. This makes MMAD\nonly suitable as the evaluation dataset and not for training. In Anomaly-Instruct-125K, the texts are based on\nthe question-answer format, where each response contains\nsome text descriptions for the anomalies. However, 72K\ndata of this dataset comes from the Web, which has distribution deviations from real-world industrial scenarios. The\nAD-PL dataset is only collected based on: MVTecAD [5],\nVisA [68] and MPDD [23], and the text data in AD-PL are\nalso coarse-grained answers. By comparison, our MMRAD has more diverse industrial AD images, and the elaborate reasoning-based texts also provide better explainability.\nIt should be a stronger contribution to the AD community.\n\ntypes. Constructing such a dataset from scratch (taking pictures) is very challenging, but fortunately, a large amount of\nopen-source AD datasets have provided us with rich image\nresources. However, these datasets cannot be directly used\nfor multimodal anomaly detection research. To ensure data\nscale and diversity, we extensively collected and sampled\nfrom 14 publicly available AD datasets (see Tab.1). Specifically, the datasets we employed include MVTecAD [5],\nVisA [68], MVTecLOCO [7], MVTec3D [6], MPDD [23],\nGoodsAD [62], RealIAD [45], RealIAD-D3 [67], MANTA\n[15], MIAD [4], CableInspect [1], WFDD [9], TextureAD\n[27], and 3CAD [51]. During processing these datasets, we\nfound that many samples in these datasets are of low quality. Thus, to ensure the quality of our MMR-AD dataset,\nwe manually checked all the data (∼ 190K original images)\nand removed low-quality samples. In addition, to assist in\nsubsequent text generation (see Sec.3.2) and also for evaluating the model’s ability to accurately locate anomalies,\nwe further manually annotated the bounding boxes and text\nlabels for the anomalous regions.\n\n3. The MMR-AD Dataset\n\nFigure 2. The illustration of the text generation pipeline. We\nutilize the (reference, input) image pair and leverage Qwen2.5VL-72B to automate the generation of reasoning-based texts. We\nprompt the model to generate the reasoning-based AD thinking\nprocess (i.e., based on comparison and analysis of the two images). To ensure that the model can correctly recognize abnormal\nareas, we plot red bboxes on the image as visual hints and also\nprovide the anomaly types and bbox coordinates of the abnormal\nareas as text hints to the instruction. In the generated texts, the red\nparts mark the anomaly-related reasoning words.\n\n3.1. Data Collections\nTable 1. Statistics on the composition of our MMR-AD dataset.\nImage Source\n\nSampled Images\n\nText Tokens\n\nObject Categories\n\nAnomaly Types\n\nNum Anomalies\n\nMVTecAD [5]\nVisA [68]\nMVTecLOCO [7]\nMVTec3D [6]\nMPDD [23]\nGoodsAD [62]\nRealIAD [45]\nRealIAD-D3 [67]\nMANTA [15]\nMIAD [4]\nCableInspect [1]\nWFDD [9]\nTextureAD [27]\n3CAD [51]\n\n2485\n2287\n1889\n1176\n540\n2028\n50389\n3632\n35347\n16026\n2701\n291\n1876\n6470\n\n503306\n501651\n366251\n254543\n112631\n381232\n10273862\n711109\n7312147\n3263933\n739424\n60121\n539164\n1362052\n\n15\n12\n6\n10\n6\n6\n30\n20\n38\n6\n3\n4\n24\n8\n\n37\n35\n47\n26\n10\n13\n44\n17\n81\n11\n6\n10\n24\n34\n\n1588\n1568\n1078\n1132\n416\n1705\n44283\n2961\n31824\n15349\n2879\n252\n1292\n6548\n\nSUM\n\n127137\n\n26381426\n\n188\n\n395\n\n112875\n\nOur goal is to construct a large-scale multimodal industrial anomaly detection dataset to facilitate MLLMbased general AD research. Therefore, this dataset should\nbe large-scale, where samples are images from real-world\nproducts with diverse product categories and anomaly\n\n3.2. Text Generation\nImage-text Pair\n\nImage Select\n\nNearest\n\nNormal Image Set\n\nReference Image\n\n+\n\nText Hint\n\nInput Image\nGround-Truth Bbox\n([154, 78, 303, 205])\n\nVisual Prompt\n\nPrior Knowledge\nObject category: ”cable”;\nAnomaly Type: “missing cable”;\nAnomaly Localization: “[154, 78, 303, 205]”\n\nText Generation Instruction\nYou are an industrial image inspector...You need to determine if there\nare any anomalies in the second image…&lt;hint&gt;…You need to think\nabout the reasoning process and then provided us the answer…\n\n&lt;think&gt;\nTo determine if there are any anomalies in the second image, I will\ncompare it with the first image. The first image shows a normal sample\nwith three cables of different colors (yellow, blue, and brown) arranged in\na circular pattern. Each cable has a distinct color and structure.\nIn the second image, there is an empty space where one of the cables\nshould be. This indicates that a cable is missing from its expected position.\nThe other two cables appear to be intact and correctly positioned.\nBased on this analysis, the anomaly in the second image is the missing\ncable. The location of the missing cable can be determined by comparing\nthe positions of the remaining cables with those in the first image. The\nmissing cable's location corresponds to the area where the yellow cable\nwas present in the first image.\nTherefore, the coordinates for the abnormal area are [154, 78, 303, 205].\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [154, 78, 303, 205], 'label': 'missing\ncable'}&lt;/answer&gt;\n\nDue to the lack of text annotations in public AD datasets,\nthe currently collected data cannot be directly used to train\nand evaluate MLLM-based AD models. However, manual annotation for each sample is too costly and timeconsuming, especially the quality of reasoning texts written\nby humans is also low. To this end, we propose an automatic pipeline that can leverage current strong MLLMs to\nefficiently generate text data for each sample. As shown\nin Fig.2, our pipeline leverages the visual reasoning capabilities of Qwen2.5-VL-72B [3] to first generate elaborate\n\n\fTable 2. Template for text data generation instruction. hint will be replaced with the specific coordinates and types of anomalous regions.\nThe prompt template will also be used in subsequent training and testing, but the gray part in the template will be removed.\nSystem Prompt\nYou are a professional industrial image inspector, particularly skilled at identifying abnormal (defective) areas in images.\nUser Prompt\n- &lt;Reference Image&gt;&lt;Input Image&gt;The first image is a normal sample, and you need to carefully inspect and analyze these two images to determine if there are any anomalies (defects) in the second image.\n- If there are anomalies, return their locations in the form of coordinates (hint: the red box in the second image is our reminder, and the location and label of the abnormal area is: hint).\n- You first need to think about the reasoning and analysis process in the mind and then provide us with the answer.\n- The red box is our hint, you can’t generate any content related to it.\n- You should output the coordinate location(s) of the abnormal area(s) in the reasoning process, but can’t indicate that we provide location hint to you.\nOutput Format (strictly follow)\nThe reasoning process and answer are enclosed within &lt;think&gt;&lt;/think&gt; and &lt;answer&gt;&lt;/answer&gt; tags, i.e., &lt;think&gt;reasoning and analysis process here&lt;/think&gt;&lt;answer&gt;Yes or No. If Yes, continue to\noutput all locations, the format should be like {‘bbox 2d’: [x1, y1, x2, y2], ‘label’: ‘&lt;anomaly type&gt;’}&lt;/answer&gt;.\n\nreasoning data and then output the answer. Unlike previous\nworks [18, 49] that generate text data only based on one image, we provide a spatially-aligned nearest sample (please\nsee Appendix B for details) as the normal reference sample\nfor each input sample and instruct the Qwen2.5-VL-72B to\ngenerate AD-related text data by comparing the input image\nwith the reference image. As we think that the essence of\nanomalies is relative to normal, and only knowing what is\nnormal can detect anomalies well. Since Qwen2.5-VL-72B\nis primarily trained on natural images and may struggle with\nindustrial anomaly detection, we further provide additional\nvisual and textual hints. For the visual hints, we plot a red\nbounding box for each anomalous region on the input image to make the model aware of the locations of anomalies.\nThe textual hints are composed of the bounding box coordinates of the anomalous regions and corresponding anomaly\ntypes, such as “the location and label of the abnormal area\nis ([xmin , ymin , xmax , ymax ], ‘broken’)”.\nAfter obtaining the MLLM-generated texts, to ensure\nthat the text description is consistent with the anomalies in\nthe image, we further verify the generated texts and only retain the correct texts. Specifically, we extract the predicted\nanomaly regions from “&lt;answer&gt;&lt;/answer&gt;” and compare them with the true anomaly regions. The text is considered correct when the predicted and true anomaly regions\nare consistent. More details about the verification process\nare provided in Appendix C.\nText Data Generation Instruction. To correctly generate the “think-then-answer” text, we design a straightforward instruction template that guides Qwen2.5-VL-72B to\nfollow our specified requirements. As shown in Tab.2, we\nintentionally constrain the output of the model to follow this\nstructural format, avoiding the model simply copying our\nhints to the generated response without dedicated thinking.\n\n3.3. Data Statistics\nOur MMR-AD dataset totally contains 127137 images from\n188 classes of industrial products across 14 public AD\ndatasets, with 395 anomaly types and 112875 annotated\nanomalous regions. Among these, 98915 images are categorized as anomalous and have mask annotations and\nbounding boxes to provide abnormal location information.\n\nFor text data, after tokenization, there are a total of 26M\ntext tokens, with an average of 208 tokens per sample.\nCompared with previous multi-modal AD datasets (MMAD\n[24], Anomaly-Instruct-125K [49]), as shown in Tab.3,\nMMR-AD leads significantly in both dataset size, anomaly\ntype, text granularity, and text volume. We show several\nexamples from the MMR-AD dataset in Fig.3.\nTable 3. Comparison with previous multi-modal AD datasets on\n✗ : short description text.\ndifferent attributes. ✘: no reasoning text. ✔\n✔: detailed reasoning text. “coarse” means anomalous location\nis described in coarse-grained words, such as “top left”, “bottom\nright”, etc. “precise” means anomalous location is described in\nfine-grained coordinates, such as “[xmin , ymin , xmax , ymax ]”.\nIn Anomaly-Instruct-125K, there is no defect type label given for\neach sample, thus the “Defect Types” column is hard to count.\nDataset\n\nObject\nCategories\n\nImage Number\nNormal Anomaly\nAll\n\nDefect\nTypes\n\nReasoning\nText\n\nText\nTokens\n\nText Tokens\nPer Sample\n\nMMAD [24]\nAnomaly-Instruct-125K [49]\n\n38\n463\n\n3290\n63628\n\n5076\n61285\n\n8366\n125K\n\n244\n/\n\n✘\n✗\n✔\n\n0.58M\n10M\n\n69\n80\n\nAnomalous Region\nLocation\ncoarse\ncoarse\n\nMMR-AD\n\n188\n\n28222\n\n98915\n\n127K\n\n395\n\n✔\n\n26M\n\n208\n\nprecise\n\nAdvantage Analysis. Our MMR-AD dataset has advantages in the following aspects: (1) High Quality: To ensure\nlarge scale and high diversity, we collected a wide range of\nindustrial product categories and rich anomaly types in our\nMMR-AD dataset (see Tab.1). Meanwhile, to guarantee the\nquality of the dataset, we manually checked all the data and\nremoved low-quality samples. MMR-AD is the first multimodal AD dataset to provide over 127K industrial product\nsamples. In contrast, 72K data of Anomaly-Instruct-125K\ncomes from the Web, which is not from real-world industrial scenarios. (2) Better Explainability: Compared with\nMMAD and Anomaly-Instruct-125K, MMR-AD provides\na more comprehensive anomaly detection reasoning process, which can provide better explainability (see Fig.3) for\nthe decision of the model (on why the model makes such\na decision and how the model detects anomalies through\nstep-by-step analysis and comparison). While MMAD only\nprovides QA format text with multiple choices, this lacks\nexplainability. Text data in Anomaly-Instruct-125K only\ncontains a brief description of anomalies without an explicit reasoning process, the explainability is also insufficient. (3) Improvable: Our MMR-AD dataset provides\noriginal bounding box data for anomalous regions. This\n\n\fAnomaly-Instruct-125K\nAre there any anomalies in this\ncable image?\n- Yes, the green wire is missing its\ninternal copper conductors, unlike\nthe blue and brown wires, which\ncontain complete sets of bundled\ncopper strands.\n\nAre there any significant anomalies\ndetected on this cookie?\n- Yes, there are two significant\nanomalies on the cookie: a central\ndefect featuring a noticeable hole\nand an edge defect showing a gap\nor crack.\n\nMMAD\n\nIs there any defect in the object?\nA: Yes. √\nB: No.\nThere is a defect in the object. What\nis the type of the defect?\nA: A mold growth.\nB: A crack. √\nC: A stain.\nD: A deformation.\nThere is a defect in the object. Where\nis the defect?\nA: On the tip.\nB: Inside the nut.\nC: On the base.\nD: Around the center. √\n\nMMR-AD\n\n&lt;think&gt;\nTo determine if there are any anomalies in the second\nimage, I will compare it with the first image. The first\nimage shows a normal sample of three cables with their\ninternal wires neatly arranged and no visible defects.\nIn the second image, upon close inspection:\n- The green cable appears normal.\n- The brown cable also appears normal.\n\n- The blue cable has some wires that seem bent or\nmisaligned compared to the neat arrangement in the\nfirst image.\nBased on this analysis, the blue cable in the\nsecond image contains an anomaly where the wires\nare bent. The location of this abnormal area is [91, 199,\n217, 296].\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [91, 199, 217, 296],\n'label': 'bent wire'}&lt;/answer&gt;\n\nMMR-AD\n\nMMR-AD\n\n&lt;think&gt;\nTo determine if there are any anomalies in the second image, I\nwill compare it with the first image which is considered normal.\n\n&lt;think&gt;\nTo determine if there are anomalies in the second image, I'll compare the\ncontents of both images:\n\n1. **Shape and Structure**: The second image shows a cookie\nthat appears to have an irregular shape compared to the first one.\nThere seems to be a part where the structure of the cookie is\nbroken or cracked.\n2. **Surface Texture**: Upon closer inspection, there is a\nnoticeable area on the surface of the cookie in the second image\nwhere the texture is disrupted. This disruption looks like a hole or\na missing piece of the cookie.\n3. **Chocolate Chips**: The distribution of chocolate chips\nseems consistent between both images, so this is not a point of\nconcern.\n\n1. **First Image Analysis**:\n- The left side contains three fruits: a peach and two oranges.\n- The right side contains granola with nuts and dried fruit.\n\nBased on these observations, the areas that appear\nabnormal are:\n- A crack on the left side of the cookie.\n- A hole near the center-right of the cookie.\n\nBased on this analysis, the content has been rearranged, which indicates\nan anomaly in the second image. The locations of the abnormal areas can be\nidentified as follows:\n- The area that originally contained fruits is now filled with granola: [50, 28, 256,\n395].\n- The area that originally contained granola is now filled with fruits: [222, 33, 515,\n395].\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [50, 28, 256, 395], 'label': 'Component\nSwapped'}, {'bbox_2d': [222, 33, 515, 395], 'label': 'Component\nSwapped'}&lt;/answer&gt;\n\nThe coordinates for these areas can be estimated as follows:\n- Crack: [72, 154, 123, 314]\n- Hole: [203, 167, 275, 241]\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [72, 154, 123, 314], 'label':\n'crack'}, {'bbox_2d': [203, 167, 275, 241], 'label': 'hole'}&lt;/answer&gt;\n\n2. **Second Image Analysis**:\n- The left side now contains granola with nuts and dried fruit.\n- The right side contains the three fruits (peach and two oranges).\n\n3. **Comparison**:\n- In the first image, the fruits were on the left and the granola was on the right.\n- In the second image, the positions of these components have been swapped.\n\nFigure 3. Data examples from our MMR-AD dataset and comparison with MMAD [24] and Anomaly-Instruct-125K [49]. In our MMRAD, each data example is based on two images: the first is the normal reference sample, and the second is the input sample. The reasoning\nand analysis words are highlighted in blue and red, red especially marks the anomaly-related reasoning words. Finally, a summary of the\nreasoning and analysis contents is provided at the end of &lt;think&gt;, these words are highlighted in bold.\n\nmeans that MMR-AD not only can be used to evaluate the\nprecise anomaly localization ability of MLLM-based AD\nmodels, but more importantly, it is improvable. If users are\nnot satisfied with the existing texts, based on the raw bounding boxes and our automatic pipeline, they can flexibly utilize the latest and more powerful MLLMs to generate better\ntext data, and then train better AD models. However, both\nMMAD and Anomaly-Instruct-125K do not provide bounding box data, which makes it hard for these two datasets to\nbe improved with the introduction of new MLLMs.\n\n4. Baseline\nBased on MMR-AD, we further propose a baseline model,\nAnomaly-R1, which is fine-tuned from Qwen2.5-VL with\nthe LoRA adapter [22]. Recently, reinforcement learning\nhas gained widespread application in the post-training process of MLLMs [16, 37, 48]. Compared to conventional\npost-training strategies such as supervised fine-tuning and\ndirect preference optimization [40], RL offers better generalization and has been demonstrated as the key part in\nlearning reasoning capabilities. Therefore, we also opt to\ntrain our baseline model based on reinforcement learning.\n\n4.1. Reinforcement Learning\nThe recent rule-based reinforcement learning [42, 59] has\npromoted the success of many reasoning models. We think\nthat the rule-based reinforcement learning is also quite suitable for the anomaly detection task, as we can provide clear\nrewards for RL training based on whether the generated answers are consistent with the ground-truth labels.\nReward Function. We employ the prompt template in\nTab.2 to guide the model first to perform an explicit thinking\n\nprocess and then provide the final answer. With the output\nformat, we can define our reward functions as follows:\n• Result Reward. The model’s generated final answers\nmust align with the ground-truth labels. For abnormal samples, the final answers should include “Yes”, while for normal samples, they need to have “No”. If the extracted final\nanswer is correct, the reward is 1, otherwise it is 0.\n• Consistency Penalty. However, simply depending\non the image-level answers is not precise enough. During\ntraining, we observed that for ground-truth abnormal areas,\nthe model may incorrectly predict their locations but still\noutput “Yes”. When a sample demonstrates poor anomalous region localization but produces the correct answer, a\nreward of 1 will make this pattern inevitably reinforced, resulting in the model not truly learning what needs to be considered as abnormal and how to correctly identify anomalies. Instead, it may be easier to recognize the entire sample as abnormal due to some noise disturbance. To address\nthis issue, we introduce an additional consistency penalty.\nSpecifically, we calculate the IOUs between the predicted\nbboxes and the ground-truth bboxes, and when the IoU\n&gt; 0.5, we consider a predicted bbox being matched to a\nground-truth bbox. For each ground-truth bbox, if there is\nno matched bbox, the corresponding abnormal area will be\nconsidered as not being detected correctly. For N undetected ground-truth bboxes, we add a penalty of −0.2 ∗ N .\nOptimization Algorithm. We utilize GRPO [42] as the\nRL optimization algorithm, as GRPO can bypass the need\nfor the value model by computing the relative advantage\nof each response within a group of responses to the same\nquery. Specifically, for each input query q, we sample a\ngroup of responses {o1 , o2 , . . . , oG }. Then GRPO maxi-\n\n\fmizes the following objective for optimizing the model πθ .\n\u0014\nEq∼D,{oi }G\n\ni=1 ∼πθold (·|q)\n\n1\nPG\n\n|oi |\nG X\nX\n\ni=1 |oi | i=1 t=1\n\n\u0010\nmin wi,t (θ)Âi,t ,\n\n\u0015\n\u0011\nclip(wi,t (θ), 1 − ϵ, 1 + ϵ)Âi,t − βDKL (πθ ||πref )\n\n(1)\n\nwhere G is the number of generated responses to each\nquery q (i.e., the group size), ϵ and β are the PPO clipping hyperparameter and the coefficient controlling the KL\npenalty, respectively. The importance ratio wi,t (θ) and advantage Âi,t of the token oi,t are calculated as:\nri − mean({ri }G\nπθ (oi,t |q, oi,&lt;t )\ni=1 )\n; Âi,t =\nπθold (oi,t |q, oi,&lt;t )\n)\nstd({ri }G\ni=1\n(2)\nwhere all the tokens in oi share the same advantage as Âi,t ,\n{ri }G\ni=1 means the group of rewards for the groups of generated responses {oi }G\ni=1 .\nContrastive Sampling. During training, a major issue\nof GRPO is that a group of advantages may be all zero (i.e.,\nif all responses {oi }G\ni=1 of a particular query are correct (or\nwrong), the received rewards are the same, the resulting\nadvantages for this group are all zero). A zero advantage\nwill result in zero policy gradient, thereby increasing the\nnoise sensitivity of the batch gradient and degrading sample efficiency. Empirically, the model will become more\naccurate during the training process, and the number of correctly predicted responses will continue to increase. This\nmeans that the effective number of prompts in the batch\nkeeps decreasing, which can lead to larger variance in gradient and dampen the gradient signals for model training.\nTo this end, we propose a contrastive sampling approach to\nensure that each query receives both positive and negative\nresponses. To avoid the case that all responses are negative, for each query, we include the correct text provided\nin our MMR-AD dataset as a positive response to the response group. Because this text is generated based on our\nhints and has been checked (see Sec.3.2), it can be guaranteed to be correct (positive). If all responses are positive,\nwe will randomly select two responses and then utilize an\nexternal MLLM (e.g., Qwen2.5-VL-72B) to regenerate. To\nobtain corresponding negative responses, we will add opposite hints (i.e., if the sample is normal, we will tell the\nmodel that “this sample is abnormal”) in the prompt and\nrequire the model to generate responses based on our hints.\nAnomaly-Related Domain Knowledge. One characteristic of MLLMs is that we can introduce domain-specific\nknowledge in the prompt to help the model better complete\ntasks. In our MMR-AD dataset, a text label that can summarize the anomaly visual appearance is provided for each\nanomalous region. Then, for each product category, we\ncan collect all non-repetitive text labels as domain knowledge for providing to the MLLM, prompting the model to\nwi,t (θ) =\n\ninspect whether there are corresponding anomalies in the\nreasoning process, and avoiding identifying some other differences that are not considered anomalies in this product\nas anomalies. Specifically, we inject the following domain\nknowledge prompt in the input instruction:\nDomain Knowledge: In the &lt;category name&gt; sample, the following types of anomalies: &lt;category-specific\nanomalies&gt;, may occur. You should carefully inspect\nwhether there are these anomalies, and apart from these\nanomaly types, other minor differences do not need to be\nconsidered as anomalies.\nwhere &lt;category name&gt; will be replaced with specific product name, &lt;category-specific anomalies&gt; contains specific anomaly text labels for this product, e.g., “broken”, “deformation”, “missing component”, etc.\n\n4.2. Cold-Start Initialization\nSince generalist MLLMs are not initially trained for\nanomaly detection tasks, directly applying MLLMs for reinforcement learning training yields poor results (see Tab.5).\nTherefore, we first train the model by supervised fine-tuning\n(SFT) on our MMR-AD dataset for cold-start initialization.\nThis SFT training phase aims to teach the model the basic\nformat-following ability and assist it in familiarizing the industrial anomaly detection and localization task.\n\n5. Experiments\n5.1. Experimental Setup\nImplementation Details. For the cold-start initialization of\nAnomaly-R1, we adopt Qwen2.5-VL-7B as the base model\nand post-train it via supervised fine-tuning for 3 epochs.\nWe employ the LoRA technique [22] to fine-tune the base\nmodel. The low rank r in LoRA is set to 16. During the SFT\nphase, the learning rate is set to 2e-5, and the batch size is\nset to 4. During the RL phase, for rollout, the prompt batch\nsize is 32, and we sample 8 responses for each prompt. The\nmaximum number of tokens for generation is set to 512 tokens. The ϵ and β in the GRPO algorithm are set to 0.2 and\n0.001, respectively. The learning rate is set to 2e-6. During\ninference, we use the min-p sampling [33] strategy with the\ntemperature and mip-p hyperparameters set to 1.5 and 0.1.\nMore elaborated implementation details are in Appendix D.\nEvaluation Datasets. One key advantage of our MMRAD dataset is that all samples are divided into multiple subdatasets based on their original dataset names. Thus, our\nMMR-AD dataset is very suitable for training and evaluating MLLM-based GAD models. We can utilize a subdataset\nas the testing set and the remaining subdatasets as the training set. Evaluating on all subdatasets will result in too many\nexperiments. Then, we select four subdatasets for evaluation, including MVTecAD, VisA, MVTec3D, and MPDD.\nWe utilize accuracy, recall, and precision as the evaluation\n\n\fTable 4. Performance evaluation of anomaly detection and localization for both commercial and open-source MLLMs. All the MLLMbased models (except AnomalyGPT) are based on the (reference, input) image pair as the image input and use the instruction template in\nTab.2 for generation. ·/· means anomaly detection/localization metrics, respectively. Anomaly-R1-7B† is a variant in which we add domain\nknowledge (see Sec.4.1). Bold means the best performance (the full-shot AD models are not included in the comparison).\nMVTecAD\n\nModel\nAccuracy\n\nRecall\n\nVisA\nPrecision\n\nAccuracy\n\nRecall\n\nMVTec3D\nPrecision\n\nMPDD\n\nAccuracy\n\nRecall\n\nPrecision\n\nAccuracy\n\nRecall\n\nPrecision\n\n75.7/10.9\n67.8/7.0\n75.0/27.2\n74.1/15.7\n74.8/11.2\n\n90.1/18.3\n74.0/11.5\n85.3/41.1\n77.0/25.5\n99.8/25.0\n\n83.2/19.9\n83.4/14.8\n84.1/43.2\n89.3/29.4\n75.5/16.7\n\n62.1/16.3\n63.1/13.6\n68.4/21.2\n70.5/23.9\n59.3/18.0\n\n92.2/23.2\n84.3/20.4\n91.9/34.5\n85.7/40.6\n98.3/42.8\n\n60.8/26.7\n64.3/22.3\n67.0/29.2\n74.1/31.1\n58.9/22.5\n\n67.1/6.1\n75.1/0.7\n75.5/1.0\n75.9/2.1\n59.9/1.2\n71.6/13.3\n65.8/1.1\n74.4/1.4\n64.7/-\n\n69.1/9.6\n98.4/1.6\n88.6/2.1\n87.8/3.9\n55.1/1.8\n75.8/19.2\n66.7/1.9\n83.8/2.6\n68.6/-\n\n86.7/13.9\n75.7/1.3\n83.2/2.0\n84.3/4.5\n90.9/3.6\n86.4/27.0\n86.9/2.4\n85.6/2.9\n84.6/-\n\n64.1/10.0\n59.0/3.5\n68.3/3.9\n65.9/5.4\n63.6/7.2\n67.0/24.7\n64.3/4.1\n70.2/5.1\n67.6/-\n\n70.7/12.7\n99.1/7.5\n91.5/7.6\n96.6/10.7\n61.2/9.1\n77.0/32.4\n64.5/5.8\n87.5/10.1\n73.2/-\n\n68.8/18.0\n58.7/5.2\n66.2/6.1\n64.1/9.2\n71.7/15.1\n71.3/37.9\n69.8/8.7\n71.0/8.3\n58.9/-\n\nCommercial Model\nGemini-2.5-pro\nGPT-4o\nGPT-5\nOpenAI-o4-mini\nQwen-QVQ-Max\n\n79.4/34.4\n68.9/8.1\n78.7/41.8\n81.3/34.4\n73.4/26.6\n\n98.4/46.0\n74.1/12.9\n95.9/64.2\n94.4/53.5\n99.7/44.6\n\n79.0/48.8\n82.4/16.9\n79.4/53.0\n83.1/46.5\n73.5/35.9\n\n65.7/10.5\n57.6/3.7\n65.8/18.5\n73.0/12.3\n57.2/4.8\n\n97.2/17.1\n69.4/5.8\n94.5/31.0\n89.1/20.9\n96.6/10.0\n\n62.7/21.3\n61.1/9.2\n63.3/30.7\n71.4/22.2\n56.6/8.2\n\nLlama4-Maverick\nGemma3-27B\nInternVL3-8B\nInternVL3-38B\nQwen2.5-VL-7B\nQwen2.5-VL-72B\nInternVL3.5-8B\nInternVL3.5-38B\nAnomalyGPT-7B\n\n76.1/19.9\n74.4/4.0\n78.4/5.5\n83.8/6.3\n75.0/8.9\n83.9/36.4\n76.5/5.4\n84.9/7.1\n85.7/-\n\n83.2/28.4\n99.6/8.5\n96.3/10.5\n97.3/11.5\n70.8/12.5\n94.4/47.8\n81.3/9.7\n95.6/13.2\n86.5/-\n\n83.5/36.2\n74.2/7.0\n78.5/9.5\n83.5/11.7\n92.4/20.8\n85.6/53.0\n85.4/10.6\n85.8/12.4\n90.6/-\n\n63.8/6.7\n58.5/0.5\n71.5/2.9\n71.7/2.2\n65.9/2.2\n70.0/11.1\n67.8/2.2\n74.1/1.8\n72.8/-\n\n71.6/10.3\n98.6/1.4\n72.2/5.0\n89.9/3.9\n50.4/3.0\n79.1/15.9\n66.1/3.3\n87.5/3.2\n67.6/-\n\nPaDiM [12]\nPatchCore [41]\nHGAD [56]\nDinomaly [19]\nINP-Former [31]\n\n93.4/65.0\n93.8/73.2\n96.2/73.2\n94.1/58.5\n95.7/59.2\n\n96.2/84.7\n97.5/82.7\n96.1/86.3\n93.2/84.3\n97.5/84.6\n\n94.8/74.0\n94.6/86.8\n98.3/82.4\n97.8/66.0\n96.9/66.2\n\n81.5/34.1\n83.0/44.9\n90.6/52.7\n79.8/34.3\n83.2/36.2\n\n80.6/48.6\n80.3/51.2\n91.5/64.0\n69.8/47.5\n78.1/51.2\n\n85.2/51.9\n90.7/78.0\n92.1/75.5\n96.0/54.2\n93.4/53.7\n\n82.2/32.4\n81.4/39.7\n84.5/45.5\n82.0/44.3\n84.8/48.2\n\n97.0/44.8\n96.6/46.2\n95.4/56.6\n93.1/62.8\n93.2/58.0\n\n84.1/52.8\n83.5/69.8\n87.6/64.8\n86.7/57.1\n89.3/69.0\n\n74.7/28.1\n86.3/57.3\n86.5/34.2\n87.5/56.0\n87.9/49.4\n\n96.4/48.2\n84.1/62.9\n81.8/51.6\n88.3/64.7\n85.1/65.9\n\n72.6/37.4\n92.3/76.5\n90.2/44.2\n91.0/69.0\n94.2/58.4\n\nAnomaly-R1-7B\nAnomaly-R1-7B†\n\n88.8/66.3\n91.0/67.7\n\n91.9/74.2\n94.3/76.0\n\n92.8/84.2\n93.2/83.2\n\n74.9/36.4\n79.0/37.9\n\n72.3/41.2\n77.0/45.2\n\n82.7/77.3\n83.7/70.5\n\n74.6/48.5\n80.2/48.4\n\n73.8/56.0\n87.5/63.2\n\n92.8/78.8\n88.3/68.2\n\n70.8/35.9\n73.5/36.9\n\n74.2/45.6\n93.4/50.0\n\n77.6/52.8\n71.0/49.6\n\nOpen-source Model\n66.2/15.4\n57.3/0.9\n74.2/6.3\n69.0/4.9\n77.1/8.7\n71.0/25.5\n72.4/5.5\n72.4/3.8\n79.8/-\n\nFull-shot Anomaly Detection Model\n\nmetrics, as MLLMs directly generate text-based answers,\nwhich are not suitable for AUROC calculation.\nEvaluated Models. In this work, we wonder to know\nhow the current generalist MLLMs perform when used for\nindustrial AD. Then, we evaluate a large number of the latest and most powerful MLLMs as baselines. For commercial models, we call their APIs, including Gemini-2.5-pro\n[16], GPT-4o [35], GPT-5 [36], OpenAI-o4-mini [37], and\nQwen-QVQ-Max [39]. For open-source models, we adapt\nand test Llama4 [32], Gemma3 [17], InternVL3 [66], InternVL3.5 [48], and Qwen2.5-VL [3].\n\n5.2. Experimental Results\nIn Tab.4, we report the dataset-level average results across\ntheir respective data classes. For anomaly localization, we\nreport the results under 0.1 IoU (i.e., if IoU ≥ 0.1, the predicted box is considered correct). The results in Tab.4 reveal that even the current most powerful generalist MLLMs\n(e.g., GPT-5, Gemini-2.5-pro) are still not competent for industrial AD tasks. Especially, the performance of precise\nanomaly localization (based on predicting bounding boxes)\nis very poor. Although at a relatively low IoU, the localization accuracies of many models are even less than 10%.\nIn the experiments, we also observed that the generalist\nMLLMs tend to recognize samples as abnormal, and some\n\nmodels almost classify all samples as abnormal (e.g., QwenQVQ-Max, Gemma3-27B, the recall values are abnormally\nhigh, and the precisions are very low).\nThrough post-training on our MMR-AD dataset, our\nfinetuned Anomaly-R1-7B shows significant performance\nimprovement compared to the base model, Qwen2.5-VL7B. Especially, the anomaly localization capability has been\ngreatly improved (8.9 to 66.3 on MVTecAD). Even compared to larger models, our Anomaly-R1-7B also shows better anomaly detection and localization capabilities. This\nindicates that post-training on domain-specialized multimodal AD datasets is necessary when applying generalist\nMLLMs to industrial anomaly detection. Our MMR-AD\nnot only provides high-quality training data to effectively\nenhance the anomaly reasoning, detection, and localization\ncapabilities of MLLMs, but also can be used to comprehensively evaluate the general AD performance of MLLMbased AD models. Therefore, our dataset provides strong\nsupport for MLLM-based general AD research.\nFurthermore, to know the gap with the previous expert\nmodels, we also report the results of two classical AD models and current SOTA multi-class AD models. However,\nconventional AD models output anomaly scores, which are\nnot suitable for measuring the final accuracy and require\nfurther thresholding. To this end, we change the threshold\n\n\fin the range [0, 1] with 0.1 as a step1 , and then select the best\nvalue as the final threshold. The results show that there is\nstill a certain performance gap between MLLM-based general AD models and the conventional full-shot AD models. This is understandable, as neither our Anomaly-R1 nor\nother MLLMs have been retrained on these datasets, while\nthe full-shot AD models are trained using all normal samples from these datasets. This also indicates that general\nAD still has a large room for improvement.\nQualitative Results. Due to the page limitation, we\nshow some qualitative results in Appendix E.\n\n5.3. Further Analysis\nIs the reasoning-based text necessary? Currently, reasoning is widely regarded as a critical pathway for LLMs to\naddress complex problems and reach AGI. In the research\nof multimodal anomaly detection, we also wonder to know\nwhether reasoning can bring stronger generalizability. To\nthis end, we remove the reasoning texts in the &lt;think&gt; part\nduring training, allowing the model to directly predict the\nfinal answers. The results are in Tab.5. It can be found that\nwithout the explicit reasoning steps, the model performs\nworse than the reasoning-based model. This demonstrates\nthat explicit reasoning is conducive for the MLLM to learn\ngeneral AD analysis and comparison abilities to recognize\nanomalies, while direct prediction is prone to making the\nmodel memorize the trained anomalies.\nTable 5. Further analysis experiments. We investigate the impact\nof Reasoning-based Text, Normal Reference Image, Cold Start Initialization, Contrastive Sampling, and Domain knowledge.\nMVTecAD\n\nModel\nw/o Reasoning Data\nw/o Normal Reference Image\nw/o CoT Cold-Start\nw/o Reinforcement learning\nw/o Contrastive Sampling\nAnomaly-R1-7B\n+ Domain Knowledge\n\nVisA\n\nAccuracy\n\nRecall\n\nPrecision\n\nAccuracy\n\nRecall\n\nPrecision\n\n81.3/53.5\n81.7/62.1\n75.1/12.3\n84.5/55.9\n87.7/62.2\n88.8/66.3\n91.0/67.7\n\n89.7/63.4\n87.2/71.4\n84.3/15.4\n88.1/64.4\n85.1/69.2\n91.9/74.2\n94.3/76.0\n\n84.8/70.6\n88.3/80.1\n81.4/23.9\n87.9/77.7\n96.9/84.6\n92.8/84.2\n93.2/83.2\n\n66.1/18.8\n62.5/24.9\n68.0/5.3\n73.3/34.3\n73.7/35.8\n74.9/36.4\n79.0/37.9\n\n68.0/24.8\n52.2/29.1\n77.5/6.3\n63.8/40.3\n56.8/39.3\n72.3/41.2\n77.0/45.2\n\n68.6/39.5\n80.8/70.5\n68.3/10.8\n83.4/68.3\n91.0/80.7\n82.7/77.3\n83.7/70.5\n\nCan MLLMs effectively utilize the normal reference\nimage? When humans recognize anomalies, having a template image to understand what normal looks like is often\nvery helpful. To further investigate the effect of the normal\nreference image, we conduct experiments without the normal reference image in each input prompt. The results are\nshown in Tab.5. The results indicate that normal reference\nimage is valuable, and the model’s general AD ability can\nbe significantly improved. This indicates that the MLLM\ncan effectively utilize the normal reference image to learn\ngeneral analysis and comparison abilities.\n1 For anomaly localization, we utilize the same threshold to obtain the\n\nsegmentation mask, and then utilize cv2.findContours to obtain the bounding boxes of segmented regions, and finally perform NMS to obtain the\npredicted bboxes. We also select the best value as the final threshold.\n\nCan only RL incentivize AD reasoning capability in\nMLLMs? We further investigate whether AD models can\nbe directly trained by RL. Unfortunately, as shown in Tab.5,\ndirectly applying RL to train the AD model has proven\nchallenging in stimulating the MLLM’s AD reasoning capability. In particular, with zero-RL, the anomaly localization performance of the model is quite poor. Moreover, we observed that during training, the model even performed poorly in following the basic &lt;think&gt;&lt;answer&gt;\noutput format. Thus, we think that since generalist MLLMs\ninitially don’t have good AD-related capabilities, the CoT\ncold-start initialization on our MMR-AD dataset is necessary for making them familiar with the AD task and endowing them with domain knowledge for further post-training.\nAblation study of the contrastive sampling. We examine the effectiveness of the contrastive sampling strategy. In\nTab.5, it can be found that when the contrastive sampling is\nremoved, the performance of the model will decrease. This\nindicates that this strategy can effectively avoid the negative\nimpact of zero advantage groups.\nAnomaly-related domain knowledge. As shown in\nTab.5, the inclusion of domain knowledge significantly improves performance. This indicates that the lack of domain\nknowledge is a major limitation of MLLMs in industrial\nAD. Simply providing relevant knowledge in the form of\ntext, the model can effectively utilize them to make more\naccurate decisions.\n\n6. Conclusion\nIn this work, our evaluation of current SOTA MLLMs\nshows less than optimistic results, revealing their weakness\nin tackling industrial AD tasks, especially the poor ability\nto accurately locate anomalies. This indicates that domainspecific post-training of MLLMs is still necessary. However, the AD field lacks a large-scale multimodal dataset\nfor training and evaluating MLLM-based AD models. To\nfacilitate MLLM-based general AD research, we introduce\nMMR-AD, the current largest multimodal reasoning-based\nIAD dataset. Based on the MMR-AD dataset, we further present a baseline model, Anomaly-R1, which can\nachieve remarkable improvements over advanced generalist MLLMs. We hope that MMR-AD will pave the way for\nmultimodal anomaly detection research and promote the development of MLLM-based general AD models.\n\nAcknowledgments\nThis work was supported in part by the National Natural\nScience Fund of China (No.62371295), the Shanghai Jiao Tong University AI for Engineering Initiative (No.WH410263001/001), and the Science and\nTechnology Commission of Shanghai Municipality\n(No.22DZ2229005).\n\n\fReferences\n[1] Akshatha Arodi, Margaux Luck, Jean-Luc Bedwani, Aldo\nZaimi, Ge Li, Nicolas Pouliot, Julien Beaudry, and\nGaétan Marceau Caron.\nCableinspect-ad: An expertannotated anomaly detection dataset. In NeurIPS, 2024. 3\n[2] Jinze Bai, Shuai Bai, Shusheng Yang, Shijie Wang, Sinan\nTan, Peng Wang, Junyang Lin, Chang Zhou, and Jinren\nZhou. Qwen-vl: A frontier large vision-language model with\nversatile abilities. arXiv preprint arXiv: 2308.12966, 2023.\n2\n[3] Shuai Bai, Keqin Chen, Xuejing Liu, Jialin Wang, Wenbin\nGe, Sibo Song, Kai Dang, Peng Wang, Shijie Wang, Jun\nTang, and et al. Qwen2.5-vl technical report. arXiv preprint\narXiv:2502.13923, 2025. 2, 3, 7\n[4] Tianpeng Bao, Jiadong Chen, Wei Li, Xiang Wang, Jingjing\nFei, Liwei Wu, Rui Zhao, and Ye Zheng. Miad: A maintenance inspection dataset for unsupervised anomaly detection. In ICCV Workshop, 2023. 3\n[5] Paul Bergmann, Michael Fauser, David Sattlegger, and\nCarsten Steger. Mvtec ad - a comprehensive real-world\ndataset for unsupervised anomaly detection. In CVPR, 2019.\n3\n[6] Paul Bergmann, Xin Jin, David Sattlegger, and Carsten Steger. The mvtec 3d-ad dataset for unsupervised 3d anomaly\ndetection and localization. arXiv preprint arXiv:2112.09045,\n2021. 3\n[7] Paul Bergmann, Kilian Batzner, Michael Fauser, David Sattlegger, and Carsten Steger. Beyond dents and scratches:\nLogical constraints in unsupervised anomaly detection and\nlocalization. In IJCV, 2022. 3\n[8] Yunkang Cao, Xiaohao Xu, Chen Sun, Xiaonan Huang, and\nWeiming Shen. Towards generic anomaly detection and\nunderstanding: Large-scale visual-linguistic model (gpt-4v)\ntakes the lead. arXiv preprint arXiv:2311.02782, 2023. 1, 2\n[9] Qiyu Chen, Huiyuan Luo, Chengkan LV, and Zhengtao\nZhang. A unified anomaly synthesis strategy with gradint\nascent for industrial anomaly detection and localization. In\nECCV, 2024. 3\n[10] Zhe Chen, Weiyun Wang, Yue Cao, Yangzhou Liu, Zhangwei Gao, Erfei Cui, Jinguo Zhu, Shenglong Ye, Hao Tian,\nZhaoyang Liu, and et al. Expanding performance boundaries\nof open-source multimodal models with model, data, and\ntest-time scaling. arXiv preprint arXiv:2412.05271, 2024.\n2\n[11] Zhe Chen, Jiannan Wu, Wenhai Wang, Weijie Su, Guo Chen,\nSen Xing, Muyan Zhong, Qinglong Zhang, Xizhou Zhu,\nLewei Lu, and et al. Internvl: Scaling up vision foundation models and aligning for generic visual-linguistic tasks.\nIn CVPR, 2024. 2\n[12] Thomas Defard, Aleksandr Setkov, Angelique Loesch, and\nRomaric Audigier. Padim: a patch distribution modeling framework for anomaly detection and localization. In\n1st International Workshop on Industrial Machine Learning,\n2021. 1, 7\n[13] Hanqiu Deng and Xingyu Li. Anomaly detection via reverse\ndistillation from one-class embedding. In CVPR, 2022. 1\n\n[14] Xiaoyi Dong, Pan Zhang, Yuhang Zang, Yuhang Cao, Bin\nWang, Linke Ouyang, Xilin Wei, Songyang Zhang, Haodong\nDuan, Maosong Cao, and et al. Internlm-xcomposer2:\nMastering free-form text-image composition and comprehension in vision-language large model. arXiv preprint\narXiv:2401.16420, 2024. 2\n[15] Lei Fan, Dongdong Fan, Zhiguang Hu, Yiwen Ding, Donglin\nDi, Kai Yi, Maurice Pagnucco, and Yang Song. Manta:\nA large-scale multi-view and visual-text anomaly detection\ndataset for tiny objects. In CVPR, 2025. 3\n[16] Google Gemini Team. Gemini 2.5: Pushing the frontier with advanced reasoning, multimodality, long context,\nand next generation agentic capabilities. arXiv preprint\narXiv:2507.06261, 2025. 2, 5, 7\n[17] Google Gemma Team. Gemma 3 technical report. arXiv\npreprint arXiv:2503.19786, 2025. 7\n[18] Zhaopeng Gu, Bingke Zhu, Guibo Zhu, Yingying Chen,\nMing Tang, and Jinqiao Wang. Anomalygpt: Detecting industrial anomalies using large vision-language models. In\nAAAI, 2024. 1, 3, 4\n[19] Jia Guo, Shuai Lu, Weihang Zhang, Fang Chen, Huiqi Li,\nand Hongen Liao. Dinomaly: The less is more philosophy in\nmulti-class unsupervised anomaly detection. In CVPR, 2025.\n1, 7\n[20] Jianfei Hu Hanxi Li, Bo Li, Hao Chen, Yongbin Zheng, and\nChunhua Shen. Target before shooting: Accurate anomaly\ndetection and localization under one millisecond via cascade\npatch retrieval. arXiv preprint arXiv: 2308.06748, 2023. 1\n[21] Haoyang He, Jiangning Zhang, Hongxu Chen, Xuhai Chen,\nZhishan Li, Xu Chen, Yabiao Wang, Chengjie Wang, and\nLei Xie. Diad: A diffusion-based framework for multi-class\nanomaly detection. In AAAI, 2024. 1\n[22] Edward Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu,\nYuanzhi Li, Shean Wang, Lu Wang, and Weizhu Chen. Lora:\nLow rank adaptation of large language models. In ICLR,\n2022. 5, 6, 2\n[23] Stepan Jezek, Martin Jonak, Radim Burget, Pavel Dvorak,\nand Milos Skotak. Deep learning-based defect detection of\nmetal parts: evaluating current methods in complex conditions. In 13th International Congress on Ultra Modern\nTelecommunications and Control Systems and Workshops,\n2021. 3\n[24] Xi Jiang, Jian Li, Hanqiu Deng, Yong Liu, Bin-Bin Gao,\nYifeng Zhou, Jialin Li, ChengjieWang, and Feng Zheng.\nMmad: The first-ever comprehensive benchmark for multimodal large language models in indutrial anomaly detection.\nIn ICLR, 2025. 3, 4, 5\n[25] Yuqi Jiang, Xudong Lu, Qian Jin, Qi Sun, Hanming Wu, and\nCheng Zhuo. Fabgpt: An efficient large multimodal model\nfor complex wafer defect knowledge queries. arXiv preprint\narXiv:2407.10810, 2024. 3\n[26] Yuqi Jiang, Xudong Lu, Qian Jin, Qi Sun, Hanming Wu, and\nCheng Zhuo. Vmad: Visual-enhanced multimodal large language model for zero-shot anomaly detection. IEEE Transactions on Automation Science and Engineering, 2024. 3\n[27] Tianwu Lei, Bohan Wang, Silin Chen, Shurong Cao, and\nNingmu Zou. Texture-ad: An anomaly detection dataset and\n\n\fbenchmark for real algorithm development. arXiv preprint\narXiv:2409.06367, 2024. 3\n[28] Yuanze Li, Haolin Wang, Shihao Yuan, Ming Liu, Debin\nZhao, Yiwen Guo, Chen Xu, and Guangming Shi. Myriad: Large multimodal model by applying vision experts\nfor industrial anomaly detection. arXiv preprint arXiv:\n2310.19070, 2023. 1, 3\n[29] Haotian Liu, Chunyuan Li, Qingyang Wu, and Yong Jae Lee.\nVisual instruction tuning. In NeurIPS, 2023. 2\n[30] Haotian Liu, Chunyuan Li, Yuheng Li, Bo Li, Yuanhan Zhang, Sheng Shen, and Yong Jae Lee.\nLlavanext: Improved reasoning, ocr, and world knowledge.\nhttps://github.com/LLaVA-VL/LLaVA-NeXT, 2024. 2\n[31] Wei Luo, Yunkang Cao, Haiming Yao, Xiaotian Zhang,\nJianan Lou, Yuqi Cheng, Weiming Shen, and Wenyong Yu.\nExploring intrinsic normal prototypes within a single image\nfor universal anomaly detection. In CVPR, 2025. 1, 7\n[32] Meta.\nThe llama 4 herd: The beginning of a\nnew era of natively multimodal ai innovation.\nhttps://ai.meta.com/blog/llama-4-multimodal-intelligence,\n2025. 7\n[33] Nguyen Nhat Minh, Andrew Baker, Clement Neo, Allen\nRoush, Andreas Kirsch, and Ravid Shwartz-Ziv. Turning\nup the heat: Min-p sampling for creative and coherent llm\noutputs. In ICLR, 2025. 6, 2\n[34] OpenAI.\nGpt-4v(ision)\nsystem\ncard.\nhttps://cdn.openai.com/papers/GPTV System Card.pdf,\n2023. 2\n[35] OpenAI. Gpt-4o system card. https://cdn.openai.com/gpt4o-system-card.pdf, 2024. 7\n[36] OpenAI. Gpt-5 system card. https://cdn.openai.com/gpt-5system-card.pdf, 2025. 7\n[37] OpenAI.\nOpenai o3 and o4-mini system card.\nhttps://cdn.openai.com/pdf/2221c875-02dc-4789-800be7758f3722c1/o3-and-o4-mini-system-card.pdf, 2025. 2, 5,\n7\n[38] Zhiliang Peng, Wenhui Wang, Li Dong, Yaru Hao, Shaohan\nHuang, Shuming Ma, and Furu Wei. Kosmos-2: Grounding multimodal large language models to the world. arXiv\npreprint arXiv:2306.14824, 2023. 2\n[39] Alibaba Qwen Team. Qvq-max: Think with evidence.\nhttps://qwenlm.github.io/blog/qvq-max-preview, 2025. 7\n[40] Rafael Rafailov, Archit Sharma, Eric Mitchell, Stefano Ermon, Christopher D. Manning, and Chelsea Finn. Direct\npreference optimization: Your language model is secretly a\nreward model. In NeurIPS, 2023. 5\n[41] Karsten Roth, Latha Pemula, Joaquin Zepeda, Bernhard\nScholkopf, Thomas Brox, and Peter Gehler. Towards total\nrecall in industrial anomaly detection. In CVPR, 2022. 1, 7\n[42] Zhihong Shao, Peiyi Wang, Qihao Zhu, Runxin Xu, Junxiao\nSong, Xiao Bi, Haowei Zhang, Mingchuan Zhang, YK Li, Y\nWu, and et al. Deepseekmath: Pushing the limits of mathematical reasoning in open language models. arXiv preprint\narXiv:2402.03300, 2024. 5\n[43] Guangming Sheng, Chi Zhang, Zilingfeng Ye, Xibin Wu,\nWang Zhang, Ru Zhang, Yanghua Peng, Haibin Lin, and\nChuan Wu. Hybridflow: A flexible and efficient rlhf framework. arXiv preprint arXiv:2409.19256, 2024. 2\n\n[44] Gemini Team, Rohan Anil, Sebastian Borgeaud, Yonghui\nWu, Jean-Baptiste Alayrac, Jiahui Yu, Radu Soricut, Johan\nSchalkwyk, Andrew M Dai, Anja Hauth, and et al. Gemini: a\nfamily of highly capable multimodal models. arXiv preprint\narXiv:2312.1180, 2023. 2\n[45] Chengjie Wang, Wenbing Zhu, Bin-Bin Gao, Zhenye Gan,\nJiangning Zhang, Zhihao Gu, Shuguang Qian, Mingang\nChen, and Lizhuang Ma. Real-iad: A real-world multi-view\ndataset for benchmarking versatile industrial anomaly detection. In CVPR, 2024. 2, 3\n[46] Peng Wang, Shuai Bai, Sinan Tan, Shijie Wang, Zhihao Fan,\nJinze Bai, Keqin Chen, Xuejing Liu, Jialin Wang, Wenbin Ge, and et al. Qwen2-vl: Enhancing vision-language\nmodel’s perception of the world at any resolution. arXiv\npreprint arXiv:2409.12191, 2024. 2\n[47] Weihan Wang, Qingsong Lv, Wenmeng Yu, Wenyi Hong, Ji\nQi, Yan Wang, Junhui Ji, Zhuoyi Yang, Lei Zhao, Xixuan\nSong, and et al. Cogvlm: Visual expert for pretrained language models. arXiv preprint arXiv:2311.03079, 2023. 2\n[48] Weiyun Wang, Zhangwei Gao, Lixin Gu, Hengjun Pu, Long\nCui, XingguangWei, Zhaoyang Liu, and et al. Internvl3.5:\nAdvancing open-source multimodal models in versatility,\nreasoning, and efficiency. arXiv preprint arXiv:2508.18265,\n2025. 2, 5, 7\n[49] Jiacong Xu, Shao-Yuan Lo, Bardia Safaei, Vishal M. Patel,\nand Isht Dwivedi. Towards zero-shot anomaly detection and\nreasoning with multimodal large language models. In CVPR,\n2025. 3, 4, 5\n[50] Xiaohao Xu, Yunkang Cao, Yongqi Chen, Weiming Shen,\nand Xiaonan Huang. Customizing visual-language foundation models for multi-modal anomaly detection and reasoning. arXiv preprint arXiv:2403.11083, 2024. 1, 2\n[51] Enquan Yang, Peng Xing, Hanyang Sun, Wenbo Guo, Yuanwei Ma, Zechao Li, and Dan Zeng. 3cad: A large-scale realworld 3c product dataset for unsupervised anomaly detection. In AAAI, 2025. 3\n[52] Xincheng Yao, Ruoqi Li, Zefeng Qian, Yan Luo, and\nChongyang Zhang. Focus the discrepancy: Intra- and intercorrelation learning for image anomaly detection. In ICCV,\n2023. 1\n[53] Xincheng Yao, Ruoqi Li, Jing Zhang, Jun Sun, and\nChongyang Zhang. Explicit boundary guided semi-pushpull contrastive learning for supervised anomaly detection.\nIn CVPR, 2023. 1\n[54] Xincheng Yao, Chongyang Zhang, Ruoqi Li, Jun Sun, and\nZhenyu Liu. One-for-all: Proposal masked cross-class\nanomaly detection. In AAAI, 2023. 1\n[55] Xincheng Yao, Zixin Chen, Guangtao Zhai, and Chongyang\nZhang. Resad: A simple framework for class generalizable\nanomaly detection. In neurIPS, 2024. 1\n[56] Xincheng Yao, Ruoqi Li, Zefeng Qian, Lu Wang, and\nChongyang Zhang. Hierarchical gaussian mixture normalizing flow modeling for unified anomaly detection. In ECCV,\n2024. 1, 7\n[57] Qinghao Ye, Haiyang Xu, Jiabo Ye, Ming Yan, Haowei\nLiu, Qi Qian, Ji Zhang, Fei Huang, and Jingren Zhou.\nmplug-owl2: Revolutionizing multi-modal large language\n\n\fmodel with modality collaboration.\narXiv preprint\narXiv:2311.04257, 2023. 2\n[58] Zhiyuan You, Lei Cui, Yujun Shen, Kai Yang, Xin Lu,\nYu Zheng, and Xinyi Le. A unified model for multi-class\nanomaly detection. arXiv preprint arXiv:2206.03687, 2022.\n1\n[59] Qiying Yu, Zheng Zhang, Ruofei Zhu, Yufeng Yuan, Xiaochen Zuo, Yu Yue, Weinan Dai, Tiantian Fan, Gaohong\nLiu, Lingjun Liu, Xin Liu, Haibin Lin, Zhiqi Lin, Bole\nMa, Guangming Sheng, Yuxuan Tong, Chi Zhang, Mofan\nZhang, Wang Zhang, Hang Zhu, Jinhua Zhu, Jiaze Chen,\nJiangjie Chen, Chengyi Wang, Hongli Yu, Yuxuan Song, Xiangpeng Wei, Hao Zhou, Jingjing Liu, Wei-Ying Ma, YaQin Zhang, Lin Yan, Mu Qiao, Yonghui Wu, and Mingxuan\nWang. Dapo: An open-source llm reinforcement learning\nsystem at scale. arXiv preprint arXiv:2503.14476, 2025. 5\n[60] Guoxin Zang, Xue Li, Donglin Di, Lanshun Nie, Dechen\nZhan, Yang Song, and Lei Fan. Sage: A visual language model for anomaly detection via fact enhancement and\nentropy-aware alignment. In ACM MM, 2025. 3\n[61] Jiangning Zhang, Haoyang He, Xuhai Chen2, Zhucun Xue,\nYabiao Wang, Chengjie Wang, Lei Xie, and Yong Liu.\nGpt-4v-ad: Exploring grounding potential of vqa-oriented\ngpt-4v for zero-shot anomaly detection. arXiv preprint\narXiv:2311.02612, 2023. 1, 2\n[62] Jian Zhang, Runwei Ding, Miaoju Ban, and Linhui Dai.\nPku-goodsad: A supermarket goods dataset for unsupervised\nanomaly detection and segmentation. IEEE Robotics and Automation Letters, 2024. 3\n[63] Qihang Zhou, Guansong Pang, Yu Tian, Shibo He, and Jiming Chen. Anomalyclip: Object-agnostic prompt learning for\nzero-shot anomaly detection. In ICLR, 2024. 1\n[64] Deyao Zhu, Jun Chen, Xiaoqian Shen, Xiang Li, and Mohamed Elhoseiny. Minigpt-4: Enhancing vision-language\nunderstanding with advanced large language models. In\nICLR, 2024. 2\n[65] JiaWen Zhu and Guansong Pang. Toward generalist anomaly\ndetection via in-context residual learning with few-shot sample prompts. In CVPR, 2024. 1\n[66] Jinguo Zhu, Weiyun Wang, Zhe Chen, Zhaoyang Liu, Shenglong Ye, Lixin Gu, Hao Tian, and et al. Internvl3: Exploring\nadvanced training and test-time recipes for open-source multimodal models. arXiv preprint arXiv:2504.10479, 2025. 7\n[67] Wenbing Zhu, Lidong Wang, Ziqing Zhou1, Chengjie Wang,\nYurui Pan, Ruoyi Zhang, Zhuhao Chen, Linjie Cheng, BinBin Gao, Jiangning Zhang, Zhenye Gan, Yuxie Wang, Yulong Chen, Shuguang Qian, Mingmin Chi, Bo Peng, and\nLizhuang Ma. Real-iad d³: A real-world 2d/pseudo-3d/3d\ndataset for industrial anomaly detection. In CVPR, 2025. 3\n[68] Yang Zou, Jongheon Jeong, Latha Pemula, Dongqing Zhang,\nand Onkar Dabeer. Spot-the-difference self-supervised pretraining for anomaly detection and segmentation. In ECCV,\n2022. 3\n\n\fMMR-AD: A Large-Scale Multimodal Dataset for Benchmarking General\nAnomaly Detection with Multimodal Large Language Models\nSupplementary Material\nA. More Discussions\n\nB. Spatially-aligned Normal Reference Sample\n\nChain-of-Thought Data. One concern about our work\nis that our MMR-AD dataset relies on Chain-of-Thought\n(CoT) reasoning, which is primarily designed for languagecentric reasoning tasks, while anomaly detection fundamentally depends on fine-grained visual perception. Excessive\ntextual reasoning may distract the model’s attention from\nvisual cues. We think that CoT and fine-grained visual perception are not conflicting. Our CoT reasoning is to teach\nthe model to carefully analyze the main areas in two images and compare them to identify discrepancies. The CoT\ntexts are closely around image contents (for fine-grained\nimage-text alignment) rather than just language-centric reasoning (see Fig.3). In Tab.5, we have also verified that\nthe reasoning data is critical. Without reasoning data, the\nmodel performs significantly worse (88.8 to 81.3 and 74.9\nto 66.1). Our Anomaly-R1-7B is finetuned from Qwen2.5VL-7B and can significantly outperform Qwen2.5-VL-7B\n(see Tab.4), demonstrating the effectiveness of our dataset.\n\nNormal samples are usually diverse, especially the foreground objects may not be highly aligned in different normal samples. This may lead to a reduction in the normal\nreference effect. To this end, we can select a spatiallyaligned nearest sample as the normal reference sample for\neach input sample. In this paper, we follow [20] to employ a spatial alignment retrieval approach to retrieve spatially aligned samples from test normal images for the input image I. Given total N normal images, we extract\nfirst layer features with a pre-trained light-weight network\n(e.g., ResNet-18), the corresponding features are denoted\nas {Fi ∈ RHp ×Wp ×Cp |i = 1, 2, . . . , N }. Then we collect all raw patch features of different normal images together into the feature set P = {Flatten(Fi )k ∈ RCp |k =\n1, 2, . . . , N Hp Wp }. The K-means clustering algorithm is\nperformed on P to obtain Nc clustering centers C = {ck ∈\nRCp |k = 1, 2, . . . , Nc }. The feature map Fi and clustering centers C are further utilized to calculate the block-wise\nstatistics for each normal image Ii . Specifically, the feature\nmap Fi is evenly divided into S × S grids as:\n\nDomain Shifts in MMR-AD To ensure data scale and\ndiversity, our MMR-AD dataset is extensively collected\nand sampled from 14 publicly available AD datasets. Using public datasets is because they are collected from the\nreal world and already have remarkable domain shifts (e.g.,\nMANTA is from five domains: mechanics, electronics,\nmedicine, agriculture, and groceries, 3CAD is from 3C\nelectronics, GoodsAD is from groceries). The sensors and\nlighting used during collection are also different. Among\nthese datasets,the product categories are completely different. Thus, we think that cross-dataset experiments (Tab.4)\ninclude strong domain shift challenges. The expected scope\nof MMR-AD is still industrial AD and is not suitable for\ndirect application in medical or video anomaly detection.\nPixel-level Localization. Unlike conventional anomaly\ndetection methods that generate anomaly score maps, we\nemploy bounding boxes (bbox) to predict the location of\nanomalies. Predicting bbox is because that current MLLMs\ncannot output images, hard to generate segmentation maps\ndirectly. However, in industrial applications, bbox is also a\ncommonly used way (e.g, many YOLO-based defect detectors output bboxes). A feasible extension method is to combine with SAM, where MLLM generates several special\n&lt;SEG&gt; tokens after bbox tokens, and then utilizes these\ntokens as conditional control to SAM, which predicts segmentation maps based on the input image and conditional\ntokens.\n\nHp\n\nWp\n\nF̂iu,v ∈ R S × S ×Cp , u, v = 1, 2, . . . , S\n\n(3)\n\nFor each grid, we can calculate its block-wise statistics in\nthe “Bag of Words” style as:\nFlatten\n\nF̂iu,v −→ {fk ∈ F̂iu,v |k = 1, 2, . . . , Hp Wp /S 2 }\nBoW\n\n→ hu,v ∈ RNc\n\n(4)\n\nwhere hu,v denotes a BoW histogram of F̂iu,v with respect\nto the codebook C. Specifically, we first construct Nc bins\nand then calculate the distances from fk to all centers in\nC. The value in the bin that is related to the minimum distance will be added by one. The histogram is then normalized so that ||hu,v ||1 = 1, ∀u, v. We can obtain all\nstatistical histograms for an image Ii and denote them as\n2\nH i ∈ RS ×Nc . Then, for the input image I and i-th normal image, we can calculate the KL divergence between\ntheir histograms to measure the spatial alignment degree between them. Specifically, we calculate the block-wise KL\ni\ni\ndivergence Du,v\n= KL(Hu,v\n, Hu,v ) for each block (u, v),\nwhere Hu,v means the histogram in (u, v) position of the\ninput image. By sorting the block divergences in increasing\norder, we can get the following sorted block divergences\n{D1i ≤ D2i ≤ D3i · · · ≤ DSi 2 }\n\n(5)\n\n\fThe spatial alignment degree between I and Ii is estimated\nas:\n2\n\nS −τ\n\ni\nDalign\n≜\n\nX\n1\nDi , i = 1, 2, . . . , N\nS 2 − τ j=1 j\n\n(6)\n\nwhere τ is a small number for ignoring large block divergences.\nBased on the spatial alignment degree, we can retrieve\nthe top-K neighbor normal images (we denote the set of indices as ι) as few-shot normal reference images Nref =\n{Iι1 , Iι1 , . . . , IιK }. Then, the nearest normal image Iι1\nis used as the normal reference image in our method (see\nSec.3.2 and Tab.2). In implementation, the hyperparameters S, Nc , τ , and K are set as 5, 12, 5, and 10, respectively.\n\nC. Text Verification Process\nAfter obtaining the MLLM-generated texts, we should further verify whether the generated texts are correct and filter\nout the incorrect texts. To this end, we propose an automatic\nverification approach. Specifically, we extract the predicted\nanomaly regions from “&lt;answer&gt;&lt;/answer&gt;” and verify\nwhether they are consistent with the true anomaly regions.\nWe have checked all the generated texts and found that the\ntexts in all answers followed our data generation instruction\nvery well. When the answer contains “No”, there will be no\nanomaly location outputs; only when the answer contains\n“Yes”, there will be corresponding anomaly location outputs. All the generated anomaly regions are in {‘bbox 2d’:\n[x1, y1, x2, y2], ‘label’: ‘&lt;anomaly type&gt;’} format.\nFor normal samples, their generated answers should include “No”. Otherwise, the corresponding texts are considered incorrect. For abnormal samples, the answers should\ncontain “Yes”, and the predicted anomaly regions should\nbe consistent with the true anomaly regions. For each predicted anomaly instance (one “{...}”, Python dict), we calculate the IoU between its bounding box and the bounding\nbox of one true anomaly region, and we calculate the semantic similarity (SS) between their labels (we utilize the\nSentenceTransformers library to measure text semantic similarity). Only when the IoU &gt; 0.9 and the SS &gt; 0.6, we\nconsider the predicted anomaly instance can match one true\nanomaly region. For one abnormal sample, the generated\nanswer is considered correct only if the number of predicted\nanomaly instances is equal to the number of true anomaly\nregions, and each predicted anomaly instance matches a true\nanomaly region. Otherwise, the corresponding generated\ntext of this sample is considered incorrect. Moreover, we\nalso hired multiple experienced annotators to further check\nwhether the texts in &lt;think&gt; match the final answer and\nremove the inconsistent texts.\n\nD. Implementation Details\nFor the MMR-AD dataset preparation, we call the\nQwen2.5-VL-72B API to generate reasoning-based text\ndata. For the cold-start initialization of Anomaly-R1, we\nadopt Qwen2.5-VL-7B as the base model and post-train it\nvia supervised fine-tuning for 3 epochs. We employ the\nLoRA technique [22] to fine-tune the base model. The low\nrank r and α hyperparameter in LoRA are both set to 16.\nDuring the SFT phase, the learning rate is set to 2e-5, and\nthe batch size is set to 4. The learning rate warmup ratio\nand the weight decay hyperparameter are both set to 0.1.\nDuring the RL phase, for rollout, the prompt batch size is\n32, and we sample 8 responses for each prompt. When generating responses, the key sampling hyperparameters, such\nas temperature, top p and top k, are set to 1.0, 1.0, and -1,\nrespectively. The mini-batch size for model update is set to\n8, which means we employ off-policy optimization and the\nmodel will be updated 4 times for each rollout (i.e., 32 // 8).\nWe limit the maximum number of input prompt tokens (including image tokens) to 2048, and the maximum number\nof tokens for generation is set to 512 tokens. The ϵ and β in\nthe GRPO algorithm are set to 0.2 and 0.001, respectively.\nThe learning rate is set to 2e-6. The learning rate warmup\nratio and the weight decay hyperparameter are set as 0.1 and\n0.01, respectively. We utilize the VeRL framework [43] for\nRL training.\nDuring inference, we use the min-p sampling [33] strategy with the temperature and mip-p hyperparameters set to\n1.5 and 0.1. The maximum number of tokens for generation\nis set to 512.\n\nE. Qualitative Results\nIn Fig.4, 5, and 6, we provide the qualitative comparison of\nour Anomaly-R1-7B with GPT-4o and Qwen2.5-VL-72B.\nFor commercial models, GPT-5 and o4-mini cannot be qualitatively compared as the APIs don’t provide users with\n&lt;think&gt; texts. The &lt;think&gt; texts generated by Gemini2.5-pro are too long to effectively present in a limited space,\nso we also don’t include it in the qualitative comparison.\nFor open-source models, as our model is based on Qwen2.5VL-7B, it’s very suitable for comparison with Qwen2.5VL-72B. Although both GPT-4o and Qwen2.5-VL-72B can\nsuccessfully identify the three examples as abnormal, their\ndecisions are based on hallucination (see Fig.4, 5), and\ntheir anomaly localization accuracy is also poor (Fig.6). By\ncomparison, our Anomaly-R1-7B has correct reasoning and\nshows more accurate anomaly localization results.\nIn Fig.7 and 8, we further show some failure cases generated by our Anomaly-R1-7B.\n\n\fNormal Reference Image\nNormal Reference Image\nGPT-4o\n\nPredicted Bbox\nQwen2.5-VL-72B\n\nPredicted Bbox\nOurs\n\nPredicted Bbox\n\n&lt;think&gt;The first image represents a normal sample, which gives a baseline to compare against.\nCarefully observing the second image in comparison to the first one, a clear abnormality is\nnoticeable near the bottom left. A foreign object or broken fragment is visible within the inner\ncircle perimeter that does not exist in the normal sample. This anomaly disrupts the continuity of\nthe clean, uniform perimeter seen in the normal image.\nTo determine the exact location of the defect, I identify coordinates by referring to the position\nof the anomaly in pixels normalized between 0 to 448 for x and y dimensions. This specific defect\nhas anomalous properties, and its label should reflect as 'foreign object/broken\nfragment'.&lt;/think&gt;&lt;answer&gt;Yes{'bbox_2d': [170, 330, 210, 360], 'label': 'foreign object/broken\nfragment'}&lt;/answer&gt;\n&lt;think&gt;To determine if there are any anomalies in the second image compared to the first, I'll\nanalyze the differences:\n1. **Surface Texture and Color**: The first image shows a smooth surface with consistent\ncoloration around the rim. The second image has an irregular dark spot on the lower left side of\nthe rim, which appears to be a different texture or material.\n2. **Shape and Symmetry**: Both images appear circular and symmetrical overall, but the\npresence of the dark spot disrupts this symmetry in the second image.\n3. **Light Reflection**: The light reflection patterns seem similar in both images, indicating no\nsignificant changes in the material properties except for the dark spot.\nBased on these observations, the dark spot is likely an anomaly.\n&lt;/think&gt;&lt;answer&gt;Yes.{'bbox_2d': [128, 409, 205, 476], 'label': 'dark spot'}&lt;/answer&gt;\n\n&lt;think&gt;To determine if there are any anomalies in the second image, I will compare it with the\nfirst image which is considered normal.\n1. **Visual Inspection**: The first image shows a clean and uniform surface with no visible defects.\nThe second image appears to have some irregularities.\n2. **Surface Analysis**: Upon closer inspection of the second image, there seems to be an area\nwhere the material looks different from the rest. This area has a rough texture and color variation\ncompared to the smooth surface in the first image.\n3. **Location Identification**: The anomaly is located towards the bottom left quadrant of the\nimage. By analyzing the position relative to the overall structure, the coordinates can be estimated\nas [97, 296, 184, 370].\nBased on this analysis, there is indeed an anomaly present in the second image.\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [97, 296, 184, 370], 'label': 'broken'}&lt;/answer&gt;\n\nFigure 4. Green marks correct reasoning and correct bbox coordinates, red marks wrong reasoning and imprecise bbox coordinates.\nQwen2.5-VL-72B shows severe hallucination, thinking that there\nis an abnormal dark spot, and locating to the white area at the bottom of the image.\n\nGPT-4o\n\nPredicted Bbox\nQwen2.5-VL-72B\n\nPredicted Bbox\nOurs\n\n&lt;think&gt;Upon comparing the first image (normal) with the second image, I observe that there is\nan anomaly visible in the black capsule section of the pill. Specifically, there appears to be a chip\nor missing part on the surface of the capsule near the boundary between the black and orange\nsections. This defect disrupts the uniform shape and integrity of the capsule's design. Based on\ncareful inspection and comparison, I conclude that there is indeed an anomaly present in the\nsecond image.&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [140, 200, 160, 220], 'label': 'surface\nchip'}&lt;/answer&gt;\n\n&lt;think&gt;To determine if there are any anomalies in the second image compared to the first, I'll\nanalyze the differences:\n1. **Shape and Structure**: Both capsules appear to have the same overall shape and structure.\n2. **Color and Markings**: The color distribution and markings (\"actavis\" and \"500\") seem\nconsistent between the two images.\n3. **Surface Integrity**: Upon closer inspection, the second image shows a noticeable irregularity\non the black portion of the capsule near the seam where it joins the orange part. This appears as a\nsmall chip or crack.\nBased on this analysis, there is an anomaly present in the second image related to surface integrity.\n&lt;/think&gt;&lt;answer&gt;Yes.{'bbox_2d': [198, 214, 227, 246], 'label': 'surface damage'}&lt;/answer&gt;\n\n&lt;think&gt;To determine if there are any anomalies in the second image, I will compare it with the\nfirst image. The first image shows a normal capsule with no visible defects. In the second image,\nupon close inspection, there appears to be a small area on the black part of the capsule where the\nsurface seems irregular and possibly damaged. This area is located near the right middle of the\nblack section.\n\nPredicted Bbox\n\nBy analyzing the differences between the two images, the anomaly can be pinpointed to the\nlocation [189, 176, 230, 215]. This area shows an irregularity that is not present in the normal\nsample.\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [189, 176, 230, 215], 'label': 'damaged capsule'}&lt;/answer&gt;\n\nFigure 6. Green marks correct reasoning and correct bbox coordinates, red marks wrong reasoning and imprecise bbox coordinates. Although both GPT-4o and Qwen2.5-VL-72B generate correct reasoning, the anomaly localization results are still not precise\nenough.\n\nNormal Reference Image\nOurs\nNormal Reference Image\n\nInput Image\n\n&lt;think&gt;By comparing the two images, I notice that there is an anomaly (defect) present in the second\nimage. Specifically, there is damage or breakage on the blue cable area near its copper section. This\nanomaly is visible as some of the copper wires have shifted or protruded from their original position\ncompared to the first reference image. I will output the location of the anomaly in terms of bounding box\ncoordinates.&lt;/think&gt;&lt;answer&gt;Yes, [{'bbox_2d': [200, 190, 240, 230], 'label': 'copper protrusion\ndefect'}]&lt;/answer&gt;\n\nGPT-4o\n\nPredicted Bbox\n\nPredicted Bbox\nQwen2.5-VL-72B\n\nPredicted Bbox\n\nInput Image\n\nInput Image\n\n&lt;think&gt;To determine if there are any anomalies in the second image compared to the first, I'll analyze\neach cable's appearance:\n1. **Cable Insulation Color and Condition**:\n- The colors of the cables (green, blue, brown) appear consistent between both images.\n- There is no visible damage or discoloration on the insulation.\n2. **Copper Wire Strands**:\n- In the first image, the copper wire strands are tightly packed and evenly distributed within each cable.\n- In the second image, the green cable's copper strands seem slightly more spread out than in the first\nimage, but this difference is minimal and may not be significant.\n- However, the blue cable in the second image shows a noticeable anomaly: some copper strands are\nprotruding and not contained within the insulation, which is not present in the first image.\n3. **Overall Cable Structure**:\n- The overall structure of the cables appears similar in both images except for the mentioned protrusion\nin the blue cable.\nBased on this analysis, the only notable anomaly is the protruding copper strands in the blue cable of the\nsecond image.\n&lt;/think&gt;&lt;answer&gt;Yes.{'bbox_2d': [94, 205, 240, 336], 'label': 'Protruding Copper Strands’} &lt;/answer&gt;\n\nInput Image\n\n&lt;think&gt;To determine if there are any anomalies in the second image compared to the first, I'll\nanalyze the following aspects:\n1. **Shape and Structure**: Both capsules appear to have the same shape and structure. There\nare no visible deformities or irregularities in the outline of the capsule in the second image.\n2. **Color and Texture**: The color distribution between the black and orange sections appears\nconsistent between both images. There are no noticeable differences in texture or shading that\nwould suggest defects.\n3. **Text and Markings**: The text \\\"500\\\" is present on both capsules in the same location and\nfont style. There are no apparent distortions or missing characters.\n4. **Surface Condition**: Upon close inspection, the surface of the capsule in the second image\ndoes not show any scratches, cracks, or other surface defects when compared to the first image.\nAfter analyzing these points, it seems that the second image does not exhibit any anomalies\nwhen compared to the first image.&lt;/think&gt;\n&lt;answer&gt;No.&lt;/answer&gt;\n\nFigure 7. Failure case. Red marks wrong reasoning.\n\n&lt;think&gt;\nTo determine if there are any anomalies in the second image, I will compare it with the first image. The\nfirst image shows three circular objects with a consistent texture and color throughout. In the second\nimage, there is to have an irregularity near the blue circular object: a section that seems to be cut or\ndamaged, revealing a different texture compared to the rest of the object.\n\nOurs\n\nPredicted Bbox\n\nBy analyzing the location of this anomaly, it is evident that the abnormal area is located near the leftmost\ncircular object. The coordinates for this area can be estimated as [35, 186, 149, 247].\n&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [35, 186, 149, 247], 'label': 'cut'}&lt;/answer&gt;\n\nFigure 5. Green marks correct reasoning and correct bbox coordinates, red marks wrong reasoning and imprecise bbox coordinates.\nBoth GPT-4o and Qwen2.5-VL-72B show hallucination, thinking\nthat there is the copper protrusion defect without observing the severe cut defect.\n\nNormal Reference Image\nOurs\n\nPredicted Bbox\n\nInput Image\n\n&lt;think&gt;To determine if there are any anomalies in the second image, I will compare it with the\nfirst image. The first image shows a normal cable with three wires of different colors (blue, green,\nand brown) and metallic contacts on each wire.\nIn the second image, the same three wires are present, but one of them appears to have an issue.\nSpecifically, the blue wire seems to have a cut or damage near its metallic contact area. This is not\npresent in the first image, indicating an anomaly.\nBased on this analysis, the location of the abnormal area can be identified as [230, 348, 353,\n371].&lt;/think&gt;&lt;answer&gt;Yes. {'bbox_2d': [230, 348, 353, 371], 'label': 'cut'}&lt;/answer&gt;\"\n\nFigure 8. Failure case. Red marks wrong reasoning and incorrect\nbbox coordinates.\n\n\f</code></pre></article>\n        \n</main>\n\n<script src=\"https://cdn.jsdelivr.net/npm/katex@0.16.8/dist/katex.min.js\"></script>\n<script src=\"https://cdn.jsdelivr.net/npm/katex@0.16.8/dist/contrib/auto-render.min.js\"></script>\n<script>\n\nfunction initTheme() {\n  const saved = localStorage.getItem('kb-theme') || 'light';\n  document.documentElement.setAttribute('data-theme', saved);\n  updateThemeIcon(saved);\n}\nfunction toggleTheme() {\n  const cur = document.documentElement.getAttribute('data-theme') || 'light';\n  const next = cur === 'light' ? 'dark' : 'light';\n  document.documentElement.setAttribute('data-theme', next);\n  localStorage.setItem('kb-theme', next);\n  updateThemeIcon(next);\n}\nfunction updateThemeIcon(t) {\n  const btn = document.getElementById('theme-toggle-btn');\n  if (btn) btn.innerHTML = t === 'dark' ? '☀️' : '🌙';\n}\ndocument.addEventListener('DOMContentLoaded', initTheme);\n\nfunction setViewMode(m) {\n  const grid = document.getElementById('bento-grid-view');\n  const list = document.getElementById('list-table-view');\n  const bGrid = document.getElementById('view-grid-btn');\n  const bList = document.getElementById('view-list-btn');\n  if (m === 'list') {\n    if (grid) grid.style.display = 'none';\n    if (list) list.style.display = 'flex';\n    if (bGrid) bGrid.classList.remove('active');\n    if (bList) bList.classList.add('active');\n  } else {\n    if (grid) grid.style.display = 'grid';\n    if (list) list.style.display = 'none';\n    if (bGrid) bGrid.classList.add('active');\n    if (bList) bList.classList.remove('active');\n  }\n  localStorage.setItem('kb-view', m);\n}\ndocument.addEventListener('DOMContentLoaded', () => {\n  const s = localStorage.getItem('kb-view') || 'grid';\n  setViewMode(s);\n});\n\ndocument.addEventListener('DOMContentLoaded', () => {\n  document.querySelectorAll('pre').forEach(pre => {\n    const b = document.createElement('button');\n    b.className = 'copy-code-btn';\n    b.innerText = 'Copy';\n    b.onclick = () => {\n      const c = pre.querySelector('code') ? pre.querySelector('code').innerText : pre.innerText;\n      navigator.clipboard.writeText(c).then(() => {\n        b.innerText = 'Copied!';\n        setTimeout(() => { b.innerText = 'Copy'; }, 2000);\n      });\n    };\n    pre.appendChild(b);\n  });\n});\n\nwindow.addEventListener('keydown', (e) => {\n  if ((e.key === '/' || (e.metaKey && e.key === 'k')) && document.activeElement.tagName !== 'INPUT' && document.activeElement.tagName !== 'TEXTAREA') {\n    e.preventDefault();\n    const q = document.getElementById('global-search-input');\n    if (q) q.focus();\n  }\n});\n\n// Scrollspy for TOC\nwindow.addEventListener('scroll', () => {\n  const headers = document.querySelectorAll('.article-body h1, .article-body h2, .article-body h3');\n  const scrollPos = window.scrollY + 100;\n  headers.forEach(h => {\n    if (h.offsetTop <= scrollPos) {\n      const id = h.getAttribute('id');\n      if (id) {\n        document.querySelectorAll('.reading-sidebar a').forEach(a => {\n          a.classList.toggle('active', a.getAttribute('href') === '#' + id);\n        });\n      }\n    }\n  });\n});\n\ndocument.addEventListener(\"DOMContentLoaded\", function() {\n  if (window.renderMathInElement) {\n    renderMathInElement(document.body, {\n      delimiters: [\n        {left: '$$', right: '$$', display: true},\n        {left: '$', right: '$', display: false},\n      ],\n      throwOnError : false\n    });\n  }\n});\n</script>\n\n</body>\n</html>\n"