Is there code/a software that converts an SPDX license expression into valid OWL/RDF?
SPDX license expressions are strings that might look like "MIT OR LicenseRef-MyOwnLicense". As much as I figured, this would have to be represented differently in RDF, using multiple triples, including at least one disjunctive license set individual.
Is there already open source code/a tool that can do this conversion?
Is there already open source code/a tool that can do this conversion?
Somewhat - the SPDX Java tools and the SPDX Online tools can convert from a JSON, Tag/Value or spreadsheet containing the string representation of a license expression to RDF format (RDF/XML or RDF/TTL).
The tools won't translate just the license expression string, but that would not be too difficult to add.
Ahh nice, thank you! :-) I'll have a look at the CLI tool and converting from JSON to RDF ...
I got the tool running .. do you maybe have an example JSON file?
I got the tool running .. do you maybe have an example JSON file?
The official examples are in the spec repo - since we're working with SPDX version 2.3, you should use these examples.
Cloasing this as I think the answers have resolved. Please reopen if I've missed something.