"<!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>Published as a conference paper at ICLR 2026\n\nL IGHT M EM : L IGHTWEIGHT AND E FFICIENT\nM EMORY-AUGMENTED G ENERATION\n\narXiv:2510.18866v4 [cs.CL] 28 Feb 2026\n\nJizhan Fang♠ , Xinle Deng♠ , Haoming Xu♠ , Ziyan Jiang♠ , Yuqi Tang♠ , Ziwen Xu♠ ,\nShumin Deng♢ , Yunzhi Yao♠ , Mengru Wang♠ , Shuofei Qiao♠ , Huajun Chen♠ , Ningyu Zhang♠♣∗\n♠\nZhejiang University ♢ National University of Singapore\n♣\nState Key Lab. for Novel Software Technology, Nanjing University, P.R. China\n{fangjizhan, zhangningyu}@zju.edu.cn\n\nA BSTRACT\nDespite their remarkable capabilities, Large Language Models (LLMs) struggle\nto effectively leverage historical interaction information in dynamic and complex\nenvironments. Memory systems enable LLMs to move beyond stateless interactions by introducing persistent information storage, retrieval, and utilization\nmechanisms. However, existing memory systems often introduce substantial time\nand computational overhead. To this end, we introduce a new memory system\ncalled LightMem, which strikes a balance between the performance and efficiency of memory systems. Inspired by the Atkinson–Shiffrin model of human\nmemory, LightMem organizes memory into three complementary stages. First,\ncognition-inspired sensory memory rapidly filters irrelevant information through\nlightweight compression and groups information according to their topics. Next,\ntopic-aware short-term memory consolidates these topic-based groups, organizing\nand summarizing content for more structured access. Finally, long-term memory\nwith sleep-time update employs an offline procedure that decouples consolidation from online inference. On L ONG M EM E VAL and L O C O M O, using GPT and\nQwen backbones, LightMem consistently surpasses strong baselines, improving\nQA accuracy by up to 7.7% / 29.3%, reducing total token usage by up to 38× /\n20.9× and API calls by up to 30× / 55.5×, while purely online test-time costs are\neven lower, achieving up to 106× / 117× token reduction and 159× / 310× fewer\nAPI calls. The code is available at https://github.com/zjunlp/LightMem.\n\n1\n\nI NTRODUCTION\n\nMemory is fundamental to intelligent agent, enabling the assimilation of prior experiences, contextual cues, and task-specific knowledge that underpin robust reasoning and decision-making (Wang\net al., 2024; Behrouz et al., 2024; Du et al., 2025; Zhang et al., 2024). While Large Language Models\n(LLMs) (DeepSeek-AI et al., 2025; Achiam et al., 2023) demonstrate remarkable capabilities across\na wide range of tasks, they exhibit significant limitations when engaged in long-context or multiturn interaction scenarios due to fixed context windows and the “lost in the middle” problem (Liu\net al., 2024). Memory systems are pivotal for overcoming these limitations, as they allow LLMs to\nmaintain a persistent state across extended interactions. Recent works (Li et al., 2025b; Yang et al.,\n2024; Chhikara et al., 2025; Kang et al., 2025) address this challenge by building explicit external\nmemory through sequential summarization and long term storage, enabling models to retain and\nretrieve relevant information over long horizons.\nNote that a typical LLM memory system processes raw interaction data into manageable chunks,\nsuch as turn- or session-level in dialogue scenarios (Xu et al., 2025; Li et al., 2025a), organizes\nthem into long-term memory (e.g., databases or knowledge graphs) by indexing them into memory\nunits, and continuously updates by adding new information and discarding outdated or conflicting\ncontent (Zhong et al., 2024). This enables retrieval of relevant memories, improving coherence, and\npersonalization in long-context, multi-turn scenarios.\n∗\n\nCorresponding Author.\n\n1\n\n\fPublished as a conference paper at ICLR 2026\n\nChallenges. Despite these advances, as shown in Figure 1, contemporary memory systems still\nsuffer from significant inefficiencies and consistency issues. First, in long interactions (e.g., dialogue scenarios), both user inputs and model responses often contain substantial redundant information (Maharana et al., 2024; Wu et al., 2025). Such information is typically irrelevant to downstream tasks or subsequent memory construction, and in some cases, may even negatively affect the\nmodel’s in-context learning capability (Liu et al., 2023; Pan et al., 2025). However, current mainstream memory-related studies generally process the raw information directly without any filtering\nor refinement, leading to high overhead from noisy or irrelevant data. This inflates token consumption without proportional gains in reasoning quality or coherence. Second, memory construction\ntypically treats each turn in isolation or relies on rigid context-window boundaries, failing to\nmodel semantic connections across different turns (Tan et al., 2025). As a result, during subsequent memory item construction, the backbone LLM may generate inaccurate or incomplete item\nrepresentations due to overly entangled topics or semantics, leading to the loss of crucial contextual details. Third, memory updates and forgetting are usually performed directly during inference\nand task execution. This tight coupling introduces long test-time latency in long-horizon tasks and\nprevents deeper, reflective processing of past experiences.\nBuilding Lightweight Memory. Inspired by the efficiency and structure of human memory, we introduce\nLightMem. In particular, LightMem\nemulates human memory through\nthree key components: (1) A precompression sensory memory module\nthat filters redundant or low-value tokens from raw input and buffers the\ndistilled content. (2) A topic-aware\nshort-term memory that leverages semantic and topical similarity to dynamically group related utterances\ninto coherent segments. By adaptively determining segment boundaries based on content instead of\nfixed window sizes, this module produces more concentrated and meaningful memory units. This not only\nreduces the frequency of memory Figure 1: Comparison of previous works and LightMem.\nconstruction but also enables more\nprecise and efficient retrieval during inference. (3) A sleep-time update mechanism for long-term\nmemory maintenance. New memory entries are initially stored with timestamps to support immediate (“soft”) updates for real-time responsiveness. Later, during designated offline periods (i.e.,\n“sleep”), the system reorganizes, de-duplicates, and abstracts these entries, resolving inconsistencies and strengthening cross-knowledge connections. Crucially, this decouples expensive memory\nmaintenance from real-time inference, enabling reflective, high-fidelity updates without introducing\nlatency. By systematically filtering, organizing, and consolidating relevant information, LightMem\nsubstantially reduces computational overhead and API costs while sustaining accurate, coherent\nreasoning over extended interactions. We detail each component in §3.\nResults and Evaluation. On LongMemEval (Wu et al., 2025), LightMem consistently outperforms\nthe strongest baseline, improving accuracy by 2.09%–6.40% with GPT and up to 7.67% with Qwen.\nIn terms of overall efficiency (online + offline), LightMem reduces total token usage by up to 38×\nfor GPT and 21.8× for Qwen, lowers API calls by up to 30× and 17.1×, and accelerates runtime by\nup to 12.4× and 6.3×, respectively. If considering only online test-time costs, the gains become even\nlarger: LightMem cuts token usage by up to 105.9× (GPT) and 117.1× (Qwen), and reduces API\ncalls by up to 159.4× and 309.9×. On the LoCoMo benchmark (Maharana et al., 2024), LightMem\nmaintains strong advantages, achieving 6.10%–29.29% higher accuracy and substantial efficiency\nimprovements—boosting token efficiency by up to 20.92×, reducing API calls by up to 55.48×, and\nspeeding up runtime by up to 8.21× across GPT and Qwen backbones. Furthermore, case studies\nin §5.6 show that the offline “sleep-time” consolidation enhances long-term memory reliability,\nmitigating information loss.\n2\n\n\fPublished as a conference paper at ICLR 2026\n\n2\n\nP RELIMINARY\n\n2.1\n\nC ONVENTIONAL M EMORY S YSTEMS FOR LLM S\n\nWe describe mainstream memory architectures pipeline in terms of two major stages. (I) Memory\nBank Construction. This stage can be further decomposed into three sub-stages: (a) Raw data D\nare first processed at a chosen level of granularity, D(g) = fseg (D; g), g ∈ {turn, session, topic} in\ndialog scenario; (b) The segmented data D(g) are then summarized or extracted to generate memory entries, E = fsum (D(g) ), which are stored and organized within structural backends such as\nvector databases or knowledge graphs to enable long-term retention; (c) Many systems incorporate an updating mechanism to mitigate issues such as context conflicts or outdated information,\nM ′ = fupdate (M, R; U ), where M denotes the existing memory bank, R represents newly generated\nmemory entries, and U specifies the update or forgetting policy. (II) Retrieval and Usage. When a\nnew user query arrives, the system retrieves relevant entries from the memory bank, integrates them\nwith the query to construct the final prompt, and then invokes the model to produce a response.\n2.2\n\nL IMITATIONS OF E XISTING LLM M EMORY S YSTEMS\n\nCompared to human memory, current LLM memory systems are burdened by high maintenance\ncosts, mainly due to three limitations: 1) Redundant Sensory Memory. In current systems, fsum ()\nand fgran (; g = topic) are typically executed by calling stronger LLMs. Feeding raw data D directly\nwastes resources and even weakens in-context learning due to redundancy. A key challenge is to\ndesign lightweight mechanisms that pre-compress inputs and apply pre-attention strategies to capture semantic units at different granularities efficiently. 2) Balancing Effectiveness and Efficiency\nin STM. As shown in Figure 1, when input granularity is fixed, D(g) must pass through the entire\npipeline. Excessively fine granularity increases latency and underutilizes STM capacity, whereas\noverly coarse granularity without semantic constraints or grouping may cause mixed or entangled\nsemantics and topics, leading to inaccurate memory construction and loss of fine-grained details\nin subsequent processes. This calls for strategies that better balance effectiveness and efficiency\nin STM. 3) Inefficient LTM Updating. Current fupdate () mechanisms face two main issues: (i)\nenforcing strict real-time updates at test time incurs significant latency, whereas STM can provide\nshort-term context without immediate LTM updates; (ii) memory banks are updated sequentially due\nto ordering constraints (read-after-write/write-after-read), rather than being triggered dynamically.\nThese limitations raise a research question: Can we design LLM memory that is both efficient and\nlightweight, inspired by human memory mechanisms?\n\n3\n\nLIGHTMEM ARCHITECTURE\n\nAnalogous to the human memory, we design LightMem as shown in Figure 2, which consists of three\nlight modules: Light1 implements an efficient Sensory Memory Module that selectively preserves\nsalient information from raw input (§3.1), Light2 realizes a topic-aware STM Module for transient\ninformation processing (§3.2), and Light3 provides an LTM module designed to minimize test time\nupdate latency (§3.3) with a sleep time update mechanism. The overall pipeline framework of\nLightMem, its specific models, and comparisons with other memory frameworks are presented in\nAppendix A.1. The complexity analysis for LightMem’s efficiency gains is in Section 4.\n3.1\n\nL IGHT 1: C OGNITIVE - INSPIRED SENSORY MEMORY\n\nIn long horizon interaction scenarios, such as user–assistant dialogues, a large portion of the information is redundant. Therefore, we design a Pre-Compressing Submodule to eliminate redundant\ntokens, followed by the Topic Segmentation Submodule that forms semantic topic-based segments\nfor following faster and more accurate memory construction.\nPre-Compressing Submodule. This module leverages a compression model θ to eliminate redundant tokens, tailored for compatibility with the downstream memory construction phase:\nx̂ = {xi ∈ x | P (retain xi | x; θ) &gt; τ } , τ = Percentile ({xj }, r) ,\nFollowing Xia et al. (2025), we use LLMLingua-2 (Pan et al., 2024b) as our compression model θ.\nLet x be the raw input tokens, θ the model, and r the compression ratio. The threshold τ is set to\n3\n\n\fPublished as a conference paper at ICLR 2026\n\nFigure 2: The LightMem architecture. LightMem consists of three modules: a) An efficient Sensory Memory Module, b) a topic aware STM Module, and c) an LTM module updated in sleep time.\nthe r-th percentile of retention scores, keeping only tokens above τ . For P (retain xi | x), we treat\nthe compression process as a binary token classification task (“retain” or “discard”). For each token\nxi in a sequence x, the model θ outputs a logit vector ℓi , and the retention probability is given by:\nP (retain xi | x; θ) = softmax(ℓi )1 ,\nwhere the subscript 1 denotes the “retain” class. Tokens with probabilities above a dynamic threshold are included in the compressed sequence. In addition, LightMem can also employ more general\ngenerative LLM as the pre-compression model. We further implement a token filtering mechanism\nbased on the cross-entropy between the model’s predicted distribution and the true token labels:\nX\nP (retain xi | x; θ) = −\nq(xi ) log P (xi | x; θ)\nxi ∈V\n\nwhere q(xi ) denotes the true token label distribution. Tokens with higher conditional entropy under\na given context are more uncertain and less predictable, indicating greater informational uniqueness\nand a more critical role in semantic expression, such distinctive tokens are essential for subsequent\nmemory construction and are therefore retained.\nTopic Segmentation Submodule. Existing works indicate that topic-granular input facilitates improved performance in memory systems (Pan et al., 2025; Tan et al., 2025). As shown in Figure 2, LightMem maintains a sensory memory buffer to temporarily store information after precompression. When the accumulated information reaches the buffer’s maximum capacity, a hybrid\ntopic segmentation operation based on attention and similarity is triggered. We use the compression\nmodel θ and an embedding model to compute attention matrices and semantic similarities, respectively. We define the final segmentation boundaries as the intersection of attention-based boundaries\nB1 and similarity-based boundaries B2 :\nB1 = {k | Mk,k−1 &gt; Mk−1,k−2 , Mk,k−1 &gt; Mk+1,k , 1 &lt; k &lt; n} ,\nn\no\nB2 = k sim(sk−1 , sk ) &lt; τ, 1 ≤ k &lt; n , B = B1 ∩ B2 .\nSpecifically, dialogue scenarios possess natural semantic units, namely the conversational turn. We\nconstruct a turn-level attention matrix M ∈ Rn×n . B1 are identified as local maxima in the sequence\n{Mk,k−1 }, i.e., the sub-diagonal elements of M corresponding to attention between consecutive sentences. The detailed process of B1 and illustrative cases are provided in Appendix C.1. To mitigate\n4\n\n\fPublished as a conference paper at ICLR 2026\n\nattention sinks and dilution in attention-based methods, we compute semantic similarity between\nadjacent turns near each candidate boundary in B1 . Boundaries with similarity below threshold τ\nform set B2 , which helps determine the final topic boundaries B.\n3.2\n\nL IGHT 2: T OPIC - AWARE SHORT- TERM MEMORY\n\nAfter obtaining individual topic segments, forming an index structure of {topic, message turns},\nwhere message turns = {useri , modeli }. These are first placed into the STM buffer. When the token\ncount in the buffer reaches a preset threshold, we invoke LLM fsum to generate concise summaries\nof every structure. The final index structure stored in LTM is {topic, {sumi , useri , modeli }}.\nsumi = fsum (Si ) ,\n\nSi ⊆ { useri , modeli }, Si ̸= ∅,\n\nEntryi = { topic, ei := embedding(sumi ), useri , modeli } ,\nwhere Entryi denotes the memory entry to be stored in LTM. Compared with inputting at the granularity of a single turn or session, directly feeding multiple sessions can reduce subsequent API calls\nbut often introduces inaccurate memory entries due to excessive topic mixing, leading to performance degradation. In contrast, topic-constrained input granularity minimizes API calls to the greatest extent while preserving summarization accuracy and maintaining stable system performance.\n3.3\n\nL IGHT 3: L ONG - TERM M EMORY WITH S LEEP - TIME U PDATE\n\nSoft Updating at Test Time. At test time, when memory entries arrive, LightMem directly inserts\nthem into LTM with soft updates, thereby decoupling the update process from online inference. Due\nto real-time updates being converted to direct insertions, interaction latency is significantly reduced.\nAfter all entries are inserted or when an update trigger arrives, we compute an update queue for\nevery entry in LTM.\nn\no\nQ(ei ) = Topk (ej , sim(vi , vj )) | tj ≥ ti , j ̸= i ,\n:n\n\nwhere ei denotes the i-th memory entry with embedding vi and timestamp ti , sim(·, ·) is the similarity function, and Topk {·}:n indicates selecting the top-k most similar candidates, with the update\nqueue Q(ei ) length fixed at n. Consistent with existing work, we select the top-k existing memory\nentries with the highest semantic similarity as potential update sources. On this basis, we further\nimpose the constraint that only entries with later timestamps are allowed to update earlier ones\n(tj ≥ ti ), which is consistent with realistic temporal dynamics. Here, Q(ei ) denotes the queue of\nother entries that may update ei . Since this process involves only similarity retrieval, it is fast and\nlightweight, and can be executed offline in parallel with online inference.\nOffline Parallel Update. LightMem does not simply transfer online update latency to offline phases,\nit substantially reduces the overall update latency. The online update mechanism in existing memory\nframeworks enforces sequential updates, leading to a total latency that accumulates with each update. As shown in Figure 2, in LightMem, each memory entry maintains a global update queue, with\neach queue corresponding to a distinct fupdate operation. Since the update targets are independent\nacross queues, updates can be executed in parallel, thereby greatly reducing the total latency.\n\n4\n\nC OMPLEXITY ANALYSIS ABOUT L IGHT M EM\n\nMethod\nBaselines\n\nSummary Tokens\nN (Lsum-in + T + Lsum-out )\n\nUpdate Tokens\nN M1 R1 (Lup-in + Lup-out )\n\nAPI Calls Runtime\nN\n\u0010O(Nx) \u0011\nrx T\nrx T\nrx T\nr T\nLightMem N th\n(Lsum-in + th + Lsum-out ) N th\nM2 R2 (Lup-in + Lup-out ) N th\nO N th\nTable 1: Complexity comparison between LightMem and other memory systems. The specific\ndefinitions of each symbol are provided in the Appendix A.2.\nAs shown in Table 4, we consider a dialogue with N turns, each containing on average T tokens.\nIn conventional memory systems, each turn triggers a summarization call, consuming Lsum-in + T +\nLsum-out tokens and totaling N (Lsum-in + T + Lsum-out ) tokens with N API calls. Each summarization\n5\n\n\fPublished as a conference paper at ICLR 2026\n\nproduces M1 memory entries, a fraction R1 of which retrieve at least one relevant neighbor and\ntrigger an update, resulting in an update-token cost of N M1 R1 (Lup-in + Lup-out ).\nIn LightMem, each turn is first passed through iterative pre-compression submodule, retaining only\nrx T tokens after x iterations, and appended to a short-term memory (STM) buffer of capacity th.\nrx T\nSummarization is triggered only when the buffer reaches capacity, yielding N th\nsummarization\ncalls, each consuming Lsum-in + th + Lsum-out tokens. Each summarization produces M2 memory\nentries, but stricter retrieval constraints, including semantic similarity and timestamp filtering, rerx T\nduce the fraction R2 that trigger updates. Hence, the update phase involves N th\nM2 R2 calls, with\nx\nr T\na total token cost of N th\nM2 R2 (Lup-in + Lup-out ).\nx\n\nr T\nOverall, LightMem requires only N th\nAPI calls for both summarization operations, substantially\nreducing token usage and call frequency compared to other systems. Correspondingly, the runtime\ncomplexity\n\u0010 x \u0011 of other memory systems is O(N ), while LightMem achieves a reduced runtime of\nr T\nO N th\n, reflecting the efficiency gain from compressed summarization and selective updates.\n\n5\n\nEXPERIMENTS\n\n5.1\n\nEXPERIMENTAL SETUP\n\nExperimental Details. (1) Our experiments adopt a realistic Incremental Dialogue Turn Feeding\nsetting, where the entire dialogue history is fed and processed at the turn level, one turn at a\ntime. This reflects practical scenarios where interactions between user and model is incrementally\nformed turn by turn. (Hu et al., 2025). (2) For considerations of both efficiency and effectiveness,\nwe employ LLMLingua-2 as our pre-compressor throughout all subsequent experiments. (3) The\nattention scores for topic segmentation are also obtained using LLMLingua-2, the size of the sensory\nmemory buffer is 512 tokens. All specific models used in this paper, can be found in Table 5.\nDatasets &amp; Baseline Methods. We use two well-known datasets, L ONG M EM E VAL (Wu et al.,\n2025) (specifically the LongMemEval-S split) and L O C O M O (Maharana et al., 2024) to evaluate\nmemory ability. We compare LightMem against several representative baselines of conversational\nmemory modeling. ① Full Text, ② Naive RAG, ③ LangMem (LangChain, 2025), ④ A-MEM (Xu\net al., 2025), ⑤ MemoryOS (Kang et al., 2025), ⑥ Mem0 (Chhikara et al., 2025). In addition, all\nmethods use GPT-4o-mini, Qwen3-30B-A3B-Instruct-2507 and GLM-4.6 as the LLM backbones.\nDetails on dataset, baselines, and experimental settings are provided in the Appendix D.\nMetrics. We evaluate these methods using both effectiveness and efficiency metrics. For effectiveness, we report Accuracy (ACC), defined as the proportion of correctly answered questions. The\nevaluation is conducted with GPT-4o-mini as an LLM judge, guided by a detailed evaluation prompt\n(see Appendix E.1). For efficiency, we focus on tracking the computational costs of the LLM invocations in memory bank construction stage (see Section 2.1), all averaged across the entire dataset,\nas it is the one tied to the design and implementation differences of memory systems. The retrieval\nand usage stage is not our focus, because for fair comparison, The fretrieve (), fchat () and number of\nretrieved entries are same among all methods. As a result, their costs exhibit only minor differences,\nand this stage is largely orthogonal to the design of memory systems, as shown in the table. Within\nthe memory bank construction stage, only the two sub-processes Summary and Update involve the\nuse of LLMs, fsum/extract () and fupdate (). So for both processes, we report the token consumption\nfrom LLM calls, including input tokens, output tokens, and total token usage (in thousands). Additionally, we track API Calls counting the total number of LLM invocations, and Runtime recording\nthe overall execution time for memory bank construction stage.\n5.2\n\nMAIN RESULTS\n\nAs shown in Table 2 and Table 3, LightMem demonstrates superior effectiveness and efficiency on\nboth datasets across both GPT and Qwen backbones. For a fair comparison, all efficiency metrics\nfor LightMem in the following analysis refer to the combined online and offline costs.\nLongMemEval. On the LongMemEval benchmark, LightMem consistently outperforms the\nstrongest baseline, A-Mem, in the ACC metric, improving accuracy by 2.09%–6.40% with GPT and\n6\n\n\fPublished as a conference paper at ICLR 2026\n\nTable 2: Effectiveness and efficiency comparison on L ONG M EM E VAL -S. The token usage is in\nthousands. – indicates no value for the metric. Bold denotes the best result, underline the secondbest. r denotes the compression rate. th denotes the capacity threshold of the STM buffer, measured\nin tokens. Each pair of r and th corresponds to two rows: one for online soft update and one for\noffline update. OP-update denotes the offline parallel update process of LightMem.\nMethod\n\nACC (%)\n\nSummary Tokens (k) Update Tokens (k)\nIn\n\nOut\n\nIn\n\nTotal (k)\n\nCalls\n\nRuntime (s)\n\nOut\n\nGPT-4o-mini\nFullText\nNaiveRAG\nLangMem\nA-MEM\nMemoryOS\nMem0\nLightMem\nr=0.5, th=256\n(OP-update)\nr=0.6, th=256\n(OP-update)\nr=0.7, th=512\n(OP-update)\n\n56.80\n61.00\n37.20\n62.60\n44.80\n53.61\n\n–\n–\n–\n214.66\n2,302.35\n424.13\n\n–\n–\n–\n42.82\n304.18\n17.76\n\n–\n–\n982.68\n1,157.52\n350.02\n560.17\n\n–\n–\n119.48\n190.81\n35.19\n150.56\n\n105.07\n–\n–\n–\n1,102.16 520.62\n1,605.81 986.55\n2,991.75 2,938.41\n1,152.62 811.57\n\n–\n867.38\n2,293.70\n5,132.06\n8,030.04\n4,248.49\n\n64.29\n64.69\n67.78\n65.39\n68.64\n67.07\n\n20.80\n–\n24.58\n–\n18.88\n–\n\n10.01\n–\n10.53\n–\n9.37\n–\n\n–\n44.46\n–\n53.98\n–\n79.38\n\n–\n2.56\n–\n3.18\n–\n4.06\n\n30.81\n47.02\n35.11\n57.16\n28.25\n83.44\n\n25.67\n70.23\n30.47\n85.07\n18.43\n125.47\n\n302.69\n342.63\n329.61\n411.56\n283.76\n496.03\n\nFullText\nNaiveRAG\nLangMem\nA-MEM\nMemoryOS\nMem0\nLightMem\nr=0.4, th=768\n(OP-update)\nr=0.6, th=768\n(OP-update)\nr=0.8, th=1024\n(OP-update)\n\n54.80\n60.80\n50.80\n65.20\n49.60\n39.51\n\n–\n–\n–\n219.21\n2,101.54\n424.20\n\n–\n–\n–\n66.98\n510.88\n15.34\n\n–\n–\n1,311.96\n1,260.54\n305.12\n411.50\n\n–\n–\n118.06\n318.20\n27.43\n111.35\n\n105.07\n–\n–\n–\n1,430.02 495.12\n1,864.93 989.30\n2,944.97 2,922.28\n1001.90 722.76\n\n–\n659.09\n3,237.16\n5,367.51\n8,721.78\n2,239.94\n\n61.95\n62.34\n70.20\n65.14\n68.69\n67.34\n\n9.01\n–\n13.19\n–\n14.82\n–\n\n16.14\n–\n19.21\n–\n18.49\n–\n\n–\n111.13\n–\n97.11\n–\n106.91\n\n–\n7.88\n–\n5.92\n–\n6.20\n\n25.15\n119.01\n32.40\n103.03\n33.31\n113.11\n\n16.54\n176.02\n19.97\n152.93\n9.43\n168.37\n\n357.13\n1036.47\n417.13\n1023.56\n355.71\n1026.90\n\nQwen3-30B-A3B-Instruct-2507\n\nGLM-4.6\nFullText\nNaiveRAG\nLangMem\nA-MEM\nLightMem\nr=0.5, th=256\nr=0.6, th=256\nr=0.7, th=512\n\n36.71\n73.20\n49.20\n70.60\n\n–\n–\n–\n444.95\n\n–\n–\n–\n63.40\n\n–\n–\n3,052.42\n1,992.04\n\n–\n–\n7.03\n403.39\n\n103.38\n–\n3,059.45\n2,903.78\n\n–\n–\n314.61\n450.40\n\n–\n53,725.15\n5,577.91\n8,068.80\n\n73.00\n73.20\n72.80\n\n16.55\n16.55\n16.55\n\n14.06\n13.99\n13.91\n\n–\n–\n–\n\n–\n–\n–\n\n30.61\n30.54\n30.46\n\n10.78\n10.78\n10.78\n\n1,014.37\n1,077.69\n1,038.19\n\nup to 7.67% with Qwen. In terms of efficiency, for GPT, LightMem reduces total token consumption by 10×–38× and API calls by 3.6×–30×; for Qwen, it reduces total tokens by 6.9×–21.8×\nand API calls by 3.3×–17.1×. Regarding runtime, LightMem achieves 2.9×–12.4× for GPT and\n1.6×–6.3× for Qwen speedup over other memory baselines.\nIf considering only online test-time cost, LightMem shows an even larger efficiency advantage.\nFor GPT, LightMem reduces total token consumption by 31.4×–105.9× and API calls by 17.1×–\n159.4×; for Qwen, it reduces total tokens by 30.1×–117.1× and API calls by 24.8×–309.9×.\nLoCoMo. On the LoCoMo dataset, LightMem also demonstrates superior performance over other\nmemory baselines. For the GPT backbone, it improves ACC by 6.10%–18.12%, achieves a 2.87×–\n7\n\n\fPublished as a conference paper at ICLR 2026\n\nTable 3: Effectiveness and efficiency comparison on L O C O M O. Due to space limitations and for\nease of comparison, we merge the results before and after LightMem’s offline update into a single\nrow. The ACC reported corresponds to the performance after the offline update.\nMethod\n\nACC (%)\n\nSummary Tokens (k) Update Tokens (k)\nIn\n\nOut\n\nIn\n\nTotal (k)\n\nCalls\n\nRuntime (s)\n\nOut\n\nGPT-4o-mini\nFullText\nNaiveRAG\nLangMem\nA-MEM\nMemoryOS(locomo)1\nMemoryOS(regular)\nMem0\nLightMem(0.7,512)\nLightMem(0.7,768)\nLightMem(0.8,768)\n\n71.83\n63.64\n57.20\n64.16\n58.25\n54.87\n61.69\n71.95\n70.26\n72.99\n\n–\n–\n–\n182.74\n110.98\n226.86\n851.32\n73.19\n57.54\n62.82\n\n–\n–\n–\n49.29\n33.40\n46.61\n20.53\n20.13\n18.92\n17.95\n\n–\n–\n898.27\n729.89\n78.08\n177.66\n632.12\n6.05\n3.79\n4.14\n\n–\n–\n111.95\n187.52\n64.54\n75.34\n189.42\n0.40\n0.23\n0.28\n\n–\n–\n–\n–\n1010.22 920.62\n1149.43 1175.47\n287.00 553.45\n526.48 1016.06\n1693.39 1602.20\n99.76\n41.65\n80.48\n29.55\n85.19\n29.83\n\n–\n–\n2229.37\n6060.73\n2422.05\n3332.59\n4432.87\n848.49\n737.80\n815.32\n\n–\n–\n1142.37\n1626.80\n361.51\n666.35\n1799.40\n99.87\n108.45\n\n–\n–\n2268.57\n5543.90\n1269.70\n1982.20\n4540.70\n815.70\n1079.40\n\nQwen3-30B-A3B-Instruct-2507\nFullText\nNaiveRAG\nLangMem\nA-MEM\nMemoryOS(locomo)\nMemoryOS(regular)\nMem0\nLightMem(0.6,768)\nLightMem(0.8,1024)\n\n74.87\n66.95\n60.53\n56.10\n61.04\n51.30\n43.31\n71.36\n72.60\n\n–\n–\n–\n158.29\n122.21\n228.85\n827.09\n56.68\n61.38\n\n–\n–\n–\n60.85\n53.12\n51.60\n18.64\n34.14\n36.33\n\n–\n–\n1004.35\n924.19\n104.43\n242.27\n763.88\n8.31\n9.86\n\n–\n–\n138.02\n483.51\n81.75\n143.63\n189.80\n0.74\n0.88\n\n–\n–\n1005.37\n1175.40\n414.70\n1004.60\n1614.50\n29.10\n32.00\n\n20.92× improvement in total token efficiency, reduces API calls by 13.29×–39.78×, and accelerates\nruntime by 2.63×–8.21×. On the Qwen backbone, LightMem maintains its advantage in both effectiveness and efficiency, with 4.41%–29.29% higher ACC, 3.33×–18.02× reduction in total token\nconsumption, 12.96×–55.48× fewer API calls, and 1.18×–5.57× faster runtime.\nLightMem achieves superior performance on nearly all metrics and both LLM backbones,\nwhile demonstrating robust performance and efficiency on both LongMemEval and LoCoMo,\nhighlighting its generalizability across different models and scenarios.\n5.3\n\nA NALYSIS OF P RE -C OMPRESSING S UBMODULE\n\nPerformance and Overhead. LightMem uses an additional model (Pan et al., 2024b; Xia et al.,\n2025) for pre-compression. We evaluate its performance by randomly sampling 1/5 of L ONG M EM E VAL and compressing it at ratios shown in Figure 3(a), then prompting LLMs for in-context\nQA. When compression ratio r ranges from 50%–80%, compressed and uncompressed performance\nare comparable, demonstrating LLMs can effectively understand compressed content and validating\nLightMem’s approach. The submodule is highly efficient, consuming under 2GB of GPU memory\nwith negligible impact on overall runtime.\nImpact of r on Performance. As shown in Tables 8 and 9, The optimal r for ACC is dependent\non the STM buffer threshold th. For smaller thresholds (th ∈ {0, 256}), an r of 0.6 achieves the\nhighest ACC. In contrast, for larger thresholds (th ∈ {512, 1024}), a higher retention rate of r = 0.7\nperforms best. This suggests greater buffer capacity enables effective use of richer, less-compressed\ninformation, leveraging LLMs’ advanced long-context processing to mitigate the “lost in the middle”\nphenomenon. On average, the optimal r for ACC is 0.6, reflecting a trade-off between information\ncompression rate and the quantity of information in the STM buffer. In terms of efficiency, a lower r\n1\nMemoryOS(locomo) is the LoCoMo reproduction script in the MemoryOS library, simplifying the standard\nversion, shown as MemoryOS(regular).\n\n8\n\n\f100\n80\n60\n40\n20\n0\n\nAccuracy (%)\n\n0.8\n0%\n50%\n70%\nAttention Only\nSemantic Similarity\nAttention-Similarity\n40%\n60%\n80%\n87.0\n86.9\n86.1\n90\n85.9\n84.5\n0.7 0.63\n81.7\n80.2\n0.64\n79.4\n0.62\n76.4\n76.2\n75.0\n75.0\n0.60 0.58 0.62\n75\n0.58\n0.58\n0.58\n0.57\n0.6\n0.55\n58.5\n58.2\n0.49\n56.4\n56.2\n60\n54.3\n0.5\n45.1\n45\n0.4\nGPT-4o-mini\nqwen3-30b-a3b-instruct-2507\n0% 40% 50% 60% 70% 80% r\n(a) Accuracy Comparison of Different Compression Ratios\n(b) Segmentation Methods Comparison\n-6.3%\n68.6% 64.3%\n\nWith Topic Segmentation\nWithout Topic Segmentation\n-4.4%\n18.9 18.1\n\n-0.5%\n9.4 9.3\n\n-3.1%\n28.2 27.4\n\nacc(%) input(k) output(k) total(k)\n(c1) GPT Ablation Study\n\n-6.0%\n18.4 17.3\n\ncalls\n\nValue\n\nValue\n\nAccuracy(%)\n\nPublished as a conference paper at ICLR 2026\n\n100\n80\n60\n40\n20\n0\n\n-5.4%\n73.2% 69.2%\n\nWith Topic Segmentation\nWithout Topic Segmentation\n+2.7%\n13.2 13.5\n\n-4.5%\n19.2 18.3\n\n-1.6%\n32.4 31.9\n\nacc(%) input(k) output(k) total(k)\n(c2) Qwen Ablation Study\n\n-3.8%\n20.0 19.2\n\ncalls\n\nFigure 3: Analysis and Ablation Study of Key Modules. Fig.(a) depicts the QA accuracy when\nusing prompts compressed at different ratios (r) as in-contexts to query the LLM directly. Fig.(b)\ncompares the accuracy of different topic segmentation methods under these varying compression\nratios. Fig.(c1) and Fig.(c2) present the ablation study for the topic segmentation module, evaluating\nits impact on both performance and efficiency for the GPT and Qwen models.\n\ngenerally leads to higher efficiency, as it triggers the buffer threshold less frequently under the same\nth, resulting in fewer API calls and lower token consumption.\n5.4\n\nA NALYSIS OF T OPIC S EGMENTATION S UBMODULE\n\nSegmentation Accuracy. To validate the accuracy of our proposed hybrid topic segmentation\nmethod, we compare it with segmentation using only a single granularity: attention-only-based\nand similarity-only-based segmentation. Since the construction process of the L ONG M EM E VAL\nindicates that different sessions naturally serve as topic boundaries, we directly use them as groundtruth labels. The final accuracy is calculated as the number of correctly identified segmentation\npoints divided by the total number of labels. The results in Figure 3(b) validate the effectiveness\nof our method: it achieves higher accuracy than both individual segmentation methods across all\ncompression ratios, with an absolute accuracy exceeding 80%.\nAblation Study. As shown in Figure 3(c), removing the topic segmentation submodule slightly\nimproves efficiency but significantly harms accuracy, causing a 6.3% drop for GPT and 5.4% for\nQwen. This indicates that the submodule effectively enables models to perceive semantic units in\nthe input, facilitating subsequent memory unit generation.\n5.5\n\nA NALYSIS OF THE STM T HRESHOLD ’ S I MPACT\n\nAs illustrated in the Figure 4, the STM buffer threshold (th) has a distinct but significant impact on\nboth efficiency and performance metrics. A consistent trend is: as th increases, there is a marked\nimprovement in efficiency. In contrast, the effect on QA accuracy is non-monotonic. The optimal\nthreshold for accuracy varies depending on the model and the compression ratio (r), indicating that\na larger buffer does not always yield better performance. This highlights a crucial trade-off: while\na larger STM threshold is consistently better for reducing computational cost, the ideal setting for\nmaximizing task accuracy requires careful tuning.\n5.6\n\nA NALYSIS OF S LEEP -T IME U PDATE\n\nWhy Soft Updates Work. A primary challenge in designing memory systems is handling updates.\nWhile powerful, LLMs can be unreliable when tasked with complex real-time update operations.\nFor instance, when presented with two related but not contradictory pieces of information, an LLM\nmight incorrectly interpret them as a conflict and delete the older memory entry, leading to irreversible information loss. Instead, the optimal operations might be to merge the information or\n9\n\n\fPublished as a conference paper at ICLR 2026\n\nsimply add the new entry. In contrast, LightMem performs only incremental additions through soft\nupdates during test time, which preserves global information and complete semantics.\nCase Study: Memory Update Mechanism Comparison\nHistory1: {’Monday, 2 PM’: User is planning a trip to Tokyo.}\nHistory2: {’Monday, 4 PM’: User asks about trains to Kyoto.}\nLightMem Soft Update: Appends info\nHard Update: Overwrites memory\n-&gt; \"Tokyo trip + Kyoto inquiry\"\n-&gt; \"User plans Kyoto trip\"\n¥ Full context preserved\n. Tokyo context lost\n\n6\n\nRELATED WORK\n\nHard Prompt Compression for LLMs. Hard prompt compression improves LLM efficiency by\nremoving redundant content from prompts (Li et al., 2025c). Methods recently have evolved from\nusing smaller language models (Jiang et al., 2023; Li et al., 2023; Chuang et al., 2024) to queryaware approaches that preserve task-relevant information (Weston &amp; Sukhbaatar, 2023; Creswell\net al., 2023; Jiang et al., 2024). Additionally, lightweight bidirectional encoders have demonstrated\nstrong effectiveness and efficiency (Pan et al., 2024a; Liskavets et al., 2025).\nChunking Strategies in RAG Systems. Retrieval-Augmented Generation (RAG) systems rely on\nchunking extrernal documents into smaller units for retrieval (Lewis et al., 2020; Gao et al., 2023).\nExisting chunking strategies include rule-based methods creating fixed-size segments (Lewis et al.,\n2020; Sarthi et al., 2024; Edge et al., 2024; Gutierrez et al., 2024), semantic-based methods grouping content by topic (Qu et al., 2025), and LLM-driven methods leveraging model knowledge for\nsplitting (Pan et al., 2025; Duarte et al., 2024; Zhao et al., 2024; Liu et al., 2025b). However, all of\nthese chunking strategies for RAG systems are tailored to static scenarios, not applicable to dynamic\nand open-ended environments.\nMemory Systems for LLM Agents. Memory systems help LLM agents move beyond stateless\ninteractions to support flexible reasoning and adaptation in complex and changing environments (Liu\net al., 2025a; Mei et al., 2025). The earliest and most straightforward approaches store experiences\nas linear or sequential streams, sometimes enhanced with hierarchical structures (Liang et al., 2023;\nPark et al., 2023; Packer et al., 2023; Zhong et al., 2024; Salama et al., 2025; Fang et al., 2025).\nA more structured class of methods represents memories as nodes and their relationships as edges,\nusing trees, graphs, or temporal knowledge structures to support retrieval and update (Rezazadeh\net al., 2025; Chhikara et al., 2025; Rasmussen et al., 2025; Xu et al., 2025; Zhang et al., 2025).\nThe latest trend integrates various types of memory, allowing them to interact and synergistically\nimprove overall performance (Kang et al., 2025; Li et al., 2025b; Wang &amp; Chen, 2025; Nan et al.,\n2025). Overall, existing memory systems for LLM agents have become increasingly complex and\ncapable, leveraging hierarchical, structured, and multi-type memories. However, most focus on\nmaximizing effectiveness, with limited consideration of efficiency. While some recent works (Guo\net al., 2024; Zhao et al., 2025; Dong et al., 2025) share a similar motivation with our work, they\nfocus on lightweight adaptations of GraphRAG where the corpus is predefined and static.\n\n7\n\nCONCLUSION\n\nIn this work, we introduced LightMem, a lightweight and efficient memory framework designed to\naddress the significant overhead of memory systems for LLM agents. Inspired by the multi-stage\nAtkinson-Shiffrin human memory model, LightMem’s architecture effectively filters, organizes, and\nconsolidates information. Our empirical evaluation demonstrates that this approach maintains strong\ntask performance while sharply reducing computational costs. In the near future, we plan to accelerate LightMem’s update phase via offline pre-computed KV caches, reducing runtime overhead.\nWe aim to integrate a lightweight knowledge graph memory for explicit multi-hop reasoning and\nstructured retrieval. A multimodal memory extension will enable adaptation to visual, auditory, and\ntextual inputs in embodied and real-world scenarios.\n10\n\n\fPublished as a conference paper at ICLR 2026\n\nE THICS S TATEMENT\nLightMem enhances LLM agents by creating an external memory of user interactions. While this\nimproves agent coherence, it introduces critical ethical challenges. Storing dialogue histories poses\ninherent risks to user privacy, as conversations may contain sensitive data. The memory can also\nabsorb and perpetuate biases or misinformation from user input, potentially leading to bad agent\nbehavior. Therefore, any deployment of this technology must prioritize robust safeguards. We\nstrongly advocate for strict privacy protocols, such as data anonymization and user consent, as well\nas mechanisms to mitigate the effects of biased or false memories. Responsible development is\nessential to ensure these memory-augmented systems are used in a safe and trustworthy manner.\nR EPRODUCIBILITY S TATEMENT\nTo ensure the reproducibility of this work, we introduce the detailed implementations for LightMem\nare provided in in Section 3, Appendix C. Additionally, we plan to release our source code in the\nfuture to further support reproducibility. These measures are intended to facilitate the verification\nand replication of our results by other researchers in the field.\nACKNOWLEDGMENTS\nWe would like to express our sincere gratitude to the anonymous reviewers for their thoughtful and\nconstructive feedback. This work was supported by the National Natural Science Foundation of\nChina (No. 62576307, No. NSFCU23B2055, No. NSFCU19B2027), the Fundamental Research\nFunds for the Central Universities (226-2023-00138), the 2025 Zhejiang Provincial Center for Disease Control and Prevention Science and Technology Talent Incubation Project (No. 2025-A-04),\nthe 2025 Zhejiang Health Informatics Association Scientific Research Program (Key Project, No.\n2025XHZN-Z01), titled “Research on Monitoring and Early Warning Methods of AI Large Model\nand Infectious Disease Epidemic Data Fusion”, undertaken by the Zhejiang Provincial Center for\nDisease Control and Prevention, Yongjiang Talent Introduction Programme (2021A-156-G), and\nInformation Technology Center and State Key Lab of CAD&amp;CG, Zhejiang University.\n\nR EFERENCES\nJosh Achiam, Steven Adler, Sandhini Agarwal, Lama Ahmad, Ilge Akkaya, Florencia Leoni Aleman, Diogo Almeida, Janko Altenschmidt, Sam Altman, Shyamal Anadkat, et al. Gpt-4 technical\nreport. arXiv preprint arXiv:2303.08774, 2023.\nAli Behrouz, Peilin Zhong, and Vahab Mirrokni. Titans: Learning to memorize at test time. arXiv\npreprint arXiv:2501.00663, 2024.\nPrateek Chhikara, Dev Khant, Saket Aryan, Taranjeet Singh, and Deshraj Yadav. Mem0: Building\nproduction-ready ai agents with scalable long-term memory. ArXiv, abs/2504.19413, 2025. URL\nhttps://api.semanticscholar.org/CorpusID:278165315.\nYu-Neng Chuang, Tianwei Xing, Chia-Yuan Chang, Zirui Liu, Xun Chen, and Xia Ben Hu. Learning\nto compress prompt in natural language formats. In Kevin Duh, Helena Gómez-Adorno, and\nSteven Bethard (eds.), Proceedings of the 2024 Conference of the North American Chapter of\nthe Association for Computational Linguistics: Human Language Technologies (Volume 1: Long\nPapers), NAACL 2024, Mexico City, Mexico, June 16-21, 2024, pp. 7756–7767. Association for\nComputational Linguistics, 2024. doi: 10.18653/V1/2024.NAACL-LONG.429. URL https:\n//doi.org/10.18653/v1/2024.naacl-long.429.\nAntonia Creswell, Murray Shanahan, and Irina Higgins. Selection-inference: Exploiting large language models for interpretable logical reasoning. In The Eleventh International Conference on\nLearning Representations, ICLR 2023, Kigali, Rwanda, May 1-5, 2023. OpenReview.net, 2023.\nURL https://openreview.net/forum?id=3Pf3Wg6o-A4.\nDeepSeek-AI, Daya Guo, Dejian Yang, Haowei Zhang, Junxiao Song, Ruoyu Zhang, Runxin Xu,\nQihao Zhu, Shirong Ma, Peiyi Wang, Xiao Bi, Xiaokang Zhang, Xingkai Yu, Yu Wu, Z. F. Wu,\nZhibin Gou, Zhihong Shao, Zhuoshu Li, Ziyi Gao, Aixin Liu, Bing Xue, Bingxuan Wang, Bochao\nWu, Bei Feng, Chengda Lu, Chenggang Zhao, Chengqi Deng, Chenyu Zhang, Chong Ruan,\n11\n\n\fPublished as a conference paper at ICLR 2026\n\nDamai Dai, Deli Chen, Dongjie Ji, Erhang Li, Fangyun Lin, Fucong Dai, Fuli Luo, Guangbo Hao,\nGuanting Chen, Guowei Li, H. Zhang, Han Bao, Hanwei Xu, Haocheng Wang, Honghui Ding,\nHuajian Xin, Huazuo Gao, Hui Qu, Hui Li, Jianzhong Guo, Jiashi Li, Jiawei Wang, Jingchang\nChen, Jingyang Yuan, Junjie Qiu, Junlong Li, J. L. Cai, Jiaqi Ni, Jian Liang, Jin Chen, Kai\nDong, Kai Hu, Kaige Gao, Kang Guan, Kexin Huang, Kuai Yu, Lean Wang, Lecong Zhang,\nLiang Zhao, Litong Wang, Liyue Zhang, Lei Xu, Leyi Xia, Mingchuan Zhang, Minghua Zhang,\nMinghui Tang, Meng Li, Miaojun Wang, Mingming Li, Ning Tian, Panpan Huang, Peng Zhang,\nQiancheng Wang, Qinyu Chen, Qiushi Du, Ruiqi Ge, Ruisong Zhang, Ruizhe Pan, Runji Wang,\nR. J. Chen, R. L. Jin, Ruyi Chen, Shanghao Lu, Shangyan Zhou, Shanhuang Chen, Shengfeng Ye,\nShiyu Wang, Shuiping Yu, Shunfeng Zhou, Shuting Pan, and S. S. Li. Deepseek-r1: Incentivizing\nreasoning capability in llms via reinforcement learning. CoRR, abs/2501.12948, 2025. doi: 10.\n48550/ARXIV.2501.12948. URL https://doi.org/10.48550/arXiv.2501.12948.\nJunnan Dong, Siyu An, Yifei Yu, Qian-Wen Zhang, Linhao Luo, Xiao Huang, Yunsheng Wu, Di Yin,\nand Xing Sun. Youtu-graphrag: Vertically unified agents for graph retrieval-augmented complex\nreasoning. arXiv preprint arXiv:2508.19855, 2025.\nYiming Du, Wenyu Huang, Danna Zheng, Zhaowei Wang, Sebastien Montella, Mirella Lapata,\nKam-Fai Wong, and Jeff Z Pan. Rethinking memory in ai: Taxonomy, operations, topics, and\nfuture directions. arXiv preprint arXiv:2505.00675, 2025.\nAndré V. Duarte, João Marques, Miguel Graça, Miguel Freire, Lei Li, and Arlindo L. Oliveira.\nLumberchunker: Long-form narrative document segmentation. In Yaser Al-Onaizan, Mohit\nBansal, and Yun-Nung Chen (eds.), Findings of the Association for Computational Linguistics: EMNLP 2024, Miami, Florida, USA, November 12-16, 2024, pp. 6473–6486. Association\nfor Computational Linguistics, 2024. doi: 10.18653/V1/2024.FINDINGS-EMNLP.377. URL\nhttps://doi.org/10.18653/v1/2024.findings-emnlp.377.\nDarren Edge, Ha Trinh, Newman Cheng, Joshua Bradley, Alex Chao, Apurva Mody, Steven Truitt,\nand Jonathan Larson. From local to global: A graph rag approach to query-focused summarization. ArXiv, abs/2404.16130, 2024. URL https://api.semanticscholar.org/\nCorpusID:269363075.\nRunnan Fang, Yuan Liang, Xiaobin Wang, Jialong Wu, Shuofei Qiao, Pengjun Xie, Fei Huang,\nHuajun Chen, and Ningyu Zhang. Memp: Exploring agent procedural memory, 2025. URL\nhttps://arxiv.org/abs/2508.06433.\nYunfan Gao, Yun Xiong, Xinyu Gao, Kangxiang Jia, Jinliu Pan, Yuxi Bi, Yi Dai, Jiawei Sun, Meng\nWang, and Haofen Wang. Retrieval-augmented generation for large language models: A survey.\narXiv preprint arXiv:2312.10997, 2023.\nZirui Guo, Lianghao Xia, Yanhua Yu, Tu Ao, and Chao Huang. Lightrag: Simple and fast retrievalaugmented generation. arXiv preprint arXiv:2410.05779, 2024.\nBernal Jimenez Gutierrez, Yiheng Shu, Yu Gu, Michihiro Yasunaga, and Yu Su. Hipporag: Neurobiologically inspired long-term memory for large language models. In Amir Globersons, Lester\nMackey, Danielle Belgrave, Angela Fan, Ulrich Paquet, Jakub M. Tomczak, and Cheng Zhang\n(eds.), Advances in Neural Information Processing Systems 38: Annual Conference on Neural\nInformation Processing Systems 2024, NeurIPS 2024, Vancouver, BC, Canada, December 10 15, 2024, 2024. URL http://papers.nips.cc/paper_files/paper/2024/hash/\n6ddc001d07ca4f319af96a3024f6dbd1-Abstract-Conference.html.\nYuanzhe Hu, Yu Wang, and Julian McAuley. Evaluating memory in llm agents via incremental\nmulti-turn interactions, 2025. URL https://arxiv.org/abs/2507.05257.\nHuiqiang Jiang, Qianhui Wu, Chin-Yew Lin, Yuqing Yang, and Lili Qiu. Llmlingua: Compressing prompts for accelerated inference of large language models. In Houda Bouamor, Juan Pino,\nand Kalika Bali (eds.), Proceedings of the 2023 Conference on Empirical Methods in Natural\nLanguage Processing, EMNLP 2023, Singapore, December 6-10, 2023, pp. 13358–13376. Association for Computational Linguistics, 2023. doi: 10.18653/V1/2023.EMNLP-MAIN.825. URL\nhttps://doi.org/10.18653/v1/2023.emnlp-main.825.\n12\n\n\fPublished as a conference paper at ICLR 2026\n\nHuiqiang Jiang, Qianhui Wu, Xufang Luo, Dongsheng Li, Chin-Yew Lin, Yuqing Yang, and Lili\nQiu. Longllmlingua: Accelerating and enhancing llms in long context scenarios via prompt\ncompression. In Lun-Wei Ku, Andre Martins, and Vivek Srikumar (eds.), Proceedings of the\n62nd Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), ACL 2024, Bangkok, Thailand, August 11-16, 2024, pp. 1658–1677. Association for\nComputational Linguistics, 2024. doi: 10.18653/V1/2024.ACL-LONG.91. URL https:\n//doi.org/10.18653/v1/2024.acl-long.91.\nJiazheng Kang, Mingming Ji, Zhe Zhao, and Ting Bai. Memory os of ai agent. ArXiv,\nabs/2506.06326, 2025.\nURL https://api.semanticscholar.org/CorpusID:\n279250574.\nLangChain. Langmem sdk for agent long-term memory, 2025.\nlangchain.com/langmem-sdk-launch/.\n\nURL https://blog.\n\nPatrick Lewis, Ethan Perez, Aleksandra Piktus, Fabio Petroni, Vladimir Karpukhin, Naman\nGoyal, Heinrich Küttler, Mike Lewis, Wen-tau Yih, Tim Rocktäschel, Sebastian Riedel,\nand Douwe Kiela. Retrieval-augmented generation for knowledge-intensive NLP tasks. In\nHugo Larochelle, Marc’Aurelio Ranzato, Raia Hadsell, Maria-Florina Balcan, and HsuanTien Lin (eds.), Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12,\n2020, virtual, 2020. URL https://proceedings.neurips.cc/paper/2020/hash/\n6b493230205f780e1bc26945df7481e5-Abstract.html.\nHao Li, Chenghao Yang, An Zhang, Yang Deng, Xiang Wang, and Tat-Seng Chua. Hello again!\nllm-powered personalized agent for long-term dialogue, 2025a. URL https://arxiv.org/\nabs/2406.05925.\nYucheng Li, Bo Dong, Frank Guerin, and Chenghua Lin. Compressing context to enhance inference\nefficiency of large language models. In Houda Bouamor, Juan Pino, and Kalika Bali (eds.),\nProceedings of the 2023 Conference on Empirical Methods in Natural Language Processing,\nEMNLP 2023, Singapore, December 6-10, 2023, pp. 6342–6353. Association for Computational\nLinguistics, 2023. doi: 10.18653/V1/2023.EMNLP-MAIN.391. URL https://doi.org/\n10.18653/v1/2023.emnlp-main.391.\nZhiyu Li, Shichao Song, Hanyu Wang, Simin Niu, Ding Chen, Jiawei Yang, Chenyang Xi, Huayi\nLai, Jihao Zhao, Yezhaohui Wang, Junpeng Ren, Zehao Lin, Jiahao Huo, Tianyi Chen, Kai Chen,\nKe-Rong Li, Zhiqiang Yin, Qingchen Yu, Bo Tang, Hongkang Yang, Zhiyang Xu, and Feiyu\nXiong. Memos: An operating system for memory-augmented generation (mag) in large language\nmodels. ArXiv, abs/2505.22101, 2025b. URL https://api.semanticscholar.org/\nCorpusID:278960153.\nZongqian Li, Yinhong Liu, Yixuan Su, and Nigel Collier. Prompt compression for large language models: A survey. In Luis Chiruzzo, Alan Ritter, and Lu Wang (eds.), Proceedings\nof the 2025 Conference of the Nations of the Americas Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL 2025 - Volume 1: Long Papers, Albuquerque, New Mexico, USA, April 29 - May 4, 2025, pp. 7182–7195. Association\nfor Computational Linguistics, 2025c. doi: 10.18653/V1/2025.NAACL-LONG.368. URL\nhttps://doi.org/10.18653/v1/2025.naacl-long.368.\nXinnian Liang, Bing Wang, Huijia Huang, Shuangzhi Wu, Peihao Wu, Lu Lu, Zejun Ma, and Zhoujun Li. Scm: Enhancing large language model with self-controlled memory framework. 2023.\nURL https://api.semanticscholar.org/CorpusID:258331553.\nBarys Liskavets, Maxim Ushakov, Shuvendu Roy, Mark Klibanov, Ali Etemad, and Shane K. Luke.\nPrompt compression with context-aware sentence encoding for fast and improved LLM inference.\nIn Toby Walsh, Julie Shah, and Zico Kolter (eds.), AAAI-25, Sponsored by the Association for the\nAdvancement of Artificial Intelligence, February 25 - March 4, 2025, Philadelphia, PA, USA, pp.\n24595–24604. AAAI Press, 2025. doi: 10.1609/AAAI.V39I23.34639. URL https://doi.\norg/10.1609/aaai.v39i23.34639.\n13\n\n\fPublished as a conference paper at ICLR 2026\n\nBang Liu, Xinfeng Li, Jiayi Zhang, Jinlin Wang, Tanjin He, Sirui Hong, Hongzhang Liu, Shaokun\nZhang, Kaitao Song, Kunlun Zhu, et al. Advances and challenges in foundation agents: From\nbrain-inspired intelligence to evolutionary, collaborative, and safe systems. arXiv preprint\narXiv:2504.01990, 2025a.\nNelson F. Liu, Kevin Lin, John Hewitt, Ashwin Paranjape, Michele Bevilacqua, Fabio Petroni,\nand Percy Liang. Lost in the middle: How language models use long contexts, 2023. URL\nhttps://arxiv.org/abs/2307.03172.\nNelson F. Liu, Kevin Lin, John Hewitt, Ashwin Paranjape, Michele Bevilacqua, Fabio Petroni, and\nPercy Liang. Lost in the middle: How language models use long contexts. Trans. Assoc. Comput.\nLinguistics, 12:157–173, 2024. doi: 10.1162/TACL\\ A\\ 00638. URL https://doi.org/\n10.1162/tacl_a_00638.\nZuhong Liu, Charles-Elie Simon, and Fabien Caspani. Passage segmentation of documents for extractive question answering. In Claudia Hauff, Craig Macdonald, Dietmar Jannach, Gabriella\nKazai, Franco Maria Nardini, Fabio Pinelli, Fabrizio Silvestri, and Nicola Tonellotto (eds.), Advances in Information Retrieval - 47th European Conference on Information Retrieval, ECIR\n2025, Lucca, Italy, April 6-10, 2025, Proceedings, Part III, volume 15574 of Lecture Notes in\nComputer Science, pp. 345–352. Springer, 2025b. doi: 10.1007/978-3-031-88714-7\\ 33. URL\nhttps://doi.org/10.1007/978-3-031-88714-7_33.\nAdyasha Maharana, Dong-Ho Lee, Sergey Tulyakov, Mohit Bansal, Francesco Barbieri, and Yuwei\nFang. Evaluating very long-term conversational memory of llm agents, 2024. URL https:\n//arxiv.org/abs/2402.17753.\nLingrui Mei, Jiayu Yao, Yuyao Ge, Yiwei Wang, Baolong Bi, Yujun Cai, Jiazhi Liu, Mingyu Li,\nZhong-Zhi Li, Duzhen Zhang, et al. A survey of context engineering for large language models.\narXiv preprint arXiv:2507.13334, 2025.\nJiayan Nan, Wenquan Ma, Wenlong Wu, and Yize Chen. Nemori: Self-organizing agent memory\ninspired by cognitive science. arXiv preprint arXiv:2508.03341, 2025.\nCharles Packer, Vivian Fang, Shishir G. Patil, Kevin Lin, Sarah Wooders, and Joseph Gonzalez.\nMemgpt: Towards llms as operating systems. ArXiv, abs/2310.08560, 2023. URL https:\n//api.semanticscholar.org/CorpusID:263909014.\nZhuoshi Pan, Qianhui Wu, Huiqiang Jiang, Menglin Xia, Xufang Luo, Jue Zhang, Qingwei Lin, Victor Rühle, Yuqing Yang, Chin-Yew Lin, H. Vicky Zhao, Lili Qiu, and Dongmei Zhang. Llmlingua2: Data distillation for efficient and faithful task-agnostic prompt compression. In Lun-Wei Ku,\nAndre Martins, and Vivek Srikumar (eds.), Findings of the Association for Computational Linguistics, ACL 2024, Bangkok, Thailand and virtual meeting, August 11-16, 2024, pp. 963–981.\nAssociation for Computational Linguistics, 2024a. doi: 10.18653/V1/2024.FINDINGS-ACL.57.\nURL https://doi.org/10.18653/v1/2024.findings-acl.57.\nZhuoshi Pan, Qianhui Wu, Huiqiang Jiang, Menglin Xia, Xufang Luo, Jue Zhang, Qingwei Lin,\nVictor Rühle, Yuqing Yang, Chin-Yew Lin, et al. Llmlingua-2: Data distillation for efficient and\nfaithful task-agnostic prompt compression. arXiv preprint arXiv:2403.12968, 2024b.\nZhuoshi Pan, Qianhui Wu, Huiqiang Jiang, Xufang Luo, Hao Cheng, Dongsheng Li, Yuqing Yang,\nChin-Yew Lin, H. Vicky Zhao, Lili Qiu, and Jianfeng Gao. Secom: On memory construction\nand retrieval for personalized conversational agents. In The Thirteenth International Conference\non Learning Representations, ICLR 2025, Singapore, April 24-28, 2025. OpenReview.net, 2025.\nURL https://openreview.net/forum?id=xKDZAW0He3.\nJoon Sung Park, Joseph C. O’Brien, Carrie Jun Cai, Meredith Ringel Morris, Percy Liang, and\nMichael S. Bernstein. Generative agents: Interactive simulacra of human behavior. In Sean\nFollmer, Jeff Han, Jürgen Steimle, and Nathalie Henry Riche (eds.), Proceedings of the 36th\nAnnual ACM Symposium on User Interface Software and Technology, UIST 2023, San Francisco,\nCA, USA, 29 October 2023- 1 November 2023, pp. 2:1–2:22. ACM, 2023. doi: 10.1145/3586183.\n3606763. URL https://doi.org/10.1145/3586183.3606763.\n14\n\n\fPublished as a conference paper at ICLR 2026\n\nRenyi Qu, Ruixuan Tu, and Forrest Sheng Bao. Is semantic chunking worth the computational cost?\nIn Luis Chiruzzo, Alan Ritter, and Lu Wang (eds.), Findings of the Association for Computational Linguistics: NAACL 2025, Albuquerque, New Mexico, USA, April\n29 - May 4, 2025, pp. 2155–2177. Association for Computational Linguistics, 2025. doi:\n10.18653/V1/2025.FINDINGS-NAACL.114. URL https://doi.org/10.18653/v1/\n2025.findings-naacl.114.\nPreston Rasmussen, Pavlo Paliychuk, Travis Beauvais, Jack Ryan, and Daniel Chalef. Zep: a temporal knowledge graph architecture for agent memory. arXiv preprint arXiv:2501.13956, 2025.\nAlireza Rezazadeh, Zichao Li, Wei Wei, and Yujia Bao. From isolated conversations to hierarchical\nschemas: Dynamic tree memory representation for llms. In The Thirteenth International Conference on Learning Representations, ICLR 2025, Singapore, April 24-28, 2025. OpenReview.net,\n2025. URL https://openreview.net/forum?id=moXtEmCleY.\nRana Salama, Jason Cai, Michelle Yuan, Anna Currey, Monica Sunkara, Yi Zhang, and Yassine Benajiba. Meminsight: Autonomous memory augmentation for llm agents. ArXiv, abs/2503.21760,\n2025. URL https://api.semanticscholar.org/CorpusID:277349587.\nParth Sarthi, Salman Abdullah, Aditi Tuli, Shubh Khanna, Anna Goldie, and Christopher D. Manning. RAPTOR: recursive abstractive processing for tree-organized retrieval. In The Twelfth International Conference on Learning Representations, ICLR 2024, Vienna, Austria, May 7-11, 2024.\nOpenReview.net, 2024. URL https://openreview.net/forum?id=GN921JHCRw.\nZhen Tan, Jun Yan, I-Hung Hsu, Rujun Han, Zifeng Wang, Long T. Le, Yiwen Song, Yanfei Chen,\nHamid Palangi, George Lee, Anand Iyer, Tianlong Chen, Huan Liu, Chen-Yu Lee, and Tomas\nPfister. In prospect and retrospect: Reflective memory management for long-term personalized\ndialogue agents, 2025. URL https://arxiv.org/abs/2503.08026.\nYu Wang and Xi Chen. Mirix: Multi-agent memory system for llm-based agents. arXiv preprint\narXiv:2507.07957, 2025.\nYu Wang, Chi Han, Tongtong Wu, Xiaoxin He, Wangchunshu Zhou, Nafis Sadeq, Xiusi Chen, Zexue\nHe, Wei Wang, Gholamreza Haffari, et al. Towards lifespan cognitive systems. arXiv preprint\narXiv:2409.13265, 2024.\nJason Weston and Sainbayar Sukhbaatar. System 2 attention (is something you might need too).\narXiv preprint arXiv:2311.11829, 2023.\nDi Wu, Hongwei Wang, Wenhao Yu, Yuwei Zhang, Kai-Wei Chang, and Dong Yu. Longmemeval:\nBenchmarking chat assistants on long-term interactive memory. In The Thirteenth International\nConference on Learning Representations, ICLR 2025, Singapore, April 24-28, 2025. OpenReview.net, 2025. URL https://openreview.net/forum?id=pZiyCaVuti.\nHeming Xia, Chak Tou Leong, Wenjie Wang, Yongqi Li, and Wenjie Li. Tokenskip: Controllable\nchain-of-thought compression in llms. arXiv preprint arXiv:2502.12067, 2025.\nWujiang Xu, Zujie Liang, Kai Mei, Hang Gao, Juntao Tan, and Yongfeng Zhang. A-mem:\nAgentic memory for llm agents. ArXiv, abs/2502.12110, 2025. URL https://api.\nsemanticscholar.org/CorpusID:276421617.\nHongkang Yang, Zehao Lin, Wenjin Wang, Hao Wu, Zhiyu Li, Bo Tang, Wenqiang Wei, Jinbo\nWang, Zeyun Tang, Shichao Song, Chenyang Xi, Yu Yu, Kai Chen, Feiyu Xiong, Linpeng Tang,\nand Weinan E. Memory3 : Language modeling with explicit memory. CoRR, abs/2407.01178,\n2024. doi: 10.48550/ARXIV.2407.01178. URL https://doi.org/10.48550/arXiv.\n2407.01178.\nGuibin Zhang, Muxin Fu, Guancheng Wan, Miao Yu, Kun Wang, and Shuicheng Yan. G-memory:\nTracing hierarchical memory for multi-agent systems. arXiv preprint arXiv:2506.07398, 2025.\nZeyu Zhang, Xiaohe Bo, Chen Ma, Rui Li, Xu Chen, Quanyu Dai, Jieming Zhu, Zhenhua Dong,\nand Ji-Rong Wen. A survey on the memory mechanism of large language model based agents,\n2024. URL https://arxiv.org/abs/2404.13501.\n15\n\n\fPublished as a conference paper at ICLR 2026\n\nJihao Zhao, Zhiyuan Ji, Yuchen Feng, Pengnian Qi, Simin Niu, Bo Tang, Feiyu Xiong, and Zhiyu\nLi. Meta-chunking: Learning text segmentation and semantic completion via logical perception.\n2024. URL https://api.semanticscholar.org/CorpusID:278782541.\nYibo Zhao, Jiapeng Zhu, Ye Guo, Kangkang He, and Xiang Li. Eˆ 2graphrag: Streamlining graphbased rag for high efficiency and effectiveness. arXiv preprint arXiv:2505.24226, 2025.\nWanjun Zhong, Lianghong Guo, Qiqi Gao, He Ye, and Yanlin Wang. Memorybank: Enhancing large\nlanguage models with long-term memory. In Michael J. Wooldridge, Jennifer G. Dy, and Sriraam\nNatarajan (eds.), Thirty-Eighth AAAI Conference on Artificial Intelligence, AAAI 2024, ThirtySixth Conference on Innovative Applications of Artificial Intelligence, IAAI 2024, Fourteenth\nSymposium on Educational Advances in Artificial Intelligence, EAAI 2014, February 20-27, 2024,\nVancouver, Canada, pp. 19724–19731. AAAI Press, 2024. doi: 10.1609/AAAI.V38I17.29946.\nURL https://doi.org/10.1609/aaai.v38i17.29946.\n\n16\n\n\fPublished as a conference paper at ICLR 2026\n\nA\n\nBACKGROUND D ETAILS\n\nA.1\n\nBACKGROUND ABOUT CURRENT MEMORY SYSTEMS\n\nWe describe both the mainstream memory architectures and the LightMem pipeline in terms of two\nmajor stages. The first is the memory bank construction stage, which can be further decomposed into\nthe three sub-stages (I), (II), and (III) described in the Section 2.1. The second major stage concerns\nthe usage of the memory system, which consists of retrieval and question answering (QA).\nMemory Bank Construction As shown in Table 4, we detail the workflows of the three sub-stages\n(I), (II), and (III) for naive RAG, prevailing memory systems, and our LightMem. It can be observed\nthat baseline memory systems typically perform their update stage during user–model interaction,\nwhich introduces substantial test-time latency. In contrast, LightMem decouples this update process\nfrom online interaction, thereby significantly reducing test-time latency. All models involved in\nthese processes are listed in Table 5. As shown, LightMem introduces only one additional model,\nLLMlingua-2,beyond those used by baseline methods. This model follows a lightweight BERT\narchitecture and requires less than 2GB of GPU memory during inference, rendering its overhead\nnegligible. Moreover, for fairness, the latency introduced by this component is fully accounted for\nin our reported Runtime metric.\nTable 4: The mainstream memory architectures and the LightMem pipeline of memory bank construction stage. Black-font processes denote those executed during online test-time interactions,\nwhereas red-font processes denote those executed offline.\nMethod\n\n(I) Segment\n\n(II) Summary/Extrct\n\n(III) Update\n\nNaiveRAG\n\nRaw dialog → fseg ()\n→ {segi }\n\n→ findex () → {embi }\n\n\\\n\nOther\nMemory\nSystems\n\nRaw dialog → fseg ()\n→ {segi }\n\n→ fsum/extract () → {memory entryi }\n→ findex () → {embi }\n\n→ fretrieve () → {related entryi }\n→ fupdate ()\n→ {add, delete, update, merge...}\n\n→ STM buffer full → fsum/extract ()\n→ {topici , {memory entryj }}\n→ findex () → {topici , {embj }}\n\nOffline update trigger\n{every entryi } → fretrieve ()\n→ {related entryj } → {update queue}\nAll update queues established\n→ parallel fupdate ()\n→ {add, delete, update, merge...}\n\nRaw dialog → fseg ()\n→ {segi }\n→ fpre compress ()\n→ {comp segi }\nLightMem\n→ sensory buffer full →\nftopic () →\n{topic-wise comp segi }\n\nFunction\nfseg ()\nfindex ()\nfsum/extract ()\nfretrieve ()\nfupdate ()\nfpre compress ()\nftopic ()\nfchat ()\n\nModel / Strategy\nSegmentation strategy\nEmbedding model\nSystem backbone model\nRetrieval strategy\nSystem backbone model\nToken compression model\nTopic segmentation model\nChat model\n\nImplementation in This Paper\nTurn-level granularity input\nall-MiniLM-L6-v2\nGPT-4o-mini; Qwen3-30B-A3B-Instruct-2507\nCosine similarity vector retrieval\nGPT-4o-mini; Qwen3-30B-A3B-Instruct-2507\nLLMlingua-2\nLLMlingua-2\nGPT-4o-mini; Qwen3-30B-A3B-Instruct-2507\n\nTable 5: Mapping between functions, their roles, and the concrete models used in this paper. Blackfont entries denote models shared by both LightMem and baseline methods, whereas red-font entries\ndenote models unique to LightMem.\nRetrieval and Usage After the memory bank construction stage, we obtain an up-to-date memory\nbank. When a new user query arrives, the memory system use fretrieve () to retrieve relevant entries\nfrom this repository, appends them to the query, and then prompts the chat model fchat () to produce\na response.\n17\n\n\fPublished as a conference paper at ICLR 2026\n\nA.2\n\nN OTATION AND C OMPLEXITY D ETAILS\n\nSymbol\n\nTable 6: Notation used in complexity analysis (§Section 4).\nDefinition\n\nN\n\nTotal number of turns in a dialogue history.\n\nT\n\nAverage number of tokens per turn.\n\nr\n\nToken compression rate (as defined in the main paper). After one compression step,\nonly a fraction r of tokens is retained.\n\nx\n\nNumber of compression iterations. In LightMem, the pre-compress module may be\ninvoked multiple times for the same message to remove redundancy until the message\nis sufficiently compact. This occurs frequently in datasets such as LongMemEval.\nAll time costs are included in runtime metrics.\n\nth\n\nCapacity of the Short-Term Memory (STM) buffer, as defined in the paper.\n\nNumber of tokens in the input prompt template and output of a single backbone\nLsum-in / Lsum-out LLM call for summarization. These are similar across memory frameworks.\nM 1 / M2\n\nNumber of memory entries produced from a single summarization operation under\nOther Memory Systems (M1 ) and LightMem (M2 ).\n\nLup-in / Lup-out\n\nNumber of tokens in the input prompt template and output of a single backbone\nLLM call for memory update. Similar across frameworks.\n\nR1 / R2\n\nProportion of summary entries that successfully retrieve at least one relevant memory\nentry (triggering an update) for Other Memory Systems (R1 ) and LightMem (R2 ).\nSome entries do not retrieve any relevant counterparts and thus do not trigger updates.\n\nB\n\nU SAGE OF LLM S\n\nThroughout the preparation of this manuscript, we used LLMs to assist with improving grammar,\nclarity, and wording in parts of this work. The use of LLMs was limited to language refinement,\nwith all ideas, analyses, and conclusions solely developed by the authors.\n\nC\n\nM ETHODOLOGY D ETAILS\n\nC.1\n\nT OPIC S EGMENTATION\n\nIn this part, we present the construction of the attention matrix, the underlying rationale for topic\nsegmentation, and representative illustrative cases.\nWe extract only the user sentences from multi-turn dialogues, as they are generally more concise\nand the assistant’s responses necessarily remain consistent with the user’s theme within the same\nturn. Moreover, since the maximum input length of the LLMLingua-2 Pan et al. (2024b) model is\n512 tokens, the assistant’s often lengthy sentences cannot be effectively accommodated. Therefore,\nwe sequentially store the user sentences into a buffer and segment them, ensuring that as many\nsentences as possible are preserved while staying within the token limit. As a practical trick, if\na sentence becomes empty after compression, we retain its original uncompressed version; if the\ntoken length of a sentence still exceeds the maximum limit, we continue to compress it using the\nLLMLingua-2 model at a 0.5 compression rate until the token length falls below the threshold. To\nreduce the effect of attention sinks, we mask out the contributions of the first and last three tokens\nin each sequence and subsequently normalize the remaining attention values. Attention is derived\nfrom the higher layers of LLMLingua-2 (layers 8, 9, 10, and 11). For any two sentences, we first\ncompute token-level pairwise attention and average across tokens to obtain the overall attention of\none sentence to the target sentence; we then average across the selected layers to obtain a more robust\ninter-sentence attention score. For each current sentence, the attention scores directed toward all\n18\n\n\fPublished as a conference paper at ICLR 2026\n\nth=0\n\nGPT-4o-mini\nr=0.4\nOutput (k)\n\nInput (k)\n\n20 40\n\nTotal (k)\n\nCalls\n\n60 80\n\nOutput (k)\n\n20 40\n\nACC (%) Total (k)\n\nTime (s)\n\nCalls\n\nTotal (k)\n\nCalls\n\n60 80\n\nth=768\n\nGPT-4o-mini\nr=0.6\n\nOutput (k)\n\n20 40\n\nACC (%) Total (k)\n\nTime (s)\n\nCalls\n\n60 80\n\nTime (s)\n\nOutput (k)\n\nInput (k)\n\nOutput (k)\n\n20 40\n\nCalls\n\n60 80\n\nGPT-4o-mini\nr=0.7\nOutput (k)\n\n60 80\n\n20 40\n\nACC (%) Total (k)\n\nTime (s)\n\nCalls\n\nInput (k)\n\nOutput (k)\n\nTime (s)\n\n20 40\n\nCalls\n\n60 80\n\n100\n\nACC (%)\n\nTime (s)\n\nQwen3\nr=0.8\n\n100\n\nACC (%) Total (k)\n\nInput (k)\n\n100\n\nQwen3\nr=0.6\n\n100\n\nACC (%) Total (k)\n\nth=1024\n\nInput (k)\n\n100\n\nQwen3\nr=0.4\n\nInput (k)\n\n20 40\n\nth=512\n\nInput (k)\n\n100\n\nGPT-4o-mini\nr=0.8\nOutput (k)\n\nth=256\n\nGPT-4o-mini\nr=0.5\n\n60 80\n\nInput (k)\n\n100\n20 40\n\nACC (%) Total (k)\n\nTime (s)\n\nCalls\n\n60 80\n\n100\n\nACC (%)\n\nTime (s)\n\nFigure 4: Impact of the STM buffer threshold (th) on performance and efficiency across different\ncompression ratios (r). Each radar chart represents a specific configuration of a model (GPT-4omini or Qwen3) and a fixed compression ratio. The axes measure six key metrics: Accuracy (ACC),\ntoken consumption (Input, Output, Total), API Calls, and Runtime. To facilitate comparison, all\nvalues are normalized for visualization on the chart.\npreceding sentences are normalized within the sentence, yielding the final attention matrix. Residual\nfragments that remain after segmentation are carried over to the beginning of the next buffer for\nfurther processing, and this procedure continues iteratively until the dialogue ends.\nBased on the attention pattern, we focus on the sequence formed by each sentence’s attention scores\nrelative to its immediately preceding sentence, which directly reflects the continuity of local semantics. Therefore, we take the attention scores from the outermost layer of the attention map. When the\nattention score at a given position is higher than both its preceding and following positions, it is regarded as a local peak. If a sentence is identified as a peak, we set a segmentation point immediately\nbefore this sentence, making the peak sentence the beginning of a new segment. The rationale is\nthat the peak sentence exhibits consistently low attention to all earlier sentences overall and reflects\na clear transition from an old topic to a new one, indicating that the identified sentence marks the\ninitiation of a new topic.\n\nFigure 5: Example of Topic Segment Attention Matrix.\nFigure 5 illustrates three representative examples of reliable segmentation under 50% compression\nrate. In the first attention map, local peaks in the adjacent-sentence attention sequence appear at positions 5, 8, and 11, where the actual segmentation boundaries lie between sentences 4–5 and 11–12.\n19\n\n\fPublished as a conference paper at ICLR 2026\n\nIn the second attention map, peaks occur at positions 3, 8, 12, and 14, and the actual boundaries are\nlocated between sentences 7–8, 11–12, and 13–14. Overall, our method achieves close alignment\nwith the majority of true boundaries while providing finer-grained segmentation. These examples\ndemonstrate that our segmentation approach enables both fine-grained and reliable detection of topic\nboundaries, thereby validating its effectiveness.\nC.2\n\nC ATEGORY- WISE ACCURACY\n\nAs summarized in Table 7, retrieval-augmented and memory-centric methods (e.g., A-MEM, Mem0,\nMemoryOS) generally outperform Full Text on categories that demand information integration or\nbelief revision, such as Temporal, Multi-Session, and Knowledge-Update. In contrast, categories\nsuch as Single-User and Single-Assistant, lightweight retrieval like Naive RAG is often competitive\nand can be the most reliable option, while Single-Preference shows higher variance due to its smaller\nsample size.\nTable 7: Category-wise Accuracy. Accuracy (%) by method across question types. Parentheses\nindicate category proportion and sample size. For GPT, LightMem is configured with parameters\nr = 0.7 and th = 512; for Qwen, LightMem is configured with r = 0.4 and th = 768.\nMethod\n\nTemporal Multi-Session Knowledge-Update Single-User Single-Assistant Single-Preference\n( n=133)\n(n=133)\n(n=78)\n(n=70)\n(n=56)\n(n=30)\nGPT-4o-mini\n\nFull Text\nNaive RAG\nLangMem\nA-MEM\nMemoryOS\nMem0\nLightMem\n\n31.58\n39.85\n15.79\n47.36\n32.33\n40.15\n67.18\n\n45.45\n48.48\n20.30\n48.87\n31.06\n46.21\n71.74\n\n76.92\n67.95\n66.67\n64.11\n48.72\n70.12\n83.12\n\n87.14\n90.00\n60.00\n92.86\n80.00\n81.43\n87.14\n\n89.29\n98.21\n46.43\n96.43\n64.29\n41.07\n32.14\n\n36.67\n53.33\n60.00\n46.67\n30.00\n60.00\n68.18\n\n87.50\n98.21\n42.86\n96.43\n92.86\n26.09\n31.25\n\n50.00\n70.00\n70.00\n40.00\n33.33\n81.82\n80.00\n\nQwen3-30B-A3B-Instruct-2507\nFull Text\nNaive RAG\nLangMem\nA-MEM\nMemoryOS\nMem0\nLightMem\n\nC.3\n\n33.08\n36.84\n37.60\n51.88\n28.57\n41.94\n54.20\n\n35.61\n47.73\n38.35\n51.12\n36.84\n28.13\n51.91\n\n76.92\n65.38\n67.95\n76.93\n61.54\n28.57\n66.67\n\n82.86\n91.43\n78.57\n90.00\n72.86\n55.32\n80.00\n\nD ETAILED PARAMETER A NALYSIS\n\nAs Table 9 shows, we report the numerical results of the effects of LightMem parameters (compression ratio r and STM threshold th).\n\nD\n\nE XPERIMENT D ETAILS\n\nD.1\n\nDATASETS AND BASELINES\n\nDatasets The LongMemEval dataset (Wu et al., 2025) is designed to benchmark long-term interactive memory in conversational agents. It comprises 500 evaluation questions built upon extended\nuser-assistant dialogues. It has two different versions with different lengths: the L ONG M EM E VAL S setting contains approximately 115k tokens per problem, while the L ONG M EM E VAL -M setting\nextends up to 1.5 million tokens across 500 sessions. In our work, we adopt the L ONG M EM E VAL S version due to its balance between dialogue length and computational feasibility. The questions\nare categorized into multiple types: information extraction, multi-session reasoning, knowledge updates, temporal reasoning, and abstention. Overall, the dataset is characterized by extremely long\n20\n\n\fPublished as a conference paper at ICLR 2026\n\nTable 8: The impact of LightMem compression ratio r and STM buffer threshold th is reported\nhere. Due to space limitations, we only present a subset of representative results of the online soft\nupdate results, with more results provided in the Figure 9.\n\nQwen\n\nGPT\n\nModel\n\nth\n\nr\n\nACC\n\nInput (k)\n\nOutput (k)\n\nTotal (k)\n\nCalls\n\nTime\n\n256\n256\n256\n512\n512\n512\n1024\n1024\n1024\n\n0.5\n0.6\n0.7\n0.6\n0.7\n0.8\n0.6\n0.7\n0.8\n\n64.29\n67.68\n65.68\n63.74\n68.64\n66.67\n59.68\n64.68\n64.35\n\n20.80\n24.58\n27.66\n16.23\n18.88\n21.55\n10.34\n12.93\n14.86\n\n10.01\n10.53\n9.97\n9.45\n9.37\n8.59\n7.68\n6.90\n6.28\n\n30.81\n35.11\n37.63\n25.68\n28.25\n30.14\n18.20\n19.83\n21.14\n\n25.67\n30.47\n34.26\n15.63\n18.43\n21.11\n7.69\n8.25\n9.43\n\n302.69\n329.61\n403.59\n266.98\n283.76\n268.97\n177.45\n209.12\n216.08\n\n512\n512\n512\n768\n768\n768\n1024\n1024\n1024\n\n0.4\n0.6\n0.8\n0.4\n0.6\n0.8\n0.4\n0.6\n0.8\n\n58.57\n66.57\n67.37\n61.95\n73.20\n64.95\n53.91\n65.67\n68.69\n\n11.03\n16.22\n21.35\n9.01\n13.19\n16.94\n8.02\n11.50\n14.82\n\n17.00\n19.50\n19.36\n16.14\n19.21\n19.06\n15.44\n18.21\n18.49\n\n28.03\n35.72\n40.71\n25.15\n32.40\n36.00\n23.46\n29.71\n33.31\n\n10.11\n15.40\n20.98\n6.54\n9.97\n13.09\n4.83\n7.18\n9.43\n\n421.74\n471.09\n461.02\n357.13\n417.13\n420.14\n300.56\n396.35\n355.71\n\nhistories, wide temporal spans, and diverse question types, making it a comprehensive benchmark\nfor evaluating conversational agents’ memory capabilities. During the experiments, five samples\nfrom this dataset contained corrupted characters, which caused LightMem’s compression model to\nfail to run properly. Consequently, LightMem directly discarded these five samples when processing\nthe dataset. However, their accuracy results were uniformly treated as false. The indices of these\nfive samples in the dataset are 74, 183, 278, 351, and 380.\nThe L O C O M O benchmark targets the evaluation of long-range conversational memory. It features\nextremely long dialogues, with each conversation spanning roughly 300 turns and around 9K tokens\non average. The accompanying questions fall into four categories—Single-hop, Multi-hop, Temporal, and Open-domain—providing a comprehensive assessment of different dimensions of memory\nin LLMs.\n\nBaselines We compare our approach against several representative baselines of conversational\nmemory modeling. ① L ANG M EM (LangChain, 2025): The Langchain’s long-term memory module. ② A-MEM (Xu et al., 2025): Constructs a memory-centric knowledge graph, encoding each\ninteraction as a structured memory note and linking these notes via LLM-driven reasoning. ③ M EM ORYOS (Kang et al., 2025): Organizes conversational memory in an OS-inspired hierarchy, structuring interactions into short-term, mid-term, and long-term layers via paging and heat-based updating.\n④ M EM 0 (Chhikara et al., 2025): Extracts memories from dialogue turns through a combination of\nglobal summaries and recent context, maintaining them via LLM-guided operations.\n\nD.2\n\nI MPLEMENTATION D ETAILS\n\nAll the experiments are conducted on hardware equipped with 4×NVIDIA RTX 3090 GPUs, dual\nIntel Xeon Gold 6133 CPUs (40 cores, 80 threads), and 256 GB of RAM.\n21\n\n\fPublished as a conference paper at ICLR 2026\n\nTable 9: The impact of LightMem’s compression ratio (r) and STM buffer threshold (th).\n\nQwen3\n\nGPT-4o-mini\n\nModel\n\nth\n\nr\n\nACC\n\nInput (k)\n\nOutput (k)\n\nTotal (k)\n\nCalls\n\nTime\n\n0\n256\n512\n768\n1024\n0\n256\n512\n768\n1024\n0\n256\n512\n768\n1024\n0\n256\n512\n1024\n0\n256\n512\n1024\n\n0.4\n0.4\n0.4\n0.4\n0.4\n0.5\n0.5\n0.5\n0.5\n0.5\n0.6\n0.6\n0.6\n0.6\n0.6\n0.7\n0.7\n0.7\n0.7\n0.8\n0.8\n0.8\n0.8\n\n58.04\n57.78\n55.56\n49.29\n46.87\n62.89\n64.29\n62.44\n56.12\n50.36\n70.35\n67.68\n63.74\n64.44\n59.68\n62.35\n65.68\n68.64\n64.68\n61.52\n66.37\n66.67\n64.35\n\n27.70\n16.64\n11.05\n9.05\n7.75\n30.84\n20.80\n13.49\n10.93\n8.34\n33.17\n24.58\n16.23\n13.04\n10.34\n35.36\n27.66\n18.88\n12.93\n39.32\n30.67\n21.55\n14.86\n\n8.90\n8.40\n7.66\n6.55\n5.25\n9.75\n10.01\n8.89\n7.57\n6.97\n10.20\n10.53\n9.45\n8.10\n7.68\n9.76\n9.97\n9.37\n6.90\n9.89\n9.70\n8.59\n6.28\n\n36.60\n25.04\n18.71\n15.60\n13.00\n40.59\n30.81\n22.38\n18.50\n15.31\n43.37\n35.11\n25.68\n21.14\n18.20\n45.12\n37.63\n28.25\n19.83\n49.21\n40.37\n30.14\n21.14\n\n39.91\n20.25\n10.13\n6.57\n4.82\n43.56\n25.67\n12.70\n8.12\n6.32\n45.86\n30.47\n15.63\n9.90\n7.69\n48.08\n34.26\n18.43\n8.25\n52.97\n41.66\n21.11\n9.43\n\n500.69\n254.93\n230.59\n157.13\n118.11\n550.36\n302.69\n250.36\n203.13\n160.35\n553.07\n329.61\n266.98\n210.05\n177.45\n573.42\n403.59\n283.76\n209.12\n622.90\n489.61\n268.97\n216.08\n\n0\n256\n512\n768\n1024\n0\n256\n512\n768\n1024\n0\n256\n512\n768\n1024\n\n0.4\n0.4\n0.4\n0.4\n0.4\n0.6\n0.6\n0.6\n0.6\n0.6\n0.8\n0.8\n0.8\n0.8\n0.8\n\n56.89\n52.37\n58.57\n61.95\n53.91\n69.56\n65.37\n66.57\n73.20\n65.67\n67.68\n64.52\n67.37\n64.95\n68.69\n\n28.44\n16.82\n11.03\n9.01\n8.02\n34.90\n24.78\n16.22\n13.19\n11.50\n37.97\n30.54\n21.35\n16.94\n14.82\n\n18.30\n17.63\n17.00\n16.14\n15.44\n20.26\n19.59\n19.50\n19.21\n18.21\n20.18\n19.77\n19.36\n19.06\n18.49\n\n46.74\n34.45\n28.03\n25.15\n23.46\n55.16\n44.37\n35.72\n32.40\n29.71\n58.15\n50.31\n40.71\n36.00\n33.31\n\n41.08\n20.48\n10.11\n6.54\n4.83\n48.63\n30.66\n15.40\n9.97\n7.18\n50.81\n37.35\n20.98\n13.09\n9.43\n\n594.94\n450.98\n421.74\n357.13\n300.56\n642.10\n520.37\n471.09\n417.13\n396.35\n759.15\n550.98\n461.02\n420.14\n355.71\n\n22\n\n\fPublished as a conference paper at ICLR 2026\n\nE\n\nP ROMPTS\n\nE.1\n\nLLM- AS -J UDGE\nStandard Tasks (Single-session-user/assistant Multi-session)\nI will give you a question, a correct answer, and a response from a model. Please answer\nyes if the response contains the correct answer. Otherwise, answer no. If the response\nis equivalent to the correct answer or contains all the intermediate steps to get the correct\nanswer, you should also answer yes. If the response only contains a subset of the information\nrequired by the answer, answer no.\nQuestion: {question}\nCorrect Answer: {answer}\nModel Response: {response}\nIs the model response correct? Answer yes or no only.\n\nTemporal Reasoning Tasks\nI will give you a question, a correct answer, and a response from a model. Please answer\nyes if the response contains the correct answer. Otherwise, answer no. If the response\nis equivalent to the correct answer or contains all the intermediate steps to get the correct\nanswer, you should also answer yes. If the response only contains a subset of the information\nrequired by the answer, answer no. In addition, do not penalize off-by-one errors for the\nnumber of days. If the question asks for the number of days/weeks/months, etc., and the\nmodel makes off-by-one errors (e.g., predicting 19 days when the answer is 18), the model’s\nresponse is still correct.\nQuestion: {question}\nCorrect Answer: {answer}\nModel Response: {response}\nIs the model response correct? Answer yes or no only.\n\nKnowledge Update Tasks\nI will give you a question, a correct answer, and a response from a model. Please answer yes\nif the response contains the correct answer. Otherwise, answer no. If the response contains\nsome previous information along with an updated answer, the response should be considered\nas correct as long as the updated answer is the required answer.\nQuestion: {question}\nCorrect Answer: {answer}\nModel Response: {response}\nIs the model response correct? Answer yes or no only.\n\nSingle-session Preference Tasks\nI will give you a question, a rubric for desired personalized response, and a response from a\nmodel. Please answer yes if the response satisfies the desired response. Otherwise, answer\nno. The model does not need to reflect all the points in the rubric. The response is correct as\nlong as it recalls and utilizes the user’s personal information correctly.\nQuestion: {question}\nRubric: {answer}\nModel Response: {response}\nIs the model response correct? Answer yes or no only.\n\n23\n\n\fPublished as a conference paper at ICLR 2026\n\nAbstention Tasks\nI will give you an unanswerable question, an explanation, and a response from a model.\nPlease answer yes if the model correctly identifies the question as unanswerable. The model\ncould say that the information is incomplete, or some other information is given but the\nasked information is not.\nQuestion: {question}\nExplanation: {answer}\nModel Response: {response}\nDoes the model correctly identify the question as unanswerable? Answer yes or no only.\n\n24\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"