-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: first jsonld context #2
Open
thomasBousselin
wants to merge
6
commits into
main
Choose a base branch
from
feat/add-jsonld-context
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 3 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
5ee2527
feat: first jsonls context
thomasBousselin 4222956
feat: first jsonld context
thomasBousselin 96d8fbb
feat: first jsonld context
thomasBousselin d723c0e
feat: addition of participant
thomasBousselin ae7ed21
feat: addition of participant
thomasBousselin c4dc65f
Update README.md
telsaleh File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
## Context | ||
The [context](https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-compound.jsonld) define all | ||
the already discussed property for types : | ||
- [Asset](https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-asset.jsonld) | ||
- [DataAsset](https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-data-asset.jsonld) | ||
- [AIModelAsset](https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-ai-model-asset.jsonld) | ||
- [ServiceAsset](https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-service-asset.jsonld) | ||
|
||
## Calling the broker with the context | ||
You can use the "Link" header to define the context of your request when calling the NGSILD-Broker. | ||
``` | ||
<https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-compound.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json" | ||
``` | ||
|
||
An example of asset creation for a broker deployed on "localhost:8080" would be the following : | ||
|
||
POST "localhost:8080/ngsi-ld/v1/entities" | ||
|
||
body : [example here](https://sedimark.github.io/ontology/broker/payload-example/asset.jsonld) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"@context": { | ||
"AIModelAsset": "https://sedimark.github.io/ontology#AIModelAsset", | ||
"category": "https://sedimark.github.io/ontology#category", | ||
"purpose": "https://sedimark.github.io/ontology#purpose", | ||
"algorithm": "https://sedimark.github.io/ontology#algorithm", | ||
"serialization": "https://sedimark.github.io/ontology#serialization", | ||
"version": "http://www.w3.org/ns/dcat#version", | ||
"execution": "https://sedimark.github.io/ontology#execution", | ||
"size": "https://sedimark.github.io/ontology#size", | ||
"modified": "https://sedimark.github.io/ontology#modified", | ||
"handleStream": "https://sedimark.github.io/ontology#handleStream", | ||
"inputFormat": "https://sedimark.github.io/ontology#inputFormat", | ||
"inputParameters": "https://sedimark.github.io/ontology#inputParameters", | ||
"outputFormat": "https://sedimark.github.io/ontology#outputFormat", | ||
"outputParameters": "https://sedimark.github.io/ontology#outputParameters", | ||
"hasTrainingDataset": "https://sedimark.github.io/ontology#hasTrainingDataset", | ||
"hasArchitecture": "https://sedimark.github.io/ontology#hasArchitecture", | ||
"datasetProcessing": "https://sedimark.github.io/ontology#datasetProcessing", | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"@context": { | ||
"Asset": "https://sedimark.github.io/ontology#Asset", | ||
"title": "http://www.w3.org/ns/dcat#title", | ||
"creator": "http://www.w3.org/ns/dcat#creator", | ||
"description": "http://www.w3.org/ns/dcat#description", | ||
"publisher": "http://www.w3.org/ns/dcat#publisher", | ||
"issued": "http://www.w3.org/ns/dcat#issued", | ||
"modified": "http://www.w3.org/ns/dcat#modified", | ||
"keyword": "http://www.w3.org/ns/dcat#keyword", | ||
"license": "http://purl.org/dc/terms/license", | ||
"spatial": "http://purl.org/dc/terms/spatial", | ||
"wasGeneratedBy": "http://www.w3.org/ns/prov#wasGeneratedBy", | ||
"used": "http://www.w3.org/ns/prov#used", | ||
"startedAtTime": "http://www.w3.org/ns/prov#startedAtTime", | ||
"endedAtTime": "http://www.w3.org/ns/prov#endedAtTime", | ||
"version": "http://www.w3.org/ns/dcat#version", | ||
"endpointURL": "http://www.w3.org/ns/dcat#endpointURL", | ||
"endpointDescription": "http://www.w3.org/ns/dcat#endpointDescription", | ||
"geometry": "http://www.w3.org/ns/locn#geometry", | ||
"image": "https://sedimark.github.io/ontology# image", | ||
"relatedAsset": "https://sedimark.github.io/ontology#relatedAsset", | ||
"processingSteps": "https://sedimark.github.io/ontology#processingSteps" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"@context": [ | ||
"https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-asset.jsonld", | ||
"https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-ai-model-asset.jsonld", | ||
"https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-data-asset.jsonld", | ||
"https://sedimark.github.io/ontology/broker/jsonld-contexts/sedimark-service-asset.jsonld", | ||
"https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context-v1.8.jsonld" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"@context": { | ||
"DataAsset": "https://sedimark.github.io/ontology#DataAsset", | ||
"temporal": "http://www.w3.org/ns/dcat#temporal", | ||
"startDate": "http://www.w3.org/ns/dcat#startDate", | ||
"endDate": "http://www.w3.org/ns/dcat#endDate", | ||
"temporalResolution": "http://www.w3.org/ns/dcat#temporalResolution", | ||
"size": "http://www.w3.org/ns/dcat#size", | ||
"accrualPeriodicity": "http://purl.org/dc/terms/accrualPeriodicity", | ||
"inSeries": "http://www.w3.org/ns/dcat#inSeries" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"@context": { | ||
"ServiceAsset": "https://sedimark.github.io/ontology#ServiceAsset", | ||
"endpointURL": "http://www.w3.org/ns/dcat#endpointURL", | ||
"endpointDescription": "http://www.w3.org/ns/dcat#endpointDescription", | ||
"servesDataset": "http://www.w3.org/ns/dcat#servesDataset", | ||
"serviceConfig": "https://sedimark.github.io/ontology#serviceConfig", | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
{ | ||
"id": "urn:ngsi-ld:Asset:MyAssetId", | ||
"type": "Asset", | ||
"title": { | ||
"type": "Property", | ||
"value": "my Title" | ||
}, | ||
"creator": { | ||
"type": "Relationship", | ||
"value": "id:of:the:creator" | ||
}, | ||
"description": { | ||
"type": "Property", | ||
"value": "my Description" | ||
}, | ||
"publisher": { | ||
"type": "Relationship", | ||
"value": "id:of:the:publisher" | ||
}, | ||
"issued": { | ||
"type": "Property", | ||
"value": "2024-09-01T11:00:00.000Z" | ||
}, | ||
"modified": { | ||
"type": "Property", | ||
"value": "2024-09-01T11:00:00.000Z" | ||
}, | ||
"keyword": { | ||
"type": "Property", | ||
"value": ["Tag1", "Tag2"] | ||
}, | ||
"license": { | ||
"type": "Property", | ||
"value": "https://creativecommons.org/licenses/by-nd/4.0/" | ||
}, | ||
"spatial": { | ||
"type": "Property", | ||
"value": "https://sws.geonames.org/6299418/" | ||
}, | ||
"startedAtTime": { | ||
"type": "Property", | ||
"value": "2024-01-01T01:00:00.000Z" | ||
}, | ||
"endedAtTime": { | ||
"type": "Property", | ||
"value": "2024-12-31T23:59:59.000Z" | ||
}, | ||
"version": { | ||
"type": "Property", | ||
"value": "v1.1" | ||
}, | ||
"endpointURL": { | ||
"type": "Property", | ||
"value": "https://my.endpoint/url" | ||
}, | ||
"endpointDescription": { | ||
"type": "GeoProperty", | ||
"value": "this is what my endpoint do" | ||
}, | ||
"geometry": { | ||
"type": "Property", | ||
"value": "myValue" | ||
}, | ||
"image": { | ||
"type": "Property", | ||
"value": "https://image.com/my/image" | ||
}, | ||
"location": { | ||
"type": "GeoProperty", | ||
"value": { | ||
"type": "Point", | ||
"coordinates": [ | ||
1.5, | ||
1.5 | ||
] | ||
} | ||
} | ||
} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"geometry" property could be name "location" as "location" is already defined in the NGSILD core context.