Github user afs commented on the issue:
https://github.com/apache/jena/pull/211
**NodeToLabel**
The general idea in RIOT is that a specific, special instance of
`NodeToLabel` be used for the conversion step. Writing nodes elsewhere uses a
`NodeFormatter` which for Turtle etc takes a `NodeToLabel` for the conversion
policy. There is such an object `labels` in JenaRDF2JSONLD.
Hard coding an algorithm for JSON-LD seems less than ideal, together the
assumption that Jena blank nodes have a specific form which is a feature of the
`NodeToLabel` algorithm.
The correct way is to have a specific `NodeToLabel` for this.
Example: `NodeToLabel.createBNodeByLabelAsGiven` which will use labels
unchanged.
**Determining which label to preserve**
This could be a hint carried by `BlankNodeId` with method `boolean
BlankNodeId.preserveHint()` seems the proper way to me. This could extend to
all formats and generalizes the "use label as given" option.
If it is necessary to have a way without calling a new constructor for
`BlankNodeId`, a way to do that might be to require the string be marked, say,
`|...|` (c.f. using quotes `"`!)
I am not sure if this should be some kind of option to writing, rather than
the default.
** Parsing **
See also `LabelToNode` for the parsing direction.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---