#!/usr/bin/env python3
"""Check model calibration: predicted P(correct) vs ground truth."""

import pandas as pd

df = pd.read_parquet("data/router_data_qwen3.parquet", columns=["llm", "effect"])

print("Ground Truth P(correct) per LLM:")
llm_accuracy = df.groupby("llm")["effect"].mean().sort_values(ascending=False)
for llm, acc in llm_accuracy.items():
    print(f"  {llm:<25} {acc:.3f}")

overall = df["effect"].mean()
print(f"\nOverall accuracy: {overall:.3f}")
