Expand description
An authenticated, explicitly exposed HTTP front end for a loqui
Engine, speaking the OpenAI audio API.
The defaults are the narrow ones:
- It listens on a Unix socket in
$XDG_RUNTIME_DIR(mode 0600, in a 0700 directory) and accepts only processes running as the same user. TCP must be asked for, and network-wide TCP must be asked for twice. SeeListen. - Every TCP request needs a bearer token, loopback included. With none
configured, one is generated and stored with mode 0600. See
auth. - Requests from web pages (anything carrying
Origin) are refused, TCP requests must name an expectedHost, and there is no CORS. - Bodies, text length, audio length, queue depth, header arrival and request time are all bounded.
SECURITY.md describes the exposure model in full, and Embedding loqui safely covers choosing a listener and tokens.
Re-exports§
pub use listen::Acknowledgements;pub use listen::Listen;
Modules§
- api
- The OpenAI-compatible routes.
- auth
- Bearer tokens.
- fs
- Private files and the default places loqui keeps them.
- listen
- Where the server listens, and the rules for each choice.
- policy
- Who may call what: authentication, browser refusal, Host checking.
Structs§
- Server
- A server ready to run: bound, with its tokens resolved.
- Server
Config - Everything about how the server is exposed.