OptionalalignWhether to align objects in columns (requires alignPredicates). Default: false
OptionalalignWhether to align predicates in columns. Default: false
OptionalbaseThe base IRI for relative IRI resolution.
OptionalblankWhether to insert blank lines between subjects. Default: true
OptionalblankCustom blank node ID generator. If provided, this function will be called to generate IDs for new blank nodes.
OptionalblankBlank node formatting style. Default: 'auto'
OptionalcompactWhether to compact arrays with single items. Default: true
OptionaldirectiveControls the style used for prefix and base directives.
'turtle': Turtle-style (@prefix ex: <…> . / @base <…> .)'sparql-lowercase': SPARQL-style lowercase (prefix ex: <…> / base <…>)'sparql-uppercase': SPARQL-style uppercase (PREFIX ex: <…> / BASE <…>)
Default: 'sparql-uppercase'OptionalembedWhether to embed
OptionalemitWhether to emit PREFIX/BASE directives in serializer output.
Default: true.
OptionalgroupWhether to group statements by subject (Turtle/TriG style). Default: true for Turtle/TriG, false for N-Triples/N-Quads
OptionalindentIndentation string (default: ' ' for 2 spaces).
OptionalinlineWhether to serialize well-formed RDF lists (rdf:first/rdf:rest/rdf:nil
chains) using collection syntax (( ... )) when pretty printing.
Malformed, shared or otherwise ambiguous lists fall back to blank node
serialization so that no triples are ever dropped.
This applies only when prettyPrint is true.
Default: true
OptionalinlineWhether to serialize single-use blank nodes as local property lists
([ ... ]) when pretty printing.
This applies only when prettyPrint is true.
Default: true
OptionaljsonJSON indentation spaces (default: 2).
OptionallineLine ending string (default: '\n').
OptionalmaxMaximum line width before wrapping (0 = no wrapping). Default: 0
OptionalobjectObject list formatting style. Default: 'auto'
OptionalpredicatePredicate list formatting style. Default: 'first-same-line'
OptionalprefixesMapping of prefixes to namespaces for compacting IRIs in the output.
OptionalprettyWhether to pretty-print the JSON output with newlines and indentation.
OptionalrelabelWhether to rename all blank nodes in first-appearance order using the
blankNodeIdGenerator before serializing. Useful for exports where
source blank node labels carry parser-internal prefixes (e.g.
_:13xf400_b0) that would otherwise leak into the output.
Default: false
OptionalsortSorting option for quads.
OptionalspaceWhether to insert a space before statement punctuation (;, ,, .)
and directive terminators. When false, punctuation hugs the preceding
token (e.g. ex:s ex:p ex:o;).
Default: true
OptionaluseWhether to use
OptionaluseWhether to use the 'a' shorthand for rdf:type. Default: true for Turtle/TriG/N3, false for N-Triples/N-Quads
OptionaluseWhether to use
JSON-LD specific options.