wot

package
v1.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 29, 2026 License: Unlicense Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Contains added in v1.3.2

func Contains(pubkey nostr.PubKey) bool

Contains reports whether the given pubkey is in the latest aggregated WoT. It is safe to call at any time, even before the first computation (it will just return false).

func Count added in v1.3.2

func Count() int

Count returns the number of pubkeys in the latest aggregated WoT.

func IsComputed added in v1.3.2

func IsComputed() bool

IsComputed reports whether the WoT has been computed at least once.

func StartBackgroundComputation

func StartBackgroundComputation()

StartBackgroundComputation begins a periodic background loop that recomputes the aggregated WoT every 48 hours. It sleeps 2 minutes before the first computation to let the system stabilise.

Types

type XorFilter

type XorFilter struct {
	Items int
	xorfilter.Xor8
}

func ComputeAggregated

func ComputeAggregated(ctx context.Context) (XorFilter, error)

ComputeAggregated computes the aggregated web-of-trust filter for all pyramid members: it fetches the follow lists of all members, then the follow lists of all those followed pubkeys, and builds a xor filter from the full set.

func (XorFilter) Contains

func (f XorFilter) Contains(pubkey nostr.PubKey) bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL