Files
OSGKeyboard/OSGKeyboard/ThirdParty/Qwen3Speech/Sources/Qwen3Chat/Qwen3ChatError.swift
T
Rocky df1c5ff32c feat: migrate on-device Qwen3 ASR to CoreML for background Flow dictation
Replace MLX GPU inference with CoreML bundles so transcription continues
while the host app is backgrounded. Adds model download and warm-up,
vendored Qwen3Speech, and updates onboarding, settings, and copy for the
~1.6 GB CoreML package (iOS 18+).
2026-06-23 00:46:58 +08:00

26 lines
798 B
Swift

import Foundation
/// Errors for Qwen3.5 chat model operations.
public enum ChatModelError: LocalizedError {
case modelLoadFailed(String)
case tokenizerLoadFailed(String)
case inferenceFailed(String)
case configNotFound(URL)
case modelNotFound(URL)
public var errorDescription: String? {
switch self {
case .modelLoadFailed(let reason):
"Failed to load chat model: \(reason)"
case .tokenizerLoadFailed(let reason):
"Failed to load tokenizer: \(reason)"
case .inferenceFailed(let reason):
"Inference failed: \(reason)"
case .configNotFound(let url):
"Config not found at \(url.path)"
case .modelNotFound(let url):
"Model not found at \(url.path)"
}
}
}