score

package
v0.2.5 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BoostBestResult

func BoostBestResult(nr *bhl.RefsByName, nb bayes.Bayes) error

BoostBestResult provides additional score for the best result in NameRefs.

func NewAnnot

func NewAnnot(annot string) annotation

NewAnnot coverts annotation string to annotation type (if possible).

Types

type Score

type Score interface {
	fmt.Stringer
	// Calculate calculates scores for a given set using heuristic and
	// machine learning methods.
	Calculate(*bhl.RefsByName, ttlmch.TitleMatcher, bayes.Bayes, bool) error
}

Score interface provides methods to calculate scores that is used to rank matching quality of BHL metadata to provided publication references.

func New

func New(prec map[ScoreType]int) Score

type ScoreType

type ScoreType int
const (
	Year ScoreType = iota
	Annot
	RefTitle
	RefVolume
	RefPages
)

Jump to

Keyboard shortcuts

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