//! Serving-support library for the `lfm2-serve` binary (feature `server`).
//!
//! The binary is deliberately thin — `main`, the axum handlers, the engine threads — while the
//! reusable, pure logic lives here so it is unit-testable without a GPU or a live server:
//!
//! - [`types`] — OpenAI wire structs and the [`types::CommonParams`] validation that range-checks
//! inputs and rejects unimplemented features with a typed error.
//! - [`error`] — the [`error::ApiError`] OpenAI error envelope (`{"error":{…}}`).
//! - [`chat`] — architecture-based chat templating ([`chat::render_chat_prompt`]).
//! - [`tools`] — portable tool-call advertisement and extraction ([`tools::parse_tool_calls`]).
//! - [`stop`] — stop-sequence scanning and streaming hold-back ([`stop::first_stop`]).
pub use ApiError;