gg_dbal_semantic_search

package
v0.3.71 Latest Latest
Warning

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

Go to latest
Published: May 17, 2025 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	COLLECTION = "elastic_search_indexed"

	FLD_DBKEY  = "_key"
	FLD_KEY    = "key"
	FLD_GROUP  = "group"
	FLD_ENTITY = "entity"
	FLD_TAGS   = "tags"

	ANALYZER_LOWER = "semantic_lowercase"
)

Variables

This section is empty.

Functions

func ToKeywords

func ToKeywords(text string) []string

Types

type SemanticEngine

type SemanticEngine struct {
	// contains filtered or unexported fields
}

func NewSemanticEngine

func NewSemanticEngine(config *gg_dbal_commons.SemanticConfig) (*SemanticEngine, error)

func (*SemanticEngine) Get

func (instance *SemanticEngine) Get(group, text string, offset, count int) ([]*SemanticEngineData, error)

func (*SemanticEngine) IsCaseSensitive

func (instance *SemanticEngine) IsCaseSensitive() bool

func (*SemanticEngine) Put

func (instance *SemanticEngine) Put(group, key, text string) error

type SemanticEngineData

type SemanticEngineData struct {
	Score  int                    `json:"score"`
	Key    string                 `json:"key"`
	Group  string                 `json:"group"`
	Entity map[string]interface{} `json:"entity"`
}

Jump to

Keyboard shortcuts

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