From the introduction and illustration you seem to be describing representing data in triplets. This is common in graph databases (specifically property graphs). Have you considered a property graph, and the openCypher query language which is tailored to it?