> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fluidinference.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Audio Conversion

> Convert any audio format to 16 kHz mono Float32 for FluidAudio pipelines.

## Overview

Most FluidAudio features expect 16 kHz mono Float32 samples. `AudioConverter` uses `AVAudioConverter` under the hood for sample-rate conversion, format conversion (e.g., Int16 → Float32), and channel mixing (stereo → mono).

## File Conversion

```swift theme={null}
import FluidAudio

let converter = AudioConverter()
let samples = try converter.resampleAudioFile(path: "path/to/audio.wav")
// samples: [Float] at 16 kHz mono
```

Supported inputs: WAV, M4A, MP3, FLAC — anything readable by `AVAudioFile`.

## Streaming Conversion

```swift theme={null}
let converter = AudioConverter()

func processChunk(_ pcmBuffer: AVAudioPCMBuffer) async throws {
    let samples = try converter.resampleBuffer(pcmBuffer)
    // Feed samples to ASR/VAD/diarization
}
```

Each conversion is stateless — reuse the same converter instance across formats.
