Skip to content

Commit c82ddf7

Browse files
authored
Merge pull request #9 from a-mile/acm_rep_updates
Update references to 1.2 spec, re-ordering, content updates
2 parents 3f25463 + bf2f544 commit c82ddf7

22 files changed

+360
-171
lines changed

CODE_OF_CONDUCT.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
---
2+
title: "Contributor Code of Conduct"
3+
---
4+
15
# Contributor Code of Conduct
26

37
Contributors to the RO-Crate community, including this tutorial, are expected to comply with our [Code of Conduct](https://github.com/ResearchObject/ro-crate/blob/main/CODE_OF_CONDUCT.md) to ensure an open and inclusive environment. You may email [email protected] to report any Code of Conduct concerns.

LICENSE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ This tutorial has been adapted from the revised [RO-Crate introduction for 1.2](
2121
* Adaptation to Galaxy Training Material rendering
2222
* Explicit links to RO-Crate specifications
2323
* Example changed to different organization and license
24-
* Modiied for Carpentries style
24+
* Modified for Carpentries style
2525

2626
# Examples
2727

config.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,9 @@ contact: "[email protected]"
6868
episodes:
6969
- 01-introduction.md
7070
- 02-folder-as-crate-root.md
71-
- 03-metadata-descriptor.md
7271
- 04-root.md
7372
- 05-root-metadata.md
73+
- 03-metadata-descriptor.md
7474
- 06-cross-references.md
7575
- 07-data-entities.md
7676
- 08-contextual-entities.md
@@ -79,6 +79,7 @@ episodes:
7979
- 11-triples.md
8080
- 12-html-preview.md
8181
- 13-complete.md
82+
- 15-common-pitfalls.md
8283
- 14-next-steps.md
8384

8485
# Information for Learners

episodes/01-introduction.md

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,18 @@ exercises: 0
2323

2424
::::::::::::::::::::::::::::::::::::::: questions
2525
- How do I package data in a FAIR way?
26+
- How does an RO-Crate identify and describe its contents?
27+
- What is the difference between data entities and context entities?
28+
- What is the role of JSON-LD in RO-Crate?
2629
- How can I list the authors of individual files?
27-
- Can I use multiple licenses in the same data package?
28-
- How can I visualize JSON-LD metadata?
30+
- How can I validate and visualize RO-Crate metadata?
2931
::::::::::::::::::::::::::::::::::::::::::::::::::
3032

3133
::::::::::::::::::::::::::::::::::::::: objectives
3234
- Construct an RO-Crate by hand using JSON
33-
- Describe each part of the Research Object
3435
- Learn basic JSON-LD to create FAIR metadata
35-
- Connect different parts of the Research Object using identifiers
36+
- Describe each part of the RO-Crate
37+
- Connect different parts of the RO-Crate using identifiers
3638
::::::::::::::::::::::::::::::::::::::::::::::::::
3739

3840

@@ -50,16 +52,19 @@ _Video: An overview of the RO-Crate concept and its implementations_ (see also [
5052

5153
## Tutorial walk-through
5254

53-
In this tutorial, meant to be read along with the [RO-Crate specification](https://www.researchobject.org/ro-crate/1.1/),
55+
In this tutorial, meant to be read along with the [RO-Crate specification](https://www.researchobject.org/ro-crate/1.2/),
5456
we'll walk through the initial steps for creating a basic RO-Crate.
5557
You are invited to replicate the below steps on your local computer.
5658

5759
::::::::::::::::::::::::::::::::::::::: callout
5860
## Abbreviations
59-
- FAIR: Findable, Accessible, Interoperable, Reusable; a set of principles for publishing research data and metadata
60-
- JSON: JavaScript Object Notation, a generic structured text-based data format
61-
- JSON-LD: JSON Linked Data, a way to express Linked Data (RDF) using regular JSON
62-
- RO-Crate: Research Object Crate; a way to package research data with structured FAIR metadata
61+
- FAIR: Findable, Accessible, Interoperable, Reusable; a set of principles for publishing research data and metadata.
62+
- FDO: FAIR Digital Object; a set of recommendations to improve findability, accessibility, interoperability, and reproducibility for any digital object.
63+
- JSON: JavaScript Object Notation, a generic structured text-based data format.
64+
- JSON-LD: JSON Linked Data, a way to express Linked Data (RDF) using regular JSON.
65+
- RO-Crate: Research Object Crate; a way to package research data with structured FAIR metadata.
66+
- PID: Persistent Identifier; a long-lasting reference to a digital object.
67+
- URI: Uniform Resource Identifier; a string of characters that identifies a resource.
6368
::::::::::::::::::::::::::::::::::::::::::::::::::
6469

6570
::::::::::::::::::::::::::::::::::::::: keypoints

episodes/02-folder-as-crate-root.md

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ then add the following JSON:
3939

4040
```json
4141
{
42-
"@context": "https://w3id.org/ro/crate/1.1/context",
42+
"@context": "https://w3id.org/ro/crate/1.2/context",
4343
"@graph": [
4444

4545
]
@@ -56,7 +56,7 @@ We call the top-level folder of the crate for the **RO-Crate Root**
5656
and can now refer to its content with relative file paths.
5757

5858
We also need to make some declaration within the JSON file to turn it into a valid _RO-Crate Metadata Document_,
59-
explained in the next session.
59+
explained in the next section.
6060

6161

6262
## JSON-LD preamble
@@ -67,7 +67,7 @@ used in the rest of the RO-Crate document.
6767
These will largely map to definitions in the [schema.org](http://schema.org/) vocabulary,
6868
which can be used by RO-Crate extensions to provide additional metadata beyond the RO-Crate specifications.
6969
It is this feature of JSON-LD that helps make RO-Crate extensible for many different purposes
70-
-- this is explored further in the specification's [appendix on JSON-LD](https://www.researchobject.org/ro-crate/1.1/appendix/jsonld.html).
70+
-- this is explored further in the specification's [appendix on JSON-LD](https://www.researchobject.org/ro-crate/1.2/appendix/jsonld.html).
7171
In short, only JSON keys (_properties_) and types defined this way can be used within the RO-Crate Metadata Document.
7272

7373
However, in the general case it should be sufficient to follow the RO-Crate JSON examples directly without deeper JSON-LD understanding.
@@ -78,7 +78,7 @@ The `@type` keyword associates an object with a predefined type from the JSON-LD
7878
Almost any property can alternatively be used with an `[]` array to provide multiple values.
7979

8080
The rest of this tutorial,
81-
and indeed most of the [RO-Crate specification](https://www.researchobject.org/ro-crate/1.1/),
81+
and indeed most of the [RO-Crate specification](https://www.researchobject.org/ro-crate/specification/1.2/),
8282
specify which entities can be added to the `@graph` array.
8383

8484

@@ -88,5 +88,4 @@ specify which entities can be added to the `@graph` array.
8888
- RO-Crate uses schema.org as base vocabulary
8989
- The JSON-LD context enables optional Linked Data processing
9090
- Descriptions are listed flatly as entities in the @graph array
91-
::::::::::::::::::::::::::::::::::::::::::::::::::
92-
91+
::::::::::::::::::::::::::::::::::::::::::::::::::

episodes/03-metadata-descriptor.md

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,32 +17,48 @@ exercises: 2
1717

1818
## RO-Crate Metadata descriptor
1919

20-
The first JSON-LD _entity_ to add in the `@graph` array has the `@id` value of `ro-crate-metadata.json` to describe the JSON file itself:
20+
Next, we'll add another _entity_ to the `@graph` array has the `@id` value of `ro-crate-metadata.json` to describe the JSON file itself:
2121

2222

2323
```json
2424
{
2525
"@id": "ro-crate-metadata.json",
2626
"@type": "CreativeWork",
27-
"conformsTo": {"@id": "https://w3id.org/ro/crate/1.1"},
27+
"conformsTo": {"@id": "https://w3id.org/ro/crate/1.2"},
2828
"about": {"@id": "./"}
2929
}
3030
```
3131

32-
This required entity, known as the [RO-Crate Metadata Descriptor](https://www.researchobject.org/ro-crate/1.1/root-data-entity.html#ro-crate-metadata-file-descriptor),
32+
This required entity, known as the [RO-Crate Metadata Descriptor](https://www.researchobject.org/ro-crate/specification/1.2/root-data-entity.html#ro-crate-metadata-file-descriptor),
3333
helps this file self-identify as an RO-Crate Metadata Document,
34-
which is conforming to (`conformsTo`) the RO-Crate specification version 1.1.
34+
which is conforming to (`conformsTo`) the RO-Crate specification version 1.2.
3535
Notice that the `conformsTo` URL corresponds to the `@context` URL version-wise,
3636
but they have two different functions.
3737
The context brings the defined terms into the metadata document,
3838
while the conformance declares which RO-Crate conventions of using those terms are being followed.
3939

40+
:::::::::::::::::::::::::::::::::::::::: callout
41+
42+
## Adding entities to the JSON array
43+
44+
Because we're adding incrementally to the `@graph` array.
45+
It is important to remember the comma `,` between each entity,
46+
**except** for the final entity in the JSON array;
47+
and likewise for the properties within the JSON object for each entity.
48+
This is an artefact of the strict [JSON](https://www.json.org/) file format rules to simplify parsing.
49+
The order of the entities within the `@graph` JSON-LD array
50+
and the order of the keys within a JSON object is _not significant_.
51+
The _graph_ content is given by the `@id` cross-references.
52+
53+
You will add a comma here between the `ro-crate-metadata.json` entity, and the root data entity.
54+
::::::::::::::::::::::::::::::::::::::::::::::::::
55+
4056
::::::::::::::::::::::::::::::::::::::: callout
4157
## RO-Crate versions
42-
This tutorial is written for RO-Crate 1.1,
58+
This tutorial is written for RO-Crate 1.2,
4359
the RO-Crate website will list the [current specification version](https://www.researchobject.org/ro-crate/specification.html)
4460
-- RO-Crates can generally be upgraded to newer versions following [semantic versioning](https://semver.org/) conventions,
45-
but check the [change log](https://www.researchobject.org/ro-crate/1.1/appendix/changelog.html) for any important changes.
61+
but check the [change log](https://www.researchobject.org/ro-crate/specification/1.2/appendix/changelog.html) for any important changes.
4662
The next development version of the specification, indicated with a `-DRAFT` status,
4763
may still be subject to changes and should only be used with caution.
4864
::::::::::::::::::::::::::::::::::::::::::::::::::
@@ -52,5 +68,3 @@ may still be subject to changes and should only be used with caution.
5268
- RO-Crate specifications are versioned
5369
- The version of RO-Crate is indicated using the conformsTo property
5470
::::::::::::::::::::::::::::::::::::::::::::::::::
55-
56-

episodes/04-root.md

Lines changed: 33 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ exercises: 1
1414

1515
## RO-Crate Root
1616

17-
Next we'll add another entity to the `@graph` array,
18-
to describe the [RO-Crate Root](https://www.researchobject.org/ro-crate/1.1/root-data-entity.html#direct-properties-of-the-root-data-entity):
17+
First we'll add an entity to the `@graph` array,
18+
to describe the [RO-Crate Root](https://www.researchobject.org/ro-crate/specification/1.2/root-data-entity.html#direct-properties-of-the-root-data-entity):
1919

2020
```json
2121
{
@@ -27,23 +27,8 @@ to describe the [RO-Crate Root](https://www.researchobject.org/ro-crate/1.1/root
2727
}
2828
```
2929

30-
:::::::::::::::::::::::::::::::::::::::: callout
31-
## Adding entities to the JSON array
32-
33-
Because we're adding incrementally to the `@graph` array.
34-
It is important to remember the comma `,` between each entity,
35-
**except** for the final entity in the JSON array;
36-
and likewise for the properties within the JSON object for each entity.
37-
This is an artefact of the strict [JSON](https://www.json.org/) file format rules to simplify parsing.
38-
The order of the entities within the `@graph` JSON-LD array
39-
and the order of the keys within a JSON object is _not significant_.
40-
The _graph_ content is given by the `@id` cross-references.
41-
42-
You will add a comma here between the `ro-crate-metadata.json` entity, and the root data entity.
43-
::::::::::::::::::::::::::::::::::::::::::::::::::
44-
45-
By convention, in RO-Crate the `@id` value of `./` means that this entity describes the folder in which the RO-Crate metadata file is located.
46-
This reference from `ro-crate-metadata.json` is therefore semantically marking the `crate1` folder as being the RO-Crate Root.
30+
By convention, in RO-Crate the `@id` value of `./` means that this entity describes the folder in which the RO-Crate metadata file is located. The root data entity always has the `@type` value of `Dataset`, which is a [schema.org](https://schema.org/Dataset) type.
31+
This will be referenced from `ro-crate-metadata.json`, semantically marking the `crate1` folder as being the RO-Crate Root.
4732

4833

4934
:::::::::::::::::::::::::::::::::::::::: discussion
@@ -57,11 +42,36 @@ If the crate is being served from a Web service,
5742
such as a data repository or database where files are not organized in folders,
5843
then the `@id` might be an absolute URI instead of `./`
5944
-- this is one reason why we point to the root entity from the metadata descriptor,
60-
see section [Root Data Entity](https://www.researchobject.org/ro-crate/1.1/root-data-entity.html) for details.
45+
as you will see in the next section.
6146
::::::::::::::::::::::::::::::::::::::::::::::::::
6247

63-
:::::::::::::::::::::::::::::::::::::::: keypoints
64-
- The RO-Crate Root is the top-level object of the RO-Crate
65-
- The root identifier may be a URL, but commonly just ./ for the current folder
48+
:::::::::::::::::::::::::::::::::::::::: challenge
49+
## Add an additional type
50+
51+
1. Navigate the schema.org type list to find a subtype of `CreativeWork` that is suitable for a learning resource.
52+
2. Modify the root entity's `@type` to be an array.
53+
3. Add the type name for learning resource at the end of the array.
54+
55+
::::::::::::::: solution
56+
```json
57+
{
58+
"@id": "./",
59+
"@type": ["Dataset", "LearningResource"],
60+
"hasPart": [
61+
{"@id": "data.csv"}
62+
],
63+
"…": ""
64+
}
65+
```
66+
:::::::::::::::::::::::::
6667
::::::::::::::::::::::::::::::::::::::::::::::::::
6768

69+
The root has several metadata properties that describe the RO-Crate as a whole,
70+
considering it as a Research Object of collected resources.
71+
In the next section we will cover the required and recommended properties of the root `./`.
72+
73+
:::::::::::::::::::::::::::::::::::::::: keypoints
74+
- The RO-Crate Root is the top-level object of the RO-Crate
75+
- The root identifier is commonly just ./ for the current folder, but can be a URL
76+
- The root is always typed as a Dataset, but can have additional types
77+
::::::::::::::::::::::::::::::::::::::::::::::::::

episodes/05-root-metadata.md

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ exercises: 4
1515

1616
## Describing the root entity
1717

18-
When describing the [root entity](https://www.researchobject.org/ro-crate/1.1/root-data-entity.html#direct-properties-of-the-root-data-entity),
18+
When describing the [root entity](https://www.researchobject.org/ro-crate/specification/1.2/root-data-entity.html#direct-properties-of-the-root-data-entity),
1919
the properties generally apply to the whole of the crate.
2020
For instance it is a good idea to give a description of why these resources are gathered in a crate,
2121
as well as giving the crate a name and license for FAIR reuse and citation.
@@ -36,7 +36,7 @@ or another license of your choice:
3636
"hasPart": [ ],
3737
"name": "Example crate",
3838
"description": "I created this example by following the tutorial",
39-
"datePublished": "2023-05-22T12:03:00+0100",
39+
"datePublished": "2023-05-22",
4040
"license": { "@id": "http://spdx.org/licenses/CC0-1.0"}
4141
}
4242
```
@@ -68,9 +68,6 @@ It is still recommended to choose an overall Crate license that can legally appl
6868
::::::::::::::::::::::::::::::::::::::::::::::::::
6969

7070
:::::::::::::::::::::::::::::::::::::::: keypoints
71-
- Name, description, date published and license are required for the RO-Crate Root"
71+
- Name, description, date published and license are required for the RO-Crate Root
7272
- RO-Crate allows multiple licenses for different parts
73-
::::::::::::::::::::::::::::::::::::::::::::::::::
74-
75-
76-
73+
::::::::::::::::::::::::::::::::::::::::::::::::::

0 commit comments

Comments
 (0)