Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager allows easy handling of multiple translation models.
func NewManager ¶
func NewManager(config *configuration.Config, logger zerolog.Logger) *Manager
NewManager creates a new Manager.
func (*Manager) GetModel ¶
GetModel returns a Model for translating texts from the given source language to the given target language. It also reports whether a model for that pair or languages is present (previously loaded).
func (*Manager) LoadModels ¶
LoadModels loads all models according to the configuration. If a model path is not found, automatic download and conversion are performed using spaGO huggingface Downloader and Converter.
type Model ¶
type Model struct {
// contains filtered or unexported fields
}
Model provides high-level functionalities for loading spaGO models and performing automatic translation.
Click to show internal directories.
Click to hide internal directories.