Minival is a lightweight, LLM evaluation CLI focused on answer relevancy and faithfulness checks.
- Typer-based CLI with
init,run, andshow - Built-in metrics: answer relevancy and faithfulness
- DAG-based custom metric support
- Table, JSON, and CSV output formats
python -m pip install -e .Initialize scaffold files in your current directory:
minival initRun the default tests/config:
minival runInspect latest results:
minival showRender a metric DAG from config:
minival show --dag --metric "Citation Quality"- Main config:
minival_config.py - Test cases:
tests/*.json - Environment template:
.env.example(copy to.envlocally)
Example test case shape:
{
"name": "example_qa",
"input": "What is your return policy?",
"output": "We offer a 30-day full refund at no extra cost.",
"expected_output": "You are eligible for a 30-day full refund.",
"retrieval_context": [
"All customers are eligible for a 30-day full refund at no extra cost."
]
}python -m pip install -e .[dev]
pytestSee CONTRIBUTING.md for contribution workflow.
MIT. See LICENSE.