Skip to content

[Bug] Audio task accept headers are not respected #351

Open
@StephenHodgson

Description

@StephenHodgson

Is your feature request related to a problem? Please describe.
When settings accept headers to audio/wav or audio/mp3 when making requests to audio inference tasks using api-inference-community 0.0.32+, the returned audio file is still encoded as flac.

Describe the solution you'd like
accept headers respect the types that the client can understand.

Additional context
This is to unblock support for audio tasks in Unity game engine for upcoming hackathon.

I've tried the following tasks | models:

  • text-to-speech | speechbrain/tts-tacotron2-ljspeech
  • text-to-speech | espnet/kan-bayashi_ljspeech_vits
  • audio-to-audio | speechbrain/sepformer-wham

I suspect that the accept headers for images likely also suffer from the same issue, but have not tested.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions