Skip to main content

Module llm

Module llm 

Source
Expand description

LLM provider abstraction.

A provider takes a transcript plus tool specs and returns either free-form content, structured tool calls, or both. The trait is the only thing the agent depends on; everything beyond it (HTTP, retries, mocking) lives in adapters.

Re-exports§

pub use mock::MockProvider;
pub use openai::OpenAiProvider;

Modules§

mock
Deterministic LLM for tests and offline development.
openai
OpenAI-compatible chat-completions adapter.

Structs§

Completion
One step of model output.
ToolCall
A structured request to invoke one of the registered tools.
ToolSpec
JSON-schema description of a tool, sent verbatim to the model.

Traits§

LlmProvider