Documentation
¶
Overview ¶
Package mobile provides gomobile-compatible bindings for zerfoo inference.
All exported types use only gomobile-safe types (no slices, maps, or channels). Token IDs from Tokenize are returned as a JSON-encoded string.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Engine ¶
type Engine struct {
// contains filtered or unexported fields
}
Engine is an opaque handle to a loaded GGUF model. It wraps inference.Model and exposes a gomobile-safe API.
func (*Engine) Generate ¶
Generate produces text from the given prompt using default sampling parameters.
func (*Engine) GenerateWithConfig ¶
func (e *Engine) GenerateWithConfig(prompt string, config *GenerateConfig) (string, error)
GenerateWithConfig produces text using the provided sampling configuration.
Click to show internal directories.
Click to hide internal directories.