graph

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2024 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const NOTE_NODE_VAL = 1

Variables

This section is empty.

Functions

func SerializeGraph

func SerializeGraph(keywordMap map[string]keywords.Keyword, notes []notes.Note) ([]byte, error)

Types

type Graph

type Graph struct {
	Nodes []NodeJSON `json:"nodes"`
	Links []LinkJSON `json:"links"`
}

type LinkJSON

type LinkJSON struct {
	Source string  `json:"source"`
	Target string  `json:"target"`
	Value  float64 `json:"strength"`
	Color  string  `json:"color"`
}

type NodeJSON

type NodeJSON struct {
	ID    string  `json:"id"`
	Name  string  `json:"name"`
	Group string  `json:"group"`
	Val   float64 `json:"val"`
}

FIX: calculate document weight with non-partial bm25f, use that to define node size

Jump to

Keyboard shortcuts

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