depot/third_party/nixpkgs/pkgs/tools/audio/wyoming/faster-whisper.nix
Default email c7cb07f092 Project import generated by Copybara.
GitOrigin-RevId: 1536926ef5621b09bba54035ae2bb6d806d72ac8
2024-02-29 21:09:43 +01:00

55 lines
1.1 KiB
Nix

{ lib
, python3
, fetchFromGitHub
, fetchpatch
}:
python3.pkgs.buildPythonApplication rec {
pname = "wyoming-faster-whisper";
version = "1.1.0";
pyproject = true;
src = fetchFromGitHub {
owner = "rhasspy";
repo = "wyoming-faster-whisper";
rev = "refs/tags/v${version}";
hash = "sha256-RD6J/Q7kvd+sgTpR6ERyV+D8gpm0fF38L3U/Jp7gOgk=";
};
patches = [
(fetchpatch {
# fix setup.py
url = "https://github.com/rhasspy/wyoming-faster-whisper/commit/cdd1536997a091dcf9054da9ff424a2603067755.patch";
hash = "sha256-LGYo21FhKGXcAN9DjXzwIRqkOzTz3suXiQdgGrJSDBw=";
})
];
nativeBuildInputs = with python3.pkgs; [
setuptools
pythonRelaxDepsHook
];
pythonRelaxDeps = [
"wyoming"
];
propagatedBuildInputs = with python3.pkgs; [
ctranslate2
tokenizers
wyoming
];
pythonImportsCheck = [
"wyoming_faster_whisper"
];
# no tests
doCheck = false;
meta = with lib; {
description = "Wyoming Server for Faster Whisper";
homepage = "https://github.com/rhasspy/wyoming-faster-whisper";
license = licenses.mit;
maintainers = with maintainers; [ hexa ];
};
}