Skip to content
GitHubDiscord

Giskard Checks API Reference

These pages document the symbols in giskard.checks you will use directly. They assume you have written a test already. If you have not, start with Your First Test; the terms used here (scenario, check, trace, judge) are introduced in Core Concepts.

from giskard.checks import (
# Core types
Check,
CheckResult,
CheckStatus,
Interaction,
InteractionSpec,
Trace,
Scenario,
TestCase,
Suite,
SuiteResult,
# Built-in checks
FnCheck,
StringMatching,
RegexMatching,
JsonValid,
Readability,
SemanticSimilarity,
Equals,
NotEquals,
LessThan,
LessThanEquals,
GreaterThan,
GreaterThanEquals,
AllOf,
AnyOf,
Not,
RegoPolicy,
# Configuration
set_default_generator,
get_default_generator,
)
# LLM-based checks
from giskard.checks import (
BaseLLMCheck,
LLMCheckResult,
Groundedness,
AnswerRelevance,
Toxicity,
Conformity,
Contradiction,
LLMJudge,
)
# Generators
from giskard.checks import LLMGenerator, DatasetInputGenerator, UserSimulator
# Suite generation lives in the scan package, not in giskard.checks
from giskard.scan import generate_suite