openvino-genai-sys 0.11.0

Low-level bindings for OpenVINO GenAI (use the `openvino-genai` crate for easier-to-use bindings).
Documentation
/* automatically generated by rust-bindgen 0.72.0 */

#[repr(u32)]
#[doc = " @brief controls the stopping condition for grouped beam search. The following values are possible:\n        \"EARLY\" stops as soon as there are `num_beams` complete candidates.\n\"HEURISTIC\" stops when is it unlikely to find better candidates.\n\"NEVER\" stops when there cannot be better candidates."]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum StopCriteria {
    EARLY = 0,
    HEURISTIC = 1,
    NEVER = 2,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_generation_config_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_generation_config\n @brief type define ov_genai_generation_config from ov_genai_generation_config_opaque"]
pub type ov_genai_generation_config = ov_genai_generation_config_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_perf_metrics_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_perf_metrics\n @brief type define ov_genai_perf_metrics from ov_genai_perf_metrics_opaque."]
pub type ov_genai_perf_metrics = ov_genai_perf_metrics_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_json_container_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_json_container\n @brief Opaque type for JsonContainer"]
pub type ov_genai_json_container = ov_genai_json_container_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_chat_history_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_chat_history\n @brief Opaque type for ChatHistory"]
pub type ov_genai_chat_history = ov_genai_chat_history_opaque;
#[repr(i32)]
#[doc = " @brief Status codes for chat history operations"]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum ov_genai_chat_history_status_e {
    OV_GENAI_CHAT_HISTORY_OK = 0,
    OV_GENAI_CHAT_HISTORY_INVALID_PARAM = -1,
    OV_GENAI_CHAT_HISTORY_OUT_OF_BOUNDS = -2,
    OV_GENAI_CHAT_HISTORY_EMPTY = -3,
    OV_GENAI_CHAT_HISTORY_INVALID_JSON = -4,
    OV_GENAI_CHAT_HISTORY_ERROR = -5,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_decoded_results_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_decoded_results\n @brief type define ov_genai_decoded_results from ov_genai_decoded_results_opaque"]
pub type ov_genai_decoded_results = ov_genai_decoded_results_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_llm_pipeline_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_llm_pipeline\n @brief type define ov_genai_llm_pipeline from ov_genai_llm_pipeline_opaque\n @return ov_status_e A status code, return OK(0) if successful."]
pub type ov_genai_llm_pipeline = ov_genai_llm_pipeline_opaque;
#[repr(u32)]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum ov_genai_streaming_status_e {
    OV_GENAI_STREAMING_STATUS_RUNNING = 0,
    OV_GENAI_STREAMING_STATUS_STOP = 1,
    OV_GENAI_STREAMING_STATUS_CANCEL = 2,
}
#[doc = " @brief Structure for streamer callback functions with arguments.\n\n The callback function takes two parameters:\n - `const char* str`: A constant string extracted from the decoded result for processing\n - `void* args`: A pointer to additional arguments, allowing flexible data passing."]
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct streamer_callback {
    #[doc = "!< Pointer to the callback function"]
    pub callback_func: ::std::option::Option<
        unsafe extern "C" fn(
            str_: *const ::std::os::raw::c_char,
            args: *mut ::std::os::raw::c_void,
        ) -> ov_genai_streaming_status_e,
    >,
    #[doc = "!< Pointer to the arguments passed to the callback function"]
    pub args: *mut ::std::os::raw::c_void,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of streamer_callback"][::std::mem::size_of::<streamer_callback>() - 16usize];
    ["Alignment of streamer_callback"][::std::mem::align_of::<streamer_callback>() - 8usize];
    ["Offset of field: streamer_callback::callback_func"]
        [::std::mem::offset_of!(streamer_callback, callback_func) - 0usize];
    ["Offset of field: streamer_callback::args"]
        [::std::mem::offset_of!(streamer_callback, args) - 8usize];
};
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_vlm_decoded_results_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_vlm_decoded_results\n @brief type define ov_genai_vlm_decoded_results from ov_genai_vlm_decoded_results_opaque"]
pub type ov_genai_vlm_decoded_results = ov_genai_vlm_decoded_results_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_vlm_pipeline_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_vlm_pipeline\n @brief type define ov_genai_vlm_pipeline from ov_genai_vlm_pipeline_opaque"]
pub type ov_genai_vlm_pipeline = ov_genai_vlm_pipeline_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_whisper_generation_config_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_whisper_generation_config\n @brief type define ov_genai_whisper_generation_config from ov_genai_whisper_generation_config_opaque"]
pub type ov_genai_whisper_generation_config = ov_genai_whisper_generation_config_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_whisper_decoded_result_chunk_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_whisper_decoded_result_chunk\n @brief type define ov_genai_whisper_decoded_result_chunk from ov_genai_whisper_decoded_result_chunk_opaque"]
pub type ov_genai_whisper_decoded_result_chunk = ov_genai_whisper_decoded_result_chunk_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_whisper_decoded_results_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_whisper_decoded_results\n @brief type define ov_genai_whisper_decoded_results from ov_genai_whisper_decoded_results_opaque"]
pub type ov_genai_whisper_decoded_results = ov_genai_whisper_decoded_results_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ov_genai_whisper_pipeline_opaque {
    _unused: [u8; 0],
}
#[doc = " @struct ov_genai_whisper_pipeline\n @brief type define ov_genai_whisper_pipeline from ov_genai_whisper_pipeline_opaque"]
pub type ov_genai_whisper_pipeline = ov_genai_whisper_pipeline_opaque;
#[repr(i32)]
#[doc = " @brief Status codes for JsonContainer operations"]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum ov_genai_json_container_status_e {
    OV_GENAI_JSON_CONTAINER_OK = 0,
    OV_GENAI_JSON_CONTAINER_INVALID_PARAM = -1,
    OV_GENAI_JSON_CONTAINER_INVALID_JSON = -2,
    OV_GENAI_JSON_CONTAINER_OUT_OF_BOUNDS = -3,
    OV_GENAI_JSON_CONTAINER_ERROR = -4,
}