Versions in this module Expand all Collapse all v0 v0.9.2 Jun 20, 2026 Changes in this version + func AddDic(gs *GoSpell, name string, paths []string) error type GoSpell + func (g *GoSpell) AddDictionaryFile(dicFile string) error + func (g *GoSpell) AddDictionaryReader(dic io.Reader) error v0.9.1 Jun 15, 2026 Changes in this version type MutationOptions + NGramRootCap int v0.9.0 Jun 14, 2026 Changes in this version + func SearchPaths() []string + type Checker struct + func NewChecker(base *GoSpell) *Checker + func (c *Checker) AddWordList(wl *WordList) + func (c *Checker) InputConversion(raw []byte) string + func (c *Checker) RemoveWordList(wl *WordList) + func (c *Checker) Spell(word string) bool + func (c *Checker) Suggest(word string, limit int) ([]Suggestion, error) + type GoSpell struct + func NewGoSpell(affFile, dicFile string) (*GoSpell, error) + func NewGoSpellReader(aff, dic io.Reader) (*GoSpell, error) + func Open(name string, paths []string) (*GoSpell, error) + func (s *GoSpell) AddWordRaw(word string) bool + func (s *GoSpell) ForEachWord(fn func(word string) bool) + func (s *GoSpell) HasWord(word string) bool + func (s *GoSpell) InputConversion(raw []byte) string + func (s *GoSpell) MaxWordLen() int + func (s *GoSpell) SetSuggester(suggester Suggestions) error + func (s *GoSpell) Spell(word string) bool + func (s *GoSpell) Suggest(word string, limit int) ([]Suggestion, error) + func (s *GoSpell) WordCount() int + type LevenshteinOptions struct + MaxDistance int + type LevenshteinSuggester struct + func NewLevenshteinSuggester(opts LevenshteinOptions) *LevenshteinSuggester + func (s *LevenshteinSuggester) Init(src SuggestionSource) error + func (s *LevenshteinSuggester) Suggest(word string, limit int) ([]Suggestion, error) + type MutationOptions struct + CandidateCap int + type MutationSuggester struct + func NewMutationSuggester(opts MutationOptions) *MutationSuggester + func (s *MutationSuggester) Init(src SuggestionSource) error + func (s *MutationSuggester) Suggest(word string, limit int) ([]Suggestion, error) + type Suggestion struct + Score int + Word string + type SuggestionSource interface + ForEachWord func(func(word string) bool) + HasWord func(word string) bool + MaxWordLen func() int + WordCount func() int + type Suggestions interface + Init func(src SuggestionSource) error + Suggest func(word string, limit int) ([]Suggestion, error) + type SymSpellOptions struct + MaxDistance int + PrefixLength int + type SymSpellSuggester struct + func NewSymSpellSuggester(opts SymSpellOptions) *SymSpellSuggester + func (s *SymSpellSuggester) Init(src SuggestionSource) error + func (s *SymSpellSuggester) Suggest(word string, limit int) ([]Suggestion, error) + type TrigramOptions struct + MaxLengthDiff int + RerankLimit int + type TrigramSuggester struct + func NewTrigramSuggester(opts TrigramOptions) *TrigramSuggester + func (s *TrigramSuggester) Init(src SuggestionSource) error + func (s *TrigramSuggester) Suggest(word string, limit int) ([]Suggestion, error) + type WordList struct + func NewWordList(r io.Reader) (*WordList, error) + func NewWordListFile(name string) (*WordList, error) + func NewWordListFromDic(r io.Reader) (*WordList, error) + func OpenSupplement(name string, paths []string) (*WordList, error) + func (wl *WordList) Add(word string) + func (wl *WordList) Forbid(word string) + func (wl *WordList) HasWord(word string) bool + func (wl *WordList) IsForbidden(word string) bool