Closed zacfire closed 3 months ago
In WhisperKit
there are 2 methods with the same arguments but different return type
func transcribe(audioPath:decodeOptions:callback:) async throws -> TranscriptionResult?
func transcribe(audioPath:decodeOptions:callback:) async throws -> [TranscriptionResult]
The 1st one is deprecated and is subject to removal in a future version.
To suppress the warning, please specify the return type explicitly, e.g.
// ...
let whisper = try await WhisperKit()
let results: [TranscriptionResult] = try await whisper.transcribe(audioPath: audioPath)
// ...
Looking into what changes we can do to reduce the ambiguous errors here, good callout
@zacfire Please pull the latest and try it out with the changes from #143 thanks to @jkrukowski (it should allow your current code to work without ambiguity errors)
i try many way, but still show:Ambiguous use of 'transcribe(audioPath:decodeOptions:callback:)
Here is code: