I have wondered if being able to specify a number of the @ keywords inside
parts of the context would give us this power. Here's @context inside
@context:
{
"@context": {
"sns": "http://some/namespace",
"person": {
"@context": {
"name": "sns:personName"
}
},
"organization": {
"@context": {
"name": "sns:organizationName"
}
}
},
"person" : {
"dob" : "1975-01-01",
"name" : {
"family" : "Smith",
"given" : "Joe"
}
},
"organization" : {
"name" : "Acme"
}
}
I could imagine this adding a good deal of complexity to the
implementation, which I haven't yet attempted... any insights from
implementers?
Similarly, being able to specify @vocab inline would be a start towards
things like package.json's dependencies:
{
"@context": {
"dependencies": {
"@vocab": "http://npmjs.org/package/"
}
},
"dependencies": {
"jsonld": "~0.3.x"
}
}
Of course, this would suggest that while jsonld would be expanded to
http://npmjs.org/package/jsonld but so would the version spec... which is
still weird. Of course, the relationship is pretty complex: <package> has
dependency [has package <npm:jsonld>, has version <npm:~0.3.x>] which would
require a lot of model knowledge anyway.