aiUsageRecords.createdAt is epoch seconds since e57826d6e, but
sumUsageForBudget still compared it against a lower bound in epoch ms, so
every budget except lifetime summed to 0.
Convert the bound to seconds for usage queries, leaving windowStart in ms
for aiBudgetBreachEvents. Sum model-scoped budgets per requested model in
SQL instead of loading every row in the window into JS.