N-Quads extends N Triples with an optional fourth term naming the graph that contains each triple. Each line expresses one RDF quad: subject, predicate, object, and optionally graph.
N-Quads is the line-oriented counterpart to TriG. Where TriG groups triples into GRAPH blocks, N-Quads repeats the graph name on every line—making it easy to stream, append, and diff multi-graph datasets.
Hello world
<https://example.org/people/alice> <https://schema.org/givenName> "Alice" .
<https://example.org/people/alice> <https://schema.org/givenName> "Alice" <https://example.org/graphs/provenance> .
The first line is a triple in the default graph (no graph term). The second assigns the same triple to the named graph https://example.org/graphs/provenance.
In Wiki CLI
Use wiki export -f nquads when you want RDF serialized as N-Quads. Built pages also expose this view in the Metadata panel under the NQ chip.