hints

package
v0.44.0 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const END_OF_WORLD nostr.Timestamp = 2208999600 // 2040-01-01

Variables

View Source
var KeyBasePoints = [7]int64{
	-500,
	700,
	350,
	5,
	22,
	8,
	7,
}

Functions

This section is empty.

Types

type HintKey

type HintKey int
const (
	LastFetchAttempt HintKey = iota
	MostRecentEventFetched
	LastInRelayList
	LastInTag
	LastInNprofile
	LastInNevent
	LastInNIP05
)

func (HintKey) BasePoints

func (hk HintKey) BasePoints() int64

func (HintKey) String

func (hk HintKey) String() string

type HintsDB

type HintsDB interface {
	TopN(pubkey string, n int) []string
	Save(pubkey string, relay string, key HintKey, score nostr.Timestamp)
	PrintScores()
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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