It doesn't really solve the same problem, just one that looks like it.

That said, the answer is "builds it manually" https://github.com/rails/rails/blob/master/activemodel/lib/active_model/errors.rb#L405-L436.

They have, at least theoretically, less variation in the set of keys they need.

It builds up an array of defaults