GRAPH-COMPATIBILITY.md raw

Graph compatibility notes

Checked against the original at ../orly (pkg/database/graph-*.go, pkg/database/save-event.go, pkg/database/delete-event.go and pkg/database/indexes/keys.go), and morly's pkg/store/index/keys.mx.

Matches

order, widths and direction bytes.

direct pubkey→pubkey edges written from every p-tag.

directions.

Intentional corrections

direction byte when constructing the reverse peg key, so a p-tag edge with direction 1 constructs another peg direction 1 instead of direction 2. torly constructs the actual reverse (DirPTagIn).

pubkeys_by_depth for outbound pe. torly always reports event IDs in events_by_depth.

TraverseThread, which only recognizes outbound, inbound or both; consequently its out and in return nothing. torly maps out to eeg, in to gee, and both to the union.

GetEventsReferencingPubkey use a short common-kind list when no kinds are requested. torly scans all kinds.

Deliberate differences

Truncating them would silently change the graph, so they contribute no author, p-tag or e-tag edges. They remain stored and queryable through the normal NIP-01 indexes.

them from the response. orly excludes only the current root, so an authored event referenced by another root can appear in its result.

only creates the edge if the target already exists.

discovery order.

The deployed orly relay currently reports `graph queries not supported on this relay` because its graph executor is not initialized, so runtime comparison of _graph was not possible against that instance; the comparison above is against the source implementation.