from datetime import datetime
from pydantic import BaseModel


class MetricOut(BaseModel):
    ts: datetime
    metric_name: str
    value: float
    labels: dict


class QueryStatOut(BaseModel):
    ts: datetime
    queryid: str
    calls: int
    total_time: float
    mean_time: float
    rows: int
    query_text: str | None
