The precision of a TimeValue is currently represented as an integer in JSON. But these numbers do not have a meaning. They are just constants, for internal use in the Wikibase code base. It probably makes much more sense to represent these precision values as short strings in JSON, e.g. 'precision': 'DAY'. Or URIs, see T99907: [RFC] Human-readable serialization of TimeValue precisions in RDF.
Or does it? Code like in TimeDetailsFormatter makes use of the fact that the integer numbers 9 (year), 8 (10 years), 7 (100 years) and so on do have an order that can be used in a calculation. On the other hand I don't think this can be an argument for keeping the otherwise meaningless numbers.
These patches try to come up with a better naming scheme for these constants.