Transforming External Knowledge into Triplets for Enhanced Retrieval in RAG of LLMs

Xudong Wang, Chaoning Zhang, Qigan Sun, Zhenzhen Huang, Chang Lu, Sheng Zheng, Zeyu Ma, Caiyan Qin, Yang Yang, Hengtao ShenarXiv 2026

TL;DR

Tri-RAG is a novel framework that enhances Retrieval-Augmented Generation (RAG) by transforming unstructured external knowledge into standardized (Condition, Proof, Conclusion) triplets. By using the "Condition" as a precise semantic anchor for retrieval and the full triplet for reasoning, Tri-RAG significantly improves retrieval accuracy, reduces token consumption, and stabilizes the reasoning chains of Large Language Models (LLMs).

What Problem Does This Paper Address?

Standard RAG pipelines typically retrieve and concatenate raw, unstructured text fragments (like paragraphs) to provide context for an LLM. This approach suffers from several critical flaws:

  1. Redundancy and Noise: Raw text often contains irrelevant information that "dilutes" the context, leading to higher token costs and potential model confusion.
  2. Weak Semantic Alignment: There is often a mismatch between the structure of a user's query and the organization of raw text, making it harder for retrievers to find the most relevant evidence.
  3. Fragmented Reasoning: In complex tasks like multi-hop question answering, raw text doesn't explicitly expose the logical dependencies (assumptions vs. conclusions) needed for stable reasoning.

Tri-RAG moves away from "document-level" retrieval toward a "representation-aware" view, organizing knowledge into units that better match how LLMs reason.

Methods

The Tri-RAG framework consists of three main stages:

1. Triplet Schema

External knowledge is re-parameterized into a structured triplet: $T = (T_c, T_p, T_r)$.

  • Condition ($T_c$): The applicability scope (e.g., "If the number is even"). This serves as the retrieval head.
  • Proof ($T_p$): The supporting rationale or causal chain (e.g., "it is divisible by 2").
  • Conclusion ($T_r$): The core verifiable claim (e.g., "it meets the definition of divisibility").

2. Triplet Extraction via Soft Prompt Tuning

To convert raw text into these triplets efficiently, the authors use layer-wise soft prompt tuning. Instead of fine-tuning the entire LLM (which is computationally expensive), they optimize a small set of trainable prompt vectors injected into the layers of a frozen backbone model (like Llama-3 or DeepSeek). This allows the model to learn the specific triplet extraction task without losing its general capabilities.

The Tri-RAG extraction and inference pipeline

3. Condition-Anchored Retrieval

During inference, Tri-RAG performs a two-stage process. First, it matches the query against only the Condition ($T_c$) fields in the knowledge base. Once the top matches are found, the full triplets are retrieved and fed to the generator LLM. This "decouples" the matching signal from the generation evidence, ensuring high precision during search and high density during reasoning.

Datasets

The authors evaluated Tri-RAG across a wide array of benchmarks:

  • Long-context & Multi-hop QA: LongBench, HotpotQA, 2WikiMultihopQA, MuSiQue, Natural Questions (NQ), and SQuAD.
  • Robustness Variants: They introduced "Shuffle-Hotpot" variants where entities are replaced with type-consistent alternatives to test if the model relies on memorized facts versus retrieved evidence.

Key Insights and Ideas

  • The "Condition" is a Better Key: The ablation study (Figure 3) shows that retrieving based on the "Condition" field alone offers a superior balance of accuracy and efficiency compared to retrieving based on the full text or just the conclusion. It acts as a stable, discriminative anchor.
  • Density Over Volume: By stripping away fluff and focusing on (C, P, R), Tri-RAG increases "evidence purity." This prevents the context window from being filled with low-utility fragments, which is especially vital for models with limited context budgets.
  • Parameter Efficiency: Using soft prompts (only ~3.7M parameters) achieved better extraction quality than LoRA (~43.1M parameters), proving that structured extraction can be learned very efficiently.

Key Results

Tri-RAG consistently outperformed standard RAG and graph-based baselines (like GraphRAG and $KG^2RAG$):

  • Accuracy Gains: On the MuSiQue benchmark, Tri-RAG improved the F1 score from 71.6% (Aflow baseline) to 74.6% using GPT-4o-mini.
  • Efficiency: Tri-RAG reduced retrieval latency to 18ms, compared to 25ms for $KG^2RAG$ and over 40ms for GraphRAG. Generation time was also significantly lower (1,900ms vs 5,500ms+ for GraphRAG) due to the compact nature of the triplets.
  • Robustness: In the "Shuffle-Hotpot-Full" test, Tri-RAG maintained a higher F1 (51.7%) than the strongest baseline (50.7%), showing it is less sensitive to noisy or reordered evidence.
Retrieval-key ablation results

Limitations and Future Work

The authors acknowledge that extracting well-formed triplets is still challenging for narrative-heavy passages where premises and conclusions are scattered across many sentences. The boundaries between Condition, Proof, and Conclusion can sometimes be ambiguous.

Future directions include: * Implementing self-verification or consistency checks during the extraction phase. * Exploring multi-granular representations to capture evidence that spans across multiple sentences more effectively. * Extending the triplet format to handle even more complex, non-linear reasoning structures.

Summary updated

BibTeX
@misc{wang2026transforming,
  author = {Xudong Wang and Chaoning Zhang and Qigan Sun and Zhenzhen Huang and Chang Lu and Sheng Zheng and Zeyu Ma and Caiyan Qin and Yang Yang and Hengtao Shen},
  title = {{Transforming External Knowledge into Triplets for Enhanced Retrieval in RAG of LLMs}},
  year = {2026},
  eprint = {2604.12610},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2604.12610},
}
Figure