Skip to main content

Module engine

Module engine 

Source
Expand description

Pluggable inference engines, generalised to all task kinds.

The synthetic engine produces real, decodable bytes for every kind and is the default — it’s what unattended CI exercises end-to-end.

Real high-performance engines (llama.cpp, whisper.cpp, candle SD, Piper, ffmpeg) live behind cargo features so the default build stays small and the CI matrix stays fast. See the feature notes per implementation block below.

Modules§

multi
Composite engine that delegates per task kind.

Structs§

EngineCapabilities
What a single engine is able to do.
GradioEngine
SyntheticEngine

Traits§

Engine

Functions§

build
default_models_root
Default cache dir for downloaded model files.
render_animated_webp
Synthetic “video”: an animated WebP made of frames frames. We always emit WebP (decoders are everywhere); real video generation would use the video-ffmpeg feature.
render_procedural
Deterministic 512×512 image whose colours depend on hash(prompt).
render_wav
Real WAV file (16-bit PCM, mono, 22 050 Hz) — sine wave whose frequency depends on hash(text). Duration is 1.0 s.
synthetic_llm_response
Synthetic LLM response — deterministic by prompt hash, mimics the OpenAI chat-completion response shape so consumers can parse it.
synthetic_stt_response
Synthetic STT response — Whisper-style JSON.