Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge @type and @datatype #31

Closed
lanthaler opened this issue Sep 28, 2011 · 5 comments
Closed

Merge @type and @datatype #31

lanthaler opened this issue Sep 28, 2011 · 5 comments

Comments

@lanthaler
Copy link
Member

@type is used to set the type of the active subject.
@datatype is used to specify the datatype for a literal.

Since @datatype has always to be used with @literal in an object it is kind of redundant. E.g. consider the following:

...
  { "@literal": "4.8", "@datatype": "xsd:decimal" }
...

It would be invalid to create something like

{ "@literal": "Markus", "@type": "foaf:Person" }

I understand that in a RDF world the distinction is necessary, but in JSON-LD we do not need to distinguish the two keywords as they can't be misinterpreted.

So I would like to propose to merge @datatype and @type to @type (ISSUE-31). I think this won't cause any problems in the already implemented algorithms and just require a change from @datatype to @type. The reason behind this is that both, @type and @datatype, specify the "data type" of a construct, the only difference is that the one addresses subjects while the other addresses objects.
Since simplicity is one of the design goals of JSON-LD, the reduction of keywords is desirable.

@lanthaler
Copy link
Member Author

There was some discussion about this in the telecon on 2011-10-18

@msporny
Copy link
Member

msporny commented Nov 29, 2011

I think consensus based on the discussion noted above was to not merge the two concepts into a single keyword to ensure that authors would have an easier time understanding the differences when marking up both sets of information. Closing the issue, please re-open if you think my read on the discussion is wrong.

@lanthaler
Copy link
Member Author

Unfortunately I couldn't attend the telecon where that discussion happened. But from reading the transcript I don't think a consensus was found.. I feel quite strongly about that and would really like to further discuss it.

I understand that people with RDF background don't like the idea but they aren't really the target group JSON-LD addresses. The target group are, in my opinion, web developers/programmers and for them specifying a (data)type of something always works the same way - independently of whether it is a class or a primitive data type.

Why should we make it more complicated than we need?

-----Original Message-----
From: Manu Sporny [mailto:reply+i-1763833-
61849aa2e3f568fbf60200f7e686c0718e8b1383-456407@reply.github.com]
Sent: Tuesday, November 29, 2011 1:08 PM
To: Markus Lanthaler
Subject: Re: [json-ld.org] Merge @type and @datatype (#31)

I think consensus based on the discussion noted above was to not merge
the two concepts into a single keyword to ensure that authors would
have an easier time understanding the differences when marking up both
sets of information. Closing the issue, please re-open if you think my
read on the discussion is wrong.


Reply to this email directly or view it on GitHub:
#31 (comment)

@lanthaler
Copy link
Member Author

RESOLVED: Merge @datatype keyword with @type - @type will be used to specify both rdf:type for nodes and literal datatypes

Minutes of the 2011-12-13 telecon

gkellogg added a commit that referenced this issue Dec 15, 2011
… that indicates that the concepts are actually different. This resolves issue #31.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants