Source-linked AI summary

Beyond Sequences: Distilling Structured Decision Memory for LLM Recommendation

Leikun Liang, Guoshuai Wang, Xingsheng He, Yushan Han, Yunyi Xuan, Xiaoxiao Xu, Lin Qu

arXiv:2610.11501v1cs.CL

TL;DR

Existing LLM recommenders often flatten heterogeneous behaviors, obscuring their distinct roles in user decisions. MARI distills goals, constraints, and trade-offs into structured memories and retrieves relevant ones to ground LLM reasoning. The paper reports significant gains over state-of-the-art baselines in offline evaluation on a real-world e-commerce platform.

  • Problem

    Many recommendation approaches model single behavior types or flatten heterogeneous actions, leaving their distinct decision-making roles and trade-offs unrepresented.

    Source: §I · p. 1
  • Method

    MARI uses Post-Hoc Decision Distillation to build a Decision Memory Bank of structured user rationales and retrieves relevant memories to ground LLM recommendations.

    Source: §I · p. 2, §IV · p. 3
  • Results

    MARI significantly outperforms state-of-the-art baselines in offline evaluations on a real-world e-commerce platform.

    Source: §I · p. 2
  • Takeaways & Limitations

    The authors present MARI as a practical path toward transparent, rationale-driven recommender systems.

    Source: §VII · p. 9

Abstract

from arXiv · show

Despite the adoption of large language models (LLMs) in recommendation systems, prevailing approaches mostly model single-type behaviors (e.g., views or purchases). Even when incorporating multiple behaviors, existing methods flatten heterogeneous actions into homogeneous token sequences, ignoring their distinct decision-making roles. This flattening fails to capture semantic hierarchies and contextual nuances in complex decision-making, such as trade-offs between price and quality. Consequently, performance degrades in critical ``difficult-choice'' scenarios involving highly similar items. To bridge this gap, we propose MARI (Memory-Augmented Recommendation with Interpretability), which grounds predictions in explicit, structured decision evidence. MARI maintains a Decision Memory Bank (DMB) that archives users' past rationales as Structured Decision Memories (SDMs): concise records of goals, constraints, and trade-offs. These SDMs are generated offline via Post-Hoc Decision Distillation from heterogeneous behaviors and user-generated content. By retrieving relevant SDMs to augment LLM reasoning, MARI achieves interpretability and scalability without the prohibitive cost of processing long raw sequences. Extensive experiments show MARI significantly outperforms state-of-the-art baselines on standard next-item prediction and a newly introduced Difficult Choice Prediction task, incurring low latency overhead by decoupling memory construction from online inference. Qualitative analyses reveal actionable, human-readable insights into user decision-making, marking a concrete step toward reasoning-aware recommendation systems.

I. INTRODUCTION

Existing recommenders often flatten heterogeneous behaviors or model only single interaction types, obscuring the decision logic behind users’ choices. MARI distills historical rationales into structured memories and retrieves them to ground interpretable recommendations, including fine-grained SKU choices.

A. LLM-based Recommendation

  • LLM recommenders commonly use single-type interactions or flatten multi-behavior logs, while traditional multi-behavior models rely on opaque embeddings that lack interpretable reasoning.These approaches can obscure the distinct semantic roles and hierarchy of actions.Source: §I · p. 1

I. INTRODUCTION

  • MARI uses Post-Hoc Decision Distillation to create a Decision Memory Bank of human-readable memories encoding users’ goals, constraints, and trade-offs from heterogeneous trajectories.At inference, it retrieves relevant memories to ground LLM reasoning, separating offline knowledge construction from online recommendation.Source: §I · p. 2
  • MARI’s modular memory-augmented architecture is reported to significantly outperform state-of-the-art baselines in offline evaluations on a real-world e-commerce platform.The authors describe it as scalable and say it avoids significant latency overhead by decoupling memory construction from online inference.Source: §I · p. 2

B. Multi-Behavior Recommendation

C. Retrieval-Augmented Recommendation

The paper frames recommendation as recovering decision logic from heterogeneous interaction histories, including both next-item prediction and choices among highly similar candidates. MARI retrieves distilled decision memories to ground LLM reasoning, addressing the noise and diminishing returns of longer raw contexts.

C. Retrieval-Augmented Recommendation

  • RAG methods in recommendation retrieve behavioral or item-level evidence, whereas MARI’s Decision Memory Bank stores structured rationales about context, decisions, and outcomes.The paper’s distinction is between retrieving what users did and retrieving evidence about why they decided.Source: C. Retrieval-Augmented Recommendation · p. 2

III. PRELIMINARY

  • Heterogeneous actions such as search, view, favorite, and purchase encode complementary intent signals, but a flat sequence can miss their semantic hierarchy and decision logic.The setup treats items at SKU level, where attribute combinations such as color or size define distinct items even when titles match.Source: §III · p. 3

A. Task 1: Next-Item Prediction (NIP)

  • Next-item prediction identifies which item in a recent context will eventually be purchased, using the user’s full heterogeneous history.In the task setup, the purchased item appears earlier in the context through non-purchase interactions such as viewing or searching.Source: A. Task 1: Next-Item Prediction (NIP) · p. 3

B. Task 2: Difficult Choice Prediction (DCP)

  • Difficult Choice Prediction selects the next purchase from highly similar candidates, testing whether past decisions reveal subtle preferences and attribute-level trade-offs.The candidate set is restricted to highly substitutable items, such as products differing in price, brand, or minor features.Source: B. Task 2: Difficult Choice Prediction… · p. 3

C. Key Challenge and Our Approach

  • With DeepSeek-R1, performance peaks at around 100 historical interactions and degrades with longer sequences, consistent with raw logs adding noise rather than useful signals.MARI instead retrieves concise, interpretable memories distilled from past decisions to ground reasoning about recent context.Source: C. Key Challenge and Our Approach · p. 3, Figure 2 · p. 3

IV. METHODOLOGY

MARI separates personalized decision-memory construction from inference, organizing purchase rationales by category. Each memory is a structured record of decision logic, with factors that capture preferences and avoided attributes.

IV. METHODOLOGY

  • MARI builds a personalized Decision Memory Bank (DMB) through Post-Hoc Decision Distillation, then uses retrieved memories in recommendation reasoning.The framework separates memory construction from on-the-fly inference.Source: §IV · p. 3

1) Category-Aware:

  • Category-aware construction preserves category-conditioned purchase rules, since criteria such as organic certification or storage capacity matter in different categories.The method encodes the rationale for a user’s purchase in category c.Source: 1) Category-Aware · p. 3

2) Formal definition:

  • Each DMB record associates a purchase’s timestamp and pre-purchase behavior embedding with an SDM structured as a five-facet account of decision logic.The embedding supports similarity-based retrieval; the SDM includes preference and avoidance factors, intent reasoning, profile tags, and decision efficiency.Source: 2) Formal definition · pp. 3–4
  • Preference factors pair positively weighted attributes with chosen values, while avoidance factors record attributes explicitly rejected during exploration.The described factors and profile-tag keys come from closed vocabularies, with evidence-backed rationales generated for each factor.Source: 2) Formal definition · p. 4

B. Post-Hoc Decision Distillation (PHDD)

PHDD uses a teacher LLM to produce structured decision memories from category-filtered purchase histories, then distills that capability into a compact student model. Post-purchase reviews calibrate teacher rationales during construction but are excluded from student training and inference.

B. Post-Hoc Decision Distillation (PHDD)

2) Student Model Training via CoT Distillation:

  • A lightweight text encoder creates retrieval embeddings from the pre-purchase sequence, and the resulting DMB is stored as a category-indexed vector database.The compact student model is intended to support scalable DMB construction.Source: 2) Student Model Training via CoT… · pp. 4–5
  • The student model is trained from teacher-generated reasoning traces and final structured memories, using only pre-purchase behavior and category context as input.Training minimizes cross-entropy between student-generated tokens and the teacher’s concatenated trace and memory.Source: 2) Student Model Training via CoT… · pp. 4–5

C. Memory-Augmented Reasoning Framework

MARI processes recent interactions and retrieves decision memories in a task-dependent way. It uses behavioral similarity when the target category is unknown and favors recency within the known category for difficult-choice prediction.

C. Memory-Augmented Reasoning Framework

1) Context Processing and Adaptive Memory Retrieval:

  • For next-item prediction, MARI retrieves memories across categories by behavioral similarity because the target category is unknown beforehand.Retrieval compares an encoded current context with stored pre-purchase behavior embeddings.Source: 1) Context Processing and Adaptive… · p. 5
  • For difficult-choice prediction, MARI retrieves recent memories constrained to the known target category, falling back to similarity retrieval if that category has no records.The method prioritizes recency because fine-grained preference trade-offs can evolve rapidly within categories.Source: 1) Context Processing and Adaptive… · p. 5

2) Prompt Construction and Memory-Augmented Reasoning:

MARI combines retrieved decision memories with the current context in prompts for an LLM recommender. Its deployment options include training-free augmentation of existing recommenders, with task-specific prompting and traceable memory references.

2) Prompt Construction and Memory-Augmented Reasoning:

  • MARI combines retrieved memories with the current context to build task-specific prompts for an LLM recommender.For next-item prediction, the prompt uses recent interactions and memories retrieved from behavioral context; for difficult-choice prediction, it uses a candidate set and memories preferentially retrieved by target category.Source: 2) Prompt Construction and… · p. 5
  • The prompts ground structured reasoning in explicit decision evidence and preserve interpretability through traceable memory references.The paper states that this design can enhance robustness under data sparsity.Source: 2) Prompt Construction and… · p. 5

D. Deployment Strategies

1) Plug-and-Play Augmentation Mode:

  • In plug-and-play mode, MARI retrieves relevant memories and constructs task-appropriate prompts for an off-the-shelf recommendation LLM without training that recommender.This mode is a lightweight augmentation module for existing recommenders.Source: 1) Plug-and-Play Augmentation Mode · p. 5
  • The training-free compatibility is presented as enabling seamless integration into production pipelines without additional training costs or architectural modifications.Source: 1) Plug-and-Play Augmentation Mode · p. 5
  • The augmentation mode preserves existing model investments while enhancing decision transparency.Source: 1) Plug-and-Play Augmentation Mode · p. 5

2) CoT-Distilled Mode:

The CoT-distilled mode trains a specialized student to generate recommendations with human-interpretable rationales, while sharing MARI’s DMB infrastructure across deployment modes. The section also describes the real-world dataset and PHDD data split used to support this work.

2) CoT-Distilled Mode:

  • The CoT-distilled mode trains a specialized student to generate both recommendation predictions and justifications from retrieved memories and teacher-generated reasoning.The pipeline extracts pre-purchase context, retrieves relevant memories, prompts a teacher LLM to produce reasoning ending in the target item, and trains the student to generate that reasoning-plus-item sequence.Source: 2) CoT-Distilled Mode · p. 5
  • Both deployment modes share the DMB, letting practitioners choose between them based on system constraints and interpretability requirements.The authors state that this design scales efficiently while preserving decision semantics needed for difficult-choice recommendations.Source: 2) CoT-Distilled Mode · p. 5

A. Datasets

  • The new dataset uses six months of real-world e-commerce logs, covering search, view, favorite, and purchase behaviors alongside comprehensive item metadata.It is split into a PHDD Dataset and an MBR Dataset; the PHDD Dataset preserves observed interactions without filtering or deduplication and contains 200k training, 10k validation, and 10k test samples.Source: A. Datasets · pp. 5–6, 1) PHDD Dataset · p. 6

2) MBR Dataset:

The MBR dataset and evaluation setup cover familiar- and new-category next-item prediction plus difficult-choice prediction. The section specifies task construction, baselines, and implementation settings for evaluating memory generation and recommendation.

2) MBR Dataset:

  • MBR instances are deduplicated, filtered with a k-core threshold of 10, and split chronologically by leave-one-out, with the final two purchases reserved for testing and validation.NIP-in and NIP-out separate targets in categories the user has previously purchased from versus a first purchase in that category; DCP candidate sets contain 2–5 same-category items selected using hesitation or comparison behavior and manually validated.Source: 2) MBR Dataset · p. 6
  • The MBR dataset contains 150,000 unique users across NIP-in, NIP-out, and DCP, with each task sampled into 50k training, 10k validation, and 10k testing instances.Source: 2) MBR Dataset · p. 6

1) PHDD Task:

  • PHDD evaluates closed-set tags and factor keys with precision, and open-ended reasoning and factor values with DeepSeek-R1 judgments on three 0–5 dimensions.The dimensions are structural correctness, reasoning quality, and value abstraction; the judge uses a human-verified reference solution as its scoring benchmark.Source: 1) PHDD Task · p. 6

2) MBR Task:

  • MBR uses next-item prediction, treating the user’s subsequent actual purchase as ground truth and Hit Ratio@1 as its evaluation metric.Source: 2) MBR Task · p. 6

1) Baseline:

  • Baselines include Qwen3 models for PHDD, and ID-based multi-behavior recommenders plus unmodified Qwen3, DeepSeek-R1, and GPT-OSS for MBR.All MBR baselines predict from a unified candidate space: recent history for NIP or the supplied candidate set for DCP.Source: 1) Baseline · p. 6

2) Implementation Details:

  • The PHDD setup limits behavior context to 200 interactions from the prior two weeks, uses Qwen3-Embedding-0.6B for retrieval representations, and fully fine-tunes Qwen3-4B.Source: 2) Implementation Details · p. 6
  • The MBR setup uses context length 100, retrieves the top three memories, and fully fine-tunes Qwen3-4B on a mixture of NIP-in, NIP-out, and DCP.Source: 2) Implementation Details · p. 6

VI. EXPERIMENTAL RESULTS

MARI’s reported results span plug-and-play and fine-tuned models, with structured memories improving performance across model scales and tasks, including difficult-choice prediction. Ablations favor distilled structured memories over raw behaviors, while retrieval performance varies with memory count and task.

A. Performance Comparison

  • MARI† with SDMs improves performance across 4B–671B models, and sufficiently large models surpass strong trained ID-based baselines; MARI (4B) reaches 0.5561 on NIP-out and 0.8868 on DCP.The authors also report gains of +165% for GPT-OSS-20B and +128% for Qwen3-32B on NIP-out, while 4B/8B models degrade there; MARI† improves DCP over ID-based baselines at all model scales.Source: 1) PHDD · p. 7, Table II · p. 8
  • Figure 4 illustrates MARI using SDM information during reasoning to produce correct product recommendations.Source: 1) PHDD · p. 7, Figure 4 · p. 7

B. Ablation Study

  • Raw behavior sequences can help on NIP-in but degrade NIP-out and DCP, whereas SDM variants outperform raw-sequence MARI-B across scales.The authors attribute the difference to raw-sequence verbosity diluting decision context; explicit decision logic supports difficult-scenario reasoning.Source: B. Ablation Study · p. 7, Table III · p. 8
  • PHDD-distilled SDMs outperform undistilled SDMs, particularly on NIP-out and DCP, and adding retrieved SDMs during SFT improves over standard SFT.Source: B. Ablation Study · p. 7, Table III · p. 8

C. Effect of the Number of Retrieved Memories (K)

  • With DeepSeek-R1, Hit@1 initially improves as K rises, peaks around K = 3 or 4, and then declines; NIP-out is most sensitive to larger K.NIP-in and DCP remain stable across a broader K range, and the authors set K = 3 as the default to balance performance and context noise.Source: C. Effect of the Number of Retrieved… · pp. 7–8, Figure 5 · p. 8

D. Memory Error Analysis

The memory-error analysis finds that structured priors can remain useful under memory errors, with robustness varying by task and model capacity. The conclusion presents MARI as a way to ground recommendations in structured rationales and identifies retrieval and memory updating as future work.

D. Memory Error Analysis

  • On NIP-out, small models (4B/14B) degrade slightly under memory errors, while models ≥20B remain robust and can improve, with R1 reaching 0.307.The authors attribute this pattern to larger LLMs having sufficient intrinsic capacity to filter noise.Source: D. Memory Error Analysis · p. 8
  • On DCP, performance dips modestly but stays competitive, which the authors relate to the task’s reliance on precise preference matching.They describe DCP as more sensitive to factual inaccuracies in memory.Source: D. Memory Error Analysis · p. 8
  • The authors conclude that LLMs show robustness to memory errors, but high-quality memories remain important for maximizing complex-reasoning performance.The conclusion identifies advanced SDM retrieval and adaptive memory updates for dynamic environments as future work.Source: D. Memory Error Analysis · p. 8, §VII · p. 9

VII. CONCLUSION

  • MARI retrieves structured rationales to ground recommendations in explicit historical evidence, with the conclusion reporting accuracy, engagement, interpretability, and efficiency benefits.The conclusion describes this as a practical path toward transparent, rationale-driven recommender systems.Source: §VII · pp. 8–9

D. Memory Error Analysis

  • On NIP-in, error variants raise 4B from 0.075 to 0.094 over Base LLM.The analysis simulates error retrieval using lowest-similarity memories and error memory using random same-category SDMs from other users.Source: D. Memory Error Analysis · p. 8, Table IV · p. 9

APPENDIX

The appendix illustrates item and candidate data, gives an example Structured Decision Memory, and provides the recommendation prompt’s decision logic and output format.

A. Item Metadata Example

  • The item-metadata example gives a stroller’s category, brand, price, title, and product attributes.The example identifies a Phoenix four-wheel stroller priced at 2000.0 and lists its title and features.Source: A. Item Metadata Example · p. 10

B. Candidate Set Example

  • The candidate-set example presents three PiP Studio mugs with differing colors, prices, and inventory or popularity counts.The listed colors are orange, chocolate brown, and sky blue.Source: B. Candidate Set Example · p. 10

C. Structured Decision Memory Example

  • The example SDM records a user’s loungewear goals and trade-offs, including brand trust, cotton preference, an accepted price range, and rejected modal fabric.It summarizes searches, item inspection, alternative exploration, and the eventual purchase as evidence for those preferences.Source: C. Structured Decision Memory Example · p. 10

D. Prompt Templates

  • The prompt directs the model to select the most likely purchase using historical decisions, recent behaviors, and candidate items, then return reasoning and item identifiers in JSON.Its decision logic considers intent and purchase strength, including when the candidate pool is empty.Source: D. Prompt Templates · p. 10
Loading 2610.11501v1…