-
Notifications
You must be signed in to change notification settings - Fork 23
Explanation of examples #26
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
Comments
There are a couple of things going on:
Typically, when a transformation is shown, it's the tabular form which is shown, quite often, the transformation is not shown inline. Where we do show the tabular form, it could make sense to allow this to be either expanded, flattened, TriG, tabular and perhaps even graphical. I'd favor a control on the example result, rather than a document-wide setting personally. Note that there is a Travis-CI setup which does some basic syntax checking, which could be enhanced to validate all transformations (although, tabular isn't quite normalized enough to do this easily, right now). Do we want to add more transformations for other examples? That could certainly blow up the size of the document, but might be useful. Alternatively, a link to the playground that loads the source could allow this kind of interaction without blowing up the document size. |
Explicit examples for framing or flattening are of course a separate issue. I think that consistency is important: all examples (excep for the flattening/expansion ones, of course) must have the same series of examples, whether it makes a lot of sense or not. And relying on playground is not an option for me: I may not always be on-line (I reviewed the document, and gathered these comments, on a plane) and playground may be down... If we can have a control over each example easily, I would also be in favour of that. And if the document is large: let us be it. We will sill be smaller than the HTML doc, and infinitely more readable:-) |
B .t.w., on my last remark: if the document is too large as one HTML file, we can consider cutting the text into several files (within on recommendation) like HTML or SVG does it... |
@iherman do you know of any specs that use multiple representations/displays at once--thinking something like this would be nice https://schema.org/Person#Invoice-gen-43 |
@iherman originally referenced the OWL Primer, but I'd like to do something more granular, say with buttons below examples, which would open each variation inline. The ShEx Spec does something similar, but the key-binding is annoying (see example in http://shex.io/shex-semantics/#shapes-schema). |
@BigBlueHat, @gkellogg referred to the examples that would come to my mind... |
Relates to w3c/json-ld-syntax#26.
Relates to w3c/json-ld-syntax#26.
Relates to w3c/json-ld-syntax#26.
Relates to w3c/json-ld-syntax#26.
The various examples are shown in other syntaxes in a somewhat inconsistent manner: most of them use the result of the expansion but some of them use a table figuring, essentially, the triples.
Also, the usage of the expansion algorithm to illustrate the example is not really helpful, mainly at first reading. Most of the examples are in sections 3 and 4, whereas the expansion algorithm is defined at the very end of section 4 (in 4.25). Also, the result of the expansion algorithm, while o.k. for machine processing, is not always intuitive: e.g., everything is put into arrays, even in cases when this is fairly unexpected for a JSON reader.
I would propose two editorial changes in this respect.
(A good example for such an approach is in the OWL Primer, where there is tab at the top that governs what syntax the reader would like to see.)
The text was updated successfully, but these errors were encountered: