Documentation
¶
Overview ¶
Package litertlmgo is the module root for litertlm-go.
Consumers import the actual Go API from the subpackages:
import "github.com/vladimirvivien/litertlm-go/pkg/litertlm" import "github.com/vladimirvivien/litertlm-go/pkg/loader"
See README.md for the full usage guide and LITERTLM-BUILD.md for the native-library build recipe.
Directories
¶
| Path | Synopsis |
|---|---|
|
examples
|
|
|
chat
command
chat demonstrates the higher-level Conversation API with multi-turn JSON messages.
|
chat demonstrates the higher-level Conversation API with multi-turn JSON messages. |
|
conversation
command
conversation showcases the full Conversation API: system prompt + declared tools + structured tool_calls in the assistant reply + tool-role response message.
|
conversation showcases the full Conversation API: system prompt + declared tools + structured tool_calls in the assistant reply + tool-role response message. |
|
gpu
command
gpu demonstrates GPU-accelerated local inference plus BenchmarkInfo readout (init time, time-to-first-token, prefill/decode throughput).
|
gpu demonstrates GPU-accelerated local inference plus BenchmarkInfo readout (init time, time-to-first-token, prefill/decode throughput). |
|
hello
command
hello demonstrates a minimal synchronous inference with litertlm-go using the low-level Session API.
|
hello demonstrates a minimal synchronous inference with litertlm-go using the low-level Session API. |
|
stream
command
stream demonstrates token-by-token streaming generation using a Go channel.
|
stream demonstrates token-by-token streaming generation using a Go channel. |
|
pkg
|
|
|
litertlm
Package litertlm is a purego-backed, cgo-free Go wrapper around Google's LiteRT-LM C API (see c/engine.h in the LiteRT-LM repository).
|
Package litertlm is a purego-backed, cgo-free Go wrapper around Google's LiteRT-LM C API (see c/engine.h in the LiteRT-LM repository). |
|
loader
Package loader resolves and loads the LiteRT-LM native shared library.
|
Package loader resolves and loads the LiteRT-LM native shared library. |
|
utils
Package utils provides platform-abstracted helpers for marshalling strings across the Go/C FFI boundary.
|
Package utils provides platform-abstracted helpers for marshalling strings across the Go/C FFI boundary. |
Click to show internal directories.
Click to hide internal directories.