Should rely on the HierarchicalEntityId concept, once it has been added to the Wikibase Data Model.
The current draft at https://gerrit.wikimedia.org/r/394070 allows extensions to decorate both the EntityStore and the EntityRevisionLookup with a thin layer that knows about a specific type of "sub-entities" (in this case: Forms), and forwards calls appropriately. This decoration layer lives in the Lexeme extension, and uses Lexeme vocabulary. "Sub-entities" or "hierarchies" are never mentioned in this code.
As a consequence, the concept of "sub-entities" will (for now) exclusively live in the Lexeme code base.