Skip to content

feat(graph): support configurable follow-list kinds with separate negentropy sync - #19

Open
flox1an wants to merge 2 commits into
ContextVM:masterfrom
flox1an:upstream/follow-list-kinds
Open

flox1an wants to merge 2 commits into
ContextVM:masterfrom
flox1an:upstream/follow-list-kinds

Conversation

@flox1an

@flox1an flox1an commented Oct 12, 2026 •

Copy link
Copy Markdown

Why

The graph ignores media follows (kind 10020). Ingesting both kinds separately would overwrite an author's normal list and lose relationships.

Change

Add FOLLOW_LIST_KINDS: default 3, opt in with 3,10020. Merge each author's newest lists into one deduplicated follow set. Sync each kind separately and retain received events on abort; multi-kind sync previously stalled.

Verification

Lint/build pass; full suite: 213 pass, 5 skip, 0 fail. Bun 1.3.14/macOS with a temporary test SERVER_SECRET_KEY. Existing manager and duplicate-DuckDB type errors remain.

Operational: Changing the kind set rebuilds the graph before MCP starts, causing temporary downtime. Default behavior stays unchanged. Independent PR; keep the sync correction with the feature, and preserve both scheduler imports when merging validation scheduling.

Related: #15, #16, #17, #18. All branches are independent; combined suite: 221 pass, 5 skip, 0 fail.

Florian added 2 commits October 12, 2026 09:29
Add FOLLOW_LIST_KINDS (default 3) to select which event kinds define
follows, e.g. 3,10020 to include NIP-51 media follow lists.

Graph ingestion accepts only kind 3, keeps one event per author, and
replaces that author's follows with it, so each author's newest list of
every configured kind is merged into one follow set before ingestion.
The graph bootstrap signature records the kinds; graphs built before
this change are treated as kind-3-only and reused with the default.
…sults

relay.nostr.net never finishes a negentropy sync whose filter lists
several kinds, so with FOLLOW_LIST_KINDS=3,10020 most graph batches hit
the 30s timeout. Sync one kind per filter instead, and return the events
already received when a sync is aborted rather than discarding them.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant