Exposing GGMLLogLevel for custom log callbacks (#203)

* Made GGMLLogLevel public
This commit is contained in:
Martin Mende 2025-02-21 23:23:21 +01:00 committed by GitHub
parent d57171554a
commit 54799643e2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

View file

@ -52,7 +52,7 @@ pub(crate) use {generic_debug, generic_error, generic_info, generic_trace, gener
// Of course Windows thinks it's a special little shit and // Of course Windows thinks it's a special little shit and
// picks a signed integer for an unsigned type // picks a signed integer for an unsigned type
#[cfg_attr(all(windows, not(target_env = "gnu")), repr(i32))] #[cfg_attr(all(windows, not(target_env = "gnu")), repr(i32))]
pub(crate) enum GGMLLogLevel { pub enum GGMLLogLevel {
None = whisper_rs_sys::ggml_log_level_GGML_LOG_LEVEL_NONE, None = whisper_rs_sys::ggml_log_level_GGML_LOG_LEVEL_NONE,
Info = whisper_rs_sys::ggml_log_level_GGML_LOG_LEVEL_INFO, Info = whisper_rs_sys::ggml_log_level_GGML_LOG_LEVEL_INFO,
Warn = whisper_rs_sys::ggml_log_level_GGML_LOG_LEVEL_WARN, Warn = whisper_rs_sys::ggml_log_level_GGML_LOG_LEVEL_WARN,

View file

@ -13,6 +13,7 @@ mod whisper_logging_hook;
mod whisper_params; mod whisper_params;
mod whisper_state; mod whisper_state;
pub use common_logging::GGMLLogLevel;
pub use error::WhisperError; pub use error::WhisperError;
pub use standalone::*; pub use standalone::*;
pub use utilities::*; pub use utilities::*;