"<!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>UniSpector: Towards Universal Open-set Defect Recognition via\nSpectral-Contrastive Visual Prompting\n\narXiv:2604.02905v1 [cs.CV] 3 Apr 2026\n\nGeonuk Kim Minhoi Kim Kangil Lee Minsu Kim\nHyeonseong Jeon Jeonghoon Han Hyoungjoon Lim Junho Yim\nLG Energy Solution\n\nAbstract\nAlthough industrial inspection systems should be capable\nof recognizing unprecedented defects, most existing approaches operate under a closed-set assumption, which prevents them from detecting novel anomalies. While visual\nprompting offers a scalable alternative for industrial inspection, existing methods often suffer from prompt embedding collapse due to high intra-class variance and\nsubtle inter-class differences. To resolve this, we propose\nUniSpector, which shifts the focus from naive prompt-toregion matching to the principled design of a semantically\nstructured and transferable prompt topology. UniSpector\nemploys the Spatial-Spectral Prompt Encoder to extract\norientation-invariant, fine-grained representations; these\nserve as a solid basis for the Contrastive Prompt Encoder\nto explicitly regularize the prompt space into a semantically\norganized angular manifold. Additionally, Prompt-guided\nQuery Selection generates adaptive object queries aligned\nwith the prompt. We introduce Inspect Anything, the first\nbenchmark for visual-prompt-based open-set defect localization, where UniSpector significantly outperforms baselines by at least 19.7% and 15.8% in AP50b and AP50m ,\nrespectively. These results show that our method enable a\nscalable, retraining-free inspection paradigm for continuously evolving industrial environments, while offering critical insights into the design of generic visual prompting.\nhttps://geonuk-kimmm.github.io/UniSpector\n\n1. Introduction\nIn industrial mass production, visual inspection is essential\nfor quality control, where defect localization often matters\nmore than merely declaring whether a product is defective.\nWhile existing supervised detectors perform well in closedset scenarios with fixed defect categories [20, 30, 33], such\nassumptions rarely hold in practice, as new defect types\ncontinuously emerge and the definition of “normal” may\nshift over time. As illustrated in Figure 1, conventional\n\nFigure 1. Comparison of visual inspection paradigms: (a) closedset detectors fail on novel defect types and require costly retraining, (b) anomaly detectors cannot distinguish between defect\nclasses, and (c) visual prompting enables open-set recognition by\naligning unseen defects with exemplar prompts, providing a scalable visual inspection framework.\n\nclosed-set models [8, 10, 21, 25, 33] fail when new defects appear, requiring costly data rebuilding and retraining,\nwhereas anomaly detection methods [2, 6, 26] cannot distinguish among defect types.\nTo address category scalability without retraining,\nlanguage-driven open-set detectors leverage text descriptions [12, 19, 27]. However, in fine-grained industrial inspection, defects are often visually subtle and hard to verbalize even for domain experts, making purely text-driven\ngrounding unreliable. Consequently, visual prompting [18,\n22, 32, 38]—which matches input image regions to exemplar prompts—emerges as a scalable alternative for openset localization. Nevertheless, we find that existing visual\nprompting methods suffer from prompt embedding collapse\n\n\f(Fig. 4) when confronted with high intra-class variance and\nsubtle inter-class differences typical of industrial domains\n(Fig. 2). By treating prompt embeddings merely as implicit representations learned via prompt-to-region matching, prior works leave underexplored how the prompt embedding space should be structured to ensure robust transferability. We argue that applying visual prompting to the\nindustrial domain reveals these critical but underexplored\nstructural aspects of the visual prompting mechanism.\nTo overcome these limitations, we propose UniSpector,\na novel visual prompting framework for open-set defect detection and segmentation. Shifting the focus from promptto-region matching to the principled design of a semantically structured and transferable prompt topology. UniSpector comprises two core components: the Spatial–Spectral\nPrompt Encoder (SSPE) and the Contrastive Prompt Encoder (CPE). Specifically, SSPE redefines the visual prompt\nas a dual-domain descriptor that captures both spatial\nand spectral features. It extracts orientation-invariant frequency cues to suppress intra-class variance caused by rotational transformations, while enhancing inter-class separation through fine-grained spatial-spectral representations\ncapturing subtle textures often overlooked in the pixel domain. Building on these fine-grained representations, CPE\nexplicitly regularizes the prompt embedding space to establish a semantically structured topology within an angular manifold through contrastive learning. By enforcing\ncompactness within each class and sufficient angular separation between distinct defects, CPE ensures a semantically structured and transferable topology, where related\ndefect types lie closer in angle and dissimilar ones farther\napart—enabling semantically consistent placement of unseen defects instead of arbitrary projection. In addition, to\nimprove adaptability to novel defect types, we introduce\nPrompt-guided Query Selection (PQS), which dynamically\nselects prompt-conditioned object queries via differentiable\nGumbel–Softmax selection, ensuring that queries are adaptively initialized to the characteristics of prompt exemplar.\nTo evaluate the effectiveness, we establish Inspect Anything (InsA), the first benchmark for visual-prompt-based\nopen-set defect detection. InsA measures both in-domain\nand cross-domain generalization ability, reflecting adaptability to real-world settings where visually similar defects may arise from different products or materials. Extensive experiments demonstrate that UniSpector substantially\noutperforms existing baselines, achieving a 19.7% higher\ndetection APb50 and a 15.8% higher segmentation APm\n50 .\nThese results highlight that the principled design of the\nprompt space to mitigate intra-class variance and enhance\ninter-class separability is key to open-set defect detection.\nConsequently, UniSpector establishes a scalable foundation\nfor next-generation inspection, eliminating the need for extensive labeling and retraining in evolving environments.\n\nContributions\n1. Through the lens of industrial inspection, we identify\nunderexplored structural aspects of visual prompting,\nwhere treating prompts as implicit representations can\nlead to prompt embedding collapse due to high intraclass variance and subtle inter-class differences. Our\nfindings offer key architectural insights for designing robust, transferable visual prompting mechanisms.\n2. We propose UniSpector, a novel framework where SSPE\nextracts orientation-invariant, dual-domain representations that serve as a solid basis for CPE to explicitly regularize the prompt space into a semantically structured\nangular manifold, ensuring enhanced discriminability\nand transferability for novel defects.\n3. We establish InsA, the first benchmark for visualprompt-based open-set defect recognition. Experiment\nresults show that UniSpector surpasses baselines in\nboth in-domain and cross-domain settings, demonstrating scalable, class- and domain-generalizable inspection.\n\nFigure 2. Examples from the InsA benchmark. Top: Samples from\nthe same defect class showing high intra-class appearance variance. Bottom: Samples from different classes exhibiting similar\nvisual patterns, resulting in low inter-class separability. Such ambiguities highlight the inherent difficulty of defect recognition.\n\n2. Related Works\n2.1. Traditional defect detection and segmentation\nModern industrial defect inspection largely relies on deep\nlearning models designed for instance- or pixel-level localization. U-Net–style segmentation networks [25] remain widely adopted for their precise boundary modeling [20, 36], SSD-FasterNet [29] enhances Faster R-CNN\nwith region proposals and FPN to capture fine-grained\ndefects. Transformer-based architectures further improve\nlong-range context modeling [13, 30]. WPA-QFormer [33]\nuses wavelet decomposition and prototype queries to stabilize features for heterogeneous textures. Recent stud-\n\n\fFigure 3. Overview of UniSpector, an open-set defect detection and segmentation framework. The Spatial–Spectral Prompt Encoder extracts orientation-invariant spectral cues fused with spatial features to distinguish visually similar defects. Building on these, Contrastive\nPrompt Encoding regularizes the prompt embedding space into a structured manifold for robust open-set generalization. A Prompt-guided\nQuery Selection mechanism dynamically selects prompt-aware queries. Refer to Appendix C.1 for the inference phase architecture.\n\nies [8, 10, 21] have explored strategies to mitigate high\nintra-class variability and low inter-class separability due\nto variations in texture, illumination, or geometry. Despite\nstrong supervised performance, all of these methods assume\na fixed defect taxonomy and operate in a closed-set regime,\nmaking them unsuitable for real-world industrial environments where novel defect types continue to emerge.\n\n2.2. Visual/Text-prompted Open-Set Detection\nGroundingDINO [19] and YOLO-World [5] introduce\nnovel object detection by associating language descriptions\nwith visual features, without relying on pre-defined categories. However, in domains involving specialized or technical objects, verbal descriptions can be challenging. DINOv [18] explores the use of visual prompts as in-context\nexamples for general vision tasks, while T-Rex2 [12] and\nYOLOE [27] further integrate both text and visual prompts.\nCOSINE [23] leverages multiple backbones to extract\nmulti-modal features, and Prompt-DINO [9] applies orderaware query selection to align text and visual cues. Despite these advances, most methods assume well-defined\nclasses—assumptions rarely met in industrial defect inspection. Their focus on prompt-to-region matching neglects\nstructure of the prompt embedding space, causing semantic\ncollapse when encountering novel or fine-grained defects.\n\n3. Methods\nWe propose UniSpector, a visual prompting framework tailored for open-set defect detection and segmentation. To\nmitigate prompt embedding collapse inherent in promptto-region matching due to high intra-class variance and\nsubtle inter-class difference, UniSpector employs two critical components: (1) the Spatial-Spectral Prompt Encoder\n(SSPE), which enhances inter-class separability by integrating fine-grained spectral descriptors to distinguish subtle\ntextures beyond the pixel domain, while suppressing intraclass variance via orientation-invariant radial frequency\ncues to handle geometric rotations; and (2) leveraging these\nrefined representations, the Contrastive Prompt Encoder\n(CPE) explicitly regularizes the embedding manifold to establish a semantically organized angular topology, ensuring intra-class compactness and sufficient inter-class separation. Furthermore, Prompt-guided Query Selection (PQS)\ndynamically selects prompt-conditioned object queries.\n\n3.1. Overview\nAs shown in Fig. 3, UniSpector comprises the DETR framework. The vision encoder extracts token embeddings F ∈\nRNs ×d from a target image, where Ns and d denote the\nnumber of tokens and the hidden dimension, respectively.\n\n\fGiven K annotated prompt samples, prompt embeddings\nare averaged per class to obtain class-level prototypes pc ∈\nRd , where c is the class index. To obtain F -conditioned\nrepresentations, the decoder performs cross-attention CA(·)\nover F using object queries q ∈ RNq ×d and prototypes pc ,\nfollowed by a linear projection h(·). Here, Nq denotes the\nnumber of object queries. This process yields:\n  \\hat {\\mathbf {q}}_i = h(\\textit {CA}(\\mathbf {q}_i, \\mathcal {F})) \\text {,} \\quad \\hat {\\mathbf {p}}_c = h(\\textit {CA}(\\mathbf {p}_c, \\mathcal {F})) \n\n(1)\n\nThe final logit yi,c is then computed via the dot product between the class-level prototypes and query embeddings:\n  y_{i,c} = (\\hat {\\mathbf {p}}_c)^\\top \\hat {\\mathbf {q}}_i, \\quad i = 1,\\dots ,N_q, \\; c = 1,\\dots ,C \n\n(2)\n\nwhere C denotes the number of unique classes among\nthe K prompt samples. This design allows flexible classconditioned predictions without relying on a fixed classifier,\nsupporting robust recognition of unseen defect categories.\nThe encoder-decoder architecture and the training-inference\nphase are detailed in Appendices C.1 and C.3, respectively.\n\n3.2. Spatial-Spectral Prompt Encoder\nFor each of the K annotated prompt samples, we extract the\ncorresponding RoI patch Rk based on the annotated bounding box. To capture orientation-invariant yet fine-grained\nfeatures, we first compute the 2D Discrete Fourier Transform (DFT) of each patch, Fk (u, v) = DFT(Rk ). We then\neliminate directional bias by averaging the magnitude responses along concentric frequency rings:\n  h_k(\\rho ) = \\frac {1}{|\\Gamma _\\rho |}\\sum _{(u,v)\\in \\Gamma _\\rho } \\bigl |F_k(u,v)\\bigr |, \n\n(3)\n\nwhere Γρ denotes the set of frequency components at a radial distance ρ from the origin. The resulting 1D radial spectrum hk preserves global structural and spectral patterns\nwhile remaining orientation-invariant.\nTo derive the final multi-modal representation, we employ a dual-path encoding strategy. First, the spectral code\nzkfreq is obtained by projecting hk into a latent space via a\nRadial Frequency Encoder. In parallel, a spatial code zkspatial\nis extracted from the prompt image using masked crossattention. This attention mechanism is guided by the RoI\nmask of the prompted region, ensuring that only the defectrelevant area contributes to the representation. To effectively fuse these modalities, we employ two lightweight\nMLPs, denoted as falign and valign . The final prompt embedding e for the k-th sample is then computed as:\n  {\\mathbf {e}}_k = f_{\\text {align}}(z_k^{\\text {spatial}}) + v_{\\text {align}}(z_k^{\\text {freq}}) \n\n(4)\n\nThrough this dual-path fusion, UniSpector enhances interclass separability even under high visual similarity, while\n\nthe orientation-invariant radial spectrum effectively minimizes intra-class variance caused by rotations. Detailed\nderivations of the radial frequency extraction are provided\nin the Appendix B.\n\n3.3. Contrastive Prompt Encoding\nWe introduce the CPE, which explicitly regularizes the\nprompt embedding space to exhibit semantically coherent\ntopology to enhance open-set transferability. Specifically,\nCPE encourages two complementary properties: (1) Intraclass compactness: Aligning instances of the same class\ninto a shared semantic identity, ensuring invariance to geometric variations (e.g., orientation, width). (2) Semantic angular topology: Structuring the embedding manifold such\nthat semantically related classes occupy neighboring regions while dissimilar ones are separated by wider angular margins. To encourage this structure during training,\nwe employ the prompt embeddings with an angular-margin\ncontrastive loss, inspired by ArcFace [7]. For each defect\nclass c, a class-level prototype \\protect \\mathbf  {p}_c is computed by averaging the embeddings e of same-class instances among the K\nsamples. The cosine similarity between a prompt embedding \\protect \\mathbf  {e}_k and its class prototype \\protect \\mathbf  {p}_c is then given by\n  \\cos \\theta _{c,k} = \\frac {(\\mathbf {p}_c)^\\top \\mathbf {e}_k} {\\lVert \\mathbf {p}_c \\rVert _2 \\, \\lVert \\mathbf {e}_k \\rVert _2 } \n\n(5)\n\nWe then apply an angular-margin loss with margin m:\n\n(6)\nwhere α is a scaling factor, yk is the ground-truth class label of the k-th instance, and N is the number of prompt\ninstances in the batch. The margin m enforces a minimum angular gap between classes, preventing embedding\ncollapse. Importantly, once this margin is satisfied, embeddings are free to self-organize according to semantic\naffinity—allowing related classes to stay closer while pushing dissimilar classes farther apart, thus yielding a structured and semantically meaningful angular space. Consequently, this structured topology enables semantically consistent placement of unseen defects instead of arbitrary projection. For the full objective function integrating LCPE and\nfurther details, please refer to Appendix C.2.\n\n3.4. Prompt-guided Query Selection\nConventional DETR-style detectors and recent visual\nprompting approaches [18, 23] rely on learnable object\nqueries that encode biases from learned classes, limiting open-set generalization. Although similarity-based topK heuristics [12, 19] have been explored, they are nondifferentiable and cannot be optimized end-to-end.\n\n\fTo address this, we introduce a prompt-guided query selection module that selects a subset of vision tokens as object queries, conditioned on the given visual prompt. Given\nthe vision token embeddings F ∈ RNs ×d and class prototypes p ∈ RC×d , we first compute cosine similarities between each token and all prompts, then reduce them to a\nsingle relevance score per token by taking the maximum\nover class prototypes, resulting in a vector S ∈ RNs . To\nenable differentiable top-K selection, we add element-wise\nGumbel noise g ∈ RNs and compute soft selection weights:\n  \\tilde {\\mathbf {w}} = \\mathrm {softmax}\\big ((\\mathbf {S} + \\mathbf {g}) / \\tau \\big ), \nwhere τ is a temperature parameter. The hard top-K tokens\nare then selected based on w̃ to form a binary mask, which\nis used in the forward pass while gradients flow through\nw̃ via a Straight-Through Estimator. This produces promptconditioned object queries from the vision tokens in a fully\ndifferentiable manner, eliminating reliance on static priors.\n\n4. Experiments\nIndustrial defects are typically small, subtle, and visually\nheterogeneous, often lacking consistent semantics or clear\ncategory boundaries. To evaluate generalization ability to\nunseen defects, we introduce Inspect Anything (InsA), a\nbenchmark for open-set defect detection and segmentation\nwithin a visual prompting framework.\nInsA evaluates three aspects of generalization: (1) indomain generalization to novel defect types that share visual similarity with the seen sets, (2) cross-domain transferability to unseen defects emerging under different material\nproperties, imaging conditions, and defect morphologies,\nand (3) prompt-level generalization, quantified by aggregating results across multiple class partitions and independently sampled prompt sets to reflect stability rather than\ndependence on a single prompt configuration.\n\n4.1. InsA Benchmark Overview\n4.1.1. Dataset Composition\nAs shown in Tab. 1, InsA aggregates seven publicly available industrial defect datasets. We construct an in-domain\nopen-set protocol by splitting four datasets (GC10, MagneticTile, Real-IAD, MVTec) into disjoint seen (train) and\nunseen (test) sets. To reduce sampling bias and ensure reproducibility, we generate three splits with fixed random\nseeds \\ifmmode \\lbrace \\else \\textbraceleft \\fi 42, 82, 777\\}. All training samples for the seen sets\nacross these four datasets are merged into a single training set. To assess cross-domain transfer, we further evaluate cross-domain data drawn from 3CAD, VISION, and\nVisA, which contain imaging conditions and defect patterns\nthat differ significantly from those seen during training. Unlike the in-domain, the cross-domain setting evaluates on\nall classes of each dataset, measuring the model’s ability to\n\ntransfer beyond domain boundaries as well. Detailed dataset\ninformation is provided in the Appendix A.\n4.1.2. Evaluation\nWe adopt an exemplar-based evaluation protocol. For each\nprompt seed s \\in \\{42, 82, 777\\}, we sample 5 exemplar images per class as prompts and use the remaining images as\nqueries, without overlap between the two sets. This promptlevel seeding is independent of the class-split seeds that define the seen/unseen partitions.\nMetrics. We report \\protect \\mathrm  {AP}_{50}^{b} and \\protect \\mathrm  {AP}_{50}^{m} as the primary metrics\nas industrial defects often exhibit ambiguous or fuzzy spatial boundaries (e.g., dents, bends, scratches), making the\nprecise extent of a ground-truth region inherently subjective. Thus, stricter IoU thresholds (e.g., 0.75 or 0.95) provide limited practical value.\nReporting. We fine-tune each method on the seen set under three class-split seeds \\ifmmode \\lbrace \\else \\textbraceleft \\fi 42, 82, 777\\}, yielding three independently trained models. Each model is evaluated under the three prompt–query partitions defined by the same\nseeds, resulting in 3 \\text { (models)} \\times 3 \\text { (prompt seeds)} = 9 runs\nper setting. We report the mean across these runs for both indomain unseen and cross-domain evaluations. All baselines\nare compared under two configurations: (i) using publicly\nreleased pre-trained weights when available, and (ii) after\nfine-tuning on the InsA in-domain seen sets.\n\n4.2. Baseline Models\nWe compare our approach against two categories of related methods: visual grounding models and visual prompting models. For the visual grounding baselines, GroundingDINO [19] and YOLO-World [5] are trained using category names converted into caption-style prompts with\na unified template, “a {def ect name} defect of the\n{product name}.” GroundingDINO is evaluated solely on\ndetection as it has no segmentation head. SEEM [38] is\ntrained with both image and text prompts using the same\ncaption template, and is evaluated solely on segmentation\nas it lacks a detection head. For the visual prompting baselines, SegGPT [32] is evaluated using only the publicly released pre-trained weights, as no official training code is\navailable. Consequently, it is not fine-tuned on InsA, and\nevaluation is performed at its supported input resolution of\n448×448. All remaining models are evaluated under both\npre-trained and benchmark fine-tuning settings for fair comparison. SINE [22] and DINOv [18] are trained following\ntheir official visual prompting configurations without modification. T-Rex2 [12] is re-implemented (no official code is\nprovided) and adapted to operate in purely visual prompting\nmode. YOLOE [27] is evaluated with its textual interface\ndisabled and modified to accept only visual prompts when\nfine-tuned on InsA. Implementation details are provided in\nthe Appendix C.1,C.4.\n\n\fCount\nDataset\n\nImages\n\nDefect Instances\n\nDefect Categories\n\nGC10 [24]\nMagneticTile [11]\nReal-IAD [28]\nMVTec [3]\n3CAD [35]\nVISION [1]\nVisA [39]\n\n2,292\n388\n49,237\n1,258\n11,074\n1,757\n1,167\n\n3,563\n514\n55,326\n1,836\n16,559\n3,553\n2,131\n\n10\n5\n111\n73\n46\n44\n71\n\nTotal\n\n67,173\n\n83,482\n\n360\n\nClass Split\nIn-domain\nSeen (Train) Unseen (Test)\n7\n3\n4\n1\n83\n28\n53\n20\n147\n\n52\n\nCross-domain\n46\n44\n71\n161\n\nTable 1. Overview of the InsA benchmark composition. The in-domain split contains seen sets for training and unseen sets held out for\nopen-set evaluation, while the cross-domain split is held out for cross-domain evaluation. Refer to the Appendix A for the details.\n\nMethods\n\nIn-domain\n\nCross-domain\n\nOverall\n\nGC10\nMagneticTile\nReal-IAD\nMVTec AD\nb\nm\nb\nm\nb\nm\nAPb50 APm\n50 AP50 AP50 AP50 AP50 AP50 AP50\n\n3CAD\nVISION\nVisA\nb\nm\nb\nm\nAPb50 APm\n50 AP50 AP50 AP50 AP50\n\nAvg\nAPb50 APm\n50\n\n9.6\n8.0\n7.0\n3.4\n\n2.1\n1.5\n\n26.7\n11.0\n30.7\n29.8\n\n28.6\n27.5\n\n0.3\n1.2\n0.3\n21.7\n\n0.2\n16.7\n\n1.4\n18.8\n2.7\n5.4\n\n2.4\n4.7\n\n0.0\n0.0\n0.0\n0.0\n\n0.0\n0.0\n\n0.0\n0.0\n0.3\n0.0\n\n0.3\n0.0\n\n0.0\n0.1\n1.2\n1.7\n\n1.2\n1.6\n\n5.4\n5.6\n6.0\n8.9\n\n5.0\n7.4\n\n0.7\n0.9\n3.2\n16.5\n32.4\n1.6\n10.7\n38.2\n\n0.2\n0.1\n16.0\n0.5\n0.9\n0.8\n16.6\n33.9\n0.4\n9.5\n36.9\n\n2.0\n1.6\n30.0\n48.4\n49.0\n48.3\n43.3\n63.3\n\n0.2\n0.6\n20.1\n2.0\n1.9\n26.9\n39.6\n38.0\n45.4\n41.8\n57.7\n\n0.6\n1.2\n2.2\n21.0\n25.1\n16.6\n17.2\n69.1\n\n0.0\n0.0\n3.1\n0.5\n0.5\n1.4\n17.5\n28.8\n13.9\n15.5\n56.7\n\n4.6\n4.5\n19.0\n15.9\n24.4\n26.9\n25.8\n53.5\n\n0.3\n0.1\n6.8\n4.4\n4.1\n15.0\n15.2\n22.4\n22.7\n23.9\n46.5\n\n0.1\n0.1\n4.1\n2.9\n4.3\n4.9\n3.3\n14.1\n\n0.0\n0.0\n1.7\n0.2\n0.1\n2.1\n1.9\n2.9\n2.0\n1.4\n10.0\n\n0.7\n0.6\n4.3\n4.6\n5.4\n7.2\n3.5\n15.3\n\n0.0\n0.0\n0.9\n0.6\n0.2\n3.8\n3.8\n4.3\n5.9\n3.0\n12.5\n\n0.9\n1.0\n8.4\n10.4\n7.8\n14.4\n17.7\n32.8\n\n0.0\n0.0\n1.7\n0.9\n0.8\n7.0\n8.5\n6.7\n12.2\n15.3\n27.8\n\n1.4\n1.4\n10.2\n17.1\n21.2\n17.1\n17.4\n40.9\n\n0.1\n0.1\n7.2\n1.3\n1.2\n8.1\n14.7\n19.6\n14.6\n15.8\n35.4\n\nvisual grounding\n\nGroundingDINO [19]\nGroundingDINO† [19]\nYOLO-World [5]\nYOLO-World† [5]\nvisual prompting\n\nSEEM [38]\nSEEM† [38]\nSegGPT [32]\nSINE [22]\nSINE† [22]\nDINOv [18]\nDINOv† [18]\nT-Rex2 † [12]\nYOLOE [27]\nYOLOE† [27]\nUniSpector (Ours)†\n\nTable 2. Open-set detection and segmentation performance on the InsA. † Denotes models fine-tuned on in-domain seen sets of InsA.\n\n4.3. Comparison on InsA Benchmark\nText-prompt for open-set inspection Tab. 2 summarizes\nthe performance of UniSpector with a range of baseline methods. Visual grounding models such as GroundingDINO and YOLO-World exhibit modest performance on\ncertain datasets, but their overall AP50 remains below 10%,\nas many industrial defects cannot be fully described correctly by textual prompts. Notably, these visual grounding\napproaches show near-zero performance in cross-domain\nscenarios. These can be attributed to overfitting on highly\nspecific textual labels corresponding to seen product defects, which limits their transferability compared to purely\nvisual prompting methods.\nVisual-prompt for open-set inspection Other baselines\n(SEEM, SegGPT, and SINE) underperform even after finetuning on the training set. Recent visual prompting meth-\n\nods, DINOv and YOLOE, achieve modest performance\nwith a pre-trained model. Notably, despite DINOv being\ntrained on over one billion images in SA-1B, the subtle\nand heterogeneous nature of industrial defects limits effective transfer from such large-scale pre-training. After finetuning on InsA, both DINOv and YOLOE show slight improvements, with APb50 increasing from 10.2% to 17.1%\nand from 17.1% to 17.4%, respectively.\nIn contrast, UniSpector consistently outperforms all\nbaselines across both in-domain and cross-domain test sets\nby a substantial margin. Specifically, on MagneticTile and\nReal-IAD, UniSpector achieves APb50 scores of 63.3% and\n69.1%, respectively, demonstrating its strong potential to\ndevelop a visual inspection system that generalizes across\ndiverse defect types. However, the cross-domain performance remains relatively lower than the in-domain results,\nprimarily due to the strong dataset-specific imaging biases\n\n\fTable 3. Ablation study on individual modules in UniSpector. All experiments were conducted on the Real-IAD test set.\nSSPE\n\nCPE\n\nPQS\n\n✓\n✓\n✓\n\n✓\n✓\n\n✓\n\nAPb\n13.6\n27.9\n43.8\n46.3\n\nAPb50\n24.0\n43.0\n65.8\n69.1\n\nAbrasion on SIM card set\n\nDetection\nAPb75 APbs\n14.5\n17.9\n31.0\n38.3\n48.9\n47.4\n51.9\n50.3\n\nAPbm\n16.3\n31.4\n47.6\n50.1\n\nAPbl\n24.0\n39.8\n44.7\n47.8\n\nMissing parts on U block\n\n(a) Prompt embedding with UniSpector (ours)\n\nAPm\n7.7\n17.7\n26.0\n28.9\n\nSegmentation\nAPm\nAPm\n75\ns\n5.1\n7.2\n16.9\n17.2\n22.3\n21.0\n24.5\n23.3\n\nAPm\n50\n20.0\n34.8\n53.1\n56.7\n\nAPm\nm\n12.3\n24.8\n32.7\n34.1\n\nAPm\nl\n29.6\n33.7\n36.2\n38.0\n\nForeign objects on PCB\n\n(b) Prompt embedding with Dinov\n\nFigure 4. 3D PCA projection of L2-normalized prompt embeddings learned by UniSpector (left) and DINOv (right). Circle markers (◦)\ndenote seen sets and cross markers (×) denote unseen sets.\n\nTable 4. Comparison of query selection strategies.\nStrategy\nLearnable Parameter\nHeuristic Top-K\nPQS\n\nGC10\nAPb50 APm\n50\n34.4\n34.2\n35.6\n33.9\n38.2\n36.9\n\nVisA\nAPb50 APm\n50\n29.2\n24.7\n30.1\n25.4\n32.8\n27.8\n\ninherent in industrial inspection data. Such biases—arising\nfrom variations in illumination, texture, and capture conditions—pose a major challenge for generalization. While\nUniSpector effectively learns transferable semantic structures, its sensitivity to these domain-specific variations indicates that enhancing domain robustness—through crossdomain regularization or domain-agnostic prompt representation—remains a promising direction for future work.\n\n4.4. Model Analysis\nEffectiveness of each module Ablation studies on RealIAD (Tab. 3) confirm that each component incrementally improves performance. Specifically, given the refined\nprompt embeddings provided by SSPE, CPE yields the most\nsignificant gains by structuring the embedding space for\nopen-set transfer. Furthermore, PQS improves objectness\nestimation through prompt-adaptive queries, with the full\nintegration achieving the best results.\nQuery Selection Ablation Comparisons with fixed learnable queries and heuristic top-K similarity-based selection (Tab. 4) show simply replacing learnable queries with\nprompt-relevant tokens yields only marginal improvements.\nIn contrast, PQS achieves substantial gains across both\ndatasets and all metrics by learning a differentiable, promptconditioned query distribution.\n\n\fTable 5. In-domain evaluation on seen defect set using all categories of Real-IAD. Unlike the main open-set benchmark, here\nwe disable the seen/unseen split and train all models on the full\nlabel space, using a standard train/test split.\nMethod\n\nReal-IAD\nAPb50 APm\n50\n\nClosed-set models\n\nYOLOv11 [16]\nRT-DETR [37]\nMask2Former [4]\nMaskDINO [17]\n\n88.3\n89.9\n88.8\n91.7\n\n82.0\n84.5\n\n24.8\n29.8\n90.0\n\n20.4\n26.4\n82.7\n\nVisual-Prompting models\n\nDINOv [18]\nT-Rex2 [12]\nUniSpector (Ours)\n\nFigure 5. Intra-class cosine similarity comparison across seen and\nunseen defect classes on RealIAD.\n\nFigure 6. Effect of the number of prompt samples per defect class.\n\nSeen in-domain performance. To verify that the proposed\nframework remains competitive under fully supervised conditions, we evaluate it on Real-IAD using all defect categories for training, with images split only into train and test\nsets (Tab. 5). This setup corresponds to a pure closed-set\nevaluation. Notably, DINOv and T-Rex2 fail significantly,\nstruggling to recognize even seen classes. This confirms that\nnaive prompt-to-region matching leads to prompt embedding collapse when faced with the high intra-class variance\nof industrial defects. In contrast, our model achieves performance on par with strong closed-set baselines. These results indicate that UniSpector generalizes well to open-set\nscenarios while preserving high accuracy on seen sets.\nVisualization of Prompt Embedding We visualize the\n\nprompt embeddings learned by UniSpector and DINOv\nin a 3D embedding space. As shown in Fig. 4, UniSpector forms compact clusters within each defect class and\nclear angular separation across classes, indicating substantial reductions in both intra-class variance and inter-class\nseparability. These improvements arise from two factors:\n(1) the SSPE, which injects orientation-invariant spectral\ncues that mitigate rotation-induced intra-variance and enrich feature representation beyond pixel-level, and (2) the\nCPE, which explicitly enforces intra-class compactness and\ninter-class angular margins. In contrast, DINOv produces\nscattered and less separable embeddings, reflecting weak\nintra-class grouping—a consequence of relying solely on\nprompt-to-region matching without imposing a coherent semantic structure. Overall, UniSpector yield a semantically\norganized and transferable embedding space, where unseen\nsets (e.g., Missing parts on U block) naturally position near\nrelated seen sets (e.g., Abrasion on SIM card set), enabling\nstronger open-set generalization.\nIntra-class Variance Analysis To quantitatively assess the\ncompactness of prompt embeddings, we measure the average cosine similarity between embeddings of instances\nwithin the same class. As shown in Fig. 5, UniSpector\nachieves higher intra-class similarity for seen sets while exhibiting only slightly reduced similarity for unseen sets. In\ncontrast, T-Rex2 and DINOv show lower intra-class similarity for seen sets and more pronounced degradation for\nunseen sets. These results quantitatively confirm that UniSpector learns a more generalized embedding space, supporting improved open-set transferability.\nImpact of prompt samples. We further investigate how\nthe number of prompt per defect class influences performance on MVTec, VisA and RealIAD. Performance stabilizes with only 1–3 prompt images per class (Fig. 6). This\ndata efficiency suggests the learned space captures core defect semantics without requiring extensive exemplar diversity, making it highly practical for industrial settings, where\nhigh-quality exemplar collection is often limited.\n\n5. Conclusion\nIn this paper, we introduced UniSpector, a universal visual\nprompting framework that addresses embedding collapse\nin open-set industrial inspection. To resolve this, we proposed the SSPE to extract refined, orientation-invariant representations, providing a solid basis for the CPE to explicitly regularize the prompt space into a semantically structured angular topology. This topological structuring ensures\nintra-class compactness and inter-class separation, enabling\nrobust generalization to novel defects. Beyond its stateof-the-art performance, UniSpector offers critical insights\ninto generic visual prompting while establishing a scalable,\nretraining-free foundation for next-generation industrial inspection.\n\n\fUniSpector: Towards Universal Open-set Defect Recognition via\nSpectral-Contrastive Visual Prompting\nAppendix\nA. Dataset Details\nWe construct the Inspect Anything (InsA) benchmark from\nseven industrial inspection datasets: GC10-DET [24], Magnetic Tile Surface Defect [11], Real-IAD [28], MVTec\nAD [3], 3CAD [35], VISION [1], and VisA [39]. Among\nthese, GC10-DET, Magnetic Tile Surface Defect, RealIAD, and MVTec AD are used as in-domain datasets, with\ndefect categories partitioned into seen classes for training\nand unseen classes for testing. In contrast, 3CAD, VISION,\nand VisA serve as cross-domain datasets, used exclusively\nfor evaluating transferability to novel defect types and object appearances. To ensure robust estimates of generalization performance, we form three independent seen–unseen\nsplits with random seeds {42, 82, 777}, holding out roughly\n25% of defect categories in each in-domain dataset as unseen.\n\nA.1. Dataset Composition and Characteristics\nTable 6 summarizes key characteristics of each dataset, including product types, materials, and HSV color statistics.\nThe InsA benchmark is composed of diverse products and\nmaterials, enabling evaluation of open-set visual inspection\nperformance across varied distributions. Defect images are\ncaptured under a mix of distinct imaging conditions (e.g.,\nvery bright or very dark), resulting in generally large standard deviations in HSV channels. These distributions also\nvary across datasets, leading to differing mean values and\nfurther highlighting the challenge of generalizing visual inspection models across heterogeneous industrial data.\nGC10 [24]. GC10-DET is a defect detection dataset collected from metallic surfaces in industrial environments.\nIt comprises roughly 2,300 defect images annotated with\nbounding boxes for ten defect categories: silk spot, welding\nline, punching hole, water spot, crescent gap, oil spot, inclusion, waist folding, crease, and rolled pit. For each random\nseed, we select three categories as in-domain unseen test set\nand use the remaining seven categories as in-domain seen\ntraining set under that seed.\nMagneticTile [11]. The magnetic tile surface defect dataset\ncontains images of magnetic tile surfaces collected from\nindustrial production lines, covering both defective and\ndefect-free samples. It provides pixel-level annotations for\nfive defect categories—blowhole, crack, break, fray, and\nuneven—while normal images are discarded in our benchmark to focus solely on faulty cases. We retain approximately 400 defect images from the original release. For\n\neach random seed, we select one defect category as an\nin-domain unseen test set and use the remaining four categories as in-domain seen classes for training under that\nseed.\nReal-IAD [28]. Real-IAD is a multi-view industrial\nanomaly dataset comprising 30 real-world objects fabricated from diverse materials (e.g., plastic, rubber). Each\nobject is captured under five viewpoints and exhibits 2–5\ndistinct defect modes selected from eight defect families\n(i.e., pit, deformation, abrasion, scratch, damage, missing parts, foreign objects, and contamination). Only viewpoints equipped with pixel-level defect masks are retained\nas anomaly samples, and we use the official 1024 × 1024resolution version of the images. From the binary defect\nmasks, we perform connected-component labeling with 8connectivity to obtain instance-level segments, and discard\ncomponents whose width or height is smaller than 1% of\nthe image width or height to remove tiny noisy polygons.\nFor each split, we select 28 defect categories as in-domain\nunseen test classes and use the remaining categories as indomain seen classes for training.\nMVTec AD [3]. MVTec AD is a real-world industrial\nanomaly dataset that contains defective images across multiple object and texture categories, with various defect types\nsuch as contamination, oil, cuts, and cracks. In our benchmark, we discard all “good” images and use only anomalous\nsamples with polygon masks. From these masks, we extract\nindividual defect instances and remove components whose\nwidth or height is smaller than 1% of the corresponding image dimension, thereby filtering out tiny noisy regions.\n3CAD [35]. 3CAD is a large-scale anomaly detection\ndataset collected from real 3C product manufacturing lines,\ncovering representative defects that arise in practical production environments. It focuses on parts made of three\ncommon materials (Aluminum, Iron, and Copper) and includes multiple types of 3C components (e.g., camera covers, tablets, and PCs). Since 3CAD is designed for anomaly\ndetection, we discard the “good” class without polygon annotations and also remove the Multiple-defects class, whose\ndefect instances cannot be assigned to specific categories.\nAfter this filtering, we obtain a total of 46 defect categories.\nFrom the remaining polygons, we extract individual defect\ninstances and discard components whose width or height is\nsmaller than 1% of the corresponding image dimension to\neliminate tiny noisy regions.\nVISION [1]. The VISION benchmark unifies 14 indus-\n\n\fColor Distribution Statistics\nS\nV\n\nDataset\n\nProduct\n\nMaterial\n\nGC10 [24]\nMagneticTile [11]\nReal-IAD [28]\nMVTec AD [3]\n\nSteel\nMagnetic Tile\nPCB, Toy Brick, Transistor, etc.\nCable, Hazelnut, Tile, etc.\n\nSteel\nSteel\nPlastic, Rubber, Wood, etc.\nGlass, Metal, Fabric, etc.\n\n0.0 ± 0.0\n0.0 ± 0.0\n33.4 ± 49.5\n46.7 ± 55.1\n\n0.0 ± 0.0\n0.0 ± 0.0\n40.6 ± 65.7\n46.0 ± 47.8\n\n85.7 ± 39.6\n109.4 ± 47.4\n110.2 ± 105.5\n120.5 ± 66.7\n\n3CAD [35]\nVISION [1]\nVisA [39]\n\nCamera Cover, Tablet PC, etc.\nCapacitor, Lens, Screw, etc.\nCandle, Capsule, Macaroni, etc.\n\nAluminum, Copper, etc.\nPlastic, Steel, Wood, etc.\nPlastic, Food, etc.\n\n7.2 ± 19.2\n25.2 ± 41.1\n47.7 ± 36.4\n\n16.7 ± 49.0\n38.4 ± 70.7\n95.7 ± 71.9\n\n78.6 ± 70.5\n106.3 ± 83.3\n101.9 ± 66.1\n\nH\n\nTable 6. Dataset statistics used in the InsA benchmark, including their product types, materials, and the color distribution statistics\n(mean ± std) for each HSV channel.\n\ntrial inspection subsets, each corresponding to a distinct\nobject class from real manufacturing lines and captured at\nits native (often high) resolution; consequently, image size\nvaries across subsets. The corpus provides pixel-level instance masks for 44 defect categories. For InsA, we retain\nonly images in the train and val partitions that include polygon annotations and discard the inference split, whose labels are withheld. From the polygon masks, we remove segments whose width or height is smaller than 1% of the width\nor height of the image to filter out tiny noisy regions. All\n44 defect categories are used exclusively for cross-domain\nevaluation, and none of them are included in the training\ndata.\nVisA [39]. VisA is an industrial visual inspection dataset\ncontaining normal and defective images from 12 object categories, some of which exhibit large variations in object location and pose across images. It covers both surface-level\ndefects (e.g., scratches, dents) and structural defects (e.g.,\nmisplacement). In our benchmark, we discard all normal\nimages and retain only those that contain at least one annotated defective region. We also exclude the Other defect\nclass, whose semantics are not clearly specified. From the\nbinary defect masks, we apply connected-component labeling with 8-connectivity to obtain instance-level segments,\nand discard components whose width or height is smaller\nthan 1% of the corresponding image dimension, thereby filtering out tiny noisy regions.\n\nA.2. Prompt Allocation\nSelection of Prompt data To ensure class purity, prompt\nsamples are selected only from single-label samples that\ncontain the target defect alone; mixing co-occurring other\ncategories into a prompt would inject ambiguous cues and\ndilute the class-specific signal.\nImage-level vs. Instance-level Furthermore, unlike conventional few-shot protocols [15, 31, 34] that count shots\nper instance (box or mask), we define k with respect to\nentire images. In industrial defect inspection a single photograph often exhibits multiple defect instances whose vi-\n\nsual similarity renders selective prompting ill-posed; excluding certain regions while prompting others would implicitly guide the detector to ignore genuine defects within\nthe same frame. Counting shots at the image level therefore\nmirrors real deployment conditions and yields a fairer, more\ninterpretable comparison across categories and methods.\nPrompt Size For each defect category, we default to 5 visual prompt images during evaluation. However, to ensure a\nbalanced evaluation across all dataset in InsA. For the ”tail\nclasses” (total images ≤ 10 ), we restrict the number of\nprompts to 1, as assigning 5 prompts to classes with very\nfew target images leads to an irrational prompt-to-target ratio. As shown in Figure 7, by reducing the prompt to a single image for these cases, we achieved a more balanced and\nreasonable evaluation setting for long-tailed defect distributions. Notably, potential selection bias from using a single prompt is mitigated by averaging results across multiple\nrandom seeds, ensuring a robust evaluation.\nAlgorithm 1 Radial Frequency Feature Extraction\nRequire: Image I, Bounding boxes B, Frequency bins J\nEnsure: Spectral features F ∈ RK×J\n1: for each bounding box bi ∈ B do\n2:\nIcrop ← Crop(I, bi ) and convert to grayscale\n3:\nM ←p\n|FFTShift(FFT2D(Icrop ))|\n4:\nR ← (X − cx )2 + (Y − cy )2\n5:\nRnorm ← R/ max(R)\n6:\nfor j = 1 to J do\n7:\nfj ← mean(M [Rnorm ∈ binj ])\n8:\nend for\n9:\nfi ← L2Normalize([f1 , ..., fJ ])\n10: end for\n11: return F = [f1 , ..., fK ]T\n\nB. Details of Radial Frequency Extraction\nWe present the radial frequency extraction procedure in Algorithm 1. Given a region crop, 2D FFT is computed and\n\n\fFigure 7. Distribution of Prompt-to-Target Ratios across Defect Classes. It illustrates the prompt-to-target ratio for each defect class (with\nsample sizes). We compare our adaptive prompt strategy (Blue) against the fixed prompt strategy (Orange). By reducing the number of\nprompts to one for tail classes (total images ≤ 10), the adaptive strategy prevents an irrational ratio in the tail classes, ensuring a more\nbalanced and fair evaluation across the entire InsA dataset.\n\n(a) Prompt samples\n\n(b) Target Images\n\n(c) Prediction results\n(UniSpector)\n\n(d) Prediction results\n(Dinov)\n\nFigure 8. UniSpector is capable of recognizing unseen defects via visual prompts. (a) Orange box: user-specified prompt region. (b) Blue\nbox: corresponding ground-truth in the target image. (c) Green boxes: correct predictions by UniSpector, accurately localizing subtle\ndefects. (d) Red boxes: DINOv predictions, showing failure to localize the prompted defect.\n\n\fthe resulting frequency magnitudes are aggregated into radial bins and L2-normalized. This process introduces minimal computational overhead while providing complementary texture cues to the spatial features.\n\nC. Implementation Details\nC.1. Architectural Details\nUniSpector is built upon the MaskDINO [17] architecture,\nan encoder-decoder framework designed for unified object\ndetection and segmentation. For the encoder, we employ a\nSwin-T backbone with hierarchical stages to extract multiscale feature maps. For fair comparison, the same SwinT\nbackbone is used for DINOv, T-Rex2 and UniSpector, while\nYOLOE utilize its native YOLO11m [14] backbone due\nto architectural constraints. The decoder is composed of\n9 Deformable Transformer layers with 8 attention heads.\nEach layer consists of self-attention, multi-scale deformable\ncross-attention, and an FFN.\n\nC.2. Training Objective\nWe follow the standard MaskDINO training recipe, incorporating denoising (DN) training and auxiliary deep supervision across all L decoder layers to accelerate convergence.\nBounding box regression is supervised by L1 and GIoU\nlosses, while mask segmentation employs a combination of\nBCE and Dice losses. Classification is addressed by a Focal loss measuring the similarity between object queries and\nclass prototypes. The bipartite matching between predictions and ground truths is established via Hungarian matching. Finally, the proposed LCPE is integrated with these standard terms to form total objective:\n  \\begin {aligned} \\mathcal {L}_{\\text {total}} = \\sum _{l=0}^{L-1} \\Big ( &amp; \\lambda _{\\text {cls}}\\mathcal {L}_{\\text {cls}}^{(l)} + \\lambda _{\\text {L1}}\\mathcal {L}_{\\text {L1}}^{(l)} + \\lambda _{\\text {giou}}\\mathcal {L}_{\\text {giou}}^{(l)} +\\lambda _{\\text {bce}}\\mathcal {L}_{\\text {bce}}^{(l)} \\\\ &amp; + \\lambda _{\\text {dice}}\\mathcal {L}_{\\text {dice}}^{(l)}\\Big ) + \\mathcal {L}_{\\text {DN}} + \\lambda _{\\text {CPE}}\\mathcal {L}_{\\text {CPE}} \\end {aligned} \n\n(7)\nwhere each λ denotes the corresponding loss weight. Note\nthat LDN is the denoising counterpart of the same base\nlosses with the same coefficients as their corresponding\nmain losses. Under this joint optimization, we use the default weights: λcls = 4, λL1 = 5, λgiou = 2, λbce = 5,\nλdice = 5, and λCPE = 1.\n\nC.3. Details of Inference Phase\nAs illustrated in Figure 9, UniSpector decouples the inference process into two distinct stages to minimize computational overhead. Specifically, Prompt Embedding Extraction is performed as a one-time offline process to extract prompt embeddings. During the subsequent Promptguided Prediction stage, these stored embeddings are loaded\ndirectly, bypassing redundant re-extraction of prompt embeddings for every query. Notably, this architecture allows\n\nFigure 9. Detailed view of the inference phase. Unlike the training\nphase (see Fig. 3 in the main manuscript), inference is decoupled\ninto “Prompt Embedding Extraction” and “Prompt-guided Prediction” to minimize computational overhead by leveraging cached\nembeddings.\n\nUniSpector to seamlessly integrate prompt embeddings for\nany defect category of interest, enabling flexible and efficient deployment in open-set scenarios.\n\nC.4. Training settings\nAll Swin-T-based models are initialized with the official DINOv pre-trained wights, while YOLOE is initialized from\nits publicly available checkpoint. Training is conducted for\n20,000 steps with a total batch size of 48 on two NVIDIA\nH100 GPUs. We use the AdamW optimizer with a linear\nlearning rate schedule, a base learning rate of 1 \\times 10^{-4} , a\n10-step warm-up, and a weight decay of 0.05. Data augmentation includes random horizontal flipping, contrast adjustment (0.8–1.1), and brightness adjustment (0.5–1.3). All\nmodels are trained at an input resolution of 720 \\times 720 pixels. The radial frequency distribution is computed using 256\nbins. The scaling factor is set to s = 30.0 and the angular\nmargin to m = 0.5, which empirically stabilizes the optimization. We use N_q=300 object queries and set the\nGumbel-Softmax temperature to \\tau =1.0.\n\nD. Additional analysis\nD.1. Robustness to the quality of prompts\nTo analyze robustness to prompt quality which is indeed\ncritical factor for practical deployment. We conducted additional experiments simulating realistic industrial scenarios\nalong two dimensions: image and annotation.\nImage Degradation To simulate blurry conditions, we\nevaluated the performance under Gaussian blur kernels with\ncontrolled standard deviations (σ) on the prompt images.\n\n\fFigure 10. Robustness against prompt annotation (averaged over\n10 trials per IoU). Each perturbed box is constrained to a specific\nIoU level relative to the ground-truth label.\nTable 7. Experimental analysis under Gaussian Blur on the prompt\nimages. We evaluate the impact of varying blur levels (σ) on the\nperformance.\n\nDataset Metric Clean 0.5σ 1.0σ 1.5σ 2.0σ 2.5σ 3.0σ\nVisA\n\nb\nAP50\nm\nAP50\n\nMTile\n\nb\nAP50\nm\nAP50\n\n32.5\n28.2\n64.2\n38.9\n\n33.3 32.0 30.0 27.4 25.8 23.4\n28.3 27.6 26.3 23.8 22.3 20.4\n64.9 64.1 63.5 62.0 60.1 57.0\n39.1 38.8 37.8 36.4 34.3 31.0\n\nThe results are summarized in Table 7. Interestingly, a slight\nperformance improvement was observed at 0.5σ blur. This\nimprovement likely stems from the suppression of highfrequency noise, yielding prompt embeddings that are less\nbiased toward instance-specific artifacts. The performance\ndifferences remain small up to 1.5σ, while a clear degradation is observed beyond 2.0σ, where the image quality\ndegradation becomes visually noticeable. Performance is\nstable under Gaussian blur up to σ = 1.5 (Tab. 7) and box\nperturbations down to IoU 0.3 (Fig. 10, proving robustness.\nNoisy Annotation We further examined robustness by randomly perturbing the prompt bounding boxes to achieve\nIoU levels ranging from 0.1 to 0.9 relative to the ground\ntruth (GT). Each configuration was averaged over 10 independent trials. As shown in Figure 10, UniSpector maintains high performance down to an IoU of 0.3, demonstrating significant tolerance to imprecise annotations. Beyond this threshold, the perturbed boxes begin to encompass background or non-defect regions rather than the target defect, leading to an expected drop in precision as the\nprompt’s semantic signal becomes corrupted.\n\nD.2. Analysis of In-Context Learning Approaches\nWe conducted quantitative comparisons with representative in-context learning methods, PerSAM[1] and VRPSAM[2], as shown in the table below. When evaluated in\n\na training-free manner, PerSAM achieved an average APm\n50\nof 6.0 due to the significant domain gap. The fine-tuning\nvariant (PerSAM-F) yielded only a marginal improvement\nof +1.4 in average performance. We attribute this to a representation bottleneck: both PerSAM and VRP-SAM fundamentally rely on the representational capacity of frozen\nSAM encoders. Relying on frozen SAM general-object representations, PerSAM and VRP-SAM fail to generalize to\nInsA even after fine-tuning. Because the feature space of\nSAM, which is primarily trained on general real-world objects, may not be optimally suited for discriminating finegrained features of subtle and complex defects. For VRPSAM, since the authors do not release pre-trained weights\nfor the VRP-Encoder, we report only the performance after\ntraining the VRP-Encoder on our in-domain seen set. Relying on frozen SAM general-object representations, PerSAM and VRP-SAM fail to generalize to InsA even after\nfine-tuning (Tab. 8).\nm\nTable 8. Results of in-context learning methods (AP50\n) on InsA\nbenchmark. † indicates results obtained by fine-tuning on the indomain seen split of the proposed protocol.\n\nMethod\n\nGC10 MTile RIAD MVTe 3CAD VISN VisA Avg\n\nPerSAM\nPerSAM†\nVRP-SAM†\n\n0.0\n0.1\n0.4\n\n33.0\n34.2\n12.5\n\n0.8\n1.5\n22.3\n\n4.8\n8.7\n18.8\n\n0.1\n0.2\n3.2\n\n0.3\n1.0\n4.7\n\n3.0 6.0\n6.0 7.4\n12.2 10.6\n\nD.3. Visualization\nFigure 8 presents qualitative results for open-set defect detection. Given a user-specified region in the prompt images\n(orange bounding box), UniSpector successfully identifies\ncorresponding defect instances in the target image. As illustrated in Figure 8(c), UniSpector accurately captures even\nsubtle and fine-grained defects in PCB (TOP). Moreover,\ndespite the pronounced rotational difference between the\nprompt and target defect instance, UniSpector consistently\nlocalizes the prompted defect type (BTM).\n\nReferences\n[1] Haoping Bai, Shancong Mou, Tatiana Likhomanenko, Ramazan Gokberk Cinbis, Oncel Tuzel, Ping Huang, Jiulong\nShan, Jianjun Shi, and Meng Cao. Vision datasets: A benchmark for vision-based industrial inspection. arXiv preprint\narXiv:2306.07890, 2023. 6, 9, 10\n[2] Kilian Batzner, Lars Heckler, and Rebecca König. Efficientad: Accurate visual anomaly detection at millisecond-level\nlatencies. In Proceedings of the IEEE/CVF winter conference on applications of computer vision, pages 128–138,\n2024. 1\n[3] Paul Bergmann, Michael Fauser, David Sattlegger, and\nCarsten Steger. Mvtec ad–a comprehensive real-world\ndataset for unsupervised anomaly detection. In Proceedings\n\n\fof the IEEE/CVF conference on computer vision and pattern\nrecognition, pages 9592–9600, 2019. 6, 9, 10\n[4] Bowen Cheng, Ishan Misra, Alexander G Schwing, Alexander Kirillov, and Rohit Girdhar. Masked-attention mask\ntransformer for universal image segmentation. In Proceedings of the IEEE/CVF conference on computer vision and\npattern recognition, pages 1290–1299, 2022. 8\n[5] Tianheng Cheng, Lin Song, Yixiao Ge, Wenyu Liu, Xinggang Wang, and Ying Shan.\nYolo-world: Real-time\nopen-vocabulary object detection. In Proceedings of the\nIEEE/CVF conference on computer vision and pattern\nrecognition, pages 16901–16911, 2024. 3, 5, 6\n[6] Thomas Defard, Aleksandr Setkov, Angelique Loesch, and\nRomaric Audigier. Padim: a patch distribution modeling\nframework for anomaly detection and localization. In International conference on pattern recognition, pages 475–489.\nSpringer, 2021. 1\n[7] Jiankang Deng, Jia Guo, Niannan Xue, and Stefanos\nZafeiriou. Arcface: Additive angular margin loss for deep\nface recognition. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages\n4690–4699, 2019. 4\n[8] Hanze Ding, Zhangkai Wu, Jiyan Zhang, Ming Ping, and\nYanfang Liu. Lerenet: Eliminating intra-class differences for\nmetal surface defect few-shot semantic segmentation. arXiv\npreprint arXiv:2403.11122, 2024. 1, 3\n[9] Yuchen Guan, Chong Sun, Canmiao Fu, Zhipeng Huang,\nChun Yuan, and Chen Li. Text-guided visual prompt dino\nfor generic segmentation. In Proceedings of the IEEE/CVF\nInternational Conference on Computer Vision, pages 21288–\n21298, 2025. 3\n[10] Zican Hu, Jiaxiang Luo, and Zixiang Hong. Category relationship enhancement transformer for industrial defect segmentation. Knowledge-Based Systems, 326:114059, 2025. 1,\n3\n[11] Yibin Huang, Congying Qiu, and Kui Yuan. Surface defect\nsaliency of magnetic tile. The Visual Computer, 36(1):85–96,\n2020. 6, 9, 10\n[12] Qing Jiang, Feng Li, Zhaoyang Zeng, Tianhe Ren, Shilong\nLiu, and Lei Zhang. T-rex2: Towards generic object detection\nvia text-visual prompt synergy. In European Conference on\nComputer Vision, pages 38–57. Springer, 2024. 1, 3, 4, 5, 6,\n8\n[13] Xiaoheng Jiang, Kaiyi Guo, Yang Lu, Feng Yan, Hao\nLiu, Jiale Cao, Mingliang Xu, and Dacheng Tao. Cinformer: Transformer network with multi-stage cnn feature\ninjection for surface defect segmentation. arXiv preprint\narXiv:2309.12639, 2023. 2\n[14] Glenn Jocher and Jing Qiu. Ultralytics yolo11, 2024. 12\n[15] Bingyi Kang, Zhuang Liu, Xin Wang, Fisher Yu, Jiashi Feng,\nand Trevor Darrell. Few-shot object detection via feature\nreweighting. In Proceedings of the IEEE/CVF international\nconference on computer vision, pages 8420–8429, 2019. 10\n[16] Rahima Khanam and Muhammad Hussain. Yolov11: An\noverview of the key architectural enhancements. arXiv\npreprint arXiv:2410.17725, 2024. 8\n[17] Feng Li, Hao Zhang, Huaizhe Xu, Shilong Liu, Lei Zhang,\nLionel M Ni, and Heung-Yeung Shum. Mask dino: Towards\n\na unified transformer-based framework for object detection\nand segmentation. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages\n3041–3050, 2023. 8, 12\n[18] Feng Li, Qing Jiang, Hao Zhang, Tianhe Ren, Shilong Liu,\nXueyan Zou, Huaizhe Xu, Hongyang Li, Jianwei Yang,\nChunyuan Li, et al. Visual in-context prompting. In Proceedings of the IEEE/CVF Conference on Computer Vision\nand Pattern Recognition, pages 12861–12871, 2024. 1, 3, 4,\n5, 6, 8\n[19] Shilong Liu, Zhaoyang Zeng, Tianhe Ren, Feng Li, Hao\nZhang, Jie Yang, Qing Jiang, Chunyuan Li, Jianwei Yang,\nHang Su, et al. Grounding dino: Marrying dino with\ngrounded pre-training for open-set object detection. In European conference on computer vision, pages 38–55. Springer,\n2024. 1, 3, 4, 5, 6\n[20] Taiheng Liu, Zhaoshui He, Zhijie Lin, Guang-Zhong Cao,\nWenqing Su, and Shengli Xie. An adaptive image segmentation network for surface defect detection. IEEE Transactions on Neural Networks and Learning Systems, 35(6):\n8510–8523, 2022. 1, 2\n[21] Tongkun Liu, Bing Li, Xiao Jin, Yupeng Shi, Qiuying Li,\nand Xiang Wei. Exploring few-shot defect segmentation in\ngeneral industrial scenarios with metric learning and vision\nfoundation models. arXiv preprint arXiv:2502.01216, 2025.\n1, 3\n[22] Yang Liu, Chenchen Jing, Hengtao Li, Muzhi Zhu, Hao\nChen, Xinlong Wang, and Chunhua Shen. A simple image\nsegmentation framework via in-context examples. Advances\nin Neural Information Processing Systems, 37:25095–25119,\n2024. 1, 5, 6\n[23] Yang Liu, Yufei Yin, Chenchen Jing, Muzhi Zhu, Hao Chen,\nYuling Xi, Bo Feng, Hao Wang, Shiyu Li, and Chunhua\nShen. Unified open-world segmentation with multi-modal\nprompts. In Proceedings of the IEEE/CVF International\nConference on Computer Vision, pages 21557–21567, 2025.\n3, 4\n[24] Xiaoming Lv, Fajie Duan, Jia-jia Jiang, Xiao Fu, and Lin\nGan. Deep metallic surface defect detection: The new benchmark and detection network. Sensors, 20(6):1562, 2020. 6,\n9, 10\n[25] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. Unet: Convolutional networks for biomedical image segmentation. In International Conference on Medical image computing and computer-assisted intervention, pages 234–241.\nSpringer, 2015. 1, 2\n[26] Karsten Roth, Latha Pemula, Joaquin Zepeda, Bernhard\nSchölkopf, Thomas Brox, and Peter Gehler. Towards total\nrecall in industrial anomaly detection. In Proceedings of\nthe IEEE/CVF conference on computer vision and pattern\nrecognition, pages 14318–14328, 2022. 1\n[27] Ao Wang, Lihao Liu, Hui Chen, Zijia Lin, Jungong Han, and\nGuiguang Ding. Yoloe: Real-time seeing anything. arXiv\npreprint arXiv:2503.07465, 2025. 1, 3, 5, 6\n[28] Chengjie Wang, Wenbing Zhu, Bin-Bin Gao, Zhenye Gan,\nJiangning Zhang, Zhihao Gu, Shuguang Qian, Mingang\nChen, and Lizhuang Ma. Real-iad: A real-world multi-view\n\n\fdataset for benchmarking versatile industrial anomaly detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 22883–22892,\n2024. 6, 9, 10\n[29] Jingyao Wang and Naigong Yu. Ssd-faster net: A hybrid\nnetwork for industrial defect inspection. arXiv preprint\narXiv:2207.00589, 2022. 2\n[30] Junpu Wang, Guili Xu, Fuju Yan, Jinjin Wang, and Zhengsheng Wang. Defect transformer: An efficient hybrid transformer architecture for surface defect detection. Measurement, 211:112614, 2023. 1, 2\n[31] Xin Wang, Thomas E Huang, Trevor Darrell, Joseph E Gonzalez, and Fisher Yu. Frustratingly simple few-shot object\ndetection. arXiv preprint arXiv:2003.06957, 2020. 10\n[32] Xinlong Wang, Xiaosong Zhang, Yue Cao, Wen Wang,\nChunhua Shen, and Tiejun Huang. Seggpt: Towards segmenting everything in context. In Proceedings of the\nIEEE/CVF International Conference on Computer Vision,\npages 1130–1140, 2023. 1, 5, 6\n[33] Feng Yan, Xiaoheng Jiang, Yang Lu, Jiale Cao, Dong Chen,\nand Mingliang Xu. Wavelet and prototype augmented querybased transformer for pixel-level surface defect detection. In\nProceedings of the Computer Vision and Pattern Recognition\nConference, pages 23860–23869, 2025. 1, 2\n[34] Xiaopeng Yan, Ziliang Chen, Anni Xu, Xiaoxi Wang, Xiaodan Liang, and Liang Lin. Meta r-cnn: Towards general\nsolver for instance-level low-shot learning. In Proceedings\nof the IEEE/CVF international conference on computer vision, pages 9577–9586, 2019. 10\n[35] Enquan Yang, Peng Xing, Hanyang Sun, Wenbo Guo, Yuanwei Ma, Zechao Li, and Dan Zeng. 3cad: A large-scale realworld 3c product dataset for unsupervised anomaly detection. In Proceedings of the AAAI Conference on Artificial\nIntelligence, pages 9175–9183, 2025. 6, 9, 10\n[36] Yuting Yang, Licheng Jiao, Xu Liu, Fang Liu, Shuyuan\nYang, Lingling Li, Puhua Chen, Xiufang Li, and Zhongjian\nHuang. Dual wavelet attention networks for image classification. IEEE Transactions on Circuits and Systems for Video\nTechnology, 33(4):1899–1910, 2022. 2\n[37] Yian Zhao, Wenyu Lv, Shangliang Xu, Jinman Wei,\nGuanzhong Wang, Qingqing Dang, Yi Liu, and Jie Chen. Detrs beat yolos on real-time object detection. In Proceedings\nof the IEEE/CVF conference on computer vision and pattern\nrecognition, pages 16965–16974, 2024. 8\n[38] Xueyan Zou, Jianwei Yang, Hao Zhang, Feng Li, Linjie Li,\nJianfeng Wang, Lijuan Wang, Jianfeng Gao, and Yong Jae\nLee. Segment everything everywhere all at once. Advances\nin neural information processing systems, 36:19769–19782,\n2023. 1, 5, 6\n[39] Yang Zou, Jongheon Jeong, Latha Pemula, Dongqing Zhang,\nand Onkar Dabeer. Spot-the-difference self-supervised pretraining for anomaly detection and segmentation. arXiv\npreprint arXiv:2207.14315, 2022. 6, 9, 10\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"