Retrieval Augmented Learning: A Retrial-based Large Language Model Self-Supervised Learning and Autonomous Knowledge Generation

Zongyuan Li, Pengfei Li, Runnan Qi, Yanan Ni, Lumin Jiang, Hui Wu, Xuebo Zhang, Kuihua Huang, Xian GuoarXiv 2025 · DOI

Abstract

Retrieval-Augmented Learning (RAL) is a "train-free" framework that enables Large Language Models (LLMs) to master complex decision-making tasks through autonomous trial and error. By utilizing a dynamic Retrieval-Augmented Generation (RAG) system to propose, validate, and store strategies, RAL significantly enhances performance in environments like StarCraft II while remaining 100x more sample-efficient than traditional Reinforcement Learning.

Introduction

While Large Language Models (LLMs) demonstrate impressive reasoning capabilities, they frequently struggle in specialized domains such as complex strategy games or industrial control due to a lack of specific domain knowledge. Current solutions to this problem have significant limitations:

  1. Fine-tuning/Post-training: Demands massive GPU resources and high-quality datasets that are often unavailable.
  2. Prompt Engineering: Constrained by context window limits and the model's tendency to "hallucinate" plausible but ineffective strategies.
  3. Reflection: Models often reflect using the same flawed knowledge that caused the initial error, leading to a cycle of repeated mistakes.

RAL addresses these issues by allowing LLMs to autonomously generate, verify, and utilize accurate domain knowledge without updating model weights.

Methodology

The RAL framework transforms RAG from a static lookup tool into a dynamic "memory" for an agent. The learning process follows a three-stage pipeline:

  1. Hypothesis Proposal: Following an action, the LLM analyzes the state transition and proposes a hypothetical improved strategy ($h$), which is stored in a Hypothesis Database.
  2. Hypothesis Validation: When the agent encounters a similar situation, it retrieves and tests the hypothesis. The results—including success/failure metrics and costs—are stored in a Validation Database.
  3. Experience Generation: Once a strategy has been sufficiently tested, a "Learner" LLM summarizes the raw validation data into high-level "Experience" ($e$). This consolidated knowledge is stored in an Experience Database.
Overview of the RAL framework showing the deployment and learning cycles.

This process is entirely train-free and reward-free; "learning" occurs within the external RAG databases. During deployment, the agent retrieves the most relevant "Experience" to guide its decision-making.

Experimental Evaluation

The researchers evaluated RAL using the LLM-PySC2 environment, a specialized wrapper for StarCraft II.

  • Tasks: Combat scenarios included 3s_vs_3z (3 Stalkers vs 3 Zealots), 2a_harass (worker unit harassment), and 4s_vs_5r.
  • Benchmarks: RAL was compared against a "Baseline" (zero-shot decision making) and "Reflection" (reflecting on the previous step's error).
  • Models: Experiments utilized GPT-3.5-Turbo, GPT-4o-mini, DeepSeek-V3, and DeepSeek-R1.

Key Insights

  • RAG as Evolving Memory: Unlike traditional RAG with fixed databases, RAL treats the database as a living entity that matures from initial hypotheses to verified experiences.
  • Semantic Sample Efficiency: Traditional Reinforcement Learning (RL) requires millions of steps. RAL achieves high performance in just 25 episodes by using semantic reasoning to bypass meaningless actions.
  • Hallucination Filtering: The validation stage acts as a filter. If a model hypothesizes a poor strategy, the environment proves it wrong during validation, preventing it from becoming "Experience."
  • Cross-Model Transferability: Experiences generated by advanced models (e.g., GPT-4) can be utilized by smaller models (e.g., GPT-3.5) to immediately boost performance without additional training.

Results

RAL demonstrates significant improvements across all tested scenarios. In the 3s_vs_3z task, the baseline win rate was 35%, while traditional reflection dropped the win rate to 0% due to hallucinated strategies. In contrast, RAL achieved a 95% win rate.

Performance comparison of RAL against baseline and reflection methods across multiple StarCraft II scenarios.

Beyond raw performance, RAL is highly cost-efficient. Because it retrieves condensed experiences, prompt length only increases by approximately 300 tokens. It also shows strong Out-of-Distribution (OOD) robustness; knowledge learned on easier tasks (3s vs 3z) significantly improved performance on harder tasks (3s vs 5z). Finally, RAL maintains low latency (approx. 24s per action), comparable to direct prompting and much faster than specialized reasoning models.

Conclusion and Future Work

While RAL is effective for short-horizon transitions, it currently struggles with long-horizon problems where rewards are delayed. Furthermore, the agent's optimal strategy is limited by the LLM's "imagination" during the hypothesis stage. Future research will focus on multi-step validation and improving the diversity of the hypothesis generator to overcome these limitations.

Summary updated

BibTeX
@misc{li2025retrieval,
  author = {Zongyuan Li and Pengfei Li and Runnan Qi and Yanan Ni and Lumin Jiang and Hui Wu and Xuebo Zhang and Kuihua Huang and Xian Guo},
  title = {{Retrieval Augmented Learning: A Retrial-based Large Language Model Self-Supervised Learning and Autonomous Knowledge Generation}},
  year = {2025},
  eprint = {2505.01073},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2505.01073},
}
Figure