feat(transcription): add multilingual/language fields to ModelInfo+Settings (T8.7, M4.2)
This commit is contained in:
1 parent
e966181ab8
commit
6bc0949e7e
1 file changed
+22
@@ -45,6 +45,19 @@ pub struct ModelInfo {
|
||||
pub size_mb: u32, // approximate download size
|
||||
pub installed: bool,
|
||||
pub active: bool,
|
||||
/// `false` for the `.en` (English-only) ggml variants; `true` for the
|
||||
/// multilingual variants (no `.en` suffix, T8.7/FR-TRX-4/M4.2) — gates
|
||||
/// whether the Settings language picker is enabled for this model.
|
||||
pub multilingual: bool,
|
||||
}
|
||||
|
||||
/// One selectable transcription language (T8.7, FR-TRX-4) — ISO-639-1 code
|
||||
/// (as accepted by `whisper_rs::FullParams::set_language`) plus a display
|
||||
/// label for the Settings dropdown.
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
pub struct LanguageOption {
|
||||
pub code: String,
|
||||
pub label: String,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Copy, Serialize, Deserialize, PartialEq, Eq)]
|
||||
@@ -198,6 +211,15 @@ pub struct Settings {
|
||||
pub llm_advanced: serde_json::Value,
|
||||
pub preferred_backend: String, // auto|npu|nvidia|amd|intel|cpu
|
||||
pub whisper_model: String, // ModelInfo.id, e.g. "base.en-q5_1"
|
||||
/// Global default transcription language (T8.7, FR-TRX-4): `None`/`"auto"`
|
||||
/// lets whisper.cpp auto-detect; an ISO-639-1 code (e.g. "es") forces
|
||||
/// that language. Only takes effect with a multilingual model loaded —
|
||||
/// an English-only (`.en`) model always decodes English regardless of
|
||||
/// this setting (see `transcription::resolve_language`). Each meeting
|
||||
/// persists whatever was actually used at `Meeting.language`, so this is
|
||||
/// just the default applied at the next `start_recording`.
|
||||
#[serde(default)]
|
||||
pub whisper_language: Option<String>,
|
||||
pub low_overhead: bool,
|
||||
// Recording retention (ADR-0009). Default OFF.
|
||||
pub default_record: bool,
|
||||
|
||||
Reference in new issue
Block a user