Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Principle:OpenBMB UltraFeedback World Knowledge Injection

From Leeroopedia


Knowledge Sources
Domains NLP, Evaluation, Knowledge_Grounding
Last Updated 2023-10-02 00:00 GMT

Overview

A context enrichment strategy that injects dataset-specific ground truth knowledge into GPT-4 annotation templates to enable factual accuracy assessment.

Description

World Knowledge Injection addresses the challenge of evaluating truthfulness and helpfulness when the evaluator (GPT-4) may not have reliable knowledge about the specific topic. For certain instruction sources, ground truth information is available and is injected into the annotation templates as external context.

The injection is conditional on the instruction source (subset):

  • TruthfulQA: Injects both correct and incorrect answers: "a subset of correct answers: [...]\na subset of incorrect_answers: [...]"
  • FalseQA: Injects a simple indicator: "The question is based on a false premise."
  • FLAN: Injects the correct answers directly from the dataset
  • All other subsets: Uses a neutral placeholder: "No additional world knowledge for reference."

This context is placed in the world_knowledge placeholder within the truthfulness and helpfulness templates, allowing GPT-4 to cross-reference model responses against known facts.

Usage

Use this principle when evaluating factual accuracy of model completions where ground truth is available. Without world knowledge injection, GPT-4 must rely on its own knowledge, which may be incorrect or outdated.

Theoretical Basis

The theoretical basis is reference-grounded evaluation: an evaluator with access to ground truth produces more reliable judgments than one relying solely on parametric knowledge.

Pseudo-code Logic:

# Abstract algorithm
def construct_world_knowledge(subset: str, example: Dict) -> str:
    if subset == "truthful_qa":
        return (f"a subset of correct answers: {example['correct_answers']}\n"
                f"a subset of incorrect_answers: {example['incorrect_answers']}")
    elif subset == "false_qa":
        return "The question is based on a false premise."
    elif subset == "flan":
        return example["correct_answers"]
    else:
        return "No additional world knowledge for reference."

Related Pages

Implemented By

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment