TroyDoesAI/Phi-3-Context-Obedient-RAG

Warm
Public
4B
BF16
4096
License: cc-by-sa-4.0
Hugging Face
Overview

Overview

This model, TroyDoesAI/Phi-3-Context-Obedient-RAG, is a specialized fine-tune of Microsoft's Phi-3-mini-128k-instruct base model. Its core purpose is to significantly enhance context adherence and mitigate hallucinations, particularly within Retrieval Augmented Generation (RAG) workflows. The model achieves this through a unique, structured prompt format that explicitly delineates input blocks, associated context (metadata), and instructions.

Key Capabilities

  • Enhanced Context Adherence: Designed to strictly follow the provided contextual information, reducing the generation of ungrounded responses.
  • Reduced Hallucinations: By enforcing context obedience, the model aims to minimize instances where it generates information not present in the source material.
  • Precise Source Referencing: The training dataset includes examples where the model is prompted to cite specific source details (e.g., date, URL) from the provided context in its responses, addressing a common weakness in RAG systems.
  • Structured Prompting: Utilizes explicit delimiters (BEGININPUT, BEGINCONTEXT, ENDCONTEXT, ENDINPUT, BEGININSTRUCTION, ENDINSTRUCTION) to clearly define different parts of the prompt, helping the model accurately locate and utilize information.

Good For

  • RAG Applications: Ideal for scenarios where grounding responses in retrieved documents is critical.
  • Fact-Checking & Verification: Useful for systems requiring verifiable answers linked directly to source material.
  • Reducing AI Hallucinations: Aims to improve the trustworthiness of AI-generated content by ensuring it stays within the bounds of provided facts.
  • Complex Information Retrieval: When dealing with multiple document chunks, this model can help attribute specific parts of the answer to the correct source.