"<!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>LogicQA: Logical Anomaly Detection with\nVision Language Model Generated Questions\nYejin Kwon∗ , Daeun Moon∗ , Youngje Oh, Hyunsoo Yoon†\nDepartment of Industrial Engineering, Yonsei University\nSeoul, South Korea\n{beckykwon, dani0403, yj89.oh, hs.yoon}@yonsei.ac.kr\n\n(A)\n\narXiv:2503.20252v2 [cs.CV] 20 May 2025\n\nAbstract\nAnomaly Detection (AD) focuses on detecting samples that differ from the standard pattern, making it a vital tool in process control.\nLogical anomalies may appear visually normal yet violate predefined constraints on object presence, arrangement, or quantity, depending on reasoning and explainability. We introduce LogicQA, a framework that enhances AD\nby providing industrial operators with explanations for logical anomalies. LogicQA compiles\nautomatically generated questions into a checklist and collects responses to identify violations\nof logical constraints. LogicQA is training-free,\nannotation-free, and operates in a few-shot setting. We achieve state-of-the-art (SOTA) Logical AD performance on the public benchmark,\nMVTec LOCO AD, with an AUROC of 87.6%\nand an F1 -max of 87.0% along with the explanations of anomalies. Also, our approach has\nshown outstanding performance on semiconductor SEM corporate data, further validating\nits effectiveness in industrial applications.\n\n1\n\nAnnot-Free\n\nEnc\n\nDec\n\nEnc\n\nDec\n\nReasoning Based AD\n\n(B)\n\nVision\nModel\nAnnot-Free\n\nAnomaly\nMap\nFew-Shot\n\nVision\nFeature\nMemory\nBank M\n\nReasoning Based AD\n\nPatch\nLocal\nClass\nFew-Shot\n\n(C)\n\nVLM\n\nGenerated\nQuestions\n\nFew Normal Images\n\nVLM\n\nAnswer\nw/ Reason\n\nReasoning Based AD\n\nFew-Shot\n\nTest Image\nAnnot-Free\n\nFigure 1: Overview of Logical AD: (A) Models trained\nfrom scratch (e.g., AutoEncoder) perform logical AD\nbut require a large number of images. (B) Models leveraging memory-based AD methods (e.g., PatchCore)\nuse pre-trained vision models to extract visual features\nfrom normal images, enabling few-shot AD. (C) Our\nmethod, LogicQA, utilizes a pre-trained VLM to generate anomaly-relevant questions and analyze test images,\nusing the answers to identify and explain abnormalities.\n\nIntroduction\n\nAnomaly detection (AD) is crucial for quality control and process optimization in industrial manufacturing. Anomalies are categorized into structural\nanomalies, referring to localized defects such as\ndeformation or contamination (Bergmann et al.,\n2022; Zoghlami et al., 2024), and logical anomalies, which assess adherence to predefined constraints, including object presence, quantity, and arrangement (Batzner et al., 2024; Kim et al., 2024b).\nUnlike structural anomalies, logical anomalies demand clear explanations, as lack of reasoning may\nlead to misinterpretation. This necessitates an approach that not only detects but also explains logical anomalies (Zhang et al., 2024a).\nData-driven AD plays a critical role in highquality production and minimizing downtime in\nindustrial control systems. However, simply detecting anomalies without explanation is insufficient\n\n(Wang et al., 2018). Modern industrial systems\ndemand explainability to clarify the reasons behind\nanomalies (Li et al., 2023b; Gramelt et al., 2024).\nUnderstanding root causes enables security experts\nto take targeted actions, preventing severe malfunctions and unplanned stoppage (Xu et al., 2024).\nExisting AD scores, estimating the probability\nof an image being anomalous, offer limited interpretability regarding the cause of anomalies (Sipple\nand Youssef, 2022). As shown in Figure 1(A) and\n(B), most approaches rely on anomaly maps derived from pixel-wise anomaly scores (Tien et al.,\n2023; Hsieh and Lai, 2024; Liu et al., 2023b).\nThese heatmaps highlight abnormal regions but\nfail to explain why an anomaly has occurred. LogicQA (Logical Question Answering) (Figure 1(C))\naddresses this limitation by leveraging a Vision1\n\n\fVLMs for Logical AD Recent advancements in\nVLMs have enabled more interpretable AD by integrating vision and natural language reasoning\n(Achiam et al., 2023; Liu et al., 2024a). LogicAD\n(Jin et al., 2025) employs a pre-trained VLM as\na text feature extractor, generating explanations\nvia logical reasoning. However, it relies on classspecific Guided Chain-of-Thought (CoT) prompts,\nrequiring precise and laborious prompt engineering\nfor each anomaly category. Similarly, LogiCode\n(Zhang et al., 2024a) applies Large Language Models (LLMs) to generate Python-based logical constraints, achieving strong detection performance\nbut relying on detailed manual annotations, restricting practical industrial scalability. Our LogicQA overcomes these limitations by eliminating\nthe need for pre-defined prompts and manual annotations, making it a more efficient and adaptable\nsolution for industrial AD.\n\nLanguage Model (VLM) to generate anomalyrelevant questions and provide natural language\nexplanations, enhancing human interpretability.\nLogicQA introduces a few-shot logical AD\nframework leveraging a pre-trained VLM. Unlike\nconventional methods requiring class-specific models, LogicQA eliminates the need for training and\nmanual annotations, allowing universal applicability across different classes. With just few normal images, LogicQA efficiently detects anomalies,\nmaking it scalable and practical for industrial fields.\nWe validate LogicQA on the MVTec LOCO\nAD dataset (Bergmann et al., 2022) and realworld semiconductor SEM dataset. This evaluation\ndemonstrates its effectiveness in AD, particularly\nin semiconductor defect detection, and highlights\nits potential for broader industrial AD applications.\nOur key contributions are as follows: (1) We\nachieve SOTA performance in few-shot logical AD\nby proposing LogicQA, using a VLM to generate\nanomaly-relevant questions and detect anomalies\nthrough question answering. (2) We enhance explainability in logical AD by generating natural\nlanguage reasoning, helping engineers understand\nwhy logical anomalies occur. (3) We introduce a\ntraining-free and annotation-free approach, eliminating class-specific training and human-generated\nprompts, enabling efficient AD with few normal images for industrial uses. (4) We validate LogicQA\non both public benchmark and real-world semiconductor SEM data, demonstrating its effectiveness\nacross diverse AD settings.\n\n2\n\n3\n\nLogicQA\n\nLogical AD differs from structural AD in that it\nassesses whether an image adheres to predefined\nlogical constraints rather than identifying localized\ndefects. Since logical anomalies often appear visually normal, detecting violations requires an interpretable framework to explain the underlying\nreasoning.\n3.1\n\nFramework Overview\n\nLogicQA (Logical Question Answering) is a novel\nframework for logical AD that ensures interpretability by generating anomaly-relevant questions and\nreasoning. Unlike prior methods dependent on\nmanual annotations or class-specific prompts, LogicQA leverages a pre-trained VLM, eliminating the\nneed for annotations and human-generated prompts.\nThis enables scalable deployment in industrial applications without task-specific fine-tuning.\nOur proposed LogicQA consists of four stages:\n(1) Describing the normal images, (2) Summarizing the normal image context, (3) Generating\nthe main questions, and (4) Testing, as shown in\nFigure 2. All detailed prompts and examples are\nlisted in the Appendix A.\n\nRelated Work\n\nLogical AD Approaches Since the release of\nthe MVTec LOCO AD dataset (Bergmann et al.,\n2022), various unsupervised AD approaches have\nbeen developed. Reconstruction-based methods\n(Bergmann et al., 2022; An and Cho, 2015) rely\non AutoEncoders trained with large amounts of\nnormal images, limiting their applicability in fewshot scenarios. As PatchCore (Roth et al., 2022)\nwas introduced, vision memory bank-based methods (Kim et al., 2024b; Liu et al., 2023a) leverage\npre-trained vision models and feature banks to improve efficiency. However, these methods require\ncostly computational resources for fine-tuning. In\ncontrast, LogicQA enables logical AD without finetuning, making it more scalable and adaptable to\nreal-world applications.\n\n3.2\n\nDescribing the Normal Images\n\nTo ensure effective logical AD, LogicQA begins\nby analyzing the characteristics of normal images\nusing a pretrained VLM. A single normal image,\nalong with a predefined normality definition, is fed\n2\n\n\fSummarizing the\nNormal Image Context\n\nDescribing the Normal Images\nThree Normal Images\n1\n\n2\n\n3\n\nHere are the common characteristics:\n- Type: Splicing connectors with multiple clamps.\n- Color: The connectors have transparent casings with\nred or orange clamps/levers…\n\nz\n\n- Exactly two splicing connectors with the same number\nof cable clamps are linked by exactly one cable…\n\nNormality Definition\n- Exactly two splicing connectors with the same number\nof cable clamps are linked by exactly one cable…\n\nPrompt\n\nPrompt\nCreate a concise summary that\nreflects the shared characteristics.\n\nAnalyze the image and\ndescribe the {Class} in detail.\n\nQuery Image\n\n3\n\n- Type: These appear to be lever-type splicing\nconnectors.\n- Color: The connectors have transparent\ncasings with orange levers. The cable\nconnecting them is red…\n\nNormality Definition\n\nTesting\n\n2\n\n1\n\nHere's a detailed description:\n\nGenerating\nMain Questions\n\nPrompt\nCreate simple and clear\nz\nquestions to determine whether\nthe {Class} in the image is\nnormal or abnormal.\n\nMain Questions\nGenerate\n5 variations\nfor each of the\nmain questions\n\nQ2. Are the connectors\nrectangular and compact, each\ncontaining five clamps?\n\nQ1. Are there exactly two splicing\nconnectors in the image?\n\nSub Questions for Q1\nQ1-1\n\nQ1-2\n\nYes\n\nYes\n\nMain Questions\n\nSub Questions for Q2\n\nQ1-3\n\nQ1-4\n\nQ1-5\n\nQ2-1\n\nQ2-2\n\nYes\n\nYes\n\nYes\n\nNo\n\nNo\n\nQ1: Yes\nPrompt\nQuestion: {Sub Question}\nAt first, describe {Class} image.\nYour response must end with `- Result: Yes` or `- Result: No`.\nLet’s think step by step.\n\n…\n\nQ2-3\n\nQ2-4\n\nQ2-5\n\n…\n\nNo\n\nYes\n\nNo\n\n…\n\nQ2: No\nFinal Prediction\n\nAnomaly\n\n(There is one connector containing\ntwo clamps. So, it is anomaly.)\n\n1. Are there exactly two splicing connectors in\nthe image?\n2. Are the connectors rectangular and\ncompact, each containing five clamps?\n\n...\n\n8. Does the cable connect the two connectors\nin a way that creates mirror symmetry?\n\nFiltered questions\n( Normal set accuracy &lt; 0.8 )\n\nFigure 2: Pipeline of LogicQA. (1) Describing the Normal Images – The VLM generates textual descriptions of\nthree normal images based on a predefined normality definition. (2) Summarizing the Normal Image Context –\nShared features are extracted to define the core traits of normality. (3) Generating Main Questions – The VLM\nformulates key questions to assess whether an image is normal or anomalous. (4) Testing – The VLM generates\nsub-questions as variations of the main questions. Using a voting mechanism on the VLM’s responses, we determine\nwhether the image satisfies the main questions. If it fails to satisfy even one, it is classified as anomalous.\n\nto the model, prompting it to generate a detailed\ntextual description (Jin et al., 2025). The normality\ndefinition, adopted from Bergmann et al. (2022)\n(Appendix C.2), establishes logical constraints that\ndefine expected object attributes and configurations\nin the dataset.\nThe descriptions capture location, quantity, and\nappearance of key elements, ensuring that the\nmodel focuses on relevant structural and contextual\nfeatures rather than background noise. This process\nenhances AD robustness by aligning the model’s attention with critical aspects of normality. To further\nrefine the understanding of normality, three distinct\nnormal images are processed separately, with each\ndescription contributing to a consolidated representation of the dataset’s normality definition. This\nenables the model to generalize beyond individual\nexamples, preserving essential normal properties.\n3.3\n\ning on the most consistent and core characteristics.\nBy using diverse normal images, the model\nlearns robust normality patterns, ensuring AD remains effective across different instances. This prevents overfitting to specific examples and allows\nmodel to focus on meaningful logical constraints.\n3.4\n\nGenerating Main Questions\n\nThe question generation step refines generalized\nnormality criteria into a checklist, prompting the\nVLM to generate key multiple questions to detect\nwhether a target image is an anomaly. This method\ndecomposes anomaly detection into multiple focused questions instead of relying on a single query.\nRecent studies (Ko et al., 2024; Yang et al., 2024)\nshow that task deconstruction methods improve reliability. Hence, our method makes judgements by\nintegrating multiple main questions (Main-Qs).\nWe provide the former summary and normality\ndefinition as input when prompting the VLM to\nextract key questions. The normality definition is\nreintroduced to help the VLM extract more relevant\nnormality criteria. The resulting questions serve\nas candidate Main-Qs. Since only a few normal\nimage descriptions are available, the initial set of\nquestions may not fully generalize across all cases.\n\nSummarizing the Normal Image Context\n\nThe summarization step refines the extracted normality by feeding previously generated descriptions into the VLM and distilling shared attributes\ninto a coherent representation of common features. This process ensures that AD remains robust\nagainst variations within normal images by focus3\n\n\fMVTec LOCO AD Dataset MVTec LOCO AD\nDataset, (Bergmann et al. (2022)), consists of five\nobject categories (breakfast box, juice bottle, pushpins, screw bag, splicing connectors) from industrial scenarios, with objects selected as close as\npossible to real-world applications. Each category\nhas several types of logical anomaly.\nThe VLM struggles with cases in the MVTec\nLOCO AD dataset where images contain large\nbackground areas, leading to long input contexts\n(Liu et al., 2024c), or where they contain uniform\nobjects (Campbell et al., 2024). To address this,\nwe applied two pre-processing steps, as depicted\nin Figure 3. First, Back Patch Masking (BPM)\n(Lee et al., 2023) was used to isolate the target\nobject from the background, producing an objectcentered image. Second, Language SegmentAnything model (Lang-SAM), combined with\nGroundingDINO (Liu et al., 2024d) and SAM2\n(Ravi et al., 2024), was used to segment uniform objects individually, mitigating the VLM’s limitations\nin multi-object recognition. Details and effects of\nBPM and Lang-SAM are in the Appendix F .\n\nTo improve robustness, we evaluate their consistency by applying them to a diverse set of normal\nimages. As questions with low accuracy (below\n80%) are indicative of bias toward the few-shot\nsamples, they were excluded to ensure that the final\nset of questions remains broadly applicable without\ndataset-specific bias.\n3.5\n\nTesting\n\nIn the testing step, the goal is to judge whether\nthe query image is anomalous and to analyze the\ncause of the anomaly. Recent VLMs are not always reliable and may generate incorrect answers\nor suffer from hallucinations (Mashrur et al., 2024;\nZhang et al., 2024b). To mitigate this, we augment\neach Main-Q with five semantically equivalent subquestions (Sub-Qs) (Zhou et al., 2022). The final\ndecision is made through majority voting on the\nSub-Qs’ responses.\nBy leveraging multiple outputs instead of a single response, our method effectively reduces reasoning errors. If any Main-Q receives a ‘No’ response, it means that the image violates at least one\nnormal constraint and is classified as an anomaly.\nAdditionally, the specific Main-Qs receiving ‘No’\nprovide a clear rationale for the anomaly’s cause.\nTo enhance interpretability, our approach follows\na step-by-step (Kojima et al., 2022) reasoning process rather than a direct anomaly prediction. This\naligns with the CoT approach (Wei et al., 2022),\nwhich strengthens VLM’s logical reasoning and\nmaintains contextual consistency, thereby improving judgment reliability.\nUnlike traditional AD methods that require classspecific prompts, LogicQA eliminates such dependencies, enabling flexible and intuitive modifications by adjusting only the question and class name\n(Portillo Wightman et al., 2023). This makes it\nhighly applicable for industrial use, as it does not\nrequire predefined class-specific guided prompts or\nCoT reasoning like Jin et al. (2025), allowing for\nseamless adoption in real-world settings.\n\n4\n\nBack Patch Masking\n\nBPM Image\n\nViT\nEnc\nOriginal Image\nAttention Mask\nLang-SAM Part Capturing\n\nOriginal Image\n\nText Prompt : “Connector Block”\nCaptured Pieces\n\nLangSAM\n\nFigure 3: Input Image Pre-Processing: BPM applies\nan attention mask to the original image, masking the\nbackground, preserving objects. Lang-SAM identifies\nobjects relevant to the given prompt and returns them as\nbounding boxes.\n\nSemiconductor SEM Dataset Scanning Electron Microscopy (SEM) operates by applying a\nhigh voltage to direct an electron beam onto the surface of a sample, then secondary electrons generate\na wafer image. The SEM has around 1 nm resolution to get precise wafer surface patterns. This\ncorporate dataset reflects critical inspection stages\nin semiconductor manufacturing, directly affecting\nchip quality and production yields. The dataset has\ntwo defect types: spot and bridge. Spot defects\nappear as circular blemishes that degrade chip performance, while bridge defects take the form of\nelongated connections linking separate conductive\nlines (Kim et al., 2020).\n\nDataset\n\nWe evaluated our method using the MVTec LOCO\nAD dataset and an industrial semiconductor SEM\ndataset collected from real-world manufacturing\nprocesses. Both datasets contain normal and logical anomaly samples. ( The overview and sample\nimages of the two datasets are included in the Appendix C and E.)\n4\n\n\fMVTec LOCO AD\n(only Logical Anomaly)\n\nLogicQA (Ours)\n\nLogicAD\nJin et al. (2025)\n\nWinCLIP\nJeong et al. (2023)\n\nPatchCore\nRoth et al. (2022)\n\nGCAD\nBergmann et al. (2022)\n\nAST\nRudolph et al. (2023)\n\nFew / One shot\nExplainable\nAuto-Generated Prompt\n\n✓\n✓\n✓\n\n✓\n✓\np\n\n✓\np\np\n\n✓\np\np\n\np\np\np\n\np\np\np\n\nCategory\n\nAUROC\n\nF1 -max\n\nAUROC\n\nF1 -max\n\nAUROC\n\nF1 -max\n\nAUROC\n\nAUROC\n\nAUROC\n\nBreakfast Box\nJuice Bottle\nPushpins\nScrew Bag\nSplicing Connectors\n\n87.6\n88.2\n98.4\n71.5\n92.4\n\n91.6\n89.6\n97.6\n64.5\n91.5\n\n93.1\n81.6\n98.1\n83.8\n73.4\n\n82.7\n83.2\n98.5\n77.9\n76.1\n\n57.6\n75.1\n54.9\n69.5\n64.5\n\n63.3\n58.2\n57.3\n58.8\n59.9\n\n74.8\n93.9\n63.6\n57.8\n79.2\n\n87.0\n100.0\n97.5\n56.0\n89.7\n\n80.0\n91.6\n65.1\n80.1\n81.8\n\nAverage\n\n87.6 (1.6 ↑)\n\n87.0 (3.3 ↑)\n\n86.0\n\n83.7\n\n64.3\n\n59.5\n\n74.0\n\n86.0\n\n79.7\n\nTable 1: Logical AD performance on MVTec LOCO AD dataset. AUROC and F1 -max in % for detecting logical\nanomalies of all categories of MVTec LOCO AD Dataset. We report the mean over 3 runs for our method. Among\nmodels using the few-shot approach, the best results are highlighted in bold. The values highlighted in red indicate\nincreased score compared to LogicAD. Our LogicQA demonstrates outstanding performance while incorporating a\nfew-shot approach, explainability, and the use of auto-generated prompts.\n\n5\n\nExperiments and Results\n\n5.1\n\nExperimental Setting\n\nQi (x) is defined as:\n\n5\n5\nX\nX\n\n0, if\nqij (x) &lt;\n(1 − qij (x))\nQi (x) =\nj=1\nj=1\n\n\n1, otherwise.\n\nWe implement our experiments by leveraging\nthree SOTA VLMs (GPT-4o (Achiam et al.,\n2023), Gemini-1.5 Flash (Team et al., 2024), and\nInternVL-2.5 38B (Chen et al., 2024)). Comprehensive details on model configurations and deployment settings are outlined in the Appendix B. All\nexperiments are training-free and few-shot (three\nnormal images per test image). Our assessments\nare based on the MVTec LOCO AD dataset and\nSemiconductor SEM dataset. We conducted the\nexperiments three times for each category and calculated the average score, as indicated in Table 1.\n\nA final function F (x) determines whether the input\nis a normal image or an anomaly, defined as:\nF (x) =\n\n\n\"Normal\",\n\nif\n\nX\n\nQi (x) = 0,\n\ni\n\n\n\n\"Anomaly\", otherwise.\n\nFor each Main-Q, we take the highest logprobability among the Sub-Qs whose answers\nmatch the voted result, then apply the exponential function to all selected values. And, we get\nanomaly score for test image below:\nsi = max {log p(qij (x)) | qij (x) = Qi (x)}\nj\n\n5.2\n\nS = {esi | i = 1, . . . , m}\n(\n1 − Median(S), if F (x) = Normal\nAnomaly Score =\nMedian(S),\nif F (x) = Anomaly\n\nEvaluation Metrics\n\nOur approach uses a VLM for Vision QuestionAnswering (Sinha et al., 2025). If any of the responses to Main-Qs are “No”, the model predicts\n“Anomaly”. It is threshold-free, providing binary\npredictions and reasoning but not an anomaly score.\nSo, we propose using the VLM’s log probabilities to compute an anomaly score. Kadavath et al.\n(2022); Kim et al. (2024a); Lee et al. (2021) have\nshown that low token prediction probabilities (Log\nprobs) can indicate a lack of knowledge in LLMs\nand lead to uncertain performance on downstream\ntasks. We consider the VLM’s log-probability of\nanswers to Sub-Qs as indicators of accuracy, reliability, and confidence of answer. We define key\nformulations:\nA Sub-Q function qij outputs \"Yes(0)\" or\n\"No(1)\" for an input image x, where i ∈ [1, m]\nrepresents the number of Main-Qs, and j ∈ [1, 5]\nindexes the five Sub-Qs per Main-Q. Each Main-Q,\n\nThe logp function computes the log probability\ngenerated during the processing of the input. By\ncalculating the anomaly score as above, we use\nF1 -max and Area Under the Reciever Operating\nCharacteristic (AUROC) to evaluate our method,\nLogicQA, as same as existing approaches.\n5.3\n\nResult\n\nMVTec LOCO AD Result The performance\nof Logical AD tested on the MVTec LOCO AD\ndataset for each method is shown in Table 1, presented in terms of AUROC and F1 -max scores. For\na comprehensive comparison, the table also indicates which shot approach was chosen and whether\nexplainability is incorporated. LogicQA consistently outperforms the existing few-shot VLMbased SOTA method (Jin et al., 2025) across all\n5\n\n\fanswer accordingly. Their responses were then\ncompared with the model’s answers. Annotator1\nshowed 98% agreement for normal images and\n85% for anomalous ones, while Annotator2 showed\n98% and 86%, respectively, demonstrating high\ncorrespondence. Notably, the strong agreement for\nanomalous images indicates that LogicQA not only\ndetects anomalies but also explains their critical\ncauses, demonstrating its ability as a comprehensive anomaly explainability model.\n\nmetrics, achieving a 1.6% increase in AUROC and\na 3.3% improvement in F1 -max score. Notably, in\nthe splicing connectors class, both the AUROC and\nF1 -max metrics showed remarkable improvements,\nwith AUROC increasing by 19% and F1 -max improving by 15.4%. Even compared to full-shot\nmethods (Liu et al., 2025b; Rudolph et al., 2023),\nour LogicQA outperforms in almost all classes.\n(Frameworks utilizing in-house annotations are in\nAppendix 5).\nLogicQA not only employs a few-shot approach\nand an auto-generated question mechanism for prediction but also provides natural language explanations for anomaly causes while achieving remarkable performance compared to other models.\n\nCan other VLMs work well with LogicQA? To\nverify the applicability of our LogicQA in other\nVLMs with fewer parameters, we conducted tests\nusing Gemini-1.5 Flash (Team et al., 2024) and\nInternVL-2.5 38B (Chen et al., 2024). The experimental results, presented in Table 3 with recorded\nF1 -max scores, show that both models maintained\nstable performance, with some classes even achieving higher scores. This suggests that LogicQA can\nbe effectively applied across various VLMs.\n\nSemiconductor SEM Result As shown in Table 2, LogicQA (GPT-4o) outperforms PatchCore\n(Roth et al., 2022), a representative few-shot AD\nmethod, on the semiconductor SEM dataset, yielding an 11.1% increase in AUROC and a 14.6%\nimprovement in F1 -max. Also, LogicQA (GPT4o) excels in detecting both “Bridge” and “Spot”\nanomalies, achieving the best scores. LogicQA significantly outperforms PatchCore even using the\nsmaller open-source model InternVL-2.5 8B (Chen\net al., 2024). This suggests applicability in realworld industrial settings, where deploying large\nproprietary models may not be feasible. Additionally, LogicQA shows excellent performance in Table 2 even though it did not include the process of\nfiltering Main-Q using a few normal images.\nLogicQA\nSEM\n\nGPT-4o\n\nInternVL-2.5 8B\n\nAUROC\n\nF1 -max\n\nF1 -max\n\nAUROC\n\nF1 -max\n\n89.7\n90.8\n\n90.4\n94.3\n\n80.7\n89.7\n\n83.0\n75.4\n\n76.4\n79.2\n\nAverage\n\n90.3 (11.1 ↑)\n\n92.4 (14.6 ↑)\n\n85.2\n\n79.2\n\n77.8\n\nGemini-1.5 Flash\n\nInternVL-2.5 38B\n\n91.6\n89.6\n97.6\n64.5\n91.5\n\n83.3\n78.0\n98.9\n91.7\n46.8\n\n88.2\n73.7\n93.7\n62.6\n69.9\n\nAverage\n\n87.0\n\n79.7\n\n77.6\n\n6\n\nConclusion\n\nIn this paper, we propose LogicQA, an explainable logical AD framework leveraging a VisionLanguage Model (VLM) to detect anomalies and\nprovide natural language explanations. LogicQA\nrequires only a few normal images to define normal characteristics, significantly reducing the dependency on large labeled datasets. By eliminating\nclass-specific fine-tuning and manually generated\nprompts, LogicQA facilitates efficient and scalable\ndeployment in industrial environments. We evaluated LogicQA on the public benchmark, MVTec\nLOCO AD Dataset, where it outperformed existing explainable AD models. We further validated\nrobustness of LogicQA on a real-world manufacturing dataset, Semiconductor SEM Dataset. These\nresults confirm LogicQA as an effective, reliable,\nand practical solution for diverse industrial applications.\n\nTable 2: Logical AD performance on Semiconductor\nSEM dataset. Our LogicQA outperforms PatchCore regarding metrics and AD explainability. All experiments\nwere conducted with the same three normal images.\n\n5.4\n\nGPT-4o\n\nTable 3: LogicQA performance with other VLMs on\nthe MVTec LOCO AD dataset.\n\nPatchCore\nRoth et al. (2022)\n\nBridge\nSpot\n\nVLMs\nBreakfast Box\nJuice Bottle\nPushpins\nScrew Bag\nSplicing Connectors\n\nAblation Studies\n\nDoes LogicQA provide the correct reasoning?\nThe MVTec LOCO AD dataset does not provide\nspecific rerasons for why each anomaly image is\nclassified as anomalous. Therefore, we conducted\na human evaluation to compare the reasons behind\nthe model’s anomaly detection with human perception. Two annotators were provided with the\ndataset and Main-Qs for each class and asked to\n6\n\n\fLimitations\n\nJinwon An and Sungzoon Cho. 2015. Variational autoencoder based anomaly detection using reconstruction probability.\n\nOur framework is designed for easy application in\nindustrial settings and delivers strong performance,\nthough some limitations remain. Since our approach relies on VLMs, its performance inherently\ndepends on the VLMs’ visual recognition capabilities. Currently, VLMs exhibit imperfect accuracy\n(Wang et al., 2023; Li et al., 2023a) necessitating\nspecific image preprocessing steps. However, as\nthe technology evolves, this step may become less\nnecessary (Jiang et al., 2025; Liu et al., 2025a). Additionally, generating a well-generalized Main-Qs\nset requires diverse images. Fortunately, normal\nimages are relatively easy to obtain in industrial\nenvironments (Choi et al., 2021; Liu et al., 2024b),\nwhich helps mitigate this challenge. Also, the evaluation result on the Semiconductor SEM dataset\nconfirms our model demonstrated strong anomaly\ndetection performance even without the Main-Q\nfiltering process.\n\nKilian Batzner, Lars Heckler, and Rebecca König. 2024.\nEfficientad: Accurate visual anomaly detection at\nmillisecond-level latencies. In Proceedings of the\nIEEE/CVF Winter Conference on Applications of\nComputer Vision, pages 128–138.\nPaul Bergmann, Kilian Batzner, Michael Fauser, David\nSattlegger, and Carsten Steger. 2022. Beyond dents\nand scratches: Logical constraints in unsupervised\nanomaly detection and localization. International\nJournal of Computer Vision, 130(4):947–969.\nDeclan Iain Campbell, Sunayana Rane, Tyler Giallanza,\nC. Nicolò De Sabbata, Kia Ghods, Amogh Joshi,\nAlexander Ku, Steven M Frankland, Thomas L. Griffiths, Jonathan D. Cohen, and Taylor Whittington\nWebb. 2024. Understanding the limits of vision language models through the lens of the binding problem. In The Thirty-eighth Annual Conference on\nNeural Information Processing Systems.\nZhe Chen, Weiyun Wang, Yue Cao, Yangzhou Liu,\nZhangwei Gao, Erfei Cui, Jinguo Zhu, Shenglong\nYe, Hao Tian, Zhaoyang Liu, and 1 others. 2024.\nExpanding performance boundaries of open-source\nmultimodal models with model, data, and test-time\nscaling. arXiv preprint arXiv:2412.05271.\n\nEthics Statement\nThis research uses GPT-4o and Gemini-1.5-Flash\nas baseline models. As with any large language\nmodel, their outputs may include unintended biases\nor harmful content depending on user inputs. To\nensure ethical deployment, we apply engineering\nmeasures to mitigate these risks and enhance model\nreliability. Since both models are proprietary, with\nundisclosed training details and weights, assessing potential biases and risks remains challenging.\nAdditionally, handling sensitive data with these\nmodels requires caution due to possible unintended\nexposure. When necessary, we recommend using\nopen-source alternatives for greater transparency\nand control. AI-assisted tools were utilized solely\nfor grammar correction and linguistic refinement\nduring manuscript preparation. However, the originality, intellectual contributions, and core ideas\nof this paper are entirely the authors’ own. We\nare committed to responsible AI use, continuous\nmonitoring, and improving fairness and safety in\nreal-world applications.\n\nKukjin Choi, Jihun Yi, Changhwa Park, and Sungroh\nYoon. 2021. Deep learning for anomaly detection\nin time-series data: Review, analysis, and guidelines.\nIEEE Access, 9:120043–120065.\nDaniel Gramelt, Timon Höfer, and Ute Schmid. 2024.\nInteractive explainable anomaly detection for industrial settings. arXiv preprint arXiv:2410.12817.\nYu-Hsuan Hsieh and Shang-Hong Lai. 2024. Csad:\nUnsupervised component segmentation for\nlogical anomaly detection.\narXiv preprint\narXiv:2408.15628.\nJongheon Jeong, Yang Zou, Taewan Kim, Dongqing\nZhang, Avinash Ravichandran, and Onkar Dabeer.\n2023. Winclip: Zero-/few-shot anomaly classification and segmentation. In Proceedings of the\nIEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 19606–19616.\n\nReferences\n\nNicholas Jiang, Anish Kachinthaya, Suzanne Petryk,\nand Yossi Gandelsman. 2025. Interpreting and editing vision-language representations to mitigate hallucinations. In The Thirteenth International Conference on Learning Representations.\n\nJosh Achiam, Steven Adler, Sandhini Agarwal, Lama\nAhmad, Ilge Akkaya, Florencia Leoni Aleman,\nDiogo Almeida, Janko Altenschmidt, Sam Altman,\nShyamal Anadkat, and 1 others. 2023. Gpt-4 technical report. arXiv preprint arXiv:2303.08774.\n\nEr Jin, Qihui Feng, Yongli Mou, Stefan Decker, Gerhard\nLakemeyer, Oliver Simons, and Johannes Stegmaier.\n2025. Logicad: Explainable anomaly detection via\nvlm-based text feature extraction. arXiv preprint\narXiv:2501.01767.\n\n7\n\n\fSaurav Kadavath, Tom Conerly, Amanda Askell, Tom\nHenighan, Dawn Drain, Ethan Perez, Nicholas\nSchiefer, Zac Hatfield-Dodds, Nova DasSarma, Eli\nTran-Johnson, and 1 others. 2022. Language models (mostly) know what they know. arXiv preprint\narXiv:2207.05221.\n\nHaotian Liu, Chunyuan Li, Yuheng Li, and Yong Jae\nLee. 2024a. Improved baselines with visual instruction tuning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition,\npages 26296–26306.\nJiaqi Liu, Guoyang Xie, Jinbao Wang, Shangnian Li,\nChengjie Wang, Feng Zheng, and Yaochu Jin. 2024b.\nDeep industrial image anomaly detection: A survey.\nMachine Intelligence Research, 21(1):104–135.\n\nMinsu Kim, Hoon Jo, Moonsoo Ra, and Whoi-Yul\nKim. 2020. Weakly-supervised defect segmentation\non periodic textures using cyclegan. IEEE Access,\n8:176202–176216.\n\nNelson F. Liu, Kevin Lin, John Hewitt, Ashwin Paranjape, Michele Bevilacqua, Fabio Petroni, and Percy\nLiang. 2024c. Lost in the middle: How language\nmodels use long contexts. Transactions of the Association for Computational Linguistics, 12:157–173.\n\nSangryul Kim, Donghee Han, and Sehyun Kim. 2024a.\nProbGate at EHRSQL 2024: Enhancing SQL query\ngeneration accuracy through probabilistic threshold\nfiltering and error handling. In Proceedings of the\n6th Clinical Natural Language Processing Workshop,\npages 687–696, Mexico City, Mexico. Association\nfor Computational Linguistics.\n\nSheng Liu, Haotian Ye, and James Zou. 2025a. Reducing hallucinations in large vision-language models\nvia latent space steering. In The Thirteenth International Conference on Learning Representations.\n\nSoopil Kim, Sion An, Philip Chikontwe, Myeongkyun\nKang, Ehsan Adeli, Kilian M Pohl, and Sang Hyun\nPark. 2024b. Few shot part segmentation reveals\ncompositional logic for industrial anomaly detection.\nIn Proceedings of the AAAI conference on artificial\nintelligence, volume 38, pages 8591–8599.\n\nShilong Liu, Zhaoyang Zeng, Tianhe Ren, Feng Li, Hao\nZhang, Jie Yang, Qing Jiang, Chunyuan Li, Jianwei\nYang, Hang Su, and 1 others. 2024d. Grounding\ndino: Marrying dino with grounded pre-training for\nopen-set object detection. In European Conference\non Computer Vision, pages 38–55. Springer.\n\nMiyoung Ko, Sue Hyun Park, Joonsuk Park, and Minjoon Seo. 2024. Hierarchical deconstruction of LLM\nreasoning: A graph-based framework for analyzing\nknowledge utilization. In Proceedings of the 2024\nConference on Empirical Methods in Natural Language Processing, pages 4995–5027, Miami, Florida,\nUSA. Association for Computational Linguistics.\n\nTongkun Liu, Bing Li, Xiao Du, Bingke Jiang, Xiao\nJin, Liuyi Jin, and Zhuo Zhao. 2023a. Componentaware anomaly detection framework for adjustable\nand logical industrial visual inspection. Advanced\nEngineering Informatics, 58:102161.\n\nTakeshi Kojima, Shixiang Shane Gu, Machel Reid, Yutaka Matsuo, and Yusuke Iwasawa. 2022. Large language models are zero-shot reasoners. Advances in\nneural information processing systems, 35:22199–\n22213.\n\nWenrui Liu, Hong Chang, Bingpeng Ma, Shiguang\nShan, and Xilin Chen. 2023b. Diversity-measurable\nanomaly detection. In Proceedings of the IEEE/CVF\nConference on Computer Vision and Pattern Recognition (CVPR), pages 12147–12156.\n\nNayeon Lee, Yejin Bang, Andrea Madotto, and Pascale\nFung. 2021. Towards few-shot fact-checking via\nperplexity. In Proceedings of the 2021 Conference\nof the North American Chapter of the Association\nfor Computational Linguistics: Human Language\nTechnologies, pages 1971–1981, Online. Association\nfor Computational Linguistics.\n\nZehao Liu, Mengzhou Gao, and Pengfei Jiao. 2025b.\nGcad: Anomaly detection in multivariate time series from the perspective of granger causality. arXiv\npreprint arXiv:2501.13493.\nAkib Mashrur, Wei Luo, Nayyar A Zaidi, and Antonio\nRobles-Kelly. 2024. Robust visual question answering via semantic cross modal augmentation. Computer Vision and Image Understanding, 238:103862.\n\nYujin Lee, Harin Lim, Seoyoon Jang, and Hyunsoo\nYoon. 2023. Uniformaly: Towards task-agnostic unified framework for visual anomaly detection. arXiv\npreprint arXiv:2307.12540.\n\nGwenyth Portillo Wightman, Alexandra Delucia, and\nMark Dredze. 2023. Strength in numbers: Estimating confidence of large language models by\nprompt agreement. In Proceedings of the 3rd Workshop on Trustworthy Natural Language Processing\n(TrustNLP 2023), pages 326–362, Toronto, Canada.\nAssociation for Computational Linguistics.\n\nYifan Li, Yifan Du, Kun Zhou, Jinpeng Wang, Xin Zhao,\nand Ji-Rong Wen. 2023a. Evaluating object hallucination in large vision-language models. In Proceedings of the 2023 Conference on Empirical Methods in\nNatural Language Processing, pages 292–305, Singapore. Association for Computational Linguistics.\n\nNikhila Ravi, Valentin Gabeur, Yuan-Ting Hu, Ronghang Hu, Chaitanya Ryali, Tengyu Ma, Haitham\nKhedr, Roman Rädle, Chloe Rolland, Laura\nGustafson, and 1 others. 2024. Sam 2: Segment\nanything in images and videos. arXiv preprint\narXiv:2408.00714.\n\nZhong Li, Yuxuan Zhu, and Matthijs Van Leeuwen.\n2023b. A survey on explainable anomaly detection.\nACM Transactions on Knowledge Discovery from\nData, 18(1):1–54.\n\n8\n\n\fKarsten Roth, Latha Pemula, Joaquin Zepeda, Bernhard\nSchölkopf, Thomas Brox, and Peter Gehler. 2022.\nTowards total recall in industrial anomaly detection.\nIn Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 14318–\n14328.\n\nQian Yang, Weixiang Yan, and Aishwarya Agrawal.\n2024. Decompose and compare consistency: Measuring VLMs’ answer reliability via task-decomposition\nconsistency comparison. In Proceedings of the 2024\nConference on Empirical Methods in Natural Language Processing, pages 3613–3627, Miami, Florida,\nUSA. Association for Computational Linguistics.\n\nMarco Rudolph, Tom Wehrbein, Bodo Rosenhahn, and\nBastian Wandt. 2023. Asymmetric student-teacher\nnetworks for industrial anomaly detection. In Proceedings of the IEEE/CVF winter conference on applications of computer vision, pages 2592–2602.\n\nYiheng Zhang, Yunkang Cao, Xiaohao Xu, and Weiming Shen. 2024a. Logicode: an llm-driven framework\nfor logical anomaly detection. IEEE Transactions on\nAutomation Science and Engineering.\nYuhui Zhang, Alyssa Unell, Xiaohan Wang, Dhruba\nGhosh, Yuchang Su, Ludwig Schmidt, and Serena\nYeung-Levy. 2024b. Why are visually-grounded language models bad at image classification? In The\nThirty-eighth Annual Conference on Neural Information Processing Systems.\n\nNeelabh Sinha, Vinija Jain, and Aman Chadha. 2025.\nGuiding vision-language model selection for visual question-answering across tasks, domains, and\nknowledge types. In Proceedings of the First Workshop of Evaluation of Multi-Modal Generation, pages\n76–94, Abu Dhabi, UAE. Association for Computational Linguistics.\n\nYongchao Zhou, Andrei Ioan Muresanu, Ziwen Han,\nKeiran Paster, Silviu Pitis, Harris Chan, and Jimmy\nBa. 2022. Large language models are human-level\nprompt engineers. In The Eleventh International\nConference on Learning Representations.\n\nJohn Sipple and Abdou Youssef. 2022. A generalpurpose method for applying explainable ai for\nanomaly detection. In International Symposium on\nMethodologies for Intelligent Systems, pages 162–\n174. Springer.\n\nFiras Zoghlami, Dena Bazazian, Giovanni L. Masala,\nMario Gianni, and Asiya Khan. 2024. Viglad: Vision\ngraph neural networks for logical anomaly detection.\nIEEE Access, 12:173304–173315.\n\nGemini Team, Petko Georgiev, Ving Ian Lei, Ryan\nBurnell, Libin Bai, Anmol Gulati, Garrett Tanzer,\nDamien Vincent, Zhufeng Pan, Shibo Wang, and 1\nothers. 2024. Gemini 1.5: Unlocking multimodal\nunderstanding across millions of tokens of context.\narXiv preprint arXiv:2403.05530.\nTran Dinh Tien, Anh Tuan Nguyen, Nguyen Hoang\nTran, Ta Duc Huy, Soan TM Duong, Chanh D Tr\nNguyen, and Steven QH Truong. 2023. Revisiting reverse distillation for anomaly detection. In\n2023 IEEE/CVF Conference on Computer Vision and\nPattern Recognition (CVPR), pages 24511–24520.\nIEEE.\nJianwu Wang, Chen Liu, Meiling Zhu, Pei Guo, and\nYapeng Hu. 2018. Sensor data based system-level\nanomaly prediction for smart manufacturing. In 2018\nIEEE International Congress on Big Data (BigData\nCongress), pages 158–165. IEEE.\nJunyang Wang, Yiyang Zhou, Guohai Xu, Pengcheng\nShi, Chenlin Zhao, Haiyang Xu, Qinghao Ye, Ming\nYan, Ji Zhang, Jihua Zhu, and 1 others. 2023. Evaluation and analysis of hallucination in large visionlanguage models. arXiv preprint arXiv:2308.15126.\nJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten\nBosma, brian ichter, Fei Xia, Ed H. Chi, Quoc V Le,\nand Denny Zhou. 2022. Chain of thought prompting elicits reasoning in large language models. In\nAdvances in Neural Information Processing Systems.\nLijuan Xu, Ziyu Han, Zhen Wang, and Dawei Zhao.\n2024. Finding component relationships: A deeplearning-based anomaly detection interpreter. IEEE\nTransactions on Computational Social Systems,\n11(3):4149–4162.\n\n9\n\n\fA\n\nLogicQA - Prompts\nPrompt - Describing the Normal Images\nThis is a {Class}. Analyze the image and describe the {Class} in detail, including type, color,\nsize (length, width), material, composition, quantity, relative location.\n&lt; Normal Constraints for a {Class} &gt;\n{Normal Definition}\n{Image Prompt (Image Input)}\nExample :\nThis is a breakfast box. Analyze the image and describe the breakfast box in detail, including\ntype, color, size (length, width), material, composition, quantity, relative location..\n&lt;Normal Constraints for breakfast box&gt;\n- The breakfast box always contain exactly two tangerines and one nectarine that are always\nlocated on the left-hand side of the box.\n- The ratio and relative position of the cereals and the mix of banana chips and almonds on the\nright-hand side are fixed.\n\nPrompt - Summarizing the Normal Image Context\n[ Normal {Class} Description 1 ]\n{Description 1}\n[ Normal {Class} Description 2 ]\n{Description 2}\n[ Normal {Class} Description 3 ]\n{Description 3}\nCombine the three descriptions into one by extracting only the \"common\" features.\nCreate a concise summary that reflects the shared characteristics while removing any\nredundant or unique details.\nExample :\n[ Normal Breakfast Box Description 1 ]\nThe breakfast box is divided into two sections. ...\n[ Normal Breakfast Box Description 2 ]\nThe breakfast box in the image contains the following items:. ...\n[ Normal Breakfast Box Description 3 ]\nThe breakfast box in the image has two side. ...\nCombine the three descriptions into one by extracting only the \"common\" features.\nCreate a concise summary that reflects the shared characteristics while removing any redundant or\nunique details.\n\n10\n\n\fPrompt - Generating Main Questions\n[ Description of {Class} ]\n{ Summary Description }\n[ Normal Constraints for {Class} ]\n{Normal Definition}\nUsing the [ Normal Constraints for {Class} ] and [ Description of {Class} ], create several\nbut essential , simple and important questions to determine whether the {Class} ] in the image is\nnormal or abnormal. Ensure the questions are only based on visible characteristics, excluding\nany aspects that cannot be determined from the image. Also, simplify any difficult terms into\neasy-to-understand questions.\n(Q1) : ...\n(Q2) : ...\nExample :\n[ Description of breakfast box ]\nThe breakfast box is divided into two sections: ...\n[ Normal Constraints for breakfast box ]\n- The breakfast box always contain exactly two tangerines and one nectarine that are always\nlocated on the left-hand side of the box.\n- The ratio and relative position of the cereals and the mix of banana chips and almonds on the\nright-hand side are fixed.\nUsing the [Normal Constriants for Breakfast Box] and [Description of Breakfast Box], create\nseveral but essential , simple and important questions to determine whether the Breakfast Box in\nthe image is normal or abnormal. Ensure the questions are only based on visible characteristics,\nexcluding any aspects that cannot be determined from the image. Also, simplify any difficult terms\ninto easy-to-understand questions.\n(Q1): ...\n(Q1): ...\n\nPrompt - Generating 5 variations Sub-Questions\nGenerate five variations of the following question while keeping the semantic meaning.\nInput : {Question}\nOutput1:\nOutput2:\nOutput3:\nOutput4:\nOutput5:\nGenerate five variations of the following question while keeping the semantic meaning.\nInput : Is there one nectarine visible on the left-hand side of the breakfast box?\nOutput 1:\nOutput 2:\nOutput 3:\nOutput 4:\nOutput 5:\n\n11\n\n\fPrompt - Testing\nQuestion : {Question}\nAt first, describe {Class} image and then answer the question.\nYour response must end with ‘- Result: Yes‘ or ‘- Result: No‘.\nLet’s think step by step.\n{Test Image Prompt (Test Image Input)}\nQuestion : Can you see a single nectarine on the left side of the breakfast box?\nAt first, describe breakfast box image and then answer the question.\nYour response must end with ‘- Result: Yes‘ or ‘- Result: No‘.\nLet’s think step by step.\n\nB\n\nVLM Implementation Details\n\nB.1\n\nVLMs\n\nIn our study, we uses three VLMs: GPT-4o (Achiam et al., 2023) , Gemini-1.5 Flash (Team et al., 2024) ,\nand InternVL2.5(38B, 8B) (Chen et al., 2024). The GPT-4o model was accessed and inferred through the\nOpenAI API. For the GPT-4o model, we fixed temperature to 1.0 and other hyper-parameters to default.\nRegarding the Gemini-1.5 models, temperature is 1, top_p is 0.95, and top_k is 40. For Open-Source\nInternVL-2.5 from OpenGVLab, we set temperature to 0.2, top_p to 0.7, repetition_penalty to 1.1,\ndo_sample to True, and max_new_tokens to 512. All these settings are the same across all experiments\nand across datasets.\nB.2\n\nLocal Experimental Setup\n\nWe utilized the open-source InternVL-2.5, leveraging up to three NVIDIA A100 GPUs due to its substantial\ncomputational requirements.\nB.3\n\nLang-SAM Prompt\n\nWhen using Lang-SAM to the two classes (Pushpins, Splicing Connectors), a text prompt was\nneeded to accurately capture the independent entities. It is as follows.\n- Splicing Connectors: Connector Block\n- Pushpins: The individual black compartments within the transparent plastic storage\nbox\nB.4\n\nData Security Option\n\nTo ensure the confidentiality and security of the Semiconductor SEM dataset provided by global\ncompany, we took stringent precautions when utilizing GPT-4o for our research. Specifically, all datasharing functionalities were disabled to strictly prevent unintended exposure or transmission of data\noutside the controlled research environment. By implementing these safeguards, we ensured that no\nproprietary or sensitive information was inadvertently shared with external servers or third-party entities.\nThis approach aligns with best practices for handling proprietary industrial datasets while leveraging\nadvanced AI models for research and analysis.\n\n12\n\n\fC\n\nMVTec LOCO AD Dataset\n\nC.1\n\nMVTec LOCO AD Dataset Overview\n\nThis is a statistical outline of the public MVTec Logical Constraints Anomaly Detection (LOCO) AD\nDataset. It consists of five categories (Breakfast Box, Screw Bag, Pushpins, Splicing Connectors,\nJuice Bottle). We conducted a few-shot experiment by randomly selecting three photos from the trainnormal set.\nCategory\n\nTrain-Normal Images\n\nTest-Normal Images\n\nTest-Logical Anomaly Images\n\nDetect types\n\nBreakfast Box\nScrew Bag\nPushpins\nSplicing Connectors\nJuice Bottle\n\n351\n360\n372\n354\n335\n\n102\n122\n138\n119\n94\n\n83\n137\n91\n108\n142\n\n22\n20\n8\n21\n18\n\nTotal\n\n1772\n\n575\n\n561\n\n89\n\nTable 4: Overview of the MVTec LOCO AD dataset\n\n&lt; Breakfast Box &gt;\n\n&lt; Screw Bag &gt;\n\n&lt; Juice Bottle &gt;\n\n&lt; Pushpins &gt;\n\n&lt; Splicing Connectors &gt;\n\nFigure 4: MVTec LOCO AD Dataset Normal sample images\n\nC.2\n\nMVTec LOCO AD Dataset- Normality Definition for each class\n\nBelow is a summary of the normality definitions for each class. For Splicing Connectors and Juice Bottle,\nthe normality definitions partially change depending on the color of each cable and the fruit of the juice.\nThe changed parts are expressed in red.\n\n13\n\n\fBreakfast Box\n- The breakfast box always contain exactly two tangerines and one nectarine that are always\nlocated on the left-hand side of the box.\n- The ratio and relative position of the cereals and the mix of banana chips and almonds on\nthe right-hand side are fixed.\n\nScrew Bag\n- A screw bag contains exactly two washers, two nuts, one long screw, and one short screw.\n- All bolts (screws) are longer than 3 times the diameter of the washer.\n\nPushpins\n- Each compartment of the box of pushpins contains exactly one pushpin.\n\nSplicing Connectors\n- Exactly two splicing connectors with the same number of cable clamps are linked by exactly one cable.\n- In addition, the number of clamps has a one-to-one correspondence to the {color} of the\ncable.\n- The cable must be connected to the same position on both connectors to maintain mirror\nsymmetry.\n- The cable length is roughly longer than the length of the splicing connector terminal block.\n\nJuice Bottle\n- The juice bottle is filled with {fruit} juice and carries exactly two labels.\n- The first label is attached to the center of the bottle, with the {fruit} icon positioned exactly\nat the center of the label, clearly indicating the type of {fruit} juice.\n- The second is attached to the lower part of the bottle with the text “100% Juice” written on\nit.\n- The fill level is the same for each bottle.\n- The bottle is filled with at least 90% of its capacity with juice, but not 100%.\n\nC.3\n\nMain-Questions for each class\nBreakfast Box\n\nQ1 : Are there exactly two tangerines visible on the left-hand side of the breakfast box?\nQ2 : Is there one nectarine visible on the left-hand side of the breakfast box?\nQ3 : Does the right-hand side of the breakfast box have cereals in the upper portion?\nQ4 : Is there a mix of banana chips and almonds in the lower portion of the right-hand side\nof the breakfast box?\nQ5 : Are the fruits (tangerines and nectarine) only on the left-hand side, and are the cereals\nwith banana chips and almonds only on the right-hand side?\n\n14\n\n\fScrew Bag\nQ1 : Are there exactly two tangerines visible on the left-hand side of the breakfast box?\nQ2 : Is there one nectarine visible on the left-hand side of the breakfast box?\nQ3 : Does the right-hand side of the breakfast box have cereals in the upper portion?\nQ4 : Is there a mix of banana chips and almonds in the lower portion of the right-hand side\nof the breakfast box?\nQ5 : Are the fruits (tangerines and nectarine) only on the left-hand side, and are the cereals\nwith banana chips and almonds only on the right-hand side?\n\nPushpins\nQ1 : Is there exactly one pushpin visible in the compartment?\nQ2 : Is the pushpin yellow in color?\nQ3 : Is the compartment transparent, allowing the pushpin to be visible?\nQ4 : Is the pushpin visible against a contrasting background?\n\nSplicing Connectors - Blue\nQ1 : Are there exactly two splicing connectors visible in the image?\nQ2 : Do both connectors have the same number of wire clamps?\nQ3 : Is there only one blue cable connecting the two splicing connectors?\nQ4 : Do the connectors have transparent bodies with orange levers?\nQ5 : Do both connectors have three orange levers, indicating three cable clamps?\nQ6 : Are the connectors made from clear plastic with metal contacts inside?\nQ7 : Are the orange levers made of plastic?\nQ8 : Is the blue cable connected to the same position on both connectors?\nQ9 : Is the pushpin visible against a contrasting background?\nQ10 : Does the blue cable appear longer than the length of one of the splicing connectors?\n\nSplicing Connectors - Red\nQ1 : Are there exactly two splicing connectors in the image?\nQ2 : Do both connectors have transparent casings with red or orange clamps/levers?\nQ3 : Are the connectors rectangular and compact, each containing five clamps?\nQ4 : Is there a single red cable connecting the two splicing connectors?\nQ5 : Is the red cable slightly longer than the length of the splicing connector terminal\nblock?\nQ6 : Are the connectors positioned parallel to each other?\nQ7 : Are the splicing connectors transparent with orange levers?\nQ8 : Does the cable connect to the same clamp position on both connectors, maintaining\nmirror symmetry?\nQ9 : Are the connectors made of plastic with transparent casings?\n\n15\n\n\fSplicing Connectors - Yellow\nQ1 : Are there exactly two splicing connectors visible in the image?\nQ2 : Do both splicing connectors have the same number of levers?\nQ3 : Is the cable connecting the two splicing connectors yellow in color?\nQ4 : Does each connector have two levers, indicating two clamps?\nQ5 : Is the cable entering the same position on both connectors, maintaining symmetry?\nQ6 : Is the length of the yellow cable longer than the terminal block of each splicing connector?\nQ7 : Are the splicing connectors transparent with orange levers?\nQ8 : Are the connectors positioned symmetrically on either side of the yellow cable?\nQ9 : Is there exactly one yellow cable connecting the two splicing connectors?\nJuice Bottle - Orange\nQ1 : Is the juice bottle filled with orange juice up to at least 90% of its capacity, but not\ncompletely full?\nQ2 : Are there exactly two labels on the juice bottle?\nQ3 : Is the center label positioned in the middle of the bottle with an orange icon clearly\nvisible?\nQ4 : Does the center label have a light orange background?\nQ5 : Is the lower label attached to the lower part of the bottle?\nQ6 : Does the lower label display the text 100% Juice in bold, likely black, font?\nQ7 : Are the labels vertically aligned, with the center label above the lower label, creating a\nbalanced appearance?\nJuice Bottle - Cherry\nQ1 : Is the bottle made of clear glass, allowing the color of the cherry juice to be visible?\nQ2 : Does the bottle have a central label with a cherry icon precisely placed in the middle?\nQ3 : Is there a central label on the bottle with a cherry icon clearly indicating the type of\njuice?\nQ4 : Is there a lower label on the bottle with the text 100% Juice written on it?\nQ5 : Is the fill level of the juice in the bottle at least 90% of its capacity, with a small gap\nat the top indicating it is not completely full?\nQ6 : Is there a central label on the bottle with a cherry icon positioned exactly at the center\nof the label?\nQ7 : Is the color of the juice a deep reddish-brown, consistent with cherry juice?\nJuice Bottle - Banana\nQ1 : Is the bottle made of clear glass, allowing you to see the banana juice inside?\nQ2 : Does the juice inside the bottle appear as a creamy, light yellow color, typical of banana juice?\nQ3 : Is the bottle slender and of a standard size typically used for single-serve juice bottles?\nQ4 : Is there a central label on the bottle with a banana icon located exactly at the center of\nthe label?\nQ5 : Is there a lower label on the bottle that reads ??00% Juice?\nQ6 : Does the juice fill level reach at least 90% of the bottle’s capacity, with a small gap at\nthe top?\nQ7 : Are there exactly two labels on the bottle, one in the center and one lower down?\n\n16\n\n\fC.4\n\nSub-Questions for each class\n\nAn example of a sub-question configuration for the breakfast box class is given. The Sub-Questions\ncan be created by applying an augmentation prompt (generating 5 variations Sub-Questions) to the\nMain-Questions.\nBreakfast Box\nQ1 Sub-Questions\n- Can you see exactly two tangerines on the left side of the breakfast box?\n- Is the left-hand side of the breakfast box showing precisely two tangerines?\n- Do you observe exactly two tangerines on the left of the breakfast box?\n- Are precisely two tangerines visible on the left side of the breakfast box?\n- Does the left-hand side of the breakfast box contain exactly two tangerines?\nQ2 Sub-Questions\n- Can you see a single nectarine on the left side of the breakfast box?\n- Is there a nectarine present on the left-hand side of the breakfast box?\n- Do you spot one nectarine on the left area of the breakfast box?\n- Is a nectarine visible on the left side within the breakfast box?\n- Is there one nectarine that can be seen on the left part of the breakfast box?\nQ3 Sub-Questions\n- Are there cereals located in the upper part of the right side of the breakfast box?\n- Is the upper portion of the right side of the breakfast box filled with cereals?\n- Can cereals be found in the top section on the right-hand side of the breakfast box?\n- Does the upper section of the right side of the breakfast box contain cereals?\n- Is the top of the right-hand side of the breakfast box occupied by cereals?\nQ4 Sub-Questions\n- Does the lower section on the right side of the breakfast box contain a combination of\nbanana chips and almonds?\n- Can you find a blend of banana chips and almonds in the bottom part of the right-hand side\nof the breakfast box?\n- Are banana chips and almonds mixed together in the lower right section of the breakfast\nbox?\n- Is there a combination of banana chips and almonds located in the bottom right area of the\nbreakfast box?\n- Are banana chips and almonds present together in the lower portion on the right side of the\nbreakfast box?’\nQ5 Sub-Questions\n- Are tangerines and nectarines exclusively on the left, and are cereals with banana chips and\nalmonds exclusively on the right?\n- Is it true that the fruits, such as tangerines and nectarines, are solely placed on the left\nwhile cereals with almonds and banana chips are only on the right?\n- Are the tangerines and nectarines located only on the left side, and are the cereals containing banana chips and almonds solely on the right side?\n- Are fruits like tangerines and nectarines restricted to the left-hand side, while cereals with\nbanana chips and almonds are found only on the right?\n- Is the placement such that tangerines and nectarines are just on the left, and cereals with\nalmonds and banana chips appear only on the right?\n\n17\n\n\fC.5\n\nLogical AD performance on MVTec LOCO AD dataset.\n\nMVTec LOCO AD\n(only Logical Anomaly)\n\nLogicQA (Ours)\n\nLogicAD\nJin et al. (2025)\n\nWinCLIP\nJeong et al. (2023)\n\nPatchCore\nRoth et al. (2022)\n\nGCAD\nBergmann et al. (2022)\n\nAST\nRudolph et al. (2023)\n\nLogiCode\nZhang et al. (2024a)\n\nPSAD\nKim et al. (2024b)\n\nCategory\n\nAUROC\n\nF1 -max\n\nAUROC\n\nF1 -max\n\nAUROC\n\nF1 -max\n\nAUROC\n\nAUROC\n\nAUROC\n\nAUROC\n\nAUROC\n\nBreakfast Box\nJuice Bottle\nPushpins\nScrew Bag\nSplicing Connectors\n\n87.6\n88.2\n98.4\n71.5\n92.4\n\n91.6\n89.6\n97.6\n64.5\n91.5\n\n93.1\n81.6\n98.1\n83.8\n73.4\n\n82.7\n83.2\n98.5\n77.9\n76.1\n\n57.6\n75.1\n54.9\n69.5\n64.5\n\n63.3\n58.2\n57.3\n58.8\n59.9\n\n74.8\n93.9\n63.6\n57.8\n79.2\n\n87.0\n100.0\n97.5\n56.0\n89.7\n\n80.0\n91.6\n65.1\n80.1\n81.8\n\n98.8\n99.4\n98.8\n98.2\n98.9\n\n100.0\n99.1\n100.0\n99.3\n91.9\n\nAverage\n\n87.6\n\n87.0\n\n86.0\n\n83.7\n\n64.3\n\n59.5\n\n74.0\n\n86.0\n\n79.7\n\n98.8\n\n98.1\n\nTable 5: (Extension Ver.) Logical AD performance on MVTec LOCO AD dataset. AUROC and F1 -max in %\nfor detecting logical anomalies of all categories of MVTec LOCO AD Dataset.\n\nD\n\nCan an Anomaly Score be effectively derived from the Token Prediction Probability?\n\nWe propose using VLM’s Log Probabilities to compute an anomaly score. We assume that low token\nprediction probabilities (log_probs) lead to uncertain performance and incorrect answers, as in typical\nLLM studies. Therefore, we conducted additional experiments to verify whether this assumption is correct\nin our VLM task.\nWe extracted 50 normal images for each class and generated answers for each Main-Question. The\nVLM’s answer must be \"Yes\" for all normal images. Therefore, if it is \"No\", the answer generated by\nVLM is incorrect. We visualized each answer and the average token prediction probability at that time by\nclass.\n\nMvTec LOCO Dataset - VLM Answer Log Probability Distribution\n1\n\nMean Log Probabilities\n\n0\n\n1\n\n2\n\n3\n\n4\n\nMvTec LOCO Dataset Class\n\nSplicing Connectors - Blue\nSplicing Connectors - Yellow\nSplicing Connectors - Red\n\nJuice Bottle - Banana\nJuice Bottle - Cherry\nPushpins\n\nYes\n\nVLM Answers\n\nNo\n\nFigure 5: Log-Probability Distribution of VLM answers\n\nAs you can see from the figure 5, when generating the wrong answer \"No\" in some classes, the\ndistribution of log_probs is generated relatively widely. When VLM generating \"Yes\", there is a clear\nsection where the log_probs remains high, whereas in the case of \"No\", the log_probs come out quite\ndiversely. Since our assumption is quite consistent with the actual data, it suggests that as a result\nof verifying with actual data, it was confirmed that using the token prediction probability as the\nreliability of the answer and using it as the Anomaly Score is valid.\n\n18\n\n\fE\n\nSemicomductor SEM Dataset\n\nThis is an overview of the Semiconductor SEM Dataset. Scanning Electron Microscopy (SEM) operates by\napplying a high voltage to direct an electron beam onto the surface of a sample, then detecting secondary\nelectrons that react to this beam to generate an image. The equipment used in our experiments achieves a\nresolution of approximately 1 nm, making it highly effective for observing the minute patterns on wafer\nsurfaces.\nSemiconductor fabrication involves hundreds to thousands of processing steps, comprising dozens of\nlayers. Furthermore, each layer has a distinct pattern to form integrated circuits. This indicates a wide\nvariety of both normal and abnormal (defective) patterns, implying that a generalized anomaly detection\nmodel would require an enormously large memory bank.\nThere is two defect types for anomaly dataset, Spot Defect and Bridge Defect. These two types\nof anomaly sets share the same Normal dataset. Bridge defects occur when separate conductive lines or\nelements accidentally fuse, potentially causing short circuits. In contrast, spot defects appear as small,\nlocalized flaws on the wafer surface that can degrade overall device performance.\nThe data was provided by a global semiconductor company, and the actual data cannot be disclosed\nfor security reasons. The sample examples below are images similar to the actual images found in the\npaper (Kim et al., 2020) and attached.\n\nType\n\nTrain-Normal Images\n\nTest-Normal Images\n\nTest-Logical Anomaly Images\n\nSpot Defect\nBridge Defect\n\n342\n\n169\n\n290\n123\n\nTotal\n\n342\n\n169\n\n413\n\nTable 6: Overview of the Semiconductor SEM dataset\n\n&lt; Normal &gt;\n\n&lt; Spot Defect &gt;\n\n&lt; Bridge Defect &gt;\n\nFigure 6: Semiconductor SEM Dataset sample images\n\nE.1\n\nSemiconductor SEM Dataset- Normality Definition\nSEM wafer\n\n- There should be no Particles, Hot Spots, or Defects.\n\n19\n\n\fE.2\n\nMain-Questions\nSEM wafer\n\nQ1 : Are there no visible particles or dust on the wafer surface?\nQ2 : Are the etched patterns consistent and evenly spaced across the image?\nQ3 : Is the surface free of bright or dark spots that look out of place?\nQ4 : Do the etched lines appear smooth and uniform without breaks or distortions?\nQ5 : Does the wafer surface look clean without any unexpected irregularities?\n\nE.3\n\nSub-Questions\nSEM wafer\n\nQ1 Sub-Questions\n- Is the wafer surface completely free of visible particles or dust?\n- Are there any visible particles or dust present on the wafer surface?\n- Can you confirm that no visible particles or dust are on the wafer surface?\n- Is the wafer surface entirely clean without any visible dust or particles?\n- Do you see any visible dust or particles on the wafer surface?\nQ2 Sub-Questions\n- Are the etched patterns uniform and evenly distributed throughout the image?\n- Do the etched patterns appear consistent and evenly spaced across the entire image?\n- Are the etched designs evenly spaced and consistent throughout the image?\n- Is there uniformity in the etched patterns, with even spacing across the image?\n- Do the etched patterns maintain consistency and equal spacing across the image?\nQ3 Sub-Questions\n- Does the surface have any unusual bright or dark spots?\n- Are there any bright or dark spots on the surface that seem out of place?\n- Is the surface completely uniform, without any irregular bright or dark spots?\n- Do you notice any unexpected bright or dark spots on the surface?\n- Is the surface free from any abnormal bright or dark spots?\nQ4 Sub-Questions\n- Are the etched lines consistently smooth and uniform, without any interruptions or distortions?\n- Do the etched lines maintain a smooth and even appearance, free from breaks or irregularities?\n- Are the etched lines free from distortions and interruptions, appearing smooth and uniform?\n- Do the etched lines exhibit a continuous, smooth, and uniform pattern without any breaks?\n- Are the etched lines well-defined, smooth, and uniform, without any visible distortions or\ngaps?\nQ5 Sub-Questions\n- Is the wafer surface free of any unexpected irregularities and appears clean?\n- Does the wafer surface appear smooth and without any unwanted defects?\n- Is the wafer surface visibly clean and devoid of any unexpected anomalies?\n- Can you confirm that the wafer surface is clean and free from irregularities?\n- Does the wafer surface exhibit a clean appearance without any noticeable defects?\n\n20\n\n\fF\n\nDetails and Effect of BPM &amp; Lang-SAM\n\nThe MVTec LOCO AD Dataset required image preprocessing based on class-specific features. In the\nSplicing Connectors class, the background consists of wire entanglement, while in the Screw Bag class,\na large portion of the image is occupied by empty space within the bag. To address this, we applied Back\nPatch Masking (BPM) to these two classes. BPM isolates the foreground target from the background,\nenabling target-centric detection. Also, Pushpins class is uniformly placed in each compartment, and\nSplicing Connectors class consists of multiple identical terminals within each connector block. Since\nboth classes exhibit the uniform objects issue that makes hallucination problem in VLM, we processed\nimages using Lang-SAM.\nWe conducted an experiment to verify whether BPM is actually effective in improving the response\naccuracy of VLM. We composed a subset of 50 normal images, entered the Main-Question for each\nclass, and checked the answer. A normal image must answer \"Yes\" to the Main-Questions. If it answered\na \"No\", VLM generated an wrong answer. We calculated the correct answer rate (accuracy) for each\nMain-Question for a total of 50 normal images. As you can see in the figure 7 below, the accuracy of the\nanswer increases when BPM is processed compared to when it is not.\nWe also experimented to verify whether Lang-SAM is effective for VLM performance. We conducted\nan experiment with the same settings as the previous BPM additional experiment. As shown in figure 7,\nwe found that Lang-SAM was significantly effective in improving the accuracy of VLM answers in\nboth classes (Pushpins and Splicing Connectors).\n&lt; Splicing Connectors-Blue &gt;\n\n&lt; Splicing Connectors-Yellow &gt;\n\n&lt; Pushpins &gt;\n\n&lt; Splicing Connectors-Red &gt;\n\n&lt; Screw Bag &gt;\n\nFigure 7: BPM and Lang-SAM Effect for each class\n\n21\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"