Add a constraint for T. In TypeScript, you can add constraints that refer to each other for generic parameters.
const sumByField = <T extends {[P in K]: number}, K extends OnlyNumericKeys<T>>(data: T[], field: K) =>
data.reduce(
(acc, curr) => acc + curr[field],
0
);