Source-linked AI summary
MemRerank: Preference Memory for Personalized Product Reranking
Zhiyuan Peng, Xuyang Wu, Huaixiao Tou, Yi Fang, Yu Gong
TL;DR
Long purchase histories can strain prompts and dilute useful preference signals for personalized product reranking. MemRerank distills histories into compact, query-independent memory and trains the extractor using reranking feedback; across two categories, it raises macro-average MRR@10 from 7.41 to 8.00.
Problem
Naively appending purchase histories or transcripts strains context windows and can dilute preference signals, while balancing long-term user context with controllability and external knowledge remains open.
Source: §1 · p. 1Method
MEMRERANK distills purchase histories into compact, query-independent shopping-preference memory and post-trains the extractor with downstream setwise reranking feedback.
Source: §1 · pp. 1–2Results
7.41 to 8.00 macro-average MRR@10: MEMRERANK achieves the strongest top-100 reranking performance across two categories.
Source: §5.1 · p. 5Takeaways & Limitations
Learned preference memory can turn historical shopping behavior into concise, reusable personalization signals for agentic e-commerce search.
Source: §6 · p. 6Evaluation covers textual product metadata and purchase histories from two Amazon-C4 categories, and both training reward and final evaluation rely on proprietary o4-mini.
Source: Limitations · p. 7
Abstract
from arXiv · showhide
LLM-based shopping agents increasingly rely on long purchase histories and multi-turn interactions for personalization, yet naively appending raw history to prompts is often ineffective due to noise, length, and relevance mismatch. We propose MemRerank, a preference memory framework that distills user purchase history into concise, query-independent signals for personalized product reranking. To study this problem, we build an end-to-end benchmark and evaluation framework centered on an LLM-based \textbf{1-in-5} selection task, which measures both memory quality and downstream reranking utility. We further train the memory extractor with reinforcement learning (RL), using downstream reranking performance as supervision. Experiments with two LLM-based rerankers show that MemRerank consistently outperforms no-memory, raw-history, and off-the-shelf memory baselines, yielding up to \textbf{+10.61} absolute points in 1-in-5 accuracy. These results suggest that explicit preference memory is a practical and effective building block for personalization in agentic e-commerce systems.
1 Introduction
Appending raw purchase histories can strain context and dilute useful preference signals, motivating compact, structured preference memory for downstream reranking. MEMRERANK distills query-independent shopping preferences and trains its extractor with downstream reranking feedback.
- Naively appending purchase histories or transcripts can strain context windows and dilute useful preference signals, motivating compact, structured memory of within- and cross-category shopping patterns.Source: §1 · p. 1
- MEMRERANK distills purchase histories into query-independent within-category or within- and cross-category preference memory, reusable across future searches.The memory extractor is post-trained with GRPO (Shao et al., 2024) using feedback from a downstream setwise LLM reranker.Source: §1 · pp. 1–2
- The benchmark pairs Amazon-C4 queries with temporally preceding Amazon-Review-2023 purchase histories and fixed top-100 candidate pools from the full product corpus.It includes positive-product labels for personalized product reranking.Source: §1 · p. 2
- Across BM25 and dense retrievers, including a held-out retriever, MEMRERANK achieves the best macro-average MRR@10 and MRR@5 with much shorter memory than raw history and MR.Rec.Source: §1 · p. 2
2 Related Work
Prior work spans LLM reranking paradigms, task-specific personalized product search, and general agent-memory systems. MemRerank instead studies concise, query-independent preference memory as an input to a fixed setwise reranker, tailored to downstream product ranking.
2.1 LLM-based Rerankers
- Setwise reranking compares document groups, and this work improves its input with concise preference memory rather than changing the ranker.The related work also distinguishes pointwise scoring and listwise ranking approaches; the authors choose setwise reranking for efficiency (Peng et al., 2025).Source: §2.1 · p. 2
2.2 Personalized Product Search and Reranking
- Prior personalized search and reranking methods learn task-specific models, whereas this work uses query-independent preference memory with a fixed setwise LLM reranker to isolate memory-construction strategies.The comparisons use the same candidate pool.Source: §2.2 · p. 2
2.3 Memory in Agentic Systems
- Agent-memory systems support long-horizon reasoning, recommendation, or dialogue, while this work tailors preference memory specifically to downstream product ranking.Examples include Mem0 (Chhikara et al., 2025), MemAgent (Yu et al., 2025), and recommendation-focused MR.Rec (Huang et al., 2025b).Source: §2.3 · pp. 2–3
3 Methodology
MemRerank builds a benchmark from query-linked purchase histories and uses a learned extractor to compress them into query-independent preference memory. GRPO trains the extractor to improve five-candidate reranking utility while applying lightweight memory-quality checks.
3.1 Dataset Construction
- The benchmark pairs rewritten Amazon-C4 queries with each user’s pre-target Amazon-Review-2023 purchases, excludes the positive item, and evaluates fixed top-100 pools from four retrievers.Queries are rewritten to preserve shopping intent while removing review-specific details; products are represented by title and description. Amazon-C4 is cited as Hou et al. (2024), and the rewrite follows MR.Rec (Huang et al., 2025b).Source: §3.1 · p. 3
3.2 MEMRERANK Framework
- The extractor maps purchase history to query-independent memory, either within-category only or split into within- and cross-category preferences, for reuse across future searches.These targets are M_W and M_WC, respectively.Source: §3.2 · pp. 3–4
- At inference, a setwise reranker compares five-candidate subsets from the fixed top-100 pool and aggregates decisions into a full ranking; reported metrics cover the full pool.The same five-candidate comparison is the atomic operation for reward collection and final reranking.Source: §3.2 · p. 3
3.3 GRPO Training and Reward Design
- Training uses BM25, BLAIR-large, and Qwen3-Embedding-8B retrieval instances, while Linq-Embed-Mistral is held out for retriever-generalization evaluation.Per category, data are split 75:15:10 into train, dev, and test; eligible query-retriever pairs require the positive item in the top 100.Source: §3.3 · p. 4
- Each eligible pair yields sampled five-way instances with negatives from three rank buckets, exposing training to different portions of the top-100 candidate distribution.Two negatives are sampled from ranks 1–20, one from 21–50, and one from 51–100; eight instances are used for training and five for development.Source: §3.3 · p. 4
- GRPO optimizes extractor memories using downstream positive-selection accuracy on five-candidate sets, supplemented by deterministic checks for concise, well-formed, supported memory.The checks encourage non-empty within-category memory and penalize malformed tags, repetition, overlong output, placeholders, and unsupported evidence-like content; they regularize rather than replace reranking utility.Source: §3.3 · p. 4
4 Experimental Setup
The experiments compare preference-memory approaches against reranking without memory and raw purchase history, then evaluate an RL-trained memory extractor under a shared reranking setup. Implementation choices, including category-specific memory targets, are selected or configured for downstream reranking.
4.1 Baselines
- Baselines include no memory, raw purchase history, GPT-5.5-extracted memory, and MEMRERANK without RL; MEMRERANK uses an RL-trained extractor for query-independent preferences.No-memory reranking receives only the query and candidate products, while the raw-history baseline appends purchase-history products directly to the prompt.Source: §4.1 · pp. 4–5
- MR.Rec and Mem0 are run with Qwen2.5-7B-Instruct and the same metadata-only history window, with their outputs rendered into the reranker’s memory fields.MR.Rec summarizes category-level preferences into a profile, whereas Mem0 extracts atomic preference facts.Source: §4.1 · p. 5
4.2 Implementation Details
- Qwen2.5-7B-Instruct is the memory-extractor backbone; category-specific memory targets and checkpoints are selected using development-set reranking performance.The main table uses within+cross memory for Electronics and within-category memory for Beauty & Personal Care.Source: §4.2 · p. 5
- Training uses five epochs, rollout size 8, and o4-mini as reward reranker; utility is the fraction of sampled responses selecting the positive product.The reward reranker is sampled five times per training instance.Source: §4.2 · p. 5
- Final top-100 setwise evaluation uses o4-mini and reports MRR@10 as the primary metric, with candidate and history metadata capped at 120 words.All methods use temperature 1.0, top_p 1.0, and reasoning_effort=low; evidence fields are removed before reward scoring and final reranking, and MRR@5 is reported in Appendix A.1.Source: §4.2 · p. 5
5 Experimental Results and Analysis
MEMRERANK improves category-average reranking performance, including on held-out retrievers, while using compact preference memory; ablations show that the best memory target depends on category and that a quality reward helps across settings.
5.1 Main Results
- Across categories, MEMRERANK raises macro-average MRR@10 from 7.41 to 8.00, with category averages rising from 10.59 to 11.25 in Electronics and 4.33 to 4.75 in Beauty & Personal Care.The gains are consistent at the category-average level, though not for every retriever row.Source: §5.1 · p. 5
- On held-out Linq-Embed-Mistral, MEMRERANK achieves the best MRR@10 in both categories, improving Electronics from 13.07 to 14.36 and Beauty & Personal Care from 5.30 to 6.77 over the strongest baselines.Linq was not used to construct training negatives or select checkpoints.Source: §5.1 · pp. 5–6
- MEMRERANK achieves higher MRR@10 with compact preference memory than raw history and MR.Rec, despite their longer history or memory text.This supports learning a concise intermediate memory rather than exposing the reranker to full purchase history.Source: §5.1 · p. 6, Figure 2 · p. 6
5.2 Ablation Study
- Memory targets are category-dependent: Electronics scores 11.25 with within+cross-category memory versus 10.71 within-category, while Beauty & Personal Care scores 4.75 within-category versus 3.74 within+cross-category.Cross-category history can transfer preferences for Electronics, while unrelated purchases may add noise for Beauty & Personal Care.Source: §5.2 · p. 6, Table 2 · p. 6
- The deterministic memory-quality reward improves average MRR@10 in all four category-target comparisons, with gains of +0.73 and +0.89 on Electronics and +1.40 and +0.51 on Beauty & Personal Care.The quality term is smaller than reranking utility and regularizes memory structure, conciseness, and support without replacing task-level feedback.Source: §5.2 · p. 6, Table 2 · p. 6
6 Conclusion
MEMRERANK uses downstream reranking feedback to distill purchase histories into compact, query-independent preference memory. It achieves the best macro-average MRR@10 across BM25 and dense retrievers on top-100 reranking over Electronics and Beauty & Personal Care, including a held-out dense retriever.
6 Conclusion
- MEMRERANK trains a Qwen2.5 memory extractor with downstream setwise reranking feedback and lightweight memory-quality regularization instead of feeding long purchase histories directly to an LLM reranker.The framework produces compact, query-independent preference memory for personalized product reranking.Source: §6 · p. 6
- MEMRERANK achieves the best macro-average MRR@10 across BM25 and dense retrievers on top-100 reranking over Electronics and Beauty & Personal Care, including a held-out dense retriever.The held-out dense retriever was not used for training-negative construction.Source: §6 · p. 6
Limitations
MemRerank is evaluated on textual metadata and purchase histories from two Amazon-C4 categories, using the proprietary o4-mini API for both training reward and final evaluation.
Limitations
- The evaluation is limited to two Amazon-C4 categories and textual product signals, leaving generality across more categories, multilingual queries, and multimodal signals such as images untested.The passage identifies these broader evaluations as future work.Source: Limitations · p. 7
- Both training reward and final evaluation use the proprietary o4-mini API, which is more expensive at scale than self-hosted open-weight reranking.Future work could explore lower-cost distilled rerankers or hybrid evaluation protocols while retaining the same preference-memory interface.Source: Limitations · p. 7
A Appendix · A.1 MRR@5
The appendix reports MRR@5 results for the same test queries used in Table 1.
A.1 MRR@5
- Table 3 reports MRR@5 results for the same test queries as Table 1.Source: Table 3 · p. 10
A.2 Prompts
This section presents prompts for Mem0, MR.Rec preference-pattern and user-profile extraction, query rewriting, memory-conditioned reranking, and within-category preference-memory extraction.
A.2 Prompts
- The prompt figures cover Mem0 and MR.Rec prompts for extracting preference patterns and user profiles.Source: Figure 3 · p. 10, Figure 4 · p. 11, Figure 5 · p. 11
- Additional figures show prompts for query rewriting and reranking with memory.Source: Figure 6 · p. 11, Figure 7 · p. 12
- A separate prompt figure covers within-category shopping preference memory extraction (M_W).Source: Figure 8 · p. 13
A.3 Dataset
Figure 9 summarizes benchmark query counts by target category and compares purchase-history lengths within and across categories. Cross-category histories are generally longer, motivating separate modeling of the two preference memories.
A.3 Dataset
- Cross-category purchase histories are generally longer than within-category histories, motivating separate modeling of within-category and cross-category preference memory.History lengths are compared after excluding the target positive product.Source: Figure 9 · p. 14
- Figure 9’s top plot shows benchmark query counts for each target category, while its bottom plot compares average history lengths within and across categories.Source: Figure 9 · p. 14
- Categories are sorted by benchmark query count, and those with fewer than 100 queries are omitted for readability.Source: Figure 9 · p. 14