Documentation ¶
Overview ¶
Package textkit provides helpers to normalize and process text.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NormalizeHTMLToText ¶
Types ¶
type TextRanker ¶
type TextRanker struct {
// contains filtered or unexported fields
}
A TextRanker normalizes and processes text to extract the top ranking phrases and keywords.
func NewTextRanker ¶
func NewTextRanker() *TextRanker
NewTextRanker initializes and returns a new TextRanker.
func (*TextRanker) RankTopNPhrases ¶
func (t *TextRanker) RankTopNPhrases(text string, topN int) []string
RankTopNPhrases extracts the top N ranking phrases using TextRank.
func (*TextRanker) RankTopNWords ¶
func (t *TextRanker) RankTopNWords(text string, topN int) []string
Click to show internal directories.
Click to hide internal directories.