PulseExploreJournal ClubDebatesTrendingResearchersJournals
Instagram
HomeExploreJournal ClubTrending
Synapse
⌘+K
Synapse
January 18, 2026Gazi University Journal of Science Part A Engineering and Innovation0 citations

Evaluating the Impact of Temperature and Instruction Strategies on Hallucination in Large Language Models

View Full Paper
AKAbdullah Talha Kabakuş

Key Points

  • This research investigates how temperature and instruction strategies impact hallucination behavior in large language models.
  • Evaluated three LLMs using the TruthfulQA benchmark
  • Applied zero-shot, few-shot, and 'say-I-don't-know' prompting
  • Measured performance through exact match, token-level F1, and other metrics
  • Conducted two-way ANOVA and Tukey post-hoc analyses
  • Instruction strategies significantly influenced factual accuracy across all models
  • Few-shot prompting achieved the highest F1 score of 0.1889
  • 'Say-I-don't-know' prompts increased semantic alignment but reduced precision
  • Embedding-based similarity showed higher consistency for zero-shot responses

Abstract

Large Language Models (LLMs) have demonstrated impressive generative and reasoning abilities, yet their tendency to produce factually incorrect or fabricated information—so-called hallucinations—remains a key limitation. This study systematically examines how temperature and system instruction strategies affect hallucination behavior in open-source LLMs executed through the Ollama framework. Three representative models—Gemma 2B, Mistral 7B Instruct, and Phi-3 Mini—were evaluated on the TruthfulQA benchmark using zero-shot, few-shot, and “say-I-don’t-know” prompting paradigms. Performance was measured through exact match, token-level F1, semantic similarity, and embedding-based similarity metrics. Two-way ANOVA and3 Tukey post-hoc analyses revealed that system instruction significantly influenced factual accuracy across all models, while temperature effects were comparatively minor. Few-shot prompting achieved the highest mean F1 score (0.1889), indicating that example conditioning effectively constrained hallucinations. Conversely, “say-I-don’t-know” prompts increased semantic alignment but reduced precision, suggesting a conservative refusal bias. Embedding-based similarity analyses confirmed higher semantic consistency for zero-shot responses. The results highlight that prompt design exerts a stronger and more interpretable influence on hallucination than sampling stochasticity, offering practical guidance for improving the factual reliability of open-source LLMs.

Ask AI
Helpful
Bookmark
Share
View Full Paper

Cite This Study

Abdullah Talha Kabakuş (2026) studied this question.

synapsesocial.com/papers/696c79cde45ebfc9113cd3dehttps://doi.org/10.54287/gujsa.1819131
Ask AI
Helpful
Bookmark
Share
View Full Paper