pub type CrispasrChatOnToken = Option<unsafe extern "C" fn(utf8_chunk: *const c_char, user: *mut c_void)>;Expand description
Fired once per detokenised UTF-8 chunk during a streaming generate. The
chunk pointer is valid only for the duration of the call.
Option<...> so a null pointer clears the callback (C NULL).
Aliased Type§
pub enum CrispasrChatOnToken {
None,
Some(unsafe extern "C" fn(*const i8, *mut c_void)),
}