Role, the overloaded workhorse of the modeling world

Role, the overloaded workhorse of the modeling world If you are a data modeler or an ontologist, sooner or later you come across “role” and it becomes the “go to” pattern for most of your design problems. I know, I’ve been there. With a “role” in your hand, everything looks like a … well, whatever it is you’d hit with a role. But after a while, especially as you climb up out of structural modeling into semantic modeling, you begin to see that there are three distinct type of roles that aren’t even variations of each other. In fact, they are disjoint at the semantic level. Semantically, you have to be careful what kind of role you’re invoking, whereas at the structural level you can be pretty cavalier. Most problems just go away when you put a role in them. (We even got to treating service locations as roles of buildings, which I actually think is correct, but could still fall prey to the problem I’m about to describe.) Here’s the problem: when we say “role” we mean one of three pretty distinct things. As it turns out, you can often implement them in the same structure, which will cause you to lose sight of the fact that they are actually different. The three disjoint meanings of role are:

  • a subtype of the actor involved in the role (and therefore is really an aspect of the actor);
  • a long-term relationship between the actor and an organization or perhaps an agreement (and therefore really a reified relationship);
  • a property (and therefore is … a property).

What’s interesting (to me anyway — I’m getting to be kind of a modeling geek) is that in almost every situation I’ve looked at all three concepts exist, but in some situations it seems more normal to call one or the other the “role” and call the others something else. But that should be a clue as to the non universality of the “role” concept. By the way, structuralists tend to go to the middle meaning. So if that happens to be the more normal manifestation of role in a particular context, it will look like it worked. The further the norms get from that middle position, role as a reified relation looks less tenable. Let’s drill in a bit deeper with some examples. Let’s say we’re talking about “attorney.” Sounds like a role. But in most contexts we’re talking about the person who “is” an attorney. (or a doctor). For the most part, the attributes of the attorney are the attributes of the person. If we terminate the attorney, the person dies. Compare this with terminating the employee.

They merely lose their job. What is subtly going on here is that, in each case, there is what we would call a long-duration temporal relation. In the case of the employee, it is their employment contract with their employer. In the case of the attorney, it is their admission to the bar. But when we talk about the employee we often are talking about their employment contract. (That’s where their salary, tenure, even things like whether or not they are “exempt” – we might talk about whether employees are “exempt,”, e.g., from overtime laws but what we really mean is: is this relationship exempt, because a given employee could have multiple jobs, some of which are exempt and some aren’t.) With lawyers, however, the relationship to the Bar is very tangential. (By the way, that is even more so with doctors; as a lay person I was surprised when I found out that fewer than half of all practicing doctors are board-certified. I thought it was sort of like being admitted to the bar, but it isn’t.) Now let’s switch to the property aspect for a second. Sometimes, what puts you in a role is the presence of a property relationship. In fact the semantic community considers “role” to be a synonym for property, which seems way over the line to me. But let’s do a for instance. If you occupy a seat in a commercial airline, that is enough to make you a “passenger.” Congratulations. This is little more than steerage, or even cargo.

Your existence on the manifest is sufficient for you to be in the “role” of passenger. But this is far less than and different from either the subtype of the person or the long-term relationship we discussed earlier. Sometimes it’s the cardinality that gives it away. If you were on six planes you would be six passengers. That is, you would hold the role six times. If you had a frequent flyer account with the airline that flew three of those flights, you would have one role with them, and three others with the others (even if it were the same airline). I verified this with someone who did a lot of modeling with airlines: they consider their frequent flyers to be “customers” and everyone else are “passengers.”  That makes some sense; they set up a long-term durable temporal relation with their frequent flyers and keep track of their segments and miles flown, and occasionally give them free pretzels or Direct TV. So hopefully I’ve disamibiguated these three types of roles (although if it’s not clear, you can blame me for a lousy explanation, which is possible, or acknowledge that this is a very tough thing to disambiguate, or think I’m spiltting hairs unnecessarily).

You can certainly think the latter, but the last ten years of my semantic design experience tell me these are not arbitrary hairs being split here; this is exactly where designs get confused and conflated. Back to my job of trying to clarify the distinctions. Let’s drill in on some more examples. When we say “employee” is a role, most of the time we mean the second of my three roles: we’re talking about their relationship to a particular employer. But when we try to figure out who is “employed,” that isn’t what we’re talking about. We’re talking about subtypes of people, some of whom have at least one employment relationship and some of whom don’t. (To make matters more complicated, this is usually out of a sub population of people who aren’t yet too discouraged to look for work). It becomes more obvious that we’re talking about something different when you consider: what if 90% of the people who were not discouraged each had two jobs. Would we say we had 180% employment (or -80% unemployment if you like), or would we say we’re not counting roles2anymore we’re counting roles1 which is the subset of people who we call “employed” because they have at least one reified relationship to an employer. Having followed this train of thought, the net result for me has been two things:

1)      I now recognize that the term “role” is so overloaded that I try to avoid using it. (It doesn’t occur in gist for this reason.)

2)      I find that, in almost any design I approach, all three aspects are present. Each has a name (for attorneys, what would normally be called their role relationship to the Bar is called an “admission,” of which they could have many for as many States as they are admitted) but often people think of one of them as “the” role. That’s about all the time I can allocate in my role as a pedant — I need to get back to my role as a parent/husband/employee or whatever it is I am when I’m not writing these articles.

Scroll to top
Skip to content