sim-lib-openai-server 0.1.3

OpenAI-compatible gateway skeleton for SIM.
Documentation
1
2
3
4
5
6
7
8
9
10
11
use sim_kernel::{Cx, Result};

use crate::manifest::OpenAiGatewayLib;

/// Installs the OpenAI gateway library into the context, idempotently.
///
/// Registers [`OpenAiGatewayLib`] via `install_once`, so repeated calls on the
/// same context are no-ops after the first.
pub fn install_openai_gateway_lib(cx: &mut Cx) -> Result<()> {
    sim_lib_core::install_once(cx, &OpenAiGatewayLib).map(|_| ())
}