detect-hallucinations

Detect factual inaccuracies in LLM outputs using NLI and self-consistency methods.

29|8|Updated Jul 5, 2026
One-click install
npx skills add https://github.com/ContextJet-ai/awesome-llm-observability --skill detect-hallucinations
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: detect-hallucinations
Source: https://github.com/ContextJet-ai/awesome-llm-observability/tree/main/skills/detect-hallucinations
Command: npx skills add https://github.com/ContextJet-ai/awesome-llm-observability --skill detect-hallucinations

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires sklearn, nltk, transformers, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill helps identify when an LLM generates incorrect or misleading information, allowing you to flag or block these responses before they reach users.

Core Features & Use Cases

  • Hallucination Detection: Identifies potential factual inaccuracies in LLM outputs.
  • Customizable Methods: Supports various methods for different contexts, including NLI/entailment and self-consistency.
  • Integration: Can be integrated into production workflows for inline or sampled checks.

Quick Start

Use the detect-hallucinations skill to evaluate the output of an LLM response against provided context.

Frequently Asked Questions about detect-hallucinations

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I detect factual inaccuracies in LLM outputs?

You can detect factual inaccuracies by evaluating LLM outputs against provided context using NLI/entailment, self-consistency, and semantic entropy algorithms to flag misleading information.

What is the best way to check for hallucinations in a RAG or QA system?

Checking for hallucinations in a RAG or QA system involves assessing answer confidence against provided context using entailment and self-consistency methods to ensure factual accuracy.

Do I need transformers and sklearn to run hallucination detection algorithms?

Yes, you need the transformers, sklearn, and nltk Python libraries installed, as they provide the foundational models and text processing required to run the specific hallucination detection algorithms.

Can I integrate hallucination detection into production workflows?

Yes, you can integrate hallucination detection into production workflows for inline or sampled checks to automatically block or flag potentially incorrect LLM responses before user delivery.

How does semantic entropy help mitigate LLM hallucinations?

Semantic entropy helps mitigate LLM hallucinations by measuring variation across multiple generated answers, allowing you to assess confidence and identify outputs with high factual uncertainty.

When should I not use self-consistency for hallucination detection?

You should avoid using self-consistency for hallucination detection in open-ended generation contexts where generating multiple responses for confidence assessment is too computationally expensive.